Skip to content

@ue-too/board / index / ZoomPanPath

型エイリアス: ZoomPanPath ​

ZoomPanPath = object

定義: packages/board/src/camera/utils/zoom-pan-path.ts:29

A smooth camera path between two views, made by createZoomPanPath.

プロパティ ​

length ​

readonly length: number

定義: packages/board/src/camera/utils/zoom-pan-path.ts:35

How long the trip feels, in the metric of Van Wijk & Nuij's paper. A longer or deeper trip gives a bigger number, so it can scale an animation's duration. It is 0 when both views are the same.

メソッド ​

at() ​

at(t): CameraView

定義: packages/board/src/camera/utils/zoom-pan-path.ts:46

The camera view at progress t.

パラメータ ​

t ​

number

Progress from 0 (start view) to 1 (target view). Values outside that range are clamped, and NaN gives the start view. Equal steps of t look like equal amounts of motion, so layer any easing on top of t.

戻り値 ​

CameraView

A new view object; at(0) is exactly the start view and at(1) exactly the target view.