commit | 7cbffda6c85e0634399d74607db2a82943abe06a | [log] [tgz] |
---|---|---|
author | egdaniel <egdaniel@google.com> | Fri Apr 08 13:27:53 2016 -0700 |
committer | Commit bot <commit-bot@chromium.org> | Fri Apr 08 13:27:53 2016 -0700 |
tree | c2cc75d1fb0f3c27bf08ac0e78466a8e588f3170 | |
parent | 9e0efe57ac29b13d7f7a24ccefc456562acbad6c [diff] [blame] |
Don't create new descriptor set for vulkan uniforms every draw BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1872553005 Review URL: https://codereview.chromium.org/1872553005
diff --git a/src/gpu/vk/GrVkBuffer.h b/src/gpu/vk/GrVkBuffer.h index 289ef30..141b2a3 100644 --- a/src/gpu/vk/GrVkBuffer.h +++ b/src/gpu/vk/GrVkBuffer.h
@@ -73,7 +73,10 @@ void* vkMap(const GrVkGpu* gpu); void vkUnmap(const GrVkGpu* gpu); - bool vkUpdateData(const GrVkGpu* gpu, const void* src, size_t srcSizeInBytes); + // If the caller passes in a non null createdNewBuffer, this function will set the bool to true + // if it creates a new VkBuffer to upload the data to. + bool vkUpdateData(const GrVkGpu* gpu, const void* src, size_t srcSizeInBytes, + bool* createdNewBuffer = nullptr); void vkAbandon(); void vkRelease(const GrVkGpu* gpu);