diff --git a/src/backend/d3d12/CommandBufferD3D12.cpp b/src/backend/d3d12/CommandBufferD3D12.cpp index 86e458bf16..d1ce6a449f 100644 --- a/src/backend/d3d12/CommandBufferD3D12.cpp +++ b/src/backend/d3d12/CommandBufferD3D12.cpp @@ -479,7 +479,9 @@ namespace d3d12 { case Command::SetStencilReference: { - commands.NextCommand(); + SetStencilReferenceCmd *cmd = commands.NextCommand(); + + commandList->OMSetStencilRef(cmd->reference); } break; diff --git a/src/backend/d3d12/RenderPipelineD3D12.cpp b/src/backend/d3d12/RenderPipelineD3D12.cpp index c7d2052a38..c5f8191b60 100644 --- a/src/backend/d3d12/RenderPipelineD3D12.cpp +++ b/src/backend/d3d12/RenderPipelineD3D12.cpp @@ -162,6 +162,7 @@ namespace d3d12 { descriptor.PrimitiveTopologyType = D3D12PrimitiveTopologyType(GetPrimitiveTopology()); descriptor.NumRenderTargets = 1; descriptor.RTVFormats[0] = DXGI_FORMAT_R8G8B8A8_UNORM; + descriptor.DSVFormat = DXGI_FORMAT_D32_FLOAT_S8X24_UINT; descriptor.SampleDesc.Count = 1; Device* device = ToBackend(builder->GetDevice());