A class containing utility functions for BufferGeometry instances.
Merges the meshes together to form a batched mesh. This technique is used to reduce the number WebGL draw calls hence to improve rendering performance.
The batching will be performed among the meshes which have the same values of the following properties:
material.namevisibledisableChildRenderingcastShadowreceiveShadowrenderOrdergroupNamesgeometry.attributes (keys only)geometry.morphAttributes (keys only)object — instance of Mesh, Line, Points.
Returns the morphed attributes (position and normal) of a morphed/skinned object together with the original ones. The returned object includes 4 properties: positionAttribute, normalAttribute, morphedPositionAttribute, and morphedNormalAttribute. Can be helpful for raytracing or applying decals.
attribute — instance of BufferAttribute to perform deep clone.
Returns a deep clone of the given attribute.
geometry — instance of BufferGeometry to estimate the memory use of.
Returns the amount of bytes used by all attributes to represent the geometry.
attributes — array of BufferAttribute instances.
Merges a set of attributes into a single instance. All attributes must have compatible properties and types. If merge does not succeed, the method returns null.
Merges a set of geometries into a single instance. All geometries must have compatible attributes. If merge does not succeed, the method returns null.
geometry — instance of BufferGeometry to merge the groups of.
Merges the groups for the given geometry.
1e-4.Returns a new BufferGeometry with vertices for which all similar vertex attributes (within tolerance) are merged.
Creates a new, non-indexed geometry with smooth normals everywhere except faces that meet at an angle greater than the crease angle.
v3d.TriangleStripDrawMode and v3d.TriangleFanDrawMode.
Returns a new indexed geometry based on v3d.TrianglesDrawMode draw mode. This mode corresponds to the gl.TRIANGLES WebGL primitive.
For more info on how to obtain the source code of this module see this page.