Geometry

Overview

Geometry is a class in Aspose.3D FOSS for TypeScript. Inherits from: Entity.

Geometry objects allow adding control points, creating vertex elements (including UVs), and retrieving bounding boxes for mesh data.

This class declares 16 methods for Geometry objects in TypeScript programs. Available methods include: addControlPoint, addElement, constructor, createElement, createElementUV, findProperty, getBoundingBox, getElement, getEntityRendererKey, getProperty, getVertexElementOfUV, removeProperty, and 2 additional methods. Public members are accessible to any TypeScript application after installing the Aspose.3D FOSS for TypeScript package. Properties: castShadows, controlPoints, excluded, name, parentNode, parentNodes, and 5 more.

Properties

NameTypeAccessDescription
visiblebooleanRead/WriteGets the visible.
castShadowsbooleanRead/WriteGets the cast shadows.
receiveShadowsbooleanRead/WriteGets the receive shadows.
vertexElementsVertexElement[]ReadGets the vertex elements.
controlPointsVector4[]Read/WriteGets the control points.
parentNodesNode[]ReadGets the parent nodes.
parentNodeNode | undefinedRead/WriteGets the parent node.
excludedbooleanRead/WriteGets the excluded.
sceneScene | nullRead/WriteGets the scene.
namestringRead/WriteGets the name.
propertiesPropertyCollectionReadGets the properties.

Methods

SignatureDescription
constructor(name: string | null)Creates a Geometry with an optional name
addControlPoint(point: Vector4)Adds a Vector4 point to the geometry’s control points list
createElement(elementType: VertexElementType, mappingMode: MappingMode | null, referenceMode: ReferenceMode | null)VertexElementCreates a VertexElement of the given type with optional mapping and reference modes
createElementUV(uvMapping: TextureMapping, mappingMode: MappingMode | null, referenceMode: ReferenceMode | null)VertexElementUVCreates a UV VertexElement for the specified texture mapping and optional modes
addElement(element: VertexElement)Adds a VertexElement to the geometry’s vertexElements collection
getElement(elementType: VertexElementType)VertexElement | nullReturns the VertexElement of the specified type or null if not present
getVertexElementOfUV(textureMapping: TextureMapping)VertexElementUV | nullReturns the UV VertexElement for the given texture mapping or null
removeProperty(_prop: Property | string)booleanRemoves a property by object or name and returns true if removal succeeded
getProperty(_property: string)anyCalls getProperty(_property) on this Geometry instance.
setProperty(_property: string, _value: any)Sets the property value.
findProperty(_property: string)Property | nullCalls findProperty(_property) on this Geometry instance.
getBoundingBox()anyReturns the bounding box.
getEntityRendererKey()anyNot implemented in the FOSS edition — throws at runtime. Returns the entity renderer key.
constructor(name: string)Calls constructor(name) on this Geometry instance.
removeProperty(property: string | Property)booleanCalls removeProperty(property) on this Geometry instance.
toString()stringCalls toString on this Geometry instance.

See Also

 English