Enum CellularDistanceType
Specifies the distance metric used when computing distances to feature points in cellular (Worley) noise. The choice of metric fundamentally changes the visual character of the resulting Voronoi diagram.
Namespace: Scylla.Core.Util.Noise
Assembly: ScyllaCore.dll
Syntax
public enum CellularDistanceType
Remarks
Each metric computes distance differently, shaping how cell boundaries appear. The metric is applied consistently to both the nearest-neighbor (F1) and second-nearest-neighbor (F2) distances within the cellular noise algorithm.
This enum is consumed by DistanceType and
forwarded to the underlying CellularNoise algorithm by
EvaluateCellular2D(float, float, CellularSettings),
EvaluateCellular3D(float, float, float, CellularSettings),
FractalCellular2D(float, float, CellularSettings), and
FractalCellular3D(float, float, float, CellularSettings).
Fields
| Name | Description |
|---|---|
| Chebyshev | Chebyshev distance (chessboard metric): the maximum of absolute coordinate differences across all axes. Produces diamond-shaped cell boundaries in 2D and cubic boundaries in 3D. |
| Euclidean | Standard Euclidean distance: the straight-line distance between a sample point and a feature point, computed as the square root of the sum of squared coordinate differences. Produces smooth, rounded cell boundaries with a natural, organic Voronoi appearance. This is the default and most commonly used metric. |
| Manhattan | Manhattan distance (taxicab metric): the sum of absolute coordinate differences along each axis. Produces rectangular, grid-aligned cell boundaries with a blocky, architectural character. |