Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2022-07-20 05:50:45 +0300
committerHans Goudey <h.goudey@me.com>2022-07-20 05:50:45 +0300
commit8c5d90f5ce928e45249ddd9f642c24b6dd69d64c (patch)
treeccbbf8f065eadbe85cdc1f8d70a9d036e9c030b5 /source/blender/gpu/metal/mtl_memory.hh
parent111bf7d76b080555fd524b2b4a138bcad2e5b206 (diff)
parent215f805ce6b540177dedd71721e62c56a764a5ea (diff)
Merge branch 'master' into temp-legacy-mesh-format-optiontemp-legacy-mesh-format-option
Diffstat (limited to 'source/blender/gpu/metal/mtl_memory.hh')
-rw-r--r--source/blender/gpu/metal/mtl_memory.hh18
1 files changed, 11 insertions, 7 deletions
diff --git a/source/blender/gpu/metal/mtl_memory.hh b/source/blender/gpu/metal/mtl_memory.hh
index daa049e78af..dc5417dc11a 100644
--- a/source/blender/gpu/metal/mtl_memory.hh
+++ b/source/blender/gpu/metal/mtl_memory.hh
@@ -78,8 +78,10 @@
* Usage:
* MTLContext::get_global_memory_manager(); - static routine to fetch global memory manager.
*
- * gpu::MTLBuffer *allocate_buffer(size, is_cpu_visibile, bytes=nullptr)
- * gpu::MTLBuffer *allocate_buffer_aligned(size, alignment, is_cpu_visibile, bytes=nullptr)
+ * gpu::MTLBuffer *allocate(size, is_cpu_visibile)
+ * gpu::MTLBuffer *allocate_aligned(size, alignment, is_cpu_visibile)
+ * gpu::MTLBuffer *allocate_with_data(size, is_cpu_visibile, data_ptr)
+ * gpu::MTLBuffer *allocate_aligned_with_data(size, alignment, is_cpu_visibile, data_ptr)
*/
/* Debug memory statistics: Disabled by Macro rather than guarded for
@@ -389,11 +391,13 @@ class MTLBufferPool {
void init(id<MTLDevice> device);
~MTLBufferPool();
- gpu::MTLBuffer *allocate_buffer(uint64_t size, bool cpu_visible, const void *bytes = nullptr);
- gpu::MTLBuffer *allocate_buffer_aligned(uint64_t size,
- uint alignment,
- bool cpu_visible,
- const void *bytes = nullptr);
+ gpu::MTLBuffer *allocate(uint64_t size, bool cpu_visible);
+ gpu::MTLBuffer *allocate_aligned(uint64_t size, uint alignment, bool cpu_visible);
+ gpu::MTLBuffer *allocate_with_data(uint64_t size, bool cpu_visible, const void *data = nullptr);
+ gpu::MTLBuffer *allocate_aligned_with_data(uint64_t size,
+ uint alignment,
+ bool cpu_visible,
+ const void *data = nullptr);
bool free_buffer(gpu::MTLBuffer *buffer);
/* Flush MTLSafeFreeList buffers, for completed lists in `completed_safelist_queue_`,