Merge branch 'jekstrand_renderpass_transfer_bit_fix' into 'master'
[platform/upstream/VK-GL-CTS.git] / external / vulkancts / modules / vulkan / query_pool / vktQueryPoolCreateInfoUtil.hpp
1 #ifndef _VKTQUERYPOOLCREATEINFOUTIL_HPP
2 #define _VKTQUERYPOOLCREATEINFOUTIL_HPP
3 /*------------------------------------------------------------------------
4  * Vulkan Conformance Tests
5  * ------------------------
6  *
7  * Copyright (c) 2015 The Khronos Group Inc.
8  * Copyright (c) 2015 Intel Corporation
9  *
10  * Permission is hereby granted, free of charge, to any person obtaining a
11  * copy of this software and/or associated documentation files (the
12  * "Materials"), to deal in the Materials without restriction, including
13  * without limitation the rights to use, copy, modify, merge, publish,
14  * distribute, sublicense, and/or sell copies of the Materials, and to
15  * permit persons to whom the Materials are furnished to do so, subject to
16  * the following conditions:
17  *
18  * The above copyright notice(s) and this permission notice shall be included
19  * in all copies or substantial portions of the Materials.
20  *
21  * The Materials are Confidential Information as defined by the
22  * Khronos Membership Agreement until designated non-confidential by Khronos,
23  * at which point this condition clause shall be removed.
24  *
25  * THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
26  * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
27  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
28  * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
29  * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
30  * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
31  * MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
32  *
33  *//*!
34  * \file
35  * \brief CreateInfo utilities
36  *//*--------------------------------------------------------------------*/
37
38 #include "vkDefs.hpp"
39 #include "tcuVector.hpp"
40 #include "deSharedPtr.hpp"
41 #include <vector>
42
43 namespace vkt
44 {
45 namespace QueryPool
46 {
47
48 class ImageSubresourceRange : public vk::VkImageSubresourceRange
49 {
50 public:
51         ImageSubresourceRange           (vk::VkImageAspectFlags aspectMask,
52                                                                  deUint32                               baseMipLevel    = 0,
53                                                                  deUint32                               levelCount              = 1,
54                                                                  deUint32                               baseArrayLayer  = 0,
55                                                                  deUint32                               layerCount              = 1);
56 };
57
58 class ComponentMapping : public vk::VkComponentMapping
59 {
60 public:
61         ComponentMapping                        (vk::VkComponentSwizzle r = vk::VK_COMPONENT_SWIZZLE_R,
62                                                                  vk::VkComponentSwizzle g = vk::VK_COMPONENT_SWIZZLE_G,
63                                                                  vk::VkComponentSwizzle b = vk::VK_COMPONENT_SWIZZLE_B,
64                                                                  vk::VkComponentSwizzle a = vk::VK_COMPONENT_SWIZZLE_A);
65 };
66
67 class ImageViewCreateInfo : public vk::VkImageViewCreateInfo
68 {
69 public:
70         ImageViewCreateInfo                     (vk::VkImage                                            image,
71                                                                  vk::VkImageViewType                            viewType,
72                                                                  vk::VkFormat                                           format,
73                                                                  const vk::VkImageSubresourceRange&     subresourceRange,
74                                                                  const vk::VkComponentMapping&          components                      = ComponentMapping(),
75                                                                  vk::VkImageViewCreateFlags                     flags                           = 0);
76
77         ImageViewCreateInfo                     (vk::VkImage                                            image,
78                                                                  vk::VkImageViewType                            viewType,
79                                                                  vk::VkFormat                                           format,
80                                                                  const vk::VkComponentMapping&          components                      = ComponentMapping(),
81                                                                  vk::VkImageViewCreateFlags                     flags                           = 0);
82 };
83
84 class BufferViewCreateInfo : public vk::VkBufferViewCreateInfo
85 {
86 public:
87         BufferViewCreateInfo             (vk::VkBuffer          buffer,
88                                                                   vk::VkFormat          format,
89                                                                   vk::VkDeviceSize      offset,
90                                                                   vk::VkDeviceSize      range);
91 };
92
93 class BufferCreateInfo : public vk::VkBufferCreateInfo
94 {
95 public:
96         BufferCreateInfo                        (vk::VkDeviceSize                       size,
97                                                                  vk::VkBufferCreateFlags        usage,
98                                                                  vk::VkSharingMode                      sharingMode                             = vk::VK_SHARING_MODE_EXCLUSIVE,
99                                                                  deUint32                                       queueFamilyIndexCount   = 0,
100                                                                  const deUint32*                        pQueueFamilyIndices             = DE_NULL,
101                                                                  vk::VkBufferCreateFlags        flags                                   = 0);
102
103         BufferCreateInfo                        (const BufferCreateInfo&        other);
104         BufferCreateInfo& operator=     (const BufferCreateInfo&        other);
105
106 private:
107         std::vector<deUint32> m_queueFamilyIndices;
108 };
109
110 class ImageCreateInfo : public vk::VkImageCreateInfo
111 {
112 public:
113         ImageCreateInfo                         (vk::VkImageType                        imageType,
114                                                                  vk::VkFormat                           format,
115                                                                  vk::VkExtent3D                         extent,
116                                                                  deUint32                                       mipLevels,
117                                                                  deUint32                                       arrayLayers,
118                                                                  vk::VkSampleCountFlagBits      samples,
119                                                                  vk::VkImageTiling                      tiling,
120                                                                  vk::VkImageUsageFlags          usage,
121                                                                  vk::VkSharingMode                      sharingMode                             = vk::VK_SHARING_MODE_EXCLUSIVE,
122                                                                  deUint32                                       queueFamilyIndexCount   = 0,
123                                                                  const deUint32*                        pQueueFamilyIndices             = DE_NULL,
124                                                                  vk::VkImageCreateFlags         flags                                   = 0,
125                                                                  vk::VkImageLayout                      initialLayout                   = vk::VK_IMAGE_LAYOUT_UNDEFINED);
126
127 private:
128         ImageCreateInfo                         (const ImageCreateInfo&         other);
129         ImageCreateInfo& operator=      (const ImageCreateInfo&         other);
130
131         std::vector<deUint32> m_queueFamilyIndices;
132 };
133
134 class FramebufferCreateInfo : public vk::VkFramebufferCreateInfo
135 {
136 public:
137         FramebufferCreateInfo           (vk::VkRenderPass                                               renderPass,
138                                                                  const std::vector<vk::VkImageView>&    attachments,
139                                                                  deUint32                                                               width,
140                                                                  deUint32                                                               height,
141                                                                  deUint32                                                               layers);
142 };
143
144 class AttachmentDescription : public vk::VkAttachmentDescription
145 {
146 public:
147         AttachmentDescription   (vk::VkFormat                           format,
148                                                          vk::VkSampleCountFlagBits      samples,
149                                                          vk::VkAttachmentLoadOp         loadOp,
150                                                          vk::VkAttachmentStoreOp        storeOp,
151                                                          vk::VkAttachmentLoadOp         stencilLoadOp,
152                                                          vk::VkAttachmentStoreOp        stencilStoreOp,
153                                                          vk::VkImageLayout                      initialLayout,
154                                                          vk::VkImageLayout                      finalLayout);
155
156         AttachmentDescription   (const vk::VkAttachmentDescription &);
157 };
158
159 class AttachmentReference : public vk::VkAttachmentReference
160 {
161 public:
162         AttachmentReference             (deUint32 attachment, vk::VkImageLayout layout);
163         AttachmentReference             (void);
164 };
165
166 class SubpassDescription : public vk::VkSubpassDescription
167 {
168 public:
169         SubpassDescription                              (vk::VkPipelineBindPoint                        pipelineBindPoint,
170                                                                          vk::VkSubpassDescriptionFlags          flags,
171                                                                          deUint32                                                       inputAttachmentCount,
172                                                                          const vk::VkAttachmentReference*       inputAttachments,
173                                                                          deUint32                                                       colorAttachmentCount,
174                                                                          const vk::VkAttachmentReference*       colorAttachments,
175                                                                          const vk::VkAttachmentReference*       resolveAttachments,
176                                                                          vk::VkAttachmentReference                      depthStencilAttachment,
177                                                                          deUint32                                                       preserveAttachmentCount,
178                                                                          const deUint32*                                        preserveAttachments);
179
180         SubpassDescription                              (const vk::VkSubpassDescription&        other);
181         SubpassDescription                              (const SubpassDescription&                      other);
182         SubpassDescription& operator=   (const SubpassDescription&                      other);
183
184 private:
185         std::vector<vk::VkAttachmentReference>  m_inputAttachments;
186         std::vector<vk::VkAttachmentReference>  m_colorAttachments;
187         std::vector<vk::VkAttachmentReference>  m_resolveAttachments;
188         std::vector<deUint32>                                   m_preserveAttachments;
189
190         vk::VkAttachmentReference                               m_depthStencilAttachment;
191 };
192
193 class SubpassDependency : public vk::VkSubpassDependency
194 {
195 public:
196         SubpassDependency (     deUint32                                        srcSubpass,
197                                                 deUint32                                        dstSubpass,
198                                                 vk::VkPipelineStageFlags        srcStageMask,
199                                                 vk::VkPipelineStageFlags        dstStageMask,
200                                                 vk::VkAccessFlags                       srcAccessMask,
201                                                 vk::VkAccessFlags                       dstAccessMask,
202                                                 vk::VkDependencyFlags           dependencyFlags);
203
204         SubpassDependency (const vk::VkSubpassDependency& other);
205 };
206
207 class RenderPassCreateInfo : public vk::VkRenderPassCreateInfo
208 {
209 public:
210         RenderPassCreateInfo (const std::vector<vk::VkAttachmentDescription>&   attachments,
211                                                   const std::vector<vk::VkSubpassDescription>&          subpasses,
212                                                   const std::vector<vk::VkSubpassDependency>&           dependiences            = std::vector<vk::VkSubpassDependency>());
213
214         RenderPassCreateInfo (deUint32                                                                                  attachmentCount = 0,
215                                                   const vk::VkAttachmentDescription*                            pAttachments    = DE_NULL,
216                                                   deUint32                                                                                      subpassCount    = 0,
217                                                   const vk::VkSubpassDescription*                                       pSubpasses              = DE_NULL,
218                                                   deUint32                                                                                      dependencyCount = 0,
219                                                   const vk::VkSubpassDependency*                                        pDependiences   = DE_NULL);
220
221         void addAttachment      (vk::VkAttachmentDescription                                            attachment);
222         void addSubpass         (vk::VkSubpassDescription                                                       subpass);
223         void addDependency      (vk::VkSubpassDependency                                                        dependency);
224
225 private:
226         std::vector<AttachmentDescription>                      m_attachments;
227         std::vector<SubpassDescription>                         m_subpasses;
228         std::vector<SubpassDependency>                          m_dependiences;
229
230         std::vector<vk::VkAttachmentDescription>        m_attachmentsStructs;
231         std::vector<vk::VkSubpassDescription>           m_subpassesStructs;
232         std::vector<vk::VkSubpassDependency>            m_dependiencesStructs;
233
234         RenderPassCreateInfo                    (const RenderPassCreateInfo &other); //Not allowed!
235         RenderPassCreateInfo& operator= (const RenderPassCreateInfo &other); //Not allowed!
236 };
237
238 class RenderPassBeginInfo : public vk::VkRenderPassBeginInfo
239 {
240 public:
241         RenderPassBeginInfo (vk::VkRenderPass                                           renderPass,
242                                                  vk::VkFramebuffer                                              framebuffer,
243                                                  vk::VkRect2D                                                   renderArea,
244                                                  const std::vector<vk::VkClearValue>&   clearValues = std::vector<vk::VkClearValue>());
245
246 private:
247         std::vector<vk::VkClearValue> m_clearValues;
248
249         RenderPassBeginInfo                             (const RenderPassBeginInfo&     other); //Not allowed!
250         RenderPassBeginInfo& operator=  (const RenderPassBeginInfo&     other); //Not allowed!
251 };
252
253 class CmdPoolCreateInfo : public vk::VkCommandPoolCreateInfo
254 {
255 public:
256         CmdPoolCreateInfo (deUint32                                             queueFamilyIndex,
257                                            vk::VkCommandPoolCreateFlags flags                           = vk::VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT);
258 };
259
260 class CmdBufferBeginInfo : public vk::VkCommandBufferBeginInfo
261 {
262 public:
263         CmdBufferBeginInfo (vk::VkCommandBufferUsageFlags               flags                                   = 0);
264 };
265
266 class DescriptorPoolSize : public vk::VkDescriptorPoolSize
267 {
268 public:
269         DescriptorPoolSize (vk::VkDescriptorType _type, deUint32 _descriptorCount)
270         {
271                 type                    = _type;
272                 descriptorCount = _descriptorCount;
273         }
274 };
275
276 class DescriptorPoolCreateInfo : public vk::VkDescriptorPoolCreateInfo
277 {
278 public:
279         DescriptorPoolCreateInfo (const std::vector<vk::VkDescriptorPoolSize>&  poolSizeCounts,
280                                                           vk::VkDescriptorPoolCreateFlags                               flags,
281                                                           deUint32                                                                              maxSets);
282
283         DescriptorPoolCreateInfo& addDescriptors (vk::VkDescriptorType type, deUint32 count);
284
285 private:
286         std::vector<vk::VkDescriptorPoolSize> m_poolSizeCounts;
287 };
288
289 class DescriptorSetLayoutCreateInfo : public vk::VkDescriptorSetLayoutCreateInfo
290 {
291 public:
292         DescriptorSetLayoutCreateInfo (deUint32 bindingCount, const vk::VkDescriptorSetLayoutBinding* pBindings);
293 };
294
295 class PipelineLayoutCreateInfo : public vk::VkPipelineLayoutCreateInfo
296 {
297 public:
298         PipelineLayoutCreateInfo (deUint32                                                                              descriptorSetCount,
299                                                           const vk::VkDescriptorSetLayout*                              pSetLayouts,
300                                                           deUint32                                                                              pushConstantRangeCount  = 0,
301                                                           const vk::VkPushConstantRange*                                pPushConstantRanges             = DE_NULL);
302
303         PipelineLayoutCreateInfo (const std::vector<vk::VkDescriptorSetLayout>& setLayouts                              = std::vector<vk::VkDescriptorSetLayout>(),
304                                                           deUint32                                                                              pushConstantRangeCount  = 0,
305                                                           const vk::VkPushConstantRange*                                pPushConstantRanges             = DE_NULL);
306
307 private:
308         std::vector<vk::VkDescriptorSetLayout>  m_setLayouts;
309         std::vector<vk::VkPushConstantRange>    m_pushConstantRanges;
310 };
311
312 class PipelineCreateInfo : public vk::VkGraphicsPipelineCreateInfo
313 {
314 public:
315         class VertexInputState : public vk::VkPipelineVertexInputStateCreateInfo
316         {
317         public:
318                 VertexInputState (deUint32                                                                              vertexBindingDescriptionCount   = 0,
319                                                   const vk::VkVertexInputBindingDescription*    pVertexBindingDescriptions              = NULL,
320                                                   deUint32                                                                              vertexAttributeDescriptionCount = 0,
321                                                   const vk::VkVertexInputAttributeDescription*  pVertexAttributeDescriptions    = NULL);
322         };
323
324         class InputAssemblerState : public vk::VkPipelineInputAssemblyStateCreateInfo
325         {
326         public:
327                 InputAssemblerState (vk::VkPrimitiveTopology topology, vk::VkBool32 primitiveRestartEnable = false);
328         };
329
330         class TessellationState : public vk::VkPipelineTessellationStateCreateInfo
331         {
332         public:
333                 TessellationState (deUint32 patchControlPoints = 0);
334         };
335
336         class ViewportState : public vk::VkPipelineViewportStateCreateInfo
337         {
338         public:
339                 ViewportState                           (deUint32                                               viewportCount,
340                                                                          std::vector<vk::VkViewport>    viewports               = std::vector<vk::VkViewport>(0),
341                                                                          std::vector<vk::VkRect2D>              scissors                = std::vector<vk::VkRect2D>(0));
342
343                 ViewportState                           (const ViewportState&                   other);
344                 ViewportState& operator=        (const ViewportState&                   other);
345
346                 std::vector<vk::VkViewport> m_viewports;
347                 std::vector<vk::VkRect2D>       m_scissors;
348         };
349
350         class RasterizerState : public vk::VkPipelineRasterizationStateCreateInfo
351         {
352         public:
353                 RasterizerState (vk::VkBool32                   depthClampEnable                = false,
354                                                  vk::VkBool32                   rasterizerDiscardEnable = false,
355                                                  vk::VkPolygonMode              polygonMode                             = vk::VK_POLYGON_MODE_FILL,
356                                                  vk::VkCullModeFlags    cullMode                                = vk::VK_CULL_MODE_NONE,
357                                                  vk::VkFrontFace                frontFace                               = vk::VK_FRONT_FACE_CLOCKWISE,
358                                                  vk::VkBool32                   depthBiasEnable                 = true,
359                                                  float                                  depthBiasConstantFactor = 0.0f,
360                                                  float                                  depthBiasClamp                  = 0.0f,
361                                                  float                                  depthBiasSlopeFactor    = 0.0f,
362                                                  float                                  lineWidth                               = 1.0f);
363         };
364
365         class MultiSampleState : public vk::VkPipelineMultisampleStateCreateInfo
366         {
367         public:
368                 MultiSampleState                        (vk::VkSampleCountFlagBits                              rasterizationSamples            = vk::VK_SAMPLE_COUNT_1_BIT,
369                                                                          vk::VkBool32                                                   sampleShadingEnable                     = false,
370                                                                          float                                                                  minSampleShading                        = 0.0f,
371                                                                          const std::vector<vk::VkSampleMask>&   sampleMask                                      = std::vector<vk::VkSampleMask>(1, 0xffffffff),
372                                                                          bool                                                                   alphaToCoverageEnable           = false,
373                                                                          bool                                                                   alphaToOneEnable                        = false);
374
375                 MultiSampleState                        (const MultiSampleState&                                other);
376                 MultiSampleState& operator= (const MultiSampleState&                            other);
377
378         private:
379                 std::vector<vk::VkSampleMask> m_sampleMask;
380         };
381
382         class ColorBlendState : public vk::VkPipelineColorBlendStateCreateInfo
383         {
384         public:
385                 class Attachment : public vk::VkPipelineColorBlendAttachmentState
386                 {
387                 public:
388                         Attachment (vk::VkBool32                blendEnable                     = false,
389                                                 vk::VkBlendFactor       srcColorBlendFactor     = vk::VK_BLEND_FACTOR_SRC_COLOR,
390                                                 vk::VkBlendFactor       dstColorBlendFactor     = vk::VK_BLEND_FACTOR_DST_COLOR,
391                                                 vk::VkBlendOp           colorBlendOp            = vk::VK_BLEND_OP_ADD,
392                                                 vk::VkBlendFactor       srcAlphaBlendFactor     = vk::VK_BLEND_FACTOR_SRC_COLOR,
393                                                 vk::VkBlendFactor       dstAlphaBlendFactor     = vk::VK_BLEND_FACTOR_DST_COLOR,
394                                                 vk::VkBlendOp           alphaBlendOp            = vk::VK_BLEND_OP_ADD,
395                                                 deUint8                         colorWriteMask          = 0xff);
396                 };
397
398                 ColorBlendState (const std::vector<vk::VkPipelineColorBlendAttachmentState>&    attachments,
399                                                  vk::VkBool32                                                                                                   alphaToCoverageEnable   = false,
400                                                  vk::VkLogicOp                                                                                                  logicOp                                 = vk::VK_LOGIC_OP_COPY);
401
402                 ColorBlendState (deUint32                                                                                                               attachmentCount,
403                                                  const vk::VkPipelineColorBlendAttachmentState*                                 attachments,
404                                                  vk::VkBool32                                                                                                   logicOpEnable                   = false,
405                                                  vk::VkLogicOp                                                                                                  logicOp                                 = vk::VK_LOGIC_OP_COPY);
406
407                 ColorBlendState (const vk::VkPipelineColorBlendStateCreateInfo&                                 createInfo);
408                 ColorBlendState (const ColorBlendState&                                                                                 createInfo,
409                                                  std::vector<float>                                                                                             blendConstants                  = std::vector<float>(4));
410
411         private:
412                 std::vector<vk::VkPipelineColorBlendAttachmentState> m_attachments;
413         };
414
415         class DepthStencilState : public vk::VkPipelineDepthStencilStateCreateInfo
416         {
417         public:
418                 class StencilOpState : public vk::VkStencilOpState
419                 {
420                 public:
421                         StencilOpState (vk::VkStencilOp failOp                                  = vk::VK_STENCIL_OP_REPLACE,
422                                                         vk::VkStencilOp passOp                                  = vk::VK_STENCIL_OP_REPLACE,
423                                                         vk::VkStencilOp depthFailOp                             = vk::VK_STENCIL_OP_REPLACE,
424                                                         vk::VkCompareOp compareOp                               = vk::VK_COMPARE_OP_ALWAYS,
425                                                         deUint32                compareMask                             = 0xffffffffu,
426                                                         deUint32                writeMask                               = 0xffffffffu,
427                                                         deUint32                reference                               = 0);
428                 };
429
430                 DepthStencilState (vk::VkBool32         depthTestEnable                 = false,
431                                                    vk::VkBool32         depthWriteEnable                = false,
432                                                    vk::VkCompareOp      depthCompareOp                  = vk::VK_COMPARE_OP_ALWAYS,
433                                                    vk::VkBool32         depthBoundsTestEnable   = false,
434                                                    vk::VkBool32         stencilTestEnable               = false,
435                                                    StencilOpState       front                                   = StencilOpState(),
436                                                    StencilOpState       back                                    = StencilOpState(),
437                                                    float                        minDepthBounds                  = -1.0f,
438                                                    float                        maxDepthBounds                  = 1.0f);
439         };
440
441         class PipelineShaderStage : public vk::VkPipelineShaderStageCreateInfo
442         {
443         public:
444                 PipelineShaderStage (vk::VkShaderModule shaderModule, const char* pName, vk::VkShaderStageFlagBits stage);
445         };
446
447         class DynamicState : public vk::VkPipelineDynamicStateCreateInfo
448         {
449         public:
450                 DynamicState                    (const std::vector<vk::VkDynamicState>& dynamicStates = std::vector<vk::VkDynamicState>(0));
451
452                 DynamicState                    (const DynamicState& other);
453                 DynamicState& operator= (const DynamicState& other);
454
455                 std::vector<vk::VkDynamicState> m_dynamicStates;
456         };
457
458         PipelineCreateInfo                              (vk::VkPipelineLayout                                                           layout,
459                                                                      vk::VkRenderPass                                                                   renderPass,
460                                                                          int                                                                                            subpass,
461                                                                          vk::VkPipelineCreateFlags                                                      flags);
462
463         PipelineCreateInfo& addShader   (const vk::VkPipelineShaderStageCreateInfo&                     shader);
464
465         PipelineCreateInfo& addState    (const vk::VkPipelineVertexInputStateCreateInfo&        state);
466         PipelineCreateInfo& addState    (const vk::VkPipelineInputAssemblyStateCreateInfo&      state);
467         PipelineCreateInfo& addState    (const vk::VkPipelineColorBlendStateCreateInfo&         state);
468         PipelineCreateInfo& addState    (const vk::VkPipelineViewportStateCreateInfo&           state);
469         PipelineCreateInfo& addState    (const vk::VkPipelineDepthStencilStateCreateInfo&       state);
470         PipelineCreateInfo& addState    (const vk::VkPipelineTessellationStateCreateInfo&       state);
471         PipelineCreateInfo& addState    (const vk::VkPipelineRasterizationStateCreateInfo&      state);
472         PipelineCreateInfo& addState    (const vk::VkPipelineMultisampleStateCreateInfo&        state);
473         PipelineCreateInfo& addState    (const vk::VkPipelineDynamicStateCreateInfo&            state);
474
475 private:
476         std::vector<vk::VkPipelineShaderStageCreateInfo>                m_shaders;
477
478         vk::VkPipelineVertexInputStateCreateInfo                                m_vertexInputState;
479         vk::VkPipelineInputAssemblyStateCreateInfo                              m_inputAssemblyState;
480         std::vector<vk::VkPipelineColorBlendAttachmentState>    m_colorBlendStateAttachments;
481         vk::VkPipelineColorBlendStateCreateInfo                                 m_colorBlendState;
482         vk::VkPipelineViewportStateCreateInfo                                   m_viewportState;
483         vk::VkPipelineDepthStencilStateCreateInfo                               m_dynamicDepthStencilState;
484         vk::VkPipelineTessellationStateCreateInfo                               m_tessState;
485         vk::VkPipelineRasterizationStateCreateInfo                              m_rasterState;
486         vk::VkPipelineMultisampleStateCreateInfo                                m_multisampleState;
487         vk::VkPipelineDynamicStateCreateInfo                                    m_dynamicState;
488
489         std::vector<vk::VkDynamicState>                                                 m_dynamicStates;
490
491         std::vector<vk::VkViewport>                                                             m_viewports;
492         std::vector<vk::VkRect2D>                                                               m_scissors;
493
494         std::vector<vk::VkSampleMask>                                                   m_multisampleStateSampleMask;
495 };
496
497 class SamplerCreateInfo : public vk::VkSamplerCreateInfo
498 {
499 public:
500         SamplerCreateInfo (vk::VkFilter                         magFilter                               = vk::VK_FILTER_NEAREST,
501                                            vk::VkFilter                         minFilter                               = vk::VK_FILTER_NEAREST,
502                                            vk::VkSamplerMipmapMode      mipmapMode                              = vk::VK_SAMPLER_MIPMAP_MODE_NEAREST,
503                                            vk::VkSamplerAddressMode     addressU                                = vk::VK_SAMPLER_ADDRESS_MODE_MIRRORED_REPEAT,
504                                            vk::VkSamplerAddressMode     addressV                                = vk::VK_SAMPLER_ADDRESS_MODE_MIRRORED_REPEAT,
505                                            vk::VkSamplerAddressMode     addressW                                = vk::VK_SAMPLER_ADDRESS_MODE_MIRRORED_REPEAT,
506                                            float                                        mipLodBias                              = 0.0f,
507                                            vk::VkBool32                         anisotropyEnable                = vk::VK_FALSE,
508                                            float                                        maxAnisotropy                   = 1.0f,
509                                            vk::VkBool32                         compareEnable                   = false,
510                                            vk::VkCompareOp                      compareOp                               = vk::VK_COMPARE_OP_ALWAYS,
511                                            float                                        minLod                                  = 0.0f,
512                                            float                                        maxLod                                  = 16.0f,
513                                            vk::VkBorderColor            borderColor                             = vk::VK_BORDER_COLOR_FLOAT_OPAQUE_WHITE,
514                                            vk::VkBool32                         unnormalizedCoordinates = false);
515 };
516
517 } // QueryPool
518 } // vkt
519
520 #endif // _VKTQUERYPOOLCREATEINFOUTIL_HPP