Skip to main content

zoomCamera

@combeenation/custom-code-utils


Variable: zoomCamera()

const zoomCamera: (scenePathsOrBB?, transitionMS?, sdCtrlName?, queued) => Promise<SDUpdateQueueResult> = SdvCamera.zoomCamera

Zoom in on a certain part of the scene without modifying the camera direction

Parameters

scenePathsOrBB?

The zooming target, this can either be a certain scene path within the 3d model, a bounding box or the whole visible scene if the parameter is left empty

string[] | Box3

transitionMS?

number

Duration of the movement in milliseconds

sdCtrlName?

string

If not configured, the first shapediver instance of the configurator is used

queued?

boolean = false

true: execute camera movement after all previously added movement commands have been finished
false: Abort current and pending movement commands and move to the desired position immediatly

Returns

Promise<SDUpdateQueueResult>