aboutsummaryrefslogtreecommitdiff
path: root/layers/swapchain.cpp
AgeCommit message (Collapse)Author
2017-03-21layers: swapchain queue family count trackingMike Schuchardt
Add vkGetPhysicalDeviceQueueFamilyProperties2KHR as an alternate way get queue family count. Change-Id: Ie0efee916a1bf091eb34c8610eec3c73943db846
2017-03-21layers: swapchain post call record refactorMike Schuchardt
Change-Id: Id4063c82d9e592f982c59fb12c6d9f06a9e7b35a
2017-02-08layers:Rename get_my_data_ptr to GetLayerDataPtrTobin Ehlis
Change utility function get_my_data_ptr() to be named GetLayerDataPtr() which is more descriptive and capital camel case in-line with coding standard.
2017-01-26repo: Clang-format LVL source files using GoogleMark Lobodzinski
Switch clang-format standard from the LLVM style to the Google style for more consistency. Change-Id: I247c4abc275d7873a91522e1e234198adaa24033
2017-01-26repo: Clang-format c/cpp/h LVL files using LLVMMark Lobodzinski
Bring all source files in the repo up to date with consistent coding style/standard. Change-Id: Iceedbc17109974d3a0437fc4995441c9ad7e0c23
2017-01-24loader: Update the loader to 1.0.39Mark Young
Add new extensions for 1.0.39. Also, updated layers to include minimal set of functionality for 1.0.39 extensions. Extensions include: - VK_KHR_get_physical_device_properties2 - VK_KHR_shader_draw_parameters - VK_EXT_direct_mode_display - VK_EXT_display_surface_counter - VK_EXT_display_control Also, redo the LoaderAndLayerIf document. Change-Id: I10412086da7a798afe832a3892e18f606259b5af
2016-12-15layers: Update Valid Usage enums (VL-70)Mike Weiblen
Reviewed the following 5 files' invocation of log_msg() for opportunities to update for Valid Usage enums. layers/threading.h layers/vk_layer_logging.h layers/descriptor_sets.cpp layers/swapchain.cpp layers/unique_objects.cpp Split some composite checks apart, to better match the meaning of individual VUs. Added VU enums to a new file, and expanded the stats collection script to include the new file. Changed some placeholder uses of msgCode=="0" to "VALIDATION_ERROR_UNDEFINED". (0 is the value of the enum VALIDATION_ERROR_00000 which was misleading) When Valid Usage enums were referenced, also updated the VU database. Tweak #include order for Windows, to undo clang-format reordering. Completes Jira task VL-70. Change-Id: I550922b194e733f41316ae493098f70a54cbd64e
2016-11-29layers: Move surface format tracking to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-29layers: Move present modes tracking to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-29layers: Remove bogus CreateSharedSwapchainsKHR impl in swapchainChris Forbes
This wasn't even wired up. Parameter validation also now does these checks. Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-28layers: Remove handrolled clipped / sharingMode validation fromChris Forbes
swapchain PV now does this Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Remove husk of capabilities tracking from swapchainChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Remove remaining bits of image tracking from swapchainChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Remove husks of Acquire/Present from swapchainChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Move too many images case to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Move most of remaining swapchain creation checks to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Move complaints about presenting on bad queues to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-22layers: Move caps query / swapchain creation interaction to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-07layers: Do extension checks for KHR_display in PVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-07layers: Move swapchain and surface extension enable checks to PVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-07layers: Move enable checks for KHR_surface to PVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-07layers: Remove dead plumbing for platform extension enablesChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-11-07layers: Move platform WSI extension checks from swapchain to PVChris Forbes
We want to do all extension checks in PV-- we'll return a good FP for anything we recognize, and complain upfront if the appropriate extension wasn't enabled. Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-10-06layers: Migrate surface/swapchain interaction from swapchain to CVChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-10-04layers: Remove allocator consistency check from swapchainChris Forbes
This is now covered by object_tracker Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-09-27layers: Move image-not-acquired etc from swapchain to core validationChris Forbes
Now that Core Validation tracks the acquisition state of every swapchain image, we can do this. Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-09-27layers: Move ACQUIRE_NO_SYNC check from Swapchain to Core ValidationChris Forbes
Signed-off-by: Chris Forbes <chrisforbes@google.com>
2016-09-08layers: Remove old/unnecessary FIXME from swapchain layerIan Elliott
This FIXME comment does not apply. It may have applied, if the line being referred to once copied a pointer to user data, but at this point, the actual data is being copied into a struct owned by the swapchain layer, which is what the comment was about.
2016-09-01loader: gh888 Add KHR/EXT extensions in vulkan.hMark Young
Add the KHR_display_swapchain device extension to the loader and the core_validation layers. This fulfills the work required in JIRA LOAD-7 and gh 90. Add debug_marker to the extension list. Change-Id: I1fb70e5d44bc8c1f70fd6d1cfbd106a155081b25
2016-08-24layers: GH849: Defend against poorly-written applicationsIan Elliott
A test application was written that didn't properly call some count-based query commands. In this particular case, they always hard-coded the count variable to 1 the 2nd time the query was called. The swapchain layer was only recording the 1st count value in this case, and this caused a seg fault when the vkCreateSwapchainKHR command validation code was run. This commit better defends against such poorly-written applications, so that the vkCreateSwapchainKHR command validation code won't seg fault. This includes looking for VK_INCOMPLETE as a successful return code from the ICD.
2016-08-18layers: VT59, Change query count errors to warningsMark Lobodzinski
In patterns where an API call is normally made twice, the first with a NULL pointer returning the count of structures to receive followed by second call with a pointer to the appropriately-sized buffer, the swapchain layer was returning validation errors if the size call was made. However, this is legal behavior so these now return validation warnings. Also updated the relevant validation tests. Change-Id: I9f493b27bf4fa0bec6385499c76c5cece1ad86b9
2016-08-16layers: Run swapchain source through clang-formatMark Lobodzinski
Change-Id: Iaebe81e34e76d4760d1097da23d52d7ca2ef4273
2016-08-16layers: Some simple style tweaks for swapchainMark Lobodzinski
Fixed some variable names and removed c-style casts. Change-Id: I994ca311665a59d0f81ce0cfdeda4a66deb632be
2016-08-16layers: Removed swapchain pNext validationMark Lobodzinski
This validation is already performed in parameter_validation. Change-Id: I5fd8e92c885300aa35537d825ea67fabb723062e
2016-08-16layers: Fixed swapchain layer warning messagesMark Lobodzinski
Macro used incorrect parameter layout -- removed and in-lined log_msg calls. Change-Id: I2a21be76f83eed9fb3055f6f57f22204c9ea76f0
2016-08-16layers: Moved swapchain QFI checks into functionMark Lobodzinski
Correct object pointers passed now. Change-Id: Ib18e1849da2761373386eb44c2549be7c28752ab
2016-08-16layers: Removed swapchain ZERO_VALUE checkMark Lobodzinski
This validation is already performed in parameter_validation. Change-Id: I3c1a7f17d68fa81f7770b7dd88cb075be8e59175
2016-08-16layers: Remove swapchain WRONG_STYPE checksMark Lobodzinski
This validation is already performed in parameter_validation. Change-Id: I0b9e83cf241bfa5de93c90898f6cd5b6d9b745b5
2016-08-16layers: In-line swapchain zero_prior_count macroMark Lobodzinski
Change-Id: Ib9c58f05ef045f0450f1ba62dfc7ea4498ac119e
2016-08-16layers: Remove swapchain INVALID_COUNT macroMark Lobodzinski
Change-Id: I44d19882af69541cfe9876a22fecc0a09056ba0b
2016-08-16layers: Remove swapchain NULL_POINTER checksMark Lobodzinski
These are all overed in parameter_validation. Change-Id: I23a7fc281414b6b8bcf30c5a9660560f2b51177f
2016-08-16layers: Removed LOG_ERROR_NON_VALID_OBJ macroMark Lobodzinski
Change-Id: I0609694a3743ca764bcda6de66c0431fb63c1ad1
2016-08-16layers: Replace swapchain LOG_ERROR macrosMark Lobodzinski
Fixed some missing return codes, incorrect parameter order, bad object handles, and instance-device mismatches. Inlined log-error calls. Change-Id: I6d272cafcd8554f068896312a2b0f41a42d108be
2016-08-05GH 818: Improve swapchain error for vkCreateSwapchainKHR()Ian Elliott
When the the application calls vkCreateSwapchainKHR(), the pCreateInfo->surface used must have been previously checked as supported, by calling vkGetPhysicalDeviceSurfaceSupportKHR(). The error message needed to be more clear about this.
2016-07-21layers : gh682 move gipa dispatch table initMark Young
Move the GIPA setup of the dispatch tables for layers into the layer_init_device_dispatch_table call since we're already doing a majority of it there. This removes the need to separately setup the WSI extension entry-points. Additionally, memset the table to 0, just to make sure anything that gets added in the future is obvoiusly not set. Change-Id: I63c7c107cd9f7957e2766fdbeb8a06bc1ae0eda6
2016-07-01layers: Fix swapchain GetDisplayPlanePropertyCount count checkJon Ashburn
Change-Id: I1b16a422349eb1c5a6564704f079a0243c5ea00d
2016-06-30layers: Add some comments to swapchain for more KHR_display validationJon Ashburn
Change-Id: I9d5cf4f6f8f0f9c5177155deaa18fe521c7620a9
2016-06-30layers: Finish add support to validation for VK_KHR_display extensionJon Ashburn
Swapchain, object_tracker and unique_objects now intercept and perform validation checks for this extension. Change-Id: I2e78d1dc516103de165ef83b99665eaad05b73d9
2016-06-30Added WSI KHR_display support to validationPetros Bantolas
Add support for this extension to object_tracker and swapchain layers. Change-Id: Ifdf6095958a9d9d01720fde92e0bbd0a8a9a3216
2016-06-23Layers: GH674: Improve locking in swapchain layer.Ian Elliott
This fixes cases where the swapchain layer wasn't always unlocking before returning from a function.