|
Blender V5.3
|
#include <mtl_memory.hh>
Public Member Functions | |
MTLScratchBufferManager and MTLCircularBuffer implementation. | |
| MTLCircularBuffer (MTLContext &ctx, uint64_t initial_size, bool allow_grow) | |
| ~MTLCircularBuffer () | |
| MTLTemporaryBuffer | allocate_range (uint64_t alloc_size) |
| MTLTemporaryBuffer | allocate_range_aligned (uint64_t alloc_size, uint alignment) |
| void | flush () |
| void | reset () |
Friends | |
| class | MTLScratchBufferManager |
Definition at line 211 of file mtl_memory.hh.
| blender::gpu::MTLCircularBuffer::MTLCircularBuffer | ( | MTLContext & | ctx, |
| uint64_t | initial_size, | ||
| bool | allow_grow ) |
Definition at line 989 of file mtl_memory.mm.
References blender::BLI_assert(), blender::G, blender::G_DEBUG_GPU, and blender::gpu::MTLContext::get_current_frame_index().
Referenced by blender::gpu::MTLScratchBufferManager::init(), and MTLScratchBufferManager.
| blender::gpu::MTLCircularBuffer::~MTLCircularBuffer | ( | ) |
Definition at line 1008 of file mtl_memory.mm.
| MTLTemporaryBuffer blender::gpu::MTLCircularBuffer::allocate_range | ( | uint64_t | alloc_size | ) |
Definition at line 1013 of file mtl_memory.mm.
References allocate_range_aligned().
Referenced by MTLScratchBufferManager.
| MTLTemporaryBuffer blender::gpu::MTLCircularBuffer::allocate_range_aligned | ( | uint64_t | alloc_size, |
| uint | alignment ) |
Definition at line 1018 of file mtl_memory.mm.
References blender::BLI_assert(), blender::gpu::MTLBufferRange::buffer_offset, blender::ceil_to_multiple_ul(), blender::gpu::MTLBufferRange::data, flush(), blender::G, blender::G_DEBUG_GPU, blender::max_ulul(), blender::max_uu(), blender::gpu::MTLBufferRange::metal_buffer, blender::min_ulul(), MTL_LOG_DEBUG, MTL_LOG_WARNING, blender::gpu::MTLScratchBufferManager::mtl_scratch_buffer_max_size_, blender::gpu::MTLBufferRange::options, and blender::gpu::MTLBufferRange::size.
Referenced by allocate_range(), MTLScratchBufferManager, and blender::gpu::MTLScratchBufferManager::scratch_buffer_allocate_range_aligned().
| void blender::gpu::MTLCircularBuffer::flush | ( | ) |
Definition at line 1138 of file mtl_memory.mm.
References blender::BLI_assert(), and len().
Referenced by allocate_range_aligned(), blender::gpu::MTLScratchBufferManager::flush_active_scratch_buffer(), and MTLScratchBufferManager.
| void blender::gpu::MTLCircularBuffer::reset | ( | ) |
Definition at line 1149 of file mtl_memory.mm.
References blender::BLI_assert(), and MTL_NUM_SAFE_FRAMES.
Referenced by blender::gpu::MTLScratchBufferManager::ensure_increment_scratch_buffer(), and MTLScratchBufferManager.
|
friend |
Definition at line 212 of file mtl_memory.hh.
References allocate_range(), allocate_range_aligned(), flush(), MTLCircularBuffer(), MTLScratchBufferManager, and reset().
Referenced by MTLScratchBufferManager.