sm.voxelTerrainCell.fillEmptyConvexHull

Sets empty voxel (below threshold) material and density in convex hull shape in the cell's voxel grid.

Kind: Function

Environments: Terrain

Terrain

sm.voxelTerrainCell.fillEmptyConvexHull(
    vertices,
    margin,
    densityThreshold,
    material,
    density,
    noiseFrequency,
    noiseIntensity
)

Open the full Terrain reference

Parameters:

Name Type Description
vertices table Table of vertices {Vec3, ...} that make up the convex hull.
margin number Hull margin added outside the hull.
densityThreshold number Existing normalized density must be below threshold for fill to happen.
material integer New material to set in convex hull.
density number New normalized density to set in convex hull.
noiseFrequency (optional) number Noise frequency of applied simplex noise. (Defaults to 1)
noiseIntensity (optional) number Noise intensity of applied simplex noise. (Defaults to 0)