Camera

The HoloPlay Camera is used to capture your three.js scene for displaying in 3D on the Looking Glass. This class extends from THREE.ArrayCamera.

Code example

const camera = new HoloPlay.Camera();

Constructor

HoloPlay.Camera()

Constructs a HoloPlay Camera at position (0, 0, 1). By default the camera is pointed and focused at (0, 0, 0).

Methods

.lookAt(targetPosition : THREE.Vector3)

targetPosition - a vector representing a position in world space.

Rotates and focuses the camera towards a point in world space.

Properties

.position : THREE.Vector3

A Vector3 representing the camera's position in world space. Default is (0, 0, 1).