Skip to main content

Interface: PanZoomCamera

Defined in: src/interaction/PanZoomControls.ts:9

Duck-typed 2D camera that PanZoomControls drives. Both Camera2D and the Camera2DFrame-backed scene camera satisfy this shape, so the controller never imports the concrete camera class (avoids a circular import and keeps it testable with a plain stub).

Properties​

frameHeight​

frameHeight: number

Defined in: src/interaction/PanZoomControls.ts:13

Visible frame height in world units. Smaller = zoomed in.


frameWidth​

frameWidth: number

Defined in: src/interaction/PanZoomControls.ts:11

Visible frame width in world units. Smaller = zoomed in.


position​

position: Vector3

Defined in: src/interaction/PanZoomControls.ts:15

Live camera position. Its x/y are the frame center; z is left untouched.

Methods​

moveTo()​

moveTo(point): void

Defined in: src/interaction/PanZoomControls.ts:17

Move the camera center to a world point.

Parameters​

point​

[number, number, number]

Returns​

void