Single-header math library for SBgl.
void VoxelPool_UpdateFrame(VoxelPool *pool, uint64_t frame)
Advances the pool's internal frame counter for LRU tracking.
VoxelPool * VoxelPool_Init(SblArena *arena, uint32_t capacity)
Initializes a VoxelPool on the provided arena.
int32_t VoxelPool_AcquireSlot(VoxelPool *pool, sbgl_ivec3 pos, bool *is_new)
Acquires a slot for a given chunk position. Returns the slot index (0 to capacity-1)....
Arena allocator implementation.
VoxelPool manages a fixed number of slots for voxel chunks. It uses a flat array layout to maintain c...
uint64_t * last_used_frames
3D integer vector for chunk coordinates.