Selaa lähdekoodia

Vulkan Query Cache: make sure to wait for the query result.

Fernando Sahmkow 4 vuotta sitten
vanhempi
commit
d702b393a4
1 muutettua tiedostoa jossa 2 lisäystä ja 1 poistoa
  1. 2 1
      src/video_core/renderer_vulkan/vk_query_cache.cpp

+ 2 - 1
src/video_core/renderer_vulkan/vk_query_cache.cpp

@@ -117,7 +117,8 @@ u64 HostCounter::BlockingQuery() const {
     cache.GetScheduler().Wait(tick);
     u64 data;
     const VkResult query_result = cache.GetDevice().GetLogical().GetQueryResults(
-        query.first, query.second, 1, sizeof(data), &data, sizeof(data), VK_QUERY_RESULT_64_BIT);
+        query.first, query.second, 1, sizeof(data), &data, sizeof(data),
+        VK_QUERY_RESULT_64_BIT | VK_QUERY_RESULT_WAIT_BIT);
 
     switch (query_result) {
     case VK_SUCCESS: