Array with animation clips.
The camera feed texture.
You can use this texture however you wish but the easiest way to show the camera feed behind your content is to set it as your scene's background.
Gets rendered into shadow map.
Array with object's children.
Custom depth material to be used when rendering to the depth map. Can only be used in context of meshes. When shadow-casting with a DirectionalLight or SpotLight, if you are (a) modifying vertex positions in the vertex shader, (b) using a displacement map, (c) using an alpha map with alphaTest, or (d) using a transparent texture with alphaTest, you must specify a customDepthMaterial for proper shadows.
Same as customDepthMaterial, but used with PointLight.
When this is set, it checks every frame if the object is in the frustum of the camera before rendering the object. If set to false the object gets rendered every frame even if it is not in the frustum of the camera.
Unique number of this object instance.
Used to check whether this or derived classes are Object3Ds. Default is true. You should not change this, as it is used internally for optimisation.
Local transform.
When this is set, it calculates the matrix of position, (rotation or quaternion) and scale every frame and also recalculates the matrixWorld property.
The global transform of the object. If the Object3d has no parent, then it's identical to the local transform.
This is the inverse of matrixWorld. MatrixWorld contains the Matrix which has the world transform of the Camera.
When this is set, it calculates the matrixWorld in that frame and resets this property to false.
Optional name of the object (doesn't need to be unique).
Calls after rendering object
Calls before rendering object
Object's parent in the scene graph.
The transformation with the (camera-relative) origin specified by the anchor.
The pose mode that determines how the camera moves in the scene.
Object's local position.
This is the matrix which contains the projection.
This is the inverse of projectionMatrix.
Object's local rotation as a Quaternion.
A 4x4 column-major transformation matrix where the camera sits.
The mirror mode that is used for the rear camera.
The camera source which is used for the rear camera.
Material gets baked in shadow receiving.
Overrides the default rendering order of scene graph objects, from lowest to highest renderOrder. Opaque and transparent objects remain sorted independently though. When this property is set for an instance of Group, all descendants objects will be sorted and rendered together.
Object's local rotation (Euler angles), in radians.
Object's local scale.
Up direction.
The mirror mode that is used for the user camera.
The camera source which is used for the user camera.
An object that can be used to store custom data about the Object3d. It should not hold references to functions as these will not be cloned.
Object gets rendered if true.
Gets the current mirror mode.
Adds object as child of this object.
Adds a listener to an event type.
The type of event to listen to.
The function that gets called when the event is fired.
This updates the position, rotation and scale with the matrix.
Adds object as a child of this, while maintaining the object's world transform.
Removes all child objects.
Fire an event type.
Destroys the camera sources.
Searches through the object's children and returns the first with a matching id.
Unique number of the object instance
Searches through the object's children and returns the first with a matching name.
String to match to the children's Object3d.name property.
Checks if listener is added to an event type.
The type of event to listen to.
The function that gets called when the event is fired.
Updates the vector from local space to world space.
A local vector.
Rotates object to face point in space.
A world vector to look at.
Removes object as child of this object.
Removes a listener from an event type.
The type of the listener that gets removed.
The listener function that gets removed.
Removes this object from its current parent.
Rotate an object along an axis in object space. The axis is assumed to be normalized.
A normalized vector in object space.
The angle in radians.
Rotate an object along an axis in world space. The axis is assumed to be normalized. Method Assumes no rotated parent.
A normalized vector in object space.
The angle in radians.
Sets the pose mode to 'Anchor Origin'.
In this case the camera moves and rotates in world space around the anchor at the origin.
The anchor that defines the origin.
Starts the camera source.
If true, starts the user facing camera. (i.e selfie).
Stops the camera source.
A normalized vector in object space.
The distance to translate.
Translates object along x axis by distance.
Distance.
Translates object along y axis by distance.
Distance.
Translates object along z axis by distance.
Distance.
Processes camera frames and updates backgroundTexture
.
Call this function on your pipeline once an animation frame (e.g. during your requestAnimationFrame
function).
The Three.js WebGL renderer.
Updates local transform.
Updates the vector from world space to local space.
A world vector.
Generated using TypeDoc
Creates a camera that you can use instead of a perspective camera.
The camera provides a Camera.backgroundTexture property containing the camera feed.
The ZapparThree library needs to use your WebGL context in order to process camera frames. You can set it when your page loads using glContextSet.
https://docs.zap.works/universal-ar/web-libraries/threejs/camera-setup/