OrbitControls
Defined in: addons/src/controls/OrbitControls.ts:32
Listeners by event type, as the DOM’s EventTarget has them, for any object.
Extends
Section titled “Extends”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new OrbitControls(
camera,domElement):OrbitControls
Defined in: addons/src/controls/OrbitControls.ts:70
Parameters
Section titled “Parameters”camera
Section titled “camera”domElement
Section titled “domElement”HTMLElement
Returns
Section titled “Returns”OrbitControls
Overrides
Section titled “Overrides”Properties
Section titled “Properties”dampingFactor
Section titled “dampingFactor”dampingFactor:
number=0.92
Defined in: addons/src/controls/OrbitControls.ts:39
The fraction of a coasting turn’s speed lost each second.
enabled
Section titled “enabled”enabled:
boolean=true
Defined in: addons/src/controls/OrbitControls.ts:35
enableDamping
Section titled “enableDamping”enableDamping:
boolean=true
Defined in: addons/src/controls/OrbitControls.ts:37
A released turn keeps going and slows, as a turntable does.
maxAzimuthAngle
Section titled “maxAzimuthAngle”maxAzimuthAngle:
number=Infinity
Defined in: addons/src/controls/OrbitControls.ts:51
maxDistance
Section titled “maxDistance”maxDistance:
number=Infinity
Defined in: addons/src/controls/OrbitControls.ts:45
maxPolarAngle
Section titled “maxPolarAngle”maxPolarAngle:
number
Defined in: addons/src/controls/OrbitControls.ts:48
minAzimuthAngle
Section titled “minAzimuthAngle”minAzimuthAngle:
number=-Infinity
Defined in: addons/src/controls/OrbitControls.ts:50
The angle about +y, in radians, from +z; unbounded by default.
minDistance
Section titled “minDistance”minDistance:
number=0
Defined in: addons/src/controls/OrbitControls.ts:44
minPolarAngle
Section titled “minPolarAngle”minPolarAngle:
number=0.01
Defined in: addons/src/controls/OrbitControls.ts:47
The angle from straight up, in radians: 0 looks down from above, pi from below.
rotateSpeed
Section titled “rotateSpeed”rotateSpeed:
number
Defined in: addons/src/controls/OrbitControls.ts:41
Radians of turn for a drag across the element’s height.
target
Section titled “target”
readonlytarget:Vector3
Defined in: addons/src/controls/OrbitControls.ts:34
What the camera turns about and looks at.
targetBounds
Section titled “targetBounds”targetBounds:
Box3
Defined in: addons/src/controls/OrbitControls.ts:53
The box the target stays in when panning.
zoomSpeed
Section titled “zoomSpeed”zoomSpeed:
number=0.0015
Defined in: addons/src/controls/OrbitControls.ts:43
The dolly factor per wheel pixel, as an exponent.
Accessors
Section titled “Accessors”moving
Section titled “moving”Get Signature
Section titled “Get Signature”get moving():
boolean
Defined in: addons/src/controls/OrbitControls.ts:91
Whether the view is changing: a pointer is down, the turn coasts, or a wheel just turned.
Returns
Section titled “Returns”boolean
Methods
Section titled “Methods”addEventListener()
Section titled “addEventListener()”addEventListener<
K>(type,listener):void
Defined in: radiance/src/core/EventDispatcher.ts:5
Type Parameters
Section titled “Type Parameters”K extends keyof OrbitControlsEvents
Parameters
Section titled “Parameters”K
listener
Section titled “listener”(event) => void
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”EventDispatcher.addEventListener
dispatchEvent()
Section titled “dispatchEvent()”dispatchEvent<
K>(type,event):void
Defined in: radiance/src/core/EventDispatcher.ts:15
Type Parameters
Section titled “Type Parameters”K extends keyof OrbitControlsEvents
Parameters
Section titled “Parameters”K
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”dispose()
Section titled “dispose()”dispose():
void
Defined in: addons/src/controls/OrbitControls.ts:156
Remove every listener from the element.
Returns
Section titled “Returns”void
getDistance()
Section titled “getDistance()”getDistance():
number
Defined in: addons/src/controls/OrbitControls.ts:101
The distance from the target to the camera.
Returns
Section titled “Returns”number
removeEventListener()
Section titled “removeEventListener()”removeEventListener<
K>(type,listener):void
Defined in: radiance/src/core/EventDispatcher.ts:11
Type Parameters
Section titled “Type Parameters”K extends keyof OrbitControlsEvents
Parameters
Section titled “Parameters”K
listener
Section titled “listener”(event) => void
Returns
Section titled “Returns”void
Inherited from
Section titled “Inherited from”EventDispatcher.removeEventListener
reset()
Section titled “reset()”reset():
void
Defined in: addons/src/controls/OrbitControls.ts:111
Return to the saved view.
Returns
Section titled “Returns”void
saveState()
Section titled “saveState()”saveState():
void
Defined in: addons/src/controls/OrbitControls.ts:106
Remember the camera and target, for reset().
Returns
Section titled “Returns”void
update()
Section titled “update()”update(
dt?):boolean
Defined in: addons/src/controls/OrbitControls.ts:125
Advance a coasting turn by dt seconds, place the camera, and answer whether it moved since
the last call. A change to target or the camera’s position made by the application is
taken in here too.
Parameters
Section titled “Parameters”number = ...
Returns
Section titled “Returns”boolean