Can be used to create a flat, reflective surface like a mirror.
Note that this class can only be used with WebGLRenderer. When using WebGPURenderer, use ReflectorNode.
Example:
val geometry = PlaneGeometry(100, 100)
val reflector = new Reflector(
geometry,
js.Dynamic.literal(
clipBias = 0.003,
textureWidth = window.innerWidth * window.devicePixelRatio,
textureHeight = window.innerHeight * window.devicePixelRatio,
color = 0xc1cbcb
)
)
scene.add(reflector)
Attributes
- Companion
- object
- Graph
-
- Supertypes
Members list
Value members
Concrete methods
Frees the GPU-related resources allocated by this instance. Call this method whenever this instance is no longer used in your app.
Frees the GPU-related resources allocated by this instance. Call this method whenever this instance is no longer used in your app.
Attributes
Returns the reflector's internal render target.
Returns the reflector's internal render target.
Attributes
Inherited methods
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Returns the local-space position of the vertex at the given index, taking into account the current animation state of both morph targets and skinning.
Returns the local-space position of the vertex at the given index, taking into account the current animation state of both morph targets and skinning.
Value parameters
- index
-
The vertex index
- target
-
The target object that is used to store the method's result
Attributes
- Returns
-
The vertex position in local space
- Inherited from:
- Mesh
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Sets the values of morphTargetDictionary and morphTargetInfluences to make sure existing morph targets can influence this 3D object.
Sets the values of morphTargetDictionary and morphTargetInfluences to make sure existing morph targets can influence this 3D object.
Attributes
- Inherited from:
- Mesh
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object3D
Concrete fields
The reflector's virtual camera. This is used to render the scene from the mirror's point of view.
The reflector's virtual camera. This is used to render the scene from the mirror's point of view.
Attributes
Whether to force an update, no matter if the reflector is in view or not.
Whether to force an update, no matter if the reflector is in view or not.
Attributes
This flag can be used for type testing.
This flag can be used for type testing.
Attributes
Inherited fields
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
This flag can be used for type testing.
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
A dictionary representing the morph targets in the geometry. The key is the morph targets name, the value its attribute index. This member is undefined by default and only set when morph targets are detected in the geometry.
A dictionary representing the morph targets in the geometry. The key is the morph targets name, the value its attribute index. This member is undefined by default and only set when morph targets are detected in the geometry.
Attributes
- Inherited from:
- Mesh
An array of weights typically in the range [0,1] that specify how much of the morph is applied. This member is undefined by default and only set when morph targets are detected in the geometry.
An array of weights typically in the range [0,1] that specify how much of the morph is applied. This member is undefined by default and only set when morph targets are detected in the geometry.
Attributes
- Inherited from:
- Mesh
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D
Attributes
- Inherited from:
- Object3D