mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-14 08:50:58 +00:00
80aec45e35
I had forgotten that msaa samples was governed by the driver (as a max) and the renderpass setup code simply took the max. Thus why 1 vs 8 caused the display to render incorrectly.
72 lines
2 KiB
Text
72 lines
2 KiB
Text
{
|
|
renderpass = {
|
|
attachments = (
|
|
{
|
|
flags = 0;
|
|
format = $swapchain.format;
|
|
samples = $msaaSamples;
|
|
loadOp = VK_ATTACHMENT_LOAD_OP_CLEAR;
|
|
storeOp = VK_ATTACHMENT_STORE_OP_STORE;
|
|
stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE;
|
|
stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE;
|
|
initialLayout = VK_IMAGE_LAYOUT_UNDEFINED;
|
|
finalLayout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL;
|
|
},
|
|
{
|
|
flags = 0;
|
|
format = VK_FORMAT_D32_SFLOAT;
|
|
samples = $msaaSamples;
|
|
loadOp = VK_ATTACHMENT_LOAD_OP_CLEAR;
|
|
storeOp = VK_ATTACHMENT_STORE_OP_DONT_CARE;
|
|
stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE;
|
|
stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE;
|
|
initialLayout = VK_IMAGE_LAYOUT_UNDEFINED;
|
|
finalLayout = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL;
|
|
},
|
|
{
|
|
flags = 0;
|
|
format = $swapchain.format;
|
|
samples = VK_SAMPLE_COUNT_1_BIT;
|
|
loadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE;
|
|
storeOp = VK_ATTACHMENT_STORE_OP_STORE;
|
|
stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE;
|
|
stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE;
|
|
initialLayout = VK_IMAGE_LAYOUT_UNDEFINED;
|
|
finalLayout = VK_IMAGE_LAYOUT_PRESENT_SRC_KHR;
|
|
},
|
|
);
|
|
subpasses = (
|
|
{
|
|
pipelineBindPoint = VK_PIPELINE_BIND_POINT_GRAPHICS;
|
|
colorAttachments = (
|
|
{
|
|
attachment = 0;
|
|
layout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL;
|
|
}
|
|
);
|
|
resolveAttachments = (
|
|
{
|
|
attachment = 2;
|
|
layout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL;
|
|
}
|
|
);
|
|
depthStencilAttachment = {
|
|
attachment = 1;
|
|
layout = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL;
|
|
};
|
|
preserveAttachments = ();
|
|
},
|
|
);
|
|
dependencies = (
|
|
{
|
|
srcSubpass = VK_SUBPASS_EXTERNAL;
|
|
dstSubpass = 0;
|
|
srcStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT;
|
|
dstStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT;
|
|
srcAccessMask = 0;
|
|
dstAccessMask = "VK_ACCESS_COLOR_ATTACHMENT_READ_BIT | VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT";
|
|
dependencyFlags = 0;
|
|
}
|
|
);
|
|
}
|
|
}
|