WPI-AIM / ambf

Asynchronous Multi-Body Framework
163 stars 67 forks source link

Mouse control multipliers fix #226

Closed adnanmunawar closed 10 months ago

adnanmunawar commented 10 months ago

With this PR, users can set optional mouse control multipliers in the relevant camera description in the ADF files. These multipliers are camera-specific, and any specifier is optional. For example:


cameras: [camera1, camera2]

camera1:
  namespace: cameras/
  name: cam1
  location: {x: 4.0, y: 0.0, z: 2.0}
  look at: {x: 0.0, y: 0.0, z: -0.5}
  up: {x: 0.0, y: 0.0, z: 1.0}
  clipping plane: {near: 0.1, far: 10.0}
  field view angle: 0.8
  monitor: 0
  mouse control multipliers: {pan: 1.0, rotate: 1.0, scroll: 1.0, arcball: 1.0} # <--- All Optional multipliers set

camera2:
  namespace: cameras/
  name: cam2
  location: {x: 4.0, y: 0.0, z: 2.0}
  look at: {x: 0.0, y: 0.0, z: -0.5}
  up: {x: 0.0, y: 0.0, z: 1.0}
  clipping plane: {near: 0.1, far: 10.0}
  field view angle: 0.8
  monitor: 0
  mouse control multipliers: {pan: 1.0, arcball: 10.0} # <--- Some Optional multipliers set. Others assumed to be 1.0