All Frameworks  Class Hierarchy  This Framework  Previous  Next  Indexes

Tessellation Class CATCellTessellator

CATCellTessellator
 

Usage: you must use this class as is. You should never derive it.


public class CATCellTessellator

Class defining a Tessellation operator on a cell.

This operator discretizes a face geometry as triangles and an edge geometry as bars. The extremities of the bars are called points. Three parameters tune the tessellation result:

Sag
Defines the maximum distance between a bar and the object to tessellate
Step
Defines the maximum length of a bar. If not defined, the step is infinite (this parameter is unused)
Angle
Defines the maximum angle between the normals at each bar end.
The Tessellation operator follows the scheme of all the CGM operators:


Constructor and Destructor Index


o CATCellTessellator(CATBody*,CATCell*,double,double)
Constructs a CATCellTessellator with an infinite step.
o CATCellTessellator(CATBody*,double,double)
Constructs a CATCellTessellator with an infinite step.
o CATCellTessellator(CATCell*,double,double)
Constructs a CATCellTessellator with an infinite step.
o CATCellTessellator(double,double)
Constructs a CATCellTessellator with an infinite step.
o ~CATCellTessellator()

Method Index


o AddEdge(CATEdge*)
Adds another edge to this CATCellTessellator.
o AddFace(CATFace*)
Adds another face to this CATCellTessellator.
o GetEdge(CATEdge*,CATLONG32&,double**)
Retrieves the results (in doubles) associated with a topological edge of the input cells.
o GetEdge(CATEdge*,CATLONG32&,float**)
Retrieves the result (in floats) associated with a topological edge of the input cells.
o GetEdge(CATEdge*,CATMathSetOfPointsND**,CATMathSetOfPointsND**)
Retrieves the results associated with a topological edge of the input cells.
o GetFace(CATFace*,CATBoolean&,CATTessPointIter**,CATTessStripeIter**,CATTessFanIter**,CATTessPolyIter**,CATTessTrianIter**,short*)
Retrieves the results associated with a topological face of the input cells.
o GetVertex(CATVertex*,CATMathPoint*)
Retrieves the result associated with a topological vertex of the input cells.
o Run()
Runs this CATCellTessellator.
o SetOutputMode(CATTessOutputMode)
Defines Output mode for triangulation.
o SetStep(double)
Defines a finite step for this CATCellTessellator.

Constructor and Destructor


o CATCellTessellator
public CATCellTessellator(CATBody* iReferenceBody,
CATCell* iCell,
double iSag,
double iAngle=CATPIBY4)
Constructs a CATCellTessellator with an infinite step.
Parameters:
iReferenceBody
A reference body containing all faces which will be submitted to the CATCellTessellator by AddFace method, if this body is not provided (null pointer), triangles originating from different faces may be oriented in opposite directions. This body will not be used to tessellate edges, it may be null in this case.
iCell
The edge or face to tessellate
iSag
The Sag value.
iAngle
The Angle value in radian.
o CATCellTessellator
public CATCellTessellator(CATBody* iReferenceBody,
double iSag,
double iAngle=CATPIBY4)
Constructs a CATCellTessellator with an infinite step.
Parameters:
iReferenceBody
A reference body containing all faces which will be submitted to the CATCellTessellator by AddFace method, if this body is not provided (null pointer), triangles originating from different faces may be oriented in opposite directions. This body will not be used to tessellate edges, it may be null in this case.
iSag
The Sag value.
iAngle
The Angle value in radian.
o CATCellTessellator
public CATCellTessellator(CATCell* iCell,
double iSag,
double iAngle=CATPIBY4)
Constructs a CATCellTessellator with an infinite step.
Parameters:
iCell
The edge or face to tessellate
iSag
The Sag value.
iAngle
The Angle value in radian.
o CATCellTessellator
public CATCellTessellator(double iSag,
double iAngle=CATPIBY4)
Constructs a CATCellTessellator with an infinite step.
Parameters:
iSag
The Sag value.
iAngle
The Angle value in radian.
o ~CATCellTessellator
public ~CATCellTessellator()

Methods


o AddEdge
public void AddEdge(CATEdge* iEdge)
Adds another edge to this CATCellTessellator.
Parameters:
iEdge
The pointer to another edge to tessellate in the same operation.
o AddFace
public void AddFace(CATFace* iFace)
Adds another face to this CATCellTessellator.
Parameters:
iFace
The pointer to another face to tessellate in the same operation.
o GetEdge
public void GetEdge(CATEdge* iEdge,
CATLONG32& oNumberOfPoints,
double** oPointData)
Retrieves the results (in doubles) associated with a topological edge of the input cells.
Parameters:
iEdge
The pointer to an edge among the input cells.
oNumberOfPoints
The number of points of the resulting tessellation.
oPointData
The array of the resulting points. This array is allocated by the GetEdge method. The j-th coordinate of the i-th point is oPointData[3*(i-1)+j-1].
o GetEdge
public void GetEdge(CATEdge* iEdge,
CATLONG32& oNumberOfPoints,
float** oPointData)
Retrieves the result (in floats) associated with a topological edge of the input cells.
Parameters:
iEdge
The pointer to an edge among the input cells.
oNumberOfPoints
The number of points of the resulting tessellation.
oPointData
The array of the resulting points. This array is allocated by the GetEdge method. The j-th coordinate of the i-th point is oPointData[3*(i-1)+j-1]. of the resulting tessellation.
o GetEdge
public void GetEdge(CATEdge* iEdge,
CATMathSetOfPointsND** oMathPoints,
CATMathSetOfPointsND** oCrvParams)
Retrieves the results associated with a topological edge of the input cells.
Parameters:
iEdge
The pointer to an edge among the input cells.
oMathPoints
The pointer to the created CATMathSetOfPointsND pointer. This set contains the points (as 3 Cartesian coordinates) of the resulting tessellation.
oCrvParams
The pointer to the created CATMathSetOfPointsND pointer. This set contains the points (as a CATCrvParam on the underlying edge curve) of the resulting tessellation.
o GetFace
public void GetFace(CATFace* iFace,
CATBoolean& oPlane,
CATTessPointIter** oPoints,
CATTessStripeIter** oStrips,
CATTessFanIter** oFans,
CATTessPolyIter** oPolygons,
CATTessTrianIter** oTriangles,
short* oSide=(short *) 0)
Retrieves the results associated with a topological face of the input cells.
All the output iterators are allocated by the GetFace method, and are deleted when the operator is deleted.
Parameters:
iFace
The pointer to a face among the input cells.
oPlane
Retrieves 1 if the face is planar, 0 otherwise.
oPoints
The pointer to the created pointer to a CATTessPointIterator, to retrieve the computed points.
oStrips
The pointer to the created pointer to a CATTessStripIterator, to retrieve the computed triangle strips.
oStrips
The pointer to the created pointer to a CATTessFanIterator, to retrieve the computed triangle fans.
oStrips
The pointer to the created pointer to a CATTessPolygonIterator, to retrieve the computed polygons. The pointer to the created CATTessPolygonIterator, to retrieve the computed polygons.
oSide
The face orientation.
Legal values: 1 if the face orientation is outwards, -1 if it is inwards.
o GetVertex
public void GetVertex(CATVertex* iVertex,
CATMathPoint* oMathPoint)
Retrieves the result associated with a topological vertex of the input cells.
Parameters:
iVertex
The pointer to a vertex of the input cells.
oMathPoint
The corresponding CATMathPoint.
o Run
public void Run()
Runs this CATCellTessellator.
o SetOutputMode
public void SetOutputMode(CATTessOutputMode iMode= CATTessOutputMixed )
Defines Output mode for triangulation. Defaults to mixed output.
o SetStep
public void SetStep(double iStep)
Defines a finite step for this CATCellTessellator.
Parameters:
iStep
The Step value.

This object is included in the file: CATCellTessellator.h
If needed, your Imakefile.mk should include the module: CATTessellation

Copyright © 2003, Dassault Systèmes. All rights reserved.