MeshIndexedLines
-
class
cee.geo.MeshIndexedLines() This class implements a
Meshfor indexed lines.Rather than defining each line directly as an array of vertices, an array containing each unique vertex in the part is defined. Then lines are defined by arrays of indices that refer to elements of this vertex array. This allows lines to share vertices, thus reducing the number of vertices.
Constructors
-
cee.geo.MeshIndexedLines.constructor() - MeshIndexedLines(vertices: ArrayLike, indices: ArrayLike, optionalVertexData:
OptionalIndexedLinesVertexData):MeshIndexedLinesCreates an indexed lines mesh with the given vertices and indices.
Parameters
Returns:
MeshIndexedLines
Accessors
-
cee.geo.MeshIndexedLines.boundingBox() The
BoundingBoxof the mesh.get boundingBox():BoundingBoxReturns a copy of the
BoundingBoxof the meshReturns:
BoundingBox
-
cee.geo.MeshIndexedLines.indexArray() - get indexArray(): ArrayLike
A readonly array containing the indices of the mesh
Returns: ArrayLike
-
cee.geo.MeshIndexedLines.primitiveCount() The number of primitives in the mesh.
get primitiveCount(): numberThe number of primitives in the mesh.
Returns: number
-
cee.geo.MeshIndexedLines.primitiveType() The type of primitives that are used in the mesh.
get primitiveType():MeshPrimitiveTypeThe type of primitives that are used in the mesh.
Returns:
MeshPrimitiveType
-
cee.geo.MeshIndexedLines.textureCoordinates() - get textureCoordinates(): ArrayLike
A readonly array containing the 2d texture coordinates of the mesh
Returns: ArrayLike
-
cee.geo.MeshIndexedLines.vertexArray() - get vertexArray(): ArrayLike
A readonly array containing the vertices of the mesh
Returns: ArrayLike
-
cee.geo.MeshIndexedLines.vertexCount() The number of vertices in the mesh.
get vertexCount(): numberThe number of vertices in the mesh.
Returns: number
Methods
-
cee.geo.MeshIndexedLines.getPrimitiveVertices() - getPrimitiveVertices(primitiveIndex: number):
Vec3[]Returns a copy of the vertex indices of a given primitive.
Parameters
primitiveIndex: numberReturns:
Vec3[]
-
cee.geo.MeshIndexedLines.rayIntersect() - rayIntersect(ray:
Ray, hitItem:MeshHitItem): booleanPerforms picking on the mesh.
If a primitive was hit, the function returns true and populates the passed hitItem object with information about this primitive. It nothing was hit, returns false.
Parameters
ray:
RayhitItem:
MeshHitItemReturns: boolean