Skip to content
Snippets Groups Projects
Verified Commit 5aedcd22 authored by Tobias Frisch's avatar Tobias Frisch
Browse files

[#79] Changed memory usage for staging buffers

parent 5b243262
No related branches found
No related tags found
1 merge request!69Resolve "Rework Asset Loader API"
Pipeline #26317 passed
...@@ -49,7 +49,7 @@ namespace vkcv { ...@@ -49,7 +49,7 @@ namespace vkcv {
usageFlags = vk::BufferUsageFlagBits::eIndexBuffer; usageFlags = vk::BufferUsageFlagBits::eIndexBuffer;
break; break;
default: default:
// TODO: maybe an issue vkcv_log(LogLevel::WARNING, "Unknown buffer type");
break; break;
} }
...@@ -81,6 +81,10 @@ namespace vkcv { ...@@ -81,6 +81,10 @@ namespace vkcv {
break; break;
} }
if (type == BufferType::STAGING) {
memoryUsage = vma::MemoryUsage::eCpuToGpu;
}
auto bufferAllocation = allocator.createBuffer( auto bufferAllocation = allocator.createBuffer(
vk::BufferCreateInfo(createFlags, size, usageFlags), vk::BufferCreateInfo(createFlags, size, usageFlags),
vma::AllocationCreateInfo( vma::AllocationCreateInfo(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment