![]() |
ezEngine Release 26.9
|
CPU-side state for one voxel terrain volume managed by ezTerrainSystem. More...
#include <TerrainSystem.h>
Public Attributes | |
| bool | m_bInUse = false |
| bool | m_bDirty = true |
| bool | m_bInitialSolid = false |
| false = all cells start as air; true = all cells start as solid. Applied before brushes each bake. | |
| ezUInt8 | m_uiCleanupIterations = 1 |
| Number of topology-cleanup iterations to run after baking (0–4). Higher values remove more spike voxels at the cost of slightly more GPU work. | |
| ezUInt16 | m_uiResolution = 32 |
| User-selected inner voxels per axis (no border, no alignment). Equals the triangulated cell count. | |
| ezUInt16 | m_uiPackPitch = 5 |
| Packed X row count = BufX / 8, where BufX = ((m_uiResolution + 2*border + 7) & ~7). Stride for BakedVoxels. | |
| float | m_fVoxelSize = 1.0f |
| World-space size of one voxel. | |
| ezTransform | m_GlobalTransform = ezTransform::MakeIdentity() |
| ezGALBufferHandle | m_hFinalVertices |
| StructuredBuffer<VoxelGpuVertex> for rendering. | |
| ezGALBufferHandle | m_hFinalIndices |
| ezGALBufferHandle | m_hFinalDrawArgs |
| DrawArgs buffer: 4 uints {IndexCount, 1, 0, 0}. Written by VoxelCompactCopyCS thread 0. | |
| float | m_fFillHeight = 0.0f |
| World-space Z height below which voxels start as solid (when m_bInitialSolid is true). | |
| ezTagSet | m_Tags |
| Identity tags for this voxel volume; matched against brush include-tag filters. | |
| ezUInt64 | m_uiBrushOverlapHash = 0 |
CPU-side state for one voxel terrain volume managed by ezTerrainSystem.
| ezGALBufferHandle ezTerrainData_Voxel::m_hFinalIndices |
StructuredBuffer<uint> for rendering.
| ezGALBufferHandle ezTerrainData_Voxel::m_hFinalVertices |
StructuredBuffer<VoxelGpuVertex> for rendering.
Final render buffers — written from the shared compact scratch by VoxelCompactCopyCS each rebuild. Allocated at worst-case capacity in CreateVoxelTerrain; the copy is GPU-driven (DispatchIndirect) so only the used entries are written, and DrawArgs controls the actual draw count.