TalanSoft Toolkits  201707
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Groups Pages
List of all members
iCollideQueryTriangles Struct Referenceabstract
Inheritance diagram for iCollideQueryTriangles:
iUnknown

Detailed Description

Collide triangles query interface.

Triangles

virtual void ClearTriangles ()=0
 Clear all triangles gathered. More...
 
virtual tU32 GetNumTriangles () const =0
 Get the number of triangles gathered. {Property}. More...
 
virtual tVec3fCVecGetTrianglesVertex () const =0
 Get the triangles vertices. {Property}. More...
 
virtual tU32CVecGetTrianglesIndex () const =0
 Get the triangle indices. {Property}. More...
 

Query Parameters

virtual void SetFlags (tCollideQueryTrianglesFlags aFlags)=0
 Set the query's flags. {Property}. More...
 
virtual tCollideQueryTrianglesFlags GetFlags () const =0
 Get the query's flags. {Property}. More...
 
virtual tVec4fCVecGetClippingPlanes () const =0
 Get the query's clipping planes. {Property}. More...
 
virtual void SetCullingView (const sVec4f &avDirE)=0
 Set the query's culling direction and epsilon. {Property}. More...
 
virtual sVec4f GetCullingView () const =0
 Get the query's culling direction and epsilon. {Property}. More...
 
virtual void SetCullingClassify (tU32 aClassify)=0
 Set the cull planes classification flags. {Property}. More...
 
virtual tU32 GetCullingClassify () const =0
 Get the cull planes classification flags. {Property}. More...
 
virtual sVec3f GetAccNormal () const =0
 Get the accumulated normal of all triangles. {Property}. More...
 

Queries

virtual tU32 GatherObjectTriangles (iCollideObject *apObject, const sVec3f &avMin, const sVec3f &avMax)=0
 Gather all triangles of the object intersecting the specified AABB. More...
 
virtual tU32 GatherShapeTriangles (iCollideShape *apShape, const sVec3f &avMin, const sVec3f &avMax)=0
 Gather all triangles of the shape intersecting the specified AABB. More...
 

Additional Inherited Members

- Public Member Functions inherited from iUnknown
virtual tBool IsOK () const =0
 Check if the object is valid. More...
 
virtual tI32 AddRef ()=0
 Signal that one more reference of the object has been created. More...
 
virtual tI32 Release ()=0
 Release a reference of the object. More...
 
virtual void DeleteThis ()=0
 Bypass any reference counting and delete this object. More...
 
virtual void Invalidate ()=0
 Invalidate the object. More...
 
virtual iUnknownQueryInterface (const tUUID &aIID)=0
 Query an interface. More...
 
virtual void ListInterfaces (iMutableCollection *apLst, tU32 anFlags) const =0
 Fill a UUID list containing the UUIDs of the implemented interfaces. More...
 
virtual tI32 SetNumRefs (tI32 anNumRefs)=0
 Set the reference counter directly. More...
 
virtual tI32 GetNumRefs () const =0
 Get the number of references to this object. More...
 

Member Function Documentation

virtual void ClearTriangles ( )
pure virtual

Clear all triangles gathered.

virtual tU32 GetNumTriangles ( ) const
pure virtual

Get the number of triangles gathered. {Property}.

virtual tVec3fCVec* GetTrianglesVertex ( ) const
pure virtual

Get the triangles vertices. {Property}.

virtual tU32CVec* GetTrianglesIndex ( ) const
pure virtual

Get the triangle indices. {Property}.

virtual void SetFlags ( tCollideQueryTrianglesFlags  aFlags)
pure virtual

Set the query's flags. {Property}.

Remarks
Default is 0.
virtual tCollideQueryTrianglesFlags GetFlags ( ) const
pure virtual

Get the query's flags. {Property}.

virtual tVec4fCVec* GetClippingPlanes ( ) const
pure virtual

Get the query's clipping planes. {Property}.

Remarks
The clipping planes should be in world space when clipping objects and in shape space when clipping shapes.
Default is zero planes.
virtual void SetCullingView ( const sVec4f avDirE)
pure virtual

Set the query's culling direction and epsilon. {Property}.

Remarks
The format of the parameters is a 4D vector (Dir.x,Dir.y,Dir.z,Epsilon).
Culling does : reject triangle if (VecDot(currentTriangle.normal,Dir) < Epsilon).
Default is Vec4(0,0,0,0).
virtual sVec4f GetCullingView ( ) const
pure virtual

Get the query's culling direction and epsilon. {Property}.

virtual void SetCullingClassify ( tU32  aClassify)
pure virtual

Set the cull planes classification flags. {Property}.

Remarks
The culling will discard any triangle which is classified as one of the specified classification value.
The default value is eClassify_Back|eClassify_Coplanar.
See also
ni::cPolygon::Classify
ni::eClassify
virtual tU32 GetCullingClassify ( ) const
pure virtual

Get the cull planes classification flags. {Property}.

virtual sVec3f GetAccNormal ( ) const
pure virtual

Get the accumulated normal of all triangles. {Property}.

virtual tU32 GatherObjectTriangles ( iCollideObject apObject,
const sVec3f avMin,
const sVec3f avMax 
)
pure virtual

Gather all triangles of the object intersecting the specified AABB.

Remarks
The AABB should be in 'world' space.
The triangle's vertices will be in 'world' space.
virtual tU32 GatherShapeTriangles ( iCollideShape apShape,
const sVec3f avMin,
const sVec3f avMax 
)
pure virtual

Gather all triangles of the shape intersecting the specified AABB.

Remarks
The AABB should be using the shape's local coordinates.
The triangle's vertices will be in 'shape' space.