AnaglyphFreeCamera

Camera used to simulate anaglyphic rendering (based on FreeCamera)

see

http://doc.babylonjs.com/features/cameras#anaglyph-cameras

Hierarchy

Index

Constructors

constructor

Find examples in Playground
  • Creates a new AnaglyphFreeCamera

    Parameters

    • name: string

      defines camera name

    • position: Vector3

      defines initial position

    • interaxialDistance: number

      defines distance between each color axis

    • scene: Scene

      defines the hosting scene

    Returns AnaglyphFreeCamera

Properties

angularSensibility

Find examples in Playground
angularSensibility: number

Sets the input sensibility for a mouse input. (default is 2000.0) Higher values reduce sensitivity.

applyGravity

Find examples in Playground
applyGravity: boolean

Enable or disable gravity on the camera.

cameraDirection

Find examples in Playground
cameraDirection: Vector3

Define the current direction the camera is moving to

cameraRotation

Find examples in Playground
cameraRotation: Vector2

Define the current rotation the camera is rotating to

checkCollisions

Find examples in Playground
checkCollisions: boolean

Enable or disable collisions of the camera with the rest of the scene objects.

collisionMask

Find examples in Playground
collisionMask: number

Define a collision mask to limit the list of object the camera can collide with

ellipsoid

Find examples in Playground
ellipsoid: Vector3

Define the collision ellipsoid of the camera. This is helpful to simulate a camera body like the player body around the camera

see

http://doc.babylonjs.com/babylon101/cameras,_mesh_collisions_and_gravity#arcrotatecamera

ellipsoidOffset

Find examples in Playground
ellipsoidOffset: Vector3

Define an offset for the position of the ellipsoid around the camera. This can be helpful to determine the center of the body near the gravity center of the body instead of its head.

inputs

Find examples in Playground

Define the input manager associated to the camera.

keysDown

Find examples in Playground
keysDown: number[]

Gets or Set the list of keyboard keys used to control the backward move of the camera.

keysLeft

Find examples in Playground
keysLeft: number[]

Gets or Set the list of keyboard keys used to control the left strafe move of the camera.

keysRight

Find examples in Playground
keysRight: number[]

Gets or Set the list of keyboard keys used to control the right strafe move of the camera.

keysUp

Find examples in Playground
keysUp: number[]

Gets or Set the list of keyboard keys used to control the forward move of the camera.

lockedTarget

Find examples in Playground
lockedTarget: any

Define the current target of the camera as an object or a position.

noRotationConstraint

Find examples in Playground
noRotationConstraint: boolean

Add cconstraint to the camera to prevent it to move freely in all directions and around all axis.

onCollide

Find examples in Playground
onCollide: function

Event raised when the camera collide with a mesh in the scene.

Type declaration

rotation

Find examples in Playground
rotation: Vector3

Define the current rotation of the camera

rotationQuaternion

Find examples in Playground
rotationQuaternion: Quaternion

Define the current rotation of the camera as a quaternion to prevent Gimbal lock

speed

Find examples in Playground
speed: number

Define the current speed of the camera

updateUpVectorFromRotation

Find examples in Playground
updateUpVectorFromRotation: boolean

When set, the up vector of the camera will be updated by the rotation of the camera

Methods

attachControl

Find examples in Playground
  • attachControl(element: HTMLElement, noPreventDefault?: boolean): void

detachControl

Find examples in Playground
  • detachControl(element: HTMLElement): void
  • Detach the current controls from the camera. The camera will stop reacting to inputs.

    Parameters

    • element: HTMLElement

      Defines the element to stop listening the inputs from

    Returns void

dispose

Find examples in Playground
  • dispose(): void
  • Destroy the camera and release the current resources hold by it.

    Returns void

getClassName

Find examples in Playground
  • getClassName(): string

getFrontPosition

Find examples in Playground
  • getFrontPosition(distance: number): Vector3
  • Gets the position in front of the camera at a given distance.

    Parameters

    • distance: number

      The distance from the camera we want the position to be

    Returns Vector3

    the position

getTarget

Find examples in Playground
  • Return the current target position of the camera. This value is expressed in local space.

    Returns Vector3

    the target position

setTarget

Find examples in Playground
  • Defines the target the camera should look at.

    Parameters

    • target: Vector3

      Defines the new target as a Vector or a mesh

    Returns void

storeState

Find examples in Playground
  • Store current camera state of the camera (fov, position, rotation, etc..)

    Returns Camera

    the camera

Generated using TypeDoc