diff options
| author | Mark Lobodzinski <mark@lunarg.com> | 2017-03-01 15:01:45 -0700 |
|---|---|---|
| committer | Mark Lobodzinski <mark@lunarg.com> | 2017-03-13 16:02:59 -0600 |
| commit | b74c683ea7e241d0592138db5f32f260fd95d8a4 (patch) | |
| tree | 5e7bb6fb733dd25aace73eb8e6dff41744ba13d0 /layers/core_validation.cpp | |
| parent | aec7de9f0207ced1d6bfa01546a51b774b693e2e (diff) | |
| download | usermoji-b74c683ea7e241d0592138db5f32f260fd95d8a4.tar.xz | |
layers: Add alphaToOne device feature validation
Change-Id: I1633cf7a8a5ebeed797cdb5373e5eb2533ce6887
Diffstat (limited to 'layers/core_validation.cpp')
| -rw-r--r-- | layers/core_validation.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index 5c8b7948..e5765aa5 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -3253,6 +3253,15 @@ static bool verifyPipelineCreateState(layer_data *dev_data, std::vector<PIPELINE if (pPipeline->graphicsPipelineCI.pRasterizationState->rasterizerDiscardEnable == VK_FALSE) { auto subpass_desc = renderPass ? &renderPass->createInfo.pSubpasses[pPipeline->graphicsPipelineCI.subpass] : nullptr; + if ((pPipeline->graphicsPipelineCI.pMultisampleState->alphaToOneEnable == VK_TRUE) && + (!dev_data->enabled_features.alphaToOne)) { + skip_call |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_UNKNOWN_EXT, + 0, __LINE__, VALIDATION_ERROR_01464, "DS", + "vkCreateGraphicsPipelines(): the alphaToOne device feature is disabled: the alphaToOneEnable " + "member of the VkPipelineMultisampleStateCreateInfo structure must be set to VK_FALSE.", + validation_error_map[VALIDATION_ERROR_01464]); + } + // If subpass uses a depth/stencil attachment, pDepthStencilState must be a pointer to a valid structure if (subpass_desc && subpass_desc->pDepthStencilAttachment && subpass_desc->pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED) { |
