1// Copyright 2020-2023 The Khronos Group Inc.
2//
3// SPDX-License-Identifier: CC-BY-4.0
4
5// Common Valid Usage
6// Common to attachment reference structures
7  * [[VUID-{refpage}-layout-03077]]
8    If pname:attachment is not ename:VK_ATTACHMENT_UNUSED, pname:layout
9    must: not be ename:VK_IMAGE_LAYOUT_UNDEFINED,
10    ename:VK_IMAGE_LAYOUT_PREINITIALIZED, or
11    ename:VK_IMAGE_LAYOUT_PRESENT_SRC_KHR
12ifdef::VK_VERSION_1_2,VK_KHR_separate_depth_stencil_layouts[]
13  * [[VUID-{refpage}-separateDepthStencilLayouts-03313]]
14    If the <<features-separateDepthStencilLayouts,
15    pname:separateDepthStencilLayouts>> feature is not enabled, and
16    pname:attachment is not ename:VK_ATTACHMENT_UNUSED, pname:layout must:
17    not be ename:VK_IMAGE_LAYOUT_DEPTH_ATTACHMENT_OPTIMAL,
18    ename:VK_IMAGE_LAYOUT_DEPTH_READ_ONLY_OPTIMAL,
19    ename:VK_IMAGE_LAYOUT_STENCIL_ATTACHMENT_OPTIMAL, or
20    ename:VK_IMAGE_LAYOUT_STENCIL_READ_ONLY_OPTIMAL,
21endif::VK_VERSION_1_2,VK_KHR_separate_depth_stencil_layouts[]
22ifdef::VK_KHR_synchronization2[]
23  * [[VUID-{refpage}-synchronization2-06910]]
24    If the <<features-synchronization2, pname:synchronization2>> feature is
25    not enabled, pname:layout must: not be
26    ename:VK_IMAGE_LAYOUT_ATTACHMENT_OPTIMAL_KHR or
27    ename:VK_IMAGE_LAYOUT_READ_ONLY_OPTIMAL_KHR
28endif::VK_KHR_synchronization2[]
29ifdef::VK_EXT_attachment_feedback_loop_layout[]
30  * [[VUID-{refpage}-attachmentFeedbackLoopLayout-07311]]
31    If the <<features-attachmentFeedbackLoopLayout,
32    pname:attachmentFeedbackLoopLayout>> feature is not enabled,
33    pname:layout must: not be
34    ename:VK_IMAGE_LAYOUT_ATTACHMENT_FEEDBACK_LOOP_OPTIMAL_EXT
35endif::VK_EXT_attachment_feedback_loop_layout[]
36// Common Valid Usage
37