Contents
- Description
- Method Summary
- Method Details
- getJitter()
- evalPoint(int, double, double, int, int, int, double, double, ResultBuffer.ResultBuffer2d)
- evalPoint2(int, double, double, int, int, int, double, double, ResultBuffer.ResultBuffer2d)
- evalPoint(int, double, double, double, int, int, int, int, double, double, double, ResultBuffer.ResultBuffer3d)
- evalPoint2(int, double, double, double, int, int, int, int, double, double, double, ResultBuffer.ResultBuffer3d)
- collectPoint(int, int, int, double, double, T, PointConsumer)
- of(PointDistanceFunction, IDoubleCondition, IDoubleRange, CellJitter)
- of(PointDistanceFunction, IDoubleCondition, IDoubleRange, int, SkipCellPointEvaluator.Mode, CellJitter)
Interface PointEvaluator
- All Known Implementing Classes:
BorderPointEvaluator, BranchEvaluator, DensityPointEvaluator, DistancePointEvaluator, JitterPointEvaluator, NormalPointEvaluator, SkipCellPointEvaluator
public interface PointEvaluator
Accepts cell centre-points and handles how they are passed on to the provided ResultBuffers or PointConsumers.
-
Method Summary
Modifier and TypeMethodDescriptiondefault <T> voidcollectPoint(int cellHash, int cellX, int cellY, double cellCentreX, double cellCentreY, T ctx, PointConsumer<T> consumer) Accepts a cell centre-point and passes it to the provided consumer.voidevalPoint(int seed, double x, double y, double z, int cellHash, int cellX, int cellY, int cellZ, double cellPointX, double cellPointY, double cellPointZ, ResultBuffer.ResultBuffer3d buffer) Evaluate the distance to a cell-point in a 3D neighborhood, recording only the closest result.voidevalPoint(int seed, double x, double y, int cellHash, int cellX, int cellY, double cellPointX, double cellPointY, ResultBuffer.ResultBuffer2d buffer) Evaluate the distance to a cell-point in a 2D neighborhood, recording only the closest result.voidevalPoint2(int seed, double x, double y, double z, int cellHash, int cellX, int cellY, int cellZ, double cellPointX, double cellPointY, double cellPointZ, ResultBuffer.ResultBuffer3d buffer) Evaluate the distance to a cell-point in a 3D neighborhood, recording the closest and second-closest result.voidevalPoint2(int seed, double x, double y, int cellHash, int cellX, int cellY, double cellPointX, double cellPointY, ResultBuffer.ResultBuffer2d buffer) Evaluate the distance to a cell-point in a 2D neighborhood, recording the closest and second-closest result.default CellJitterstatic PointEvaluatorof(PointDistanceFunction distanceFunction, IDoubleCondition density, IDoubleRange distanceMod, int skipCount, SkipCellPointEvaluator.Mode skipMode, CellJitter jitter) Compose a PointEvaluator from the provided functions.static PointEvaluatorof(PointDistanceFunction distanceFunction, IDoubleCondition density, IDoubleRange distanceMod, CellJitter jitter) Compose a PointEvaluator from the provided functions.
-
Method Details
-
getJitter
- Returns:
- The jitter configuration to use when calculating cell centre-points.
-
evalPoint
void evalPoint(int seed, double x, double y, int cellHash, int cellX, int cellY, double cellPointX, double cellPointY, ResultBuffer.ResultBuffer2d buffer) Evaluate the distance to a cell-point in a 2D neighborhood, recording only the closest result.- Parameters:
seed- The seed being sampled.x- The x-coordinate being sampled.y- The y-coordinate being sampled.cellHash- The seeded hash of the cell.cellX- The x-index of the cell.cellY- The y-index of the cell.cellPointX- The x-coordinate of the cell centre point.cellPointY- The y-coordinate of the cell centre point.buffer- The buffer into which the result of the evaluation is recorded.
-
evalPoint2
void evalPoint2(int seed, double x, double y, int cellHash, int cellX, int cellY, double cellPointX, double cellPointY, ResultBuffer.ResultBuffer2d buffer) Evaluate the distance to a cell-point in a 2D neighborhood, recording the closest and second-closest result.- Parameters:
seed- The seed being sampled.x- The x-coordinate being sampled.y- The y-coordinate being sampled.cellHash- The seeded hash of the cell.cellX- The x-index of the cell.cellY- The y-index of the cell.cellPointX- The x-coordinate of the cell centre point.cellPointY- The y-coordinate of the cell centre point.buffer- The buffer into which the result of the evaluation is recorded.
-
evalPoint
void evalPoint(int seed, double x, double y, double z, int cellHash, int cellX, int cellY, int cellZ, double cellPointX, double cellPointY, double cellPointZ, ResultBuffer.ResultBuffer3d buffer) Evaluate the distance to a cell-point in a 3D neighborhood, recording only the closest result.- Parameters:
seed- The seed being sampled.x- The x-coordinate being sampled.y- The y-coordinate being sampled.z- The z-coordinate being sampled.cellHash- The seeded hash of the cell.cellX- The x-index of the cell.cellY- The y-index of the cell.cellZ- The z-index of the cell.cellPointX- The x-coordinate of the cell centre point.cellPointY- The y-coordinate of the cell centre point.cellPointZ- The z-coordinate of the cell centre point.buffer- The buffer into which the result of the evaluation is recorded.
-
evalPoint2
void evalPoint2(int seed, double x, double y, double z, int cellHash, int cellX, int cellY, int cellZ, double cellPointX, double cellPointY, double cellPointZ, ResultBuffer.ResultBuffer3d buffer) Evaluate the distance to a cell-point in a 3D neighborhood, recording the closest and second-closest result.- Parameters:
seed- The seed being sampled.x- The x-coordinate being sampled.y- The y-coordinate being sampled.z- The z-coordinate being sampled.cellHash- The seeded hash of the cell.cellX- The x-index of the cell.cellY- The y-index of the cell.cellZ- The z-index of the cell.cellPointX- The x-coordinate of the cell centre point.cellPointY- The y-coordinate of the cell centre point.cellPointZ- The z-coordinate of the cell centre point.buffer- The buffer into which the result of the evaluation is recorded.
-
collectPoint
default <T> void collectPoint(int cellHash, int cellX, int cellY, double cellCentreX, double cellCentreY, T ctx, @Nonnull PointConsumer<T> consumer) Accepts a cell centre-point and passes it to the provided consumer.- Type Parameters:
T- The type of the contextual information being passed to the consumer.- Parameters:
cellHash- The hash of the cell.cellCentreX- The x-coordinate of the cell centre-point.cellCentreY- The y-coordinate of the cell centre-point.ctx- An arbitrary piece of contextual information to pass to the collector for each point visited.consumer- A consumer of the cell centre-point.
-
of
static PointEvaluator of(PointDistanceFunction distanceFunction, @Nullable IDoubleCondition density, @Nullable IDoubleRange distanceMod, CellJitter jitter) Compose a PointEvaluator from the provided functions.- Parameters:
distanceFunction- The method for calculating distances.density- The density condition that determines which (if any) cell points are occluded.distanceMod- The distance range modifier applied to calculated distances.- Returns:
- A PointEvaluator that uses the provided functions.
-
of
static PointEvaluator of(PointDistanceFunction distanceFunction, @Nullable IDoubleCondition density, @Nullable IDoubleRange distanceMod, int skipCount, @Nonnull SkipCellPointEvaluator.Mode skipMode, CellJitter jitter) Compose a PointEvaluator from the provided functions.- Parameters:
distanceFunction- The method for calculating distances.density- The density condition that determines which (if any) cell points are occluded.distanceMod- The distance range modifier applied to calculated distances.- Returns:
- A PointEvaluator that uses the provided functions.
-