VulkanRenderer: Fix scissor handling

This commit is contained in:
Jérôme Leclercq 2022-01-01 23:02:09 +01:00
parent 1f15328fdd
commit 55784a7dfc
1 changed files with 2 additions and 6 deletions

View File

@ -126,9 +126,7 @@ namespace Nz
{
std::vector<VkDynamicState> dynamicStates;
dynamicStates.push_back(VK_DYNAMIC_STATE_VIEWPORT);
if (pipelineInfo.scissorTest)
dynamicStates.push_back(VK_DYNAMIC_STATE_SCISSOR);
dynamicStates.push_back(VK_DYNAMIC_STATE_SCISSOR);
return dynamicStates;
}
@ -170,9 +168,7 @@ namespace Nz
VkPipelineViewportStateCreateInfo createInfo = {};
createInfo.sType = VK_STRUCTURE_TYPE_PIPELINE_VIEWPORT_STATE_CREATE_INFO;
createInfo.viewportCount = 1; //< TODO: Handle multiple viewport regions
if (pipelineInfo.scissorTest)
createInfo.scissorCount = 1; //< TODO: Handle multiple scissor regions
createInfo.scissorCount = 1; //< TODO: Handle multiple scissor regions
return createInfo;
}