From da989b59143869a5c01cc923f5e75f1598d78191 Mon Sep 17 00:00:00 2001 From: Ian Elliott Date: Thu, 24 Sep 2015 18:33:16 -0600 Subject: Change ERROR -> PERF_WARN in vkAcquireNextImageKHR(). --- layers/swapchain.cpp | 25 ++++++++++++++----------- layers/swapchain.h | 3 +++ 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/layers/swapchain.cpp b/layers/swapchain.cpp index 00286576..37864dae 100644 --- a/layers/swapchain.cpp +++ b/layers/swapchain.cpp @@ -928,17 +928,20 @@ VK_LAYER_EXPORT VkResult VKAPI vkAcquireNextImageKHR(VkDevice device, VkSwapchai } } if (imagesOwnedByApp >= (pSwapchain->imageCount - 1)) { - skipCall |= LOG_ERROR(VK_OBJECT_TYPE_SWAPCHAIN_KHR, swapchain, - "VkSwapchainKHR", - "%s() called when the application already " - "owns all presentable images in this " - "swapchain except for the image currently " - "being displayed. This call to %s() cannot " - "succeed unless another thread calls the " - "vkQueuePresentKHR() function in order to " - "release ownership of one of the presentable " - "images of this swapchain.", - __FUNCTION__, __FUNCTION__); + skipCall |= LOG_PERF_WARNING(VK_OBJECT_TYPE_SWAPCHAIN_KHR, + swapchain, + "VkSwapchainKHR", + "%s() called when the application " + "already owns all presentable images " + "in this swapchain except for the " + "image currently being displayed. " + "This call to %s() cannot succeed " + "unless another thread calls the " + "vkQueuePresentKHR() function in " + "order to release ownership of one of " + "the presentable images of this " + "swapchain.", + __FUNCTION__, __FUNCTION__); } } diff --git a/layers/swapchain.h b/layers/swapchain.h index 1f99b6f4..e6b2a55a 100644 --- a/layers/swapchain.h +++ b/layers/swapchain.h @@ -53,6 +53,9 @@ typedef struct _layer_data { #define LOG_ERROR(objType, type, obj, fmt, ...) \ log_msg(&mydata.report_data, VK_DBG_REPORT_ERROR_BIT, (objType), \ (uint64_t) (obj), 0, 0, LAYER_NAME, (fmt), __VA_ARGS__) +#define LOG_PERF_WARNING(objType, type, obj, fmt, ...) \ + log_msg(&mydata.report_data, VK_DBG_REPORT_PERF_WARN_BIT, (objType), \ + (uint64_t) (obj), 0, 0, LAYER_NAME, (fmt), __VA_ARGS__) // NOTE: The following struct's/typedef's are for keeping track of -- cgit v1.2.3