public MeshGenerator(MeshSettings settings) { this.settings = settings; Mesh = new Mesh(); lookup = MeshLookup.GetInstance(settings); Allocate(); }
public void Dispose() { foreach (ChunkData data in dataByPos.Values) { data.CancelJobs(ref numWorkers); data.Dispose(); } foreach (ChunkData data in reusableData) { data.CancelJobs(ref numWorkers); data.Dispose(); } MeshLookup.GetInstance().Dispose(); }