microsoft / DirectXTK12

The DirectX Tool Kit (aka DirectXTK12) is a collection of helper classes for writing DirectX 12 code in C++
https://walbourn.github.io/directx-tool-kit-for-directx-12/
MIT License
1.48k stars 393 forks source link

D3D12_RENDER_PASS_DEPTH_STENCIL_DESC compare operator incorrectly checking StencilBeginningAccess against DepthBeginningAccess #51

Closed JosephClampett closed 5 years ago

JosephClampett commented 5 years ago
if (a.cpuDescriptor.ptr != b.cpuDescriptor.ptr) return false;
if (!(a.DepthBeginningAccess == b.DepthBeginningAccess)) return false;
if (!(a.StencilBeginningAccess == b.DepthBeginningAccess)) return false;
if (!(a.DepthEndingAccess == b.DepthEndingAccess)) return false;
if (!(a.StencilEndingAccess == b.StencilEndingAccess)) return false;

On line 2726 StencilBeginningAccess is incorrectly compared against DepthBeginningAccess.

walbourn commented 5 years ago

This is a bug with the d3dx12.h header which is actually hosted on DirectX-Graphics-Samples. Looks like this was already fixed there in this commit, so I'll update my copies of it.

walbourn commented 5 years ago

Fixed in this commit