46#ifndef vtkVoronoiTile_h
47#define vtkVoronoiTile_h
50#include "vtkFiltersMeshingModule.h"
56VTK_ABI_NAMESPACE_BEGIN
114 this->
Points.reserve(256);
118 this->
SortP.reserve(256);
120 this->
Petals->SetNumberOfComponents(3);
121 this->
Petals->Allocate(256);
172 bool InFlower(
const double x[2]);
180 return (this->
Petals->GetNumberOfTuples() > 0 ? this->Petals :
nullptr);
220 if (itr == (this->Points.end() - 1))
222 return this->Points.begin();
257 for (
const auto& p : this->
Points)
271 for (
const auto& p : this->
Points)
dynamic, self-adjusting array of double
static double Distance2BetweenPoints2D(const double p1[2], const double p2[2])
Compute distance squared between two 2D points p1 and p2.
represent and manipulate 3D points
concrete dataset represents vertices, lines, polygons, and triangle strips
Hold a reference to a vtkObjectBase instance.
static vtkSmartPointer< T > New()
Create an instance of a VTK object.
implicit function for a set of spheres
void ProducePolyData(vtkPolyData *pd)
double GetCircumFlower2()
Methods to determine whether a point x[2] is within the Voronoi flower, or Voronoi circumflower.
vtkVoronoiTile()
Constructor.
void Initialize(vtkIdType ptId, const double x[3], vtkPoints *pts, vtkIdType nPts, const vtkIdType *p)
Initialize with a convex polygon.
vtkSmartPointer< vtkDoubleArray > Petals
PointRingIterator Next(PointRingIterator &itr)
void Initialize(vtkIdType genPtId, const double genPt[3], double bds[4])
Method to initiate the construction of the polygon.
vtkDoubleArray * GetPetals()
void ComputeCircumFlower()
double * GetGeneratorPosition()
vtkIdType GetNumberOfPoints()
void UpdatePetals(double cf2)
const PointRingType & GetPoints()
void ProducePolyData(vtkPolyData *pd, vtkSpheres *spheres)
Produce a vtkPolyData (and optional implicit function) from the current polygon.
ClipIntersectionStatus IntersectWithLine(double origin[2], double normal[2], vtkIdType neiPtId)
bool InFlower(const double x[2])
bool InCircumFlower(double r2)
ClipIntersectionStatus Clip(vtkIdType neiPtId, const double neiPt[2])
Method to clip the current convex tile with a plane defined by a neighboring point.
vtkIdType GetGeneratorPointId()
Obtain information about the generated tile.
std::vector< vtkTilePoint * > SortP
bool RecomputeCircumFlower
vtkTilePoint(double tileX[2], double x[2], vtkIdType neiId)
vtkTilePoint(const vtkTilePoint &v)=default
ClipIntersectionStatus
Classes, structs, and typedefs in support of Voronoi processing.
std::vector< vtkTilePoint > PointRingType
std::vector< vtkTilePoint >::iterator PointRingIterator