|
Public Member Functions |
|
| BlueNoise (float radius, bool isTiled=true, bool usesGrid=true) |
|
bool | pointInDomain (Vec2 &a) |
|
float | getDistanceSquared (Vec2 &a, Vec2 &b) |
|
float | getDistance (Vec2 &a, Vec2 &b) |
|
Vec2 | randomPoint () |
|
Vec2 | getTiled (Vec2 v) |
|
void | getGridXY (Vec2 &v, int *gx_out, int *gy_out) |
|
void | addPoint (Vec2 pt) |
|
int | findNeighbors (Vec2 &pt, float radius) |
|
float | findClosestNeighbor (Vec2 &pt, float radius) |
|
void | findNeighborRanges (int index, RangeList &rl) |
|
void | maximize () |
|
void | relax () |
|
void | complete () |
|
void | writeToBool (bool *noise, int size) |
Data Fields |
|
std::vector< Vec2 > | points |
|
float | radius |
|
bool | isTiled |
Protected Attributes |
|
RNG | m_rng |
|
std::vector< int > | m_neighbors |
|
int(* | m_grid )[kMaxPointsPerCell] |
|
int | m_gridSize |
|
float | m_gridCellSize |