Skip to main content

interface.RenderStateCamera

API > RenderStateCamera

Interface: RenderStateCamera

Camera related render state.

Properties

far

readonly far: number

Camera's far clipping plane distance.

Remarks

This value must be larger than the near clipping plane. Any pixels that are farther away from the image plane will be clipped. Smaller values improves z-buffer resolution, which helps reduce z-fighting. Smaller values also increases the # objects culled, which could help improve rendering performance.

Source

@novorender/core3d/state/index.ts:264


fov

readonly fov: number

Camera's vertical field of view.

Remarks

For pinhole cameras, this value is interpreted as the angle between the top and bottom edge of the frustum in degrees. For orthographic cameras, this value is interpreted as the distance between the top and bottom edge of the view frustum in meters.

Source

@novorender/core3d/state/index.ts:246


kind

readonly kind: "pinhole" | "orthographic"

The type of camera projection to use.

See

pinhole orthographic

Source

@novorender/core3d/state/index.ts:222


near

readonly near: number

Camera's near clipping plane distance.

Remarks

This value must be larger than 0, preferable as large as it can comfortable be without excessive visual clipping artifacts. Any pixels that are closer to the image plane will be clipped. Larger values will greatly improve z-buffer resolution, which helps reduce z-fighting.

Source

@novorender/core3d/state/index.ts:255


pivot

readonly pivot: undefined | ReadonlyVec3

Camera pivot point in world space.

Remarks

This is used to visualize a point around which the camera will pivot when moved. (Currently not implemented)

Source

@novorender/core3d/state/index.ts:239


position

readonly position: ReadonlyVec3

Camera position in world space.

Source

@novorender/core3d/state/index.ts:225


rotation

readonly rotation: ReadonlyQuat

Camera rotation in world space.

Remarks

This rotation is from camera->world space, much like that of a local->world space transformation of any rendered object. It should not be confused with the inverse transformation, i.e. world->camera space, commonly used in shaders.

Source

@novorender/core3d/state/index.ts:232