Geometry (interface)

The Geometry interface regroups a set of function that should be implemented by every Geometry type.

Geometry Geometry Geometry Curves Curves Curves->Geometry DrawElements DrawElements DrawElements->Geometry Lines Lines Lines->Geometry Points Points Points->Geometry PolygonMesh PolygonMesh PolygonMesh->Geometry

Functions

  applyTransform ! ( in Mat44 transform )
  applyTransform ! ( in Xfo transform )
  convertToCPU ! ()
  convertToGPU ! ()
  copy ! ( in Geometry src )
Size elementCount ? ()
Vec3[] getAllPointPositions ? ()
Ref<GeometryAttributes> getAttributes ? ()
LocalBoundingVolume getBoundingVolume ? ()
String getDebugName ? ()
String getDesc ? ( in Boolean withAttributes, in Boolean useUnitTestPrint )
LocalBoundingVolume getElementBoundingVolume ? ( in Size index )
UInt32 getMemType ? ()
Ref<ThreadsafeMetaDataContainer> getMetaData ? ()
Vec3 getPointPosition ? ( in Size point )
UInt32 getStructureVersion ? ()
UInt32 getVersion ? ()
Size pointCount ? ()
  setAllPointPositions ! ( in Vec3 positions[] )
  setPointPosition ! ( in Size point, in Vec3 position )

Functions in detail

Geometry.applyTransform! ( in Mat44 transform )

Transforms the positions of the geometry (and normals if applicable)


Geometry.applyTransform! ( in Xfo transform )

Transforms the positions of the geometry (and normals if applicable)


Geometry.convertToCPU! ()


Geometry.convertToGPU! ()


Geometry.copy! ( in Geometry src )

Copies all the data from source Geometry, including attributes.


Size Geometry.elementCount? ()

Returns the number of elements for this Geometry. Elements are geometry specific: polygons for PolygonMesh, line segments for Lines, points for Points...


Vec3[] Geometry.getAllPointPositions? ()

Returns all point positions


Ref<GeometryAttributes> Geometry.getAttributes? ()

Returns the associated attribute container, if any.

注釈

the usage and meaning of attribute values is geometry specific.


LocalBoundingVolume Geometry.getBoundingVolume? ()

Returns the local bounding volume of the geometry (typically a bounding box around the point positions)


String Geometry.getDebugName? ()

Returns the debug name used when constructing the geometry.


String Geometry.getDesc? ( in Boolean withAttributes, in Boolean useUnitTestPrint )

Returns a description of the Geometry.

withAttributes If true, will print all attributes and their values
useUnitTestPrint If true, floats will use a numerically stable, unit test friendly output


LocalBoundingVolume Geometry.getElementBoundingVolume? ( in Size index )

Returns the bounding volume of an element. Elements are geometry specific: polygons for PolygonMesh, line segments for Lines, points for Points...


UInt32 Geometry.getMemType? ()

Returns the memory location id. CPU = 0, GPU = 1, VSM = 2;


Ref<ThreadsafeMetaDataContainer> Geometry.getMetaData? ()

Returns the metaData container for this Geometry.


Vec3 Geometry.getPointPosition? ( in Size point )

Returns the position of a point.


UInt32 Geometry.getStructureVersion? ()

Returns the version of the geometry structure including the the attribute set (but not attribute values).


UInt32 Geometry.getVersion? ()

Returns the version of the geometry including attribute values


Size Geometry.pointCount? ()

Returns the number of points.


Geometry.setAllPointPositions! ( in Vec3 positions[] )

Sets all point positions


Geometry.setPointPosition! ( in Size point, in Vec3 position )

Sets the positions of a point.