ZLab.Discrete ZLab.Discrete
ZLab.Discrete ZLab.Discrete
Developed by Zeke Zhang

Search Results for

    Edit this page

    Class DiscreteMesher

    Naive voxel meshing utilities: emits per-voxel meshes or a single merged mesh. Uses face culling with Morton-coded occupancy when voxel size is uniform.

    Inheritance
    object
    DiscreteMesher
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: ZLab.Discrete.Operations.Meshing
    Assembly: ZLab.Discrete.dll
    Syntax
    public static class DiscreteMesher
    Remarks

    Assumes voxels instances lie on a rectilinear grid. For the culled path, all voxels must share an identical voxelSize. If voxel sizes vary, all six faces per voxel are emitted (no merging).

    Methods

    Name Description
    GenerateMesh(ReadOnlySpan<Vector3>, Vector3, CordSystem)

    Generates a single mesh from a set of voxels, assuming a uniform voxelSize. Internal faces are culled using ZLab.Discrete.Algorithms.Encoding.Morton occupancy set (O(1) neighbor checks).

    GenerateMesh(ReadOnlySpan<Vector3>, ReadOnlySpan<Vector3>, CordSystem)

    Generates a single mesh from a set of voxels. Internal faces are culled using ZLab.Discrete.Algorithms.Encoding.Morton occupancy set (O(1) neighbor checks).

    GenerateMeshes(ReadOnlySpan<Vector3>, Vector3, Span<MeshF>, CordSystem)

    Generates an individual quad-mesh per voxel (all voxels share the same voxelSize).

    GenerateMeshes(ReadOnlySpan<Vector3>, Vector3, CordSystem)

    Generates an individual quad-mesh per voxel (all voxels share the same voxelSize).

    GenerateMeshes(ReadOnlySpan<Vector3>, ReadOnlySpan<Vector3>, Span<MeshF>, CordSystem)

    Generates an individual quad-mesh per voxel (no face merging across voxels).

    GenerateMeshes(ReadOnlySpan<Vector3>, ReadOnlySpan<Vector3>, CordSystem)

    Generates an individual quad-mesh per voxel (no face merging across voxels).

    GetVoxelBounds(ReadOnlySpan<Vector3>, Vector3)

    Gets axis-aligned bounding boxes for a set of voxels (all voxels share the same voxelSize).

    GetVoxelBounds(ReadOnlySpan<Vector3>, Vector3, Span<BBox>)

    Gets axis-aligned bounding boxes for a set of voxels (all voxels share the same voxelSize).

    GetVoxelBounds(ReadOnlySpan<Vector3>, ReadOnlySpan<Vector3>)

    Gets axis-aligned bounding boxes for a set of voxels.

    GetVoxelBounds(ReadOnlySpan<Vector3>, ReadOnlySpan<Vector3>, Span<BBox>)

    Gets axis-aligned bounding boxes for a set of voxels.