 |
VTK
9.1.0
|
Go to the documentation of this file.
116 #ifndef vtkCollisionDetectionFilter_h
117 #define vtkCollisionDetectionFilter_h
120 #include "vtkFiltersModelingModule.h"
144 VTK_ALL_CONTACTS = 0,
145 VTK_FIRST_CONTACT = 1,
146 VTK_HALF_CONTACTS = 2
155 vtkSetClampMacro(CollisionMode,
int, VTK_ALL_CONTACTS, VTK_HALF_CONTACTS);
156 vtkGetMacro(CollisionMode,
int);
163 if (this->CollisionMode == VTK_ALL_CONTACTS)
165 return "AllContacts";
167 else if (this->CollisionMode == VTK_FIRST_CONTACT)
169 return "FirstContact";
173 return "HalfContacts";
187 double bounds2[6],
double tol2,
double x1[2],
double x2[3],
int CollisionMode);
234 vtkSetMacro(BoxTolerance,
float);
235 vtkGetMacro(BoxTolerance,
float);
241 vtkSetMacro(CellTolerance,
double);
242 vtkGetMacro(CellTolerance,
double);
250 vtkSetMacro(GenerateScalars,
int);
251 vtkGetMacro(GenerateScalars,
int);
252 vtkBooleanMacro(GenerateScalars,
int);
270 vtkGetMacro(NumberOfBoxTests,
int);
277 vtkSetMacro(NumberOfCellsPerNode,
int);
278 vtkGetMacro(NumberOfCellsPerNode,
int);
286 vtkSetClampMacro(Opacity,
float, 0.0, 1.0);
287 vtkGetMacro(Opacity,
float);
represent and manipulate 3D points
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for construction, type and printing.
void SetCollisionModeToHalfContacts()
Set the collision mode to VTK_ALL_CONTACTS to find all the contacting cell pairs with two points per ...
vtkCollisionDetectionFilter()
vtkLinearTransform * GetTransform(int i)
void SetMatrix(int i, vtkMatrix4x4 *matrix)
vtkAlgorithmOutput * GetOutputPort()
generate oriented bounding box (OBB) tree
vtkPolyData * GetContactsOutput()
Get the output with the points where the contacting cells intersect.
vtkMatrix4x4 * GetMatrix(int i)
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
a simple class to control print indentation
represent and manipulate 4x4 transformation matrices
vtkIdTypeArray * GetContactCells(int i)
Get an array of the contacting cells.
~vtkCollisionDetectionFilter() override
dynamic, self-adjusting array of vtkIdType
static vtkCollisionDetectionFilter * New()
Standard methods for construction, type and printing.
vtkMTimeType GetMTime() override
Return this object's modified time.
vtkPolyData * GetInputData(int i)
Set and Get the input vtk polydata models.
void SetTransform(int i, vtkLinearTransform *transform)
Proxy object to connect input/output ports.
concrete dataset represents vertices, lines, polygons, and triangle strips
performs collision determination between two polyhedral surfaces
int IntersectPolygonWithPolygon(int npts, double *pts, double bounds[6], int npts2, double *pts2, double bounds2[6], double tol2, double x1[2], double x2[3], int CollisionMode)
Description: Intersect two polygons, return x1 and x2 as the two points of intersection.
void SetCollisionModeToAllContacts()
Set the collision mode to VTK_ALL_CONTACTS to find all the contacting cell pairs with two points per ...
void SetInputData(int i, vtkPolyData *model)
Set and Get the input vtk polydata models.
const char * GetCollisionModeAsString(void)
Set the collision mode to VTK_ALL_CONTACTS to find all the contacting cell pairs with two points per ...
int GetNumberOfContacts()
vtkAlgorithmOutput * GetContactsOutputPort()
Get the output with the points where the contacting cells intersect.
vtkPolyData * GetOutput()
Get the output data object for a port on this algorithm.
void SetCollisionModeToFirstContact()
Set the collision mode to VTK_ALL_CONTACTS to find all the contacting cell pairs with two points per ...
vtkTypeUInt32 vtkMTimeType
Superclass for algorithms that produce only polydata as output.