Skip to main content

IsometricPerspective

@zylem/game-lib


@zylem/game-lib / core / IsometricPerspective

Class: IsometricPerspective

Defined in: packages/game-lib/src/lib/camera/perspectives/isometric-perspective.ts:43

Orthographic isometric perspective.

The view direction stays locked in world space, so the target can move without the camera orbiting around it. Player look input is not accepted.

Implements​

Constructors​

Constructor​

new IsometricPerspective(options?): IsometricPerspective

Defined in: packages/game-lib/src/lib/camera/perspectives/isometric-perspective.ts:52

Parameters​

options?​

IsometricOptions

Returns​

IsometricPerspective

Properties​

defaults​

readonly defaults: object

Defined in: packages/game-lib/src/lib/camera/perspectives/isometric-perspective.ts:46

Optional defaults for smoothing and other pipeline settings.

damping​

damping: number = 1

Implementation of​

CameraPerspective.defaults


id​

readonly id: "isometric" = 'isometric'

Defined in: packages/game-lib/src/lib/camera/perspectives/isometric-perspective.ts:44

Implementation of​

CameraPerspective.id


projection​

readonly projection: "orthographic"

Defined in: packages/game-lib/src/lib/camera/perspectives/isometric-perspective.ts:45

Projection the Three.js camera must use. When omitted, the runtime keeps a perspective camera. Orthographic perspectives set this so a runtime switch replaces the camera instance.

Implementation of​

CameraPerspective.projection

Methods​

getBasePose()​

getBasePose(ctx): CameraPose

Defined in: packages/game-lib/src/lib/camera/perspectives/isometric-perspective.ts:59

Compute the raw desired pose for this frame given the current context.

Parameters​

ctx​

CameraContext

Returns​

CameraPose

Implementation of​

CameraPerspective.getBasePose