Commit df081fc2 authored by Florian Oetke's avatar Florian Oetke
Browse files

fixed some small problems

parent 6e14f7b3
......@@ -76,8 +76,6 @@ namespace mirrage::graphic {
switch(layout) {
case vk::ImageLayout::eUndefined: return vk::AccessFlags{};
case vk::ImageLayout::eGeneral: return ~vk::AccessFlags{};
case vk::ImageLayout::ePreinitialized: return vk::AccessFlagBits::eHostWrite;
case vk::ImageLayout::eColorAttachmentOptimal:
......@@ -100,8 +98,9 @@ namespace mirrage::graphic {
case vk::ImageLayout::eSharedPresentKHR:
case vk::ImageLayout::ePresentSrcKHR: return vk::AccessFlagBits::eColorAttachmentWrite;
default: return ~vk::AccessFlags{};
}
MIRRAGE_FAIL("Unreachable");
}
} // namespace
......
......@@ -28,7 +28,7 @@ namespace mirrage::renderer {
vk::ImageLayout::eShaderReadOnlyOptimal});
auto depth = builder.add_attachment(
vk::AttachmentDescription{vk::AttachmentDescriptionFlags{},
renderer.gbuffer().depth_format,
renderer.device().get_depth_format(),
vk::SampleCountFlagBits::e1,
vk::AttachmentLoadOp::eLoad,
vk::AttachmentStoreOp::eStore,
......
......@@ -14,7 +14,6 @@ namespace mirrage::renderer {
graphic::Render_target_2D& color_target,
graphic::Render_target_2D& color_target_diff,
graphic::Render_target_2D& depth_buffer,
vk::Format depth_buffer_format,
Deferred_geometry_subpass& gpass,
Deferred_lighting_subpass& lpass,
graphic::Framebuffer& out_framebuffer)
......@@ -24,10 +23,10 @@ namespace mirrage::renderer {
auto depth = builder.add_attachment(
vk::AttachmentDescription{vk::AttachmentDescriptionFlags{},
depth_buffer_format,
renderer.device().get_depth_format(),
vk::SampleCountFlagBits::e1,
vk::AttachmentLoadOp::eClear,
vk::AttachmentStoreOp::eDontCare,
vk::AttachmentStoreOp::eStore,
vk::AttachmentLoadOp::eDontCare,
vk::AttachmentStoreOp::eDontCare,
vk::ImageLayout::eUndefined,
......@@ -201,7 +200,6 @@ namespace mirrage::renderer {
color_target,
color_target_diff,
renderer.gbuffer().depth_buffer,
renderer.device().get_depth_format(),
_gpass,
_lpass,
_gbuffer_framebuffer))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment