diff options
author | quou <quou@disroot.org> | 2024-12-29 13:40:45 +1100 |
---|---|---|
committer | quou <quou@disroot.org> | 2024-12-29 13:41:56 +1100 |
commit | 7383cfcbe8ade4dce057608e971e8cb7d4b1feb7 (patch) | |
tree | 6e00d45e89c46560b2a6de6729781e6079c678d7 /video.cpp | |
parent | c41a63370e54cc1e6e0c1b1dc20e219f3cac2845 (diff) |
allow binding only a portion of a cbuffer
Diffstat (limited to 'video.cpp')
-rw-r--r-- | video.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -2760,8 +2760,8 @@ void Descriptor_Set_Vk::init( Buffer_Vk& b = *(Buffer_Vk*)&dev->get_buffer(cd->buffer); assert(cd->buffer); buf.buffer = b.buf; - buf.offset = 0; - buf.range = b.size; + buf.offset = cd->offset; + buf.range = cd->size? cd->size: b.size; wd.descriptorType = VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER; wd.pBufferInfo = &buf; } break; |