Vulkan: Allow re-use of uniform buffers when doing per-stage uploads

This is safe now because we invalidate the pointers after submitting a
command buffer.
This commit is contained in:
Stenzek
2016-11-30 23:32:23 +10:00
parent 6a4eba1153
commit ca691a9d95
2 changed files with 33 additions and 42 deletions

View File

@ -174,6 +174,11 @@ private:
bool UpdatePipeline();
bool UpdateDescriptorSet();
// Allocates storage in the uniform buffer of the specified size. If this storage cannot be
// allocated immediately, the current command buffer will be submitted and all stage's
// constants will be re-uploaded. false will be returned in this case, otherwise true.
bool ReserveConstantStorage();
void UploadAllConstants();
// Which bindings/state has to be updated before the next draw.