Lines Matching defs:const

67 static const VkVertexInputBindingDescription defaultVertexInputBindingDescription
74 static const VkVertexInputAttributeDescription defaultVertexInputAttributeDescription
82 static const VkPipelineVertexInputStateCreateInfo defaultVertexInputState
85 DE_NULL, // const void* pNext
88 &defaultVertexInputBindingDescription, // const VkVertexInputBindingDescription* pVertexBindingDescriptions
90 &defaultVertexInputAttributeDescription // const VkVertexInputAttributeDescription* pVertexAttributeDescriptions
93 static const VkStencilOpState defaultStencilOpState
104 static const VkPipelineDepthStencilStateCreateInfo defaultDepthStencilState
107 DE_NULL, // const void* pNext
120 static const VkPipelineMultisampleStateCreateInfo defaultMultisampleState
123 DE_NULL, // const void* pNext
128 DE_NULL, // const VkSampleMask* pSampleMask
133 static const VkPipelineColorBlendAttachmentState defaultColorBlendAttachmentState
145 static const VkPipelineColorBlendStateCreateInfo defaultColorBlendState
148 DE_NULL, // const void* pNext
153 &defaultColorBlendAttachmentState, // const VkPipelineColorBlendAttachmentState* pAttachments
160 VkGraphicsPipelineLibraryCreateInfoEXT makeGraphicsPipelineLibraryCreateInfo(const VkGraphicsPipelineLibraryFlagsEXT flags)
171 Move<VkPipeline> makeGraphicsPipeline (const DeviceInterface& vk,
174 const VkGraphicsPipelineCreateInfo* pCreateInfo,
175 const VkAllocationCallbacks* pAllocator = nullptr)
178 const auto retcode = vk.createGraphicsPipelines(device, pipelineCache, 1u, pCreateInfo, pAllocator, &object);
181 const bool allowCompileRequired = ((pCreateInfo->flags & VK_PIPELINE_CREATE_FAIL_ON_PIPELINE_COMPILE_REQUIRED_BIT) != 0u);
206 void checkPipelineConstructionRequirements (const InstanceInterface& vki,
213 const auto& supportedExtensions = enumerateCachedDeviceExtensionProperties(vki, physicalDevice);
238 // Cast to the base out structure which has a non-const pNext pointer.
259 // Cast to the base out structure which has a non-const pNext pointer.
275 PipelineLayoutWrapper::PipelineLayoutWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, VkDevice device, const std::vector<vk::Move<VkDescriptorSetLayout>>& descriptorSetLayout)
302 PipelineLayoutWrapper::PipelineLayoutWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, VkDevice device, deUint32 setLayoutCount, const VkDescriptorSetLayout* descriptorSetLayout)
329 PipelineLayoutWrapper::PipelineLayoutWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, VkDevice device, const VkDescriptorSetLayout descriptorSetLayout, const VkPushConstantRange* pushConstantRange)
370 PipelineLayoutWrapper::PipelineLayoutWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, VkDevice device, const VkPipelineLayoutCreateInfo* pCreateInfo, const VkAllocationCallbacks*)
399 PipelineLayoutWrapper::PipelineLayoutWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, const VkDevice device, const deUint32 setLayoutCount, const VkDescriptorSetLayout* descriptorSetLayout, const deUint32 pushConstantRangeCount, const VkPushConstantRange* pPushConstantRanges, const VkPipelineLayoutCreateFlags flags)
443 void PipelineLayoutWrapper::bindDescriptorSets (VkCommandBuffer commandBuffer, VkPipelineBindPoint pipelineBindPoint, uint32_t firstSet, uint32_t descriptorSetCount, const VkDescriptorSet* pDescriptorSets, uint32_t dynamicOffsetCount, const uint32_t* pDynamicOffsets) const
457 RenderPassWrapper::SubpassDependency::SubpassDependency (const VkSubpassDependency& dependency)
469 RenderPassWrapper::SubpassDependency::SubpassDependency (const VkSubpassDependency2& dependency)
480 const auto memBarrier = findStructure<VkMemoryBarrier2>(dependency.pNext);
499 RenderPassWrapper::RenderPassWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, VkDevice device, const VkRenderPassCreateInfo* pCreateInfo)
513 const auto multiView = findStructure<VkRenderPassMultiviewCreateInfo>(pCreateInfo->pNext);
631 RenderPassWrapper::RenderPassWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, VkDevice device, const VkRenderPassCreateInfo2* pCreateInfo)
646 const auto multiView = findStructure<VkRenderPassMultiviewCreateInfo>(pCreateInfo->pNext);
669 const auto msrtss = findStructure<VkMultisampledRenderToSingleSampledInfoEXT>(pCreateInfo->pSubpasses[s].pNext);
673 const auto dsr = findStructure<VkSubpassDescriptionDepthStencilResolve>(pCreateInfo->pSubpasses[s].pNext);
770 RenderPassWrapper::RenderPassWrapper (PipelineConstructionType pipelineConstructionType, const DeviceInterface& vk, const VkDevice device, const VkFormat colorFormat, const VkFormat depthStencilFormat, const VkAttachmentLoadOp loadOperation, const VkImageLayout finalLayoutColor,
771 const VkImageLayout finalLayoutDepthStencil, const VkImageLayout subpassLayoutColor, const VkImageLayout subpassLayoutDepthStencil, const VkAllocationCallbacks* const allocationCallbacks)
785 const bool hasColor = colorFormat != VK_FORMAT_UNDEFINED;
786 const bool hasDepthStencil = depthStencilFormat != VK_FORMAT_UNDEFINED;
787 const VkImageLayout initialLayoutColor = loadOperation == VK_ATTACHMENT_LOAD_OP_LOAD ? VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL : VK_IMAGE_LAYOUT_UNDEFINED;
788 const VkImageLayout initialLayoutDepthStencil = loadOperation == VK_ATTACHMENT_LOAD_OP_LOAD ? VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL : VK_IMAGE_LAYOUT_UNDEFINED;
809 const VkAttachmentDescription2 colorAttachmentDescription =
843 const VkAttachmentDescription2 depthStencilAttachmentDescription =
911 void RenderPassWrapper::clearAttachments(const DeviceInterface& vk, const VkCommandBuffer commandBuffer) const
915 const auto tcuFormat = vk::mapVkFormat(m_attachments[i].format);
949 void RenderPassWrapper::updateLayout(VkImage updatedImage, VkImageLayout newLayout) const
959 void recordImageBarrier (const DeviceInterface& vk,
960 const VkCommandBuffer commandBuffer,
961 const bool sync2,
962 const VkPipelineStageFlags2 srcStageMask,
963 const VkAccessFlags2 srcAccessMask,
964 const VkPipelineStageFlags2 dstStageMask,
965 const VkAccessFlags2 dstAccessMask,
966 const VkImageLayout prevLayout,
967 const VkImageLayout newLayout,
968 const VkImage image,
969 const VkImageSubresourceRange& subresourceRange)
973 const auto barrier = makeImageMemoryBarrier2(
983 const VkDependencyInfo depInfo =
986 nullptr, // const void* pNext;
989 nullptr, // const VkMemoryBarrier2* pMemoryBarriers;
991 nullptr, // const VkBufferMemoryBarrier2* pBufferMemoryBarriers;
993 &barrier, // const VkImageMemoryBarrier2* pImageMemoryBarriers;
1000 const auto barrier = makeImageMemoryBarrier(
1018 void RenderPassWrapper::transitionLayouts (const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const Subpass& subpass, bool renderPassBegin) const
1028 for (const auto& dep : m_dependencies)
1054 const auto subresourceRange = makeImageSubresourceRange(
1061 const VkPipelineStageFlags2 srcStageMask = (vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT | externalStageFlags);
1062 const VkAccessFlags2 srcAccessMask = externalAccessFlags;
1063 const VkPipelineStageFlags2 dstStageMask = vk::VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT;
1064 const VkAccessFlags2 dstAccessMask = vk::VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT;
1065 const VkImageLayout newLayout = subpass.m_colorAttachments[j].attachmentInfo.imageLayout;
1084 const auto tcuFormat = vk::mapVkFormat(subpass.m_depthStencilAttachment.format);
1085 const bool hasDepthAspect = tcu::hasDepthComponent(tcuFormat.order);
1086 const bool hasStencilAspect = tcu::hasStencilComponent(tcuFormat.order);
1094 const auto subresourceRange = makeImageSubresourceRange(
1101 const VkPipelineStageFlags2 srcStageMask = (vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT | externalStageFlags);
1102 const VkAccessFlags2 srcAccessMask = externalAccessFlags;
1103 const VkPipelineStageFlags2 dstStageMask = (vk::VK_PIPELINE_STAGE_EARLY_FRAGMENT_TESTS_BIT | vk::VK_PIPELINE_STAGE_LATE_FRAGMENT_TESTS_BIT);
1104 const VkAccessFlags2 dstAccessMask = (vk::VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_READ_BIT | vk::VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT);
1105 const VkImageLayout newLayout = subpass.m_depthStencilAttachment.attachmentInfo.imageLayout;
1125 const auto subresourceRange = makeImageSubresourceRange(
1132 const VkPipelineStageFlags2 srcStageMask = (vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT | externalStageFlags);
1133 const VkAccessFlags2 srcAccessMask = externalAccessFlags;
1134 const VkPipelineStageFlags2 dstStageMask = vk::VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT;
1135 const VkAccessFlags2 dstAccessMask = vk::VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT;
1136 const VkImageLayout newLayout = subpass.m_resolveAttachments[j].attachmentInfo.imageLayout;
1157 const auto tcuFormat = vk::mapVkFormat(subpass.m_depthStencilAttachment.format);
1158 const bool hasDepthAspect = tcu::hasDepthComponent(tcuFormat.order);
1159 const bool hasStencilAspect = tcu::hasStencilComponent(tcuFormat.order);
1167 const auto subresourceRange = makeImageSubresourceRange(
1174 const VkPipelineStageFlags2 srcStageMask = (vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT | externalStageFlags);
1175 const VkAccessFlags2 srcAccessMask = externalAccessFlags;
1176 const VkPipelineStageFlags2 dstStageMask = (vk::VK_PIPELINE_STAGE_EARLY_FRAGMENT_TESTS_BIT | vk::VK_PIPELINE_STAGE_LATE_FRAGMENT_TESTS_BIT);
1177 const VkAccessFlags2 dstAccessMask = vk::VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_READ_BIT | vk::VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT;
1178 const VkImageLayout newLayout = subpass.m_dsr.pDepthStencilResolveAttachment->layout;
1199 void RenderPassWrapper::insertDependencies (const DeviceInterface& vk, const VkCommandBuffer commandBuffer, uint32_t subpassIdx) const
1201 for (const auto& dep : m_dependencies)
1209 const VkMemoryBarrier2 barrier =
1212 nullptr, // const void* pNext;
1218 const VkDependencyInfo depInfo =
1221 nullptr, // const void* pNext;
1224 &barrier, // const VkMemoryBarrier2* pMemoryBarriers;
1226 nullptr, // const VkBufferMemoryBarrier2* pBufferMemoryBarriers;
1228 nullptr, // const VkImageMemoryBarrier2* pImageMemoryBarriers;
1234 const VkMemoryBarrier barrier =
1237 nullptr, // const void* pNext;
1251 void RenderPassWrapper::fillInheritanceRenderingInfo(deUint32 subpassIndex, std::vector<vk::VkFormat>* colorFormats, vk::VkCommandBufferInheritanceRenderingInfo* inheritanceRenderingInfo) const
1253 const auto& subpass = m_subpasses[subpassIndex];
1263 const auto tcuFormat = vk::mapVkFormat(subpass.m_depthStencilAttachment.format);
1276 void RenderPassWrapper::begin (const DeviceInterface& vk,
1277 const VkCommandBuffer commandBuffer,
1278 const VkRect2D& renderArea,
1279 const deUint32 clearValueCount,
1280 const VkClearValue* clearValues,
1281 const VkSubpassContents contents,
1282 const void* pNext) const
1317 void RenderPassWrapper::begin (const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const VkRect2D& renderArea, const VkClearValue& clearValue, const VkSubpassContents contents) const
1322 void RenderPassWrapper::begin (const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const VkRect2D& renderArea, const tcu::Vec4& clearColor, const VkSubpassContents contents) const
1324 const VkClearValue clearValue = makeClearValueColor(clearColor);
1328 void RenderPassWrapper::begin(const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const VkRect2D& renderArea, const tcu::Vec4& clearColor, const float clearDepth, const deUint32 clearStencil, const VkSubpassContents contents) const
1330 const VkClearValue clearValues[] =
1338 void RenderPassWrapper::begin (const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const VkRect2D& renderArea, const VkSubpassContents contents) const
1344 void RenderPassWrapper::begin(const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const VkRect2D& renderArea, const tcu::UVec4& clearColor, const VkSubpassContents contents) const
1346 const VkClearValue clearValue = makeClearValueColorU32(clearColor.x(), clearColor.y(), clearColor.z(), clearColor.w());
1351 void RenderPassWrapper::end (const DeviceInterface& vk, const VkCommandBuffer commandBuffer) const
1369 for (const auto& dep : m_dependencies)
1385 const bool color = !vk::isDepthStencilFormat(m_attachments[i].format);
1390 const bool hasDepthAspect = tcu::hasDepthComponent(vk::mapVkFormat(m_attachments[i].format).order);
1391 const bool hasStencilAspect = tcu::hasStencilComponent(vk::mapVkFormat(m_attachments[i].format).order);
1399 const auto subresourceRange = makeImageSubresourceRange(
1406 const VkPipelineStageFlags2 srcStageMask = (color ? vk::VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT : vk::VK_PIPELINE_STAGE_LATE_FRAGMENT_TESTS_BIT);
1407 const VkAccessFlags2 srcAccessMask = (color ? vk::VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT : vk::VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT);
1408 const VkPipelineStageFlags2 dstStageMask = (vk::VK_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT | externalStageFlags);
1409 const VkAccessFlags2 dstAccessMask = externalAccessFlags;
1410 const VkImageLayout newLayout = m_attachments[i].finalLayout;
1430 void RenderPassWrapper::beginRendering (const DeviceInterface& vk, const VkCommandBuffer commandBuffer) const
1435 const auto& subpass = m_subpasses[m_activeSubpass];
1467 const auto tcuFormat = vk::mapVkFormat(subpass.m_depthStencilAttachment.format);
1511 void RenderPassWrapper::nextSubpass (const DeviceInterface& vk, const VkCommandBuffer commandBuffer, const VkSubpassContents contents) const
1524 const auto& subpass = m_subpasses[m_activeSubpass];
1535 void RenderPassWrapper::createFramebuffer (const DeviceInterface& vk, const VkDevice device, const VkFramebufferCreateInfo* pCreateInfo, const std::vector<vk::VkImage>& images)
1575 void RenderPassWrapper::createFramebuffer (const DeviceInterface& vk, const VkDevice device, const VkFramebufferCreateInfo* pCreateInfo, vk::VkImage colorImage, vk::VkImage depthStencilImage)
1609 void RenderPassWrapper::createFramebuffer (const DeviceInterface& vk, const VkDevice device, const VkImage colorImage, const VkImageView colorAttachment, const deUint32 width, const deUint32 height, const deUint32 layers)
1641 void RenderPassWrapper::createFramebuffer (const DeviceInterface& vk, const VkDevice device, const deUint32 attachmentCount, const VkImage* imagesArray, const VkImageView* attachmentsArray, const deUint32 width, const deUint32 height, const deUint32 layers)
1700 ShaderWrapper::ShaderWrapper (const DeviceInterface& vk, VkDevice device, const vk::ProgramBinary& binary, const vk::VkShaderModuleCreateFlags createFlags)
1714 ShaderWrapper::ShaderWrapper (const ShaderWrapper& rhs) noexcept
1728 ShaderWrapper& ShaderWrapper::operator= (const ShaderWrapper& rhs) noexcept
1745 vk::VkShaderModule ShaderWrapper::getModule (void) const
1756 size_t ShaderWrapper::getCodeSize (void) const
1761 void* ShaderWrapper::getBinary (void) const
1772 void ShaderWrapper::setLayoutAndSpecialization (const PipelineLayoutWrapper* layout, const VkSpecializationInfo* specializationInfo)
1790 const InstanceInterface& vki;
1791 const DeviceInterface& vk;
1794 const std::vector<std::string>& deviceExtensions;
1795 const PipelineConstructionType pipelineConstructionType;
1796 const VkPipelineCreateFlags pipelineFlags;
1810 const VkPipelineDynamicStateCreateInfo* pDynamicState;
1930 InternalData(const InstanceInterface& instanceInterface, const DeviceInterface& vkd, VkPhysicalDevice physDevice, VkDevice vkDevice, const std::vector<std::string>& deviceExts, const PipelineConstructionType constructionType, const VkPipelineCreateFlags pipelineCreateFlags)
1943 DE_NULL, // const void* pNext
1951 DE_NULL, // const void* pNext
1967 DE_NULL, // const void* pNext
1970 DE_NULL, // const VkViewport* pViewports
1972 DE_NULL // const VkRect2D* pScissors
1977 DE_NULL, // const void* pNext
2000 bool extensionEnabled (const std::string& ext) const
2007 GraphicsPipelineWrapper::GraphicsPipelineWrapper(const InstanceInterface& vki,
2008 const DeviceInterface& vk,
2011 const std::vector<std::string>& deviceExtensions,
2012 const PipelineConstructionType pipelineConstructionType,
2013 const VkPipelineCreateFlags flags)
2025 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setMonolithicPipelineLayout(const PipelineLayoutWrapper& layout)
2035 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setDynamicState(const VkPipelineDynamicStateCreateInfo* dynamicState)
2064 std::vector<VkDynamicState> getDynamicStates(const VkPipelineDynamicStateCreateInfo* dynamicStateInfo, uint32_t setupState)
2066 static const std::set<VkDynamicState> vertexInputStates {
2073 static const std::set<VkDynamicState> preRastStates {
2111 static const std::set<VkDynamicState> fragShaderStates {
2141 static const std::set<VkDynamicState> fragOutputStates {
2169 const std::set<VkDynamicState> dynamicStates (dynamicStateInfo->pDynamicStates,
2173 for (const auto dynState : dynamicStates)
2196 const std::vector<VkDynamicState> returnedStates (begin(intersectedStates), end(intersectedStates));
2201 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setDefaultTopology(const VkPrimitiveTopology topology)
2211 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setDefaultPatchControlPoints(const deUint32 patchControlPoints)
2221 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setDefaultTessellationDomainOrigin (const VkTessellationDomainOrigin domainOrigin, bool forceExtStruct)
2243 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setDefaultRasterizerDiscardEnable(const deBool rasterizerDiscardEnable)
2294 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setDefaultVertexInputState(const deBool useDefaultVertexInputState)
2324 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setViewportStatePnext(const void* pNext)
2354 GraphicsPipelineWrapper& GraphicsPipelineWrapper::disableViewportState(const bool disable)
2364 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupVertexInputState(const VkPipelineVertexInputStateCreateInfo* vertexInputState,
2365 const VkPipelineInputAssemblyStateCreateInfo* inputAssemblyState,
2366 const VkPipelineCache partPipelineCache,
2368 const bool useNullPtrs)
2382 const auto pVertexInputState = ((vertexInputState || useNullPtrs || !m_internalData->useDefaultVertexInputState)
2385 const auto pInputAssemblyState = ((inputAssemblyState || useNullPtrs) ? inputAssemblyState : &m_internalData->inputAssemblyState);
2438 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupPreRasterizationShaderState(const std::vector<VkViewport>& viewports,
2439 const std::vector<VkRect2D>& scissors,
2440 const PipelineLayoutWrapper& layout,
2441 const VkRenderPass renderPass,
2442 const deUint32 subpass,
2443 const ShaderWrapper vertexShader,
2444 const VkPipelineRasterizationStateCreateInfo* rasterizationState,
2445 const ShaderWrapper tessellationControlShader,
2446 const ShaderWrapper tessellationEvalShader,
2447 const ShaderWrapper geometryShader,
2448 const VkSpecializationInfo *specializationInfo,
2451 const VkPipelineCache partPipelineCache,
2475 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupPreRasterizationShaderState2(const std::vector<VkViewport>& viewports,
2476 const std::vector<VkRect2D>& scissors,
2477 const PipelineLayoutWrapper& layout,
2478 const VkRenderPass renderPass,
2479 const deUint32 subpass,
2480 const ShaderWrapper vertexShader,
2481 const VkPipelineRasterizationStateCreateInfo* rasterizationState,
2482 const ShaderWrapper tessellationControlShader,
2483 const ShaderWrapper tessellationEvalShader,
2484 const ShaderWrapper geometryShader,
2485 const VkSpecializationInfo* vertSpecializationInfo,
2486 const VkSpecializationInfo* tescSpecializationInfo,
2487 const VkSpecializationInfo* teseSpecializationInfo,
2488 const VkSpecializationInfo* geomSpecializationInfo,
2491 const VkPipelineCache partPipelineCache,
2518 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupPreRasterizationShaderState3(const std::vector<VkViewport>& viewports,
2519 const std::vector<VkRect2D>& scissors,
2520 const PipelineLayoutWrapper& layout,
2521 const VkRenderPass renderPass,
2522 const deUint32 subpass,
2523 const ShaderWrapper vertexShader,
2525 const VkPipelineRasterizationStateCreateInfo* rasterizationState,
2526 const ShaderWrapper tessellationControlShader,
2528 const ShaderWrapper tessellationEvalShader,
2530 const ShaderWrapper geometryShader,
2532 const VkSpecializationInfo* vertSpecializationInfo,
2533 const VkSpecializationInfo* tescSpecializationInfo,
2534 const VkSpecializationInfo* teseSpecializationInfo,
2535 const VkSpecializationInfo* geomSpecializationInfo,
2538 const VkPipelineCache partPipelineCache,
2559 const bool hasTesc = (tessellationControlShader.isSet() || tescShaderModuleId.ptr);
2560 const bool hasTese = (tessellationEvalShader.isSet() || teseShaderModuleId.ptr);
2561 const bool hasGeom = (geometryShader.isSet() || geomShaderModuleId.ptr);
2563 const auto pRasterizationState = rasterizationState ? rasterizationState
2565 const bool forceNullTessState = (m_internalData->tessellationState.patchControlPoints == std::numeric_limits<uint32_t>::max());
2566 const auto pTessellationState = ((hasTesc || hasTese) && !forceNullTessState) ? &m_internalData->tessellationState : nullptr;
2567 const auto pViewportState = m_internalData->useViewportState ? &m_internalData->viewportState : DE_NULL;
2580 DE_NULL, // const void* pNext
2584 "main", // const char* pName
2585 vertSpecializationInfo // const VkSpecializationInfo* pSpecializationInfo
2761 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupPreRasterizationMeshShaderState(const std::vector<VkViewport>& viewports,
2762 const std::vector<VkRect2D>& scissors,
2763 const PipelineLayoutWrapper& layout,
2764 const VkRenderPass renderPass,
2765 const deUint32 subpass,
2766 const ShaderWrapper taskShader,
2767 const ShaderWrapper meshShader,
2768 const VkPipelineRasterizationStateCreateInfo* rasterizationState,
2769 const VkSpecializationInfo *taskSpecializationInfo,
2770 const VkSpecializationInfo *meshSpecializationInfo,
2773 const VkPipelineCache partPipelineCache,
2787 const bool hasTask = (taskShader.isSet());
2788 const auto taskShaderCount = static_cast<uint32_t>(hasTask);
2789 const auto pRasterizationState = rasterizationState
2794 const auto pTessellationState = nullptr;
2795 const auto pViewportState = m_internalData->useViewportState ? &m_internalData->viewportState : DE_NULL;
2801 nullptr, // const void* pNext
2805 "main", // const char* pName
2806 nullptr, // const VkSpecializationInfo* pSpecializationInfo
2920 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupFragmentShaderState(const PipelineLayoutWrapper& layout,
2921 const VkRenderPass renderPass,
2922 const deUint32 subpass,
2923 const ShaderWrapper fragmentShader,
2924 const VkPipelineDepthStencilStateCreateInfo* depthStencilState,
2925 const VkPipelineMultisampleStateCreateInfo* multisampleState,
2926 const VkSpecializationInfo* specializationInfo,
2927 const VkPipelineCache partPipelineCache,
2942 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupFragmentShaderState2(const PipelineLayoutWrapper& layout,
2943 const VkRenderPass renderPass,
2944 const deUint32 subpass,
2945 const ShaderWrapper fragmentShader,
2947 const VkPipelineDepthStencilStateCreateInfo* depthStencilState,
2948 const VkPipelineMultisampleStateCreateInfo* multisampleState,
2949 const VkSpecializationInfo* specializationInfo,
2950 const VkPipelineCache partPipelineCache,
2969 const auto pDepthStencilState = depthStencilState ? depthStencilState
2971 const auto pMultisampleState = multisampleState ? multisampleState
2973 const bool hasFrag = (fragmentShader.isSet() || fragmentShaderModuleId.ptr);
3072 GraphicsPipelineWrapper& GraphicsPipelineWrapper::setupFragmentOutputState(const VkRenderPass renderPass,
3073 const deUint32 subpass,
3074 const VkPipelineColorBlendStateCreateInfo* colorBlendState,
3075 const VkPipelineMultisampleStateCreateInfo* multisampleState,
3076 const VkPipelineCache partPipelineCache,
3099 const auto pColorBlendState = colorBlendState ? colorBlendState
3101 const auto pMultisampleState = multisampleState ? multisampleState
3326 void GraphicsPipelineWrapper::buildPipeline(const VkPipelineCache pipelineCache,
3327 const VkPipeline basePipelineHandle,
3328 const deInt32 basePipelineIndex,
3518 const auto depthClipControl = findStructure<VkPipelineViewportDepthClipControlCreateInfoEXT>(pointerToCreateInfo->pViewportState->pNext);
3521 const auto viewportShadingRate = findStructure<VkPipelineViewportShadingRateImageStateCreateInfoNV>(pointerToCreateInfo->pViewportState->pNext);
3537 const auto viewportSwizzle = findStructure<VkPipelineViewportSwizzleStateCreateInfoNV>(pointerToCreateInfo->pViewportState->pNext);
3544 const auto viewportWScaling = findStructure<VkPipelineViewportWScalingStateCreateInfoNV>(pointerToCreateInfo->pViewportState->pNext);
3553 const auto coarseSampleOrder = findStructure<VkPipelineViewportCoarseSampleOrderStateCreateInfoNV>(pointerToCreateInfo->pViewportState->pNext);
3581 const auto conservative = findStructure<VkPipelineRasterizationConservativeStateCreateInfoEXT>(pointerToCreateInfo->pRasterizationState->pNext);
3588 const auto depthClip = findStructure<VkPipelineRasterizationDepthClipStateCreateInfoEXT>(pointerToCreateInfo->pRasterizationState->pNext);
3594 const auto rasterizationLine = findStructure<VkPipelineRasterizationLineStateCreateInfoEXT>(pointerToCreateInfo->pRasterizationState->pNext);
3602 const auto rasterizationStream = findStructure<VkPipelineRasterizationStateStreamCreateInfoEXT>(pointerToCreateInfo->pRasterizationState->pNext);
3606 const auto provokingVertex = findStructure<VkPipelineRasterizationProvokingVertexStateCreateInfoEXT>(pointerToCreateInfo->pRasterizationState->pNext);
3609 const auto depthBiasRepresentationInfo = findStructure<VkDepthBiasRepresentationInfoEXT>(pointerToCreateInfo->pRasterizationState->pNext);
3620 const auto blendAdvancedState = findStructure<VkPipelineColorBlendAdvancedStateCreateInfoEXT>(pointerToCreateInfo->pColorBlendState->pNext);
3659 const auto colorWrite = findStructure<VkPipelineColorWriteCreateInfoEXT>(pointerToCreateInfo->pColorBlendState->pNext);
3698 const auto divisorInfo = findStructure<VkPipelineVertexInputDivisorStateCreateInfoEXT>(pointerToCreateInfo->pVertexInputState->pNext);
3722 const auto tessellationDomainOrigin = findStructure<VkPipelineTessellationDomainOriginStateCreateInfo>(pointerToCreateInfo->pTessellationState->pNext);
3730 const auto coverageModulation = findStructure<VkPipelineCoverageModulationStateCreateInfoNV>(pointerToCreateInfo->pMultisampleState->pNext);
3739 const auto coverageReduction = findStructure<VkPipelineCoverageReductionStateCreateInfoNV>(pointerToCreateInfo->pMultisampleState->pNext);
3742 const auto coverageToColor = findStructure<VkPipelineCoverageToColorStateCreateInfoNV>(pointerToCreateInfo->pMultisampleState->pNext);
3749 const auto sampleLocations = findStructure<VkPipelineSampleLocationsStateCreateInfoEXT>(pointerToCreateInfo->pMultisampleState->pNext);
3768 const auto representativeFragment = findStructure<VkPipelineRepresentativeFragmentTestStateCreateInfoNV>(pointerToCreateInfo->pNext);
3773 const auto fragmentShadingRate = findStructure<VkPipelineFragmentShadingRateStateCreateInfoKHR>(pointerToCreateInfo->pNext);
3780 const auto exclusiveScissor = findStructure<VkPipelineViewportExclusiveScissorStateCreateInfoNV>(pointerToCreateInfo->pNext);
3788 const auto discardRectangle = findStructure<VkPipelineDiscardRectangleStateCreateInfoEXT>(pointerToCreateInfo->pNext);
3821 creationFeedback.ptr, // const void* pNext;
3823 nullptr, // const VkPipeline* pLibraries;
3828 for (const auto& pipelinePtr : m_pipelineParts)
3830 const auto& pipeline = pipelinePtr.get();
3876 bool GraphicsPipelineWrapper::isShaderObjectDynamic (vk::VkDynamicState dynamicState) const
3881 void GraphicsPipelineWrapper::setShaderObjectDynamicStates (vk::VkCommandBuffer cmdBuffer) const
3885 const auto& vk = m_internalData->vk;
3886 const auto state = &m_internalData->pipelineCreateState;
3889 const bool meshOrTask = m_internalData->meshShader.isSet() || m_internalData->taskShader.isSet();
3890 const bool tese = m_internalData->tessellationEvaluationShader.isSet();
3891 const bool topologyPatchList = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_PRIMITIVE_TOPOLOGY) || state->topology == VK_PRIMITIVE_TOPOLOGY_PATCH_LIST;
3892 const bool rasterizerDiscardDisabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_RASTERIZER_DISCARD_ENABLE) || !state->rasterizerDiscardEnable;
3893 const bool polygonModeLine = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_POLYGON_MODE_EXT) || state->polygonMode == vk::VK_POLYGON_MODE_LINE;
3894 const bool topologyLine = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_PRIMITIVE_TOPOLOGY) ||
3897 const bool depthTestEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_DEPTH_TEST_ENABLE) || state->depthTestEnable;
3898 const bool depthBoundsTestEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_DEPTH_BOUNDS_TEST_ENABLE) || state->depthBoundsTestEnable;
3899 const bool depthBiasEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_DEPTH_BIAS_ENABLE) || state->depthBiasEnable;
3900 const bool stencilTestEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_STENCIL_TEST_ENABLE) || state->stencilTestEnable;
3901 const bool logicOpEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_LOGIC_OP_ENABLE_EXT) || state->logicOpEnable;
3902 const bool discardRectangle = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_DISCARD_RECTANGLE_ENABLE_EXT) || state->discardRectangleEnable;
3903 const bool sampleLocationsEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT) || state->sampleLocationsEnable;
3904 const bool stippledLineEnabled = !isShaderObjectDynamic(vk::VK_DYNAMIC_STATE_LINE_STIPPLE_ENABLE_EXT) || state->stippledLineEnable;
3906 for (const auto& blend : state->blendEquations)
3920 for (const auto dynamicState : m_internalData->shaderObjectDynamicStates)
4276 void GraphicsPipelineWrapper::bind (vk::VkCommandBuffer cmdBuffer) const
4278 const auto& vk = m_internalData->vk;
4286 const VkShaderStageFlagBits vertStage = vk::VK_SHADER_STAGE_VERTEX_BIT;
4289 const VkShaderStageFlagBits tescStage = vk::VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT;
4292 const VkShaderStageFlagBits teseStage = vk::VK_SHADER_STAGE_TESSELLATION_EVALUATION_BIT;
4295 const VkShaderStageFlagBits geomStage = vk::VK_SHADER_STAGE_GEOMETRY_BIT;
4298 const VkShaderStageFlagBits fragStage = vk::VK_SHADER_STAGE_FRAGMENT_BIT;
4303 const VkShaderStageFlagBits meshStage = vk::VK_SHADER_STAGE_MESH_BIT_EXT;
4309 const VkShaderStageFlagBits taskStage = vk::VK_SHADER_STAGE_TASK_BIT_EXT;
4319 deBool GraphicsPipelineWrapper::wasBuild() const
4324 deBool GraphicsPipelineWrapper::wasPipelineOrShaderObjectBuild (void) const
4343 VkPipeline GraphicsPipelineWrapper::getPipeline (void) const