fix accidentally lost from #105 (#109)

This commit is contained in:
Kai Ninomiya 2017-08-11 18:06:25 -07:00 committed by GitHub
parent b985431c82
commit ba7a3224ea
2 changed files with 3 additions and 3 deletions

View File

@ -281,7 +281,7 @@ namespace d3d12 {
if (attachmentInfo.firstSubpass == currentSubpass) {
// Load op - color
if (attachmentInfo.colorLoadOp == nxt::LoadOp::Clear) {
auto handle = currentFramebuffer->GetDSVDescriptor(attachmentSlot);
auto handle = currentFramebuffer->GetRTVDescriptor(attachmentSlot);
const auto& clear = currentFramebuffer->GetClearColor(attachmentSlot);
commandList->ClearRenderTargetView(handle, clear.color, 0, nullptr);
}
@ -308,7 +308,7 @@ namespace d3d12 {
clearFlags |= D3D12_CLEAR_FLAG_STENCIL;
}
if (clearFlags) {
auto handle = currentFramebuffer->GetRTVDescriptor(attachmentSlot);
auto handle = currentFramebuffer->GetDSVDescriptor(attachmentSlot);
const auto& clear = currentFramebuffer->GetClearDepthStencil(attachmentSlot);
// TODO(kainino@chromium.org): investigate: should the NXT clear stencil type be uint8_t?
uint8_t clearStencil = static_cast<uint8_t>(clear.stencil);

@ -1 +1 @@
Subproject commit e8eae4d7dde433b1a8dc7e9a977508f8cef9c984
Subproject commit 2cbeaac76f6fac04f077a6aea2bd1417909798f3