|
SBgl 0.1.0
A graphics framework in C99
|
Internal state for the voxel system. This structure adheres to Data-Oriented Design principles by maintaining contiguous arrays and minimizing pointer indirection. More...

Data Fields | |
| sbgl_Context * | ctx |
| Pointer to the active engine context. | |
| SblArena | poolArena |
| Arena for the CPU-side management pool for chunk slots. | |
| VoxelPool * | pool |
| Pointer to the CPU-side management pool for chunk slots. | |
| uint32_t | chunk_radius |
| Radius (in chunks) for visibility and generation logic. | |
| bool | enable_telemetry |
| Enables console output for performance metrics. | |
| sbgl_ComputePipeline | genPipe |
| Compute pipeline for initial chunk generation. | |
| sbgl_ComputePipeline | shellPipe |
| Compute pipeline for shell/boundary processing. | |
| sbgl_ComputePipeline | cullPipe |
| Compute pipeline for frustum culling and indirect command generation. | |
| sbgl_Buffer | maskBuf |
| GPU buffer storing the presence mask for all active chunks. | |
| sbgl_Buffer | instBuf |
| GPU buffer containing per-instance data for visible chunks. | |
| sbgl_Buffer | materialPaletteBuf |
| GPU buffer storing the material palette attributes. | |
| sbgl_Buffer | aabbBuf [2] |
| GPU buffer storing Axis-Aligned Bounding Boxes for culling. Double-buffered. | |
| sbgl_AABB * | cpuAABB |
| CPU-side mirror of AABB data to avoid mapping the previous frame's GPU buffer. | |
| sbgl_Buffer | indirectCmdBuf [2] |
| Double-buffered GPU storage for indirect draw commands. Double buffering prevents CPU-GPU synchronization stalls during command recording. | |
| sbgl_Buffer | shellCountsBuf |
| GPU storage for shell/active instance counts. | |
| sbgl_ivec3 | last_cam_chunk |
| World-space chunk coordinates of the camera in the previous frame. | |
| sbgl_Vec3 | camera_pos |
| Current world-space position of the camera. | |
| uint32_t | frame_idx |
| Monotonically increasing index for double-buffer rotation. | |
| uint64_t | total_frames |
| Total number of frames processed for LRU tracking. | |
| float | telemetry_timer |
| Timer for periodic telemetry reporting. | |
| uint32_t | fps_frames |
| Frame counter for FPS calculation. | |
| double | last_update_time |
| Time of the previous update for delta calculation. | |
Internal state for the voxel system. This structure adheres to Data-Oriented Design principles by maintaining contiguous arrays and minimizing pointer indirection.
Definition at line 70 of file sbgl_voxel.c.
| sbgl_Buffer sbgl_VoxelSystem::aabbBuf[2] |
GPU buffer storing Axis-Aligned Bounding Boxes for culling. Double-buffered.
Definition at line 105 of file sbgl_voxel.c.
| sbgl_Vec3 sbgl_VoxelSystem::camera_pos |
Current world-space position of the camera.
Definition at line 125 of file sbgl_voxel.c.
| uint32_t sbgl_VoxelSystem::chunk_radius |
Radius (in chunks) for visibility and generation logic.
Definition at line 81 of file sbgl_voxel.c.
| sbgl_AABB* sbgl_VoxelSystem::cpuAABB |
CPU-side mirror of AABB data to avoid mapping the previous frame's GPU buffer.
Definition at line 108 of file sbgl_voxel.c.
| sbgl_Context* sbgl_VoxelSystem::ctx |
Pointer to the active engine context.
Definition at line 72 of file sbgl_voxel.c.
| sbgl_ComputePipeline sbgl_VoxelSystem::cullPipe |
Compute pipeline for frustum culling and indirect command generation.
Definition at line 93 of file sbgl_voxel.c.
| bool sbgl_VoxelSystem::enable_telemetry |
Enables console output for performance metrics.
Definition at line 84 of file sbgl_voxel.c.
| uint32_t sbgl_VoxelSystem::fps_frames |
Frame counter for FPS calculation.
Definition at line 137 of file sbgl_voxel.c.
| uint32_t sbgl_VoxelSystem::frame_idx |
Monotonically increasing index for double-buffer rotation.
Definition at line 128 of file sbgl_voxel.c.
| sbgl_ComputePipeline sbgl_VoxelSystem::genPipe |
Compute pipeline for initial chunk generation.
Definition at line 87 of file sbgl_voxel.c.
| sbgl_Buffer sbgl_VoxelSystem::indirectCmdBuf[2] |
Double-buffered GPU storage for indirect draw commands. Double buffering prevents CPU-GPU synchronization stalls during command recording.
Definition at line 114 of file sbgl_voxel.c.
| sbgl_Buffer sbgl_VoxelSystem::instBuf |
GPU buffer containing per-instance data for visible chunks.
Definition at line 99 of file sbgl_voxel.c.
| sbgl_ivec3 sbgl_VoxelSystem::last_cam_chunk |
World-space chunk coordinates of the camera in the previous frame.
Definition at line 122 of file sbgl_voxel.c.
| double sbgl_VoxelSystem::last_update_time |
Time of the previous update for delta calculation.
Definition at line 140 of file sbgl_voxel.c.
| sbgl_Buffer sbgl_VoxelSystem::maskBuf |
GPU buffer storing the presence mask for all active chunks.
Definition at line 96 of file sbgl_voxel.c.
| sbgl_Buffer sbgl_VoxelSystem::materialPaletteBuf |
GPU buffer storing the material palette attributes.
Definition at line 102 of file sbgl_voxel.c.
| VoxelPool* sbgl_VoxelSystem::pool |
Pointer to the CPU-side management pool for chunk slots.
Definition at line 78 of file sbgl_voxel.c.
| SblArena sbgl_VoxelSystem::poolArena |
Arena for the CPU-side management pool for chunk slots.
Definition at line 75 of file sbgl_voxel.c.
| sbgl_Buffer sbgl_VoxelSystem::shellCountsBuf |
GPU storage for shell/active instance counts.
Definition at line 119 of file sbgl_voxel.c.
| sbgl_ComputePipeline sbgl_VoxelSystem::shellPipe |
Compute pipeline for shell/boundary processing.
Definition at line 90 of file sbgl_voxel.c.
| float sbgl_VoxelSystem::telemetry_timer |
Timer for periodic telemetry reporting.
Definition at line 134 of file sbgl_voxel.c.
| uint64_t sbgl_VoxelSystem::total_frames |
Total number of frames processed for LRU tracking.
Definition at line 131 of file sbgl_voxel.c.