Table of Contents

Class DepthMesher

Converts the Meta Quest's Depth API textures into a 3D mesh in worldspace using the surface nets algorithm.

public class DepthMesher : DontCreateNewSingleton<DepthMesher>
Inheritance
object
DepthMesher

Fields

TargetMeshRefreshRateHertz

The target refresh frequency for the generated mesh (in Hz). Lower rates reduce CPU overhead for stable scenes.

public float TargetMeshRefreshRateHertz

Field Value

float

TargetVolumeUpdateRateHertz

The target update frequency for the TSDF volume (in Hz). Higher rates improve responsiveness but increase GPU load; lower rates reduce overhead in stable scenes.

public float TargetVolumeUpdateRateHertz

Field Value

float

Properties

Mesh

The generated mesh.

public Mesh Mesh { get; }

Property Value

Mesh

Volume

The TSDF volume used for the surface nets operation.

public RenderTexture Volume { get; }

Property Value

RenderTexture

Methods

Awake()

protected override void Awake()

Clear()

Clears the TSDF volume and vertex-index buffer, essentially resetting the system.

public void Clear()

OnDestroy()

protected void OnDestroy()

OnDisable()

protected void OnDisable()

OnEnable()

protected void OnEnable()

Start()

protected void Start()

Events

OnMeshRefreshed

Invoked after the Mesh is updated and all optional collision and NavMesh baking completes.

public event Action? OnMeshRefreshed

Event Type

Action