Class ControlsParameters

java.lang.Object
sc.iview.controls.behaviours.ControlsParameters

public class ControlsParameters extends Object
A container to hold movement step sizes and mouse sensitivity parameters, these shall not be duplicated elsewhere in SciView. It serves three purposes: 1) hold and manage the said parameters 2) provide their current values (mostly to SciView's internal objects) 3) updates registered (scenery's) services immediately whenever any parameter changes Inside-package controls, such as NodeTranslateControl, read out this whenever they are invoked to get current state. Outside-package controls, currently only MovementCommand, ArcballCameraControl, and FPSCameraControl, that have own memory of the same-purposed attributes are synchronized here as long as they are registered here. This way, caller needs to adjusts e.g. mouse movement sensitivity only here, and not explicitly at all relevant controls.
  • Field Details

    • DEFAULT_FPS_SPEED_SLOW

      public static final float DEFAULT_FPS_SPEED_SLOW
      See Also:
    • DEFAULT_FPS_SPEED_FAST

      public static final float DEFAULT_FPS_SPEED_FAST
      See Also:
    • DEFAULT_FPS_SPEED_VERY_FAST

      public static final float DEFAULT_FPS_SPEED_VERY_FAST
      See Also:
    • DEFAULT_MOUSE_SPEED_MULT

      public static final float DEFAULT_MOUSE_SPEED_MULT
      See Also:
    • DEFAULT_MOUSE_SCROLL_MULT

      public static final float DEFAULT_MOUSE_SCROLL_MULT
      See Also:
  • Constructor Details

    • ControlsParameters

      public ControlsParameters()
    • ControlsParameters

      public ControlsParameters(graphics.scenery.controls.behaviours.ArcballCameraControl arcballCamCntrl, graphics.scenery.controls.behaviours.FPSCameraControl fpsCamCntrl)
      One can optionally register scenery's ArcballCameraControl and FPSCameraControl to be notified of changes. Any of the params may be null.
  • Method Details

    • registerArcballCameraControl

      public void registerArcballCameraControl(graphics.scenery.controls.behaviours.ArcballCameraControl arcballCamCntrl)
      Registers the scenery's ArcballCameraControl to be synchronized with this module. Provide null to unregister, to disable the synchronization.
    • unregisterArcballCameraControl

      public void unregisterArcballCameraControl()
    • registerFpsCameraControl

      public void registerFpsCameraControl(graphics.scenery.controls.behaviours.FPSCameraControl fpsCamCntrl)
      Registers the scenery's FPSCameraControl to be synchronized with this module. Provide null to unregister, to disable the synchronization.
    • unregisterFpsCameraControl

      public void unregisterFpsCameraControl()
    • registerSlowStepMover

      public void registerSlowStepMover(graphics.scenery.controls.behaviours.MovementCommand movementCommand)
    • registerFastStepMover

      public void registerFastStepMover(graphics.scenery.controls.behaviours.MovementCommand movementCommand)
    • registerVeryFastStepMover

      public void registerVeryFastStepMover(graphics.scenery.controls.behaviours.MovementCommand movementCommand)
    • unregisterSlowStepMover

      public void unregisterSlowStepMover(graphics.scenery.controls.behaviours.MovementCommand movementCommand)
    • unregisterFastStepMover

      public void unregisterFastStepMover(graphics.scenery.controls.behaviours.MovementCommand movementCommand)
    • unregisterVeryFastStepMover

      public void unregisterVeryFastStepMover(graphics.scenery.controls.behaviours.MovementCommand movementCommand)
    • setFPSSpeedSlow

      public void setFPSSpeedSlow(float fpsSpeedSlow)
    • setFPSSpeedFast

      public void setFPSSpeedFast(float fpsSpeedFast)
    • setFPSSpeedVeryFast

      public void setFPSSpeedVeryFast(float fpsSpeedVeryFast)
    • setMouseSpeedMult

      public void setMouseSpeedMult(float mouseSpeedMult)
    • setMouseScrollMult

      public void setMouseScrollMult(float mouseScrollMult)
    • reset

      public void reset()
    • getFPSSpeedSlow

      public float getFPSSpeedSlow()
    • getFPSSpeedFast

      public float getFPSSpeedFast()
    • getFPSSpeedVeryFast

      public float getFPSSpeedVeryFast()
    • getMouseSpeedMult

      public float getMouseSpeedMult()
    • getMouseScrollMult

      public float getMouseScrollMult()