#include <Voronoi.h>
|
| VORONOI_API | FVoronoiDiagram (const TArrayView< const FVector > &Sites, double ExtraBoundingSpace, double SquaredDistSkipPtThreshold=UE_KINDA_SMALL_NUMBER) |
| |
| VORONOI_API | FVoronoiDiagram (const TArrayView< const FVector > &Sites, const FBox &Bounds, double ExtraBoundingSpace, double SquaredDistSkipPtThreshold=UE_KINDA_SMALL_NUMBER) |
| |
| VORONOI_API | FVoronoiDiagram (int32 ExpectedNumSites, const FBox &Bounds, double ExtraBoundingSpace) |
| |
| | FVoronoiDiagram () |
| |
| | FVoronoiDiagram (const FVoronoiDiagram &Other)=delete |
| |
| FVoronoiDiagram & | operator= (const FVoronoiDiagram &Other)=delete |
| |
| | FVoronoiDiagram (FVoronoiDiagram &&Other)=default |
| |
| FVoronoiDiagram & | operator= (FVoronoiDiagram &&Other)=default |
| |
| VORONOI_API void | Initialize (const TArrayView< const FVector > &Sites, const FBox &Bounds, double ExtraBoundingSpace, double SquaredDistSkipPtThreshold=UE_KINDA_SMALL_NUMBER) |
| |
| VORONOI_API | ~FVoronoiDiagram () |
| |
| int32 | Num () const |
| |
| VORONOI_API void | AddSites (const TArrayView< const FVector > &Sites, double SquaredDistSkipPtThreshold=0.0f) |
| |
| VORONOI_API void | ComputeAllCellsSerial (TArray< FVoronoiCellInfo > &AllCells) |
| |
| VORONOI_API void | ComputeAllCells (TArray< FVoronoiCellInfo > &AllCells, int32 ApproxSitesPerThread=-1) |
| |
| VORONOI_API void | ComputeAllNeighbors (TArray< TArray< int32 > > &AllNeighbors, bool bExcludeBounds=true, int32 ApproxSitesPerThread=-1) |
| |
| VORONOI_API void | ComputeCellEdgesSerial (TArray< TTuple< FVector, FVector > > &Edges, TArray< int32 > &CellMember) |
| |
| VORONOI_API void | ComputeCellEdges (TArray< TTuple< FVector, FVector > > &Edges, TArray< int32 > &CellMember, int32 ApproxSitesPerThread=-1) |
| |
| VORONOI_API int32 | FindCell (const FVector &Pos, FVoronoiComputeHelper &ComputeHelper, FVector &OutFoundSite) const |
| |
| int32 | FindCell (const FVector &Pos, FVoronoiComputeHelper &ComputeHelper) const |
| |
| VORONOI_API FVoronoiComputeHelper | GetComputeHelper () const |
| |
| int32 | ApproxSitesPerThreadWithDefault (int32 ApproxSitesPerThreadIn) |
| |
◆ FVoronoiDiagram() [1/6]
Create a Voronoi diagram with the given sites, in a box bounding containing those sites
- Parameters
-
| Sites | Voronoi sites for the diagram |
| ExtraBoundingSpace | Voronoi diagram will be computed within the bounding box of the sites + this amount of extra space in each dimension |
| SquaredDistSkipPtThreshold | A safety threshold to avoid creating invalid cells: sites that are within this distance of an already-added site will not be added (If you know there will be no duplicate sites, can set to zero for faster perf.) |
◆ FVoronoiDiagram() [2/6]
Create a Voronoi diagram with the given sites, in a given bounding box
- Parameters
-
| Sites | Voronoi sites for the diagram |
| Bounds | Bounding box within which to compute the Voronoi diagram |
| ExtraBoundingSpace | Voronoi diagram will be computed within the input Bounds + this amount of extra space in each dimension |
| SquaredDistSkipPtThreshold | A safety threshold to avoid creating invalid cells: sites that are within this distance of an already-added site will not be added. (If you know there will be no duplicate sites, can set to zero for faster perf.) |
◆ FVoronoiDiagram() [3/6]
| FVoronoiDiagram::FVoronoiDiagram |
( |
int32 |
ExpectedNumSites, |
|
|
const FBox & |
Bounds, |
|
|
double |
ExtraBoundingSpace |
|
) |
| |
Make a container for a Voronoi diagram without any points. Call AddSites() after to finish creating the diagram.
- Parameters
-
| ExpectedNumSites | How many sites you expect to add in total |
| Bounds | Bounding box within which to compute the Voronoi diagram |
| ExtraBoundingSpace | Amount to expand the bounding box before computing the Voronoi diagram |
◆ FVoronoiDiagram() [4/6]
| FVoronoiDiagram::FVoronoiDiagram |
( |
| ) |
|
|
inline |
Make an empty diagram, to be filled in with a subsequent call to "Initialize()"
◆ FVoronoiDiagram() [5/6]
◆ FVoronoiDiagram() [6/6]
◆ ~FVoronoiDiagram()
| FVoronoiDiagram::~FVoronoiDiagram |
( |
| ) |
|
|
default |
◆ AddSites()
◆ ApproxSitesPerThreadWithDefault()
| int32 FVoronoiDiagram::ApproxSitesPerThreadWithDefault |
( |
int32 |
ApproxSitesPerThreadIn | ) |
|
|
inline |
◆ ComputeAllCells()
◆ ComputeAllCellsSerial()
◆ ComputeAllNeighbors()
◆ ComputeCellEdges()
◆ ComputeCellEdgesSerial()
◆ FindCell() [1/2]
◆ FindCell() [2/2]
Find the closest Voronoi cell to a given position
- Parameters
-
| Pos | Position to query for closest point |
| ComputeHelper | A valid helper as returned by GetComputeHelper() for this voronoi diagram |
| OutFoundSite | The position of the closest Voronoi site, if any |
- Returns
- The id of the Voronoi cell containing the given position, or -1 if position is outside diagram
◆ GetBounds()
◆ GetComputeHelper()
◆ Initialize()
Create a Voronoi diagram with the given sites, in a given bounding box. Any previous data is discarded.
- Parameters
-
| Sites | Voronoi sites for the diagram |
| Bounds | Bounding box within which to compute the Voronoi diagram |
| ExtraBoundingSpace | Voronoi diagram will be computed within the input Bounds + this amount of extra space in each dimension |
| SquaredDistSkipPtThreshold | A safety threshold to avoid creating invalid cells: sites that are within this distance of an already-added site will not be added. (If you know there will be no duplicate sites, can set to zero for faster perf.) |
◆ Num()
| int32 FVoronoiDiagram::Num |
( |
| ) |
const |
|
inline |
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ MinDefaultSitesPerThread
| const int FVoronoiDiagram::MinDefaultSitesPerThread = 150 |
|
static |
The documentation for this class was generated from the following files:
- Engine/Source/Runtime/Experimental/Voronoi/Public/Voronoi/Voronoi.h
- Engine/Source/Runtime/Experimental/Voronoi/Private/Voronoi/Voronoi.cpp