Skip to content

Commit

Permalink
Bug fixes in D3D12_BLEND_DESC.ctor() and D3D12_DEPTH_STENCIL_DESC ali…
Browse files Browse the repository at this point in the history
…gnment
  • Loading branch information
David Hall committed Feb 3, 2025
1 parent 06ceb27 commit 3973194
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions PInvoke/Direct3D12/D3D12.Struct.cs
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,9 @@ public D3D12_BLEND_DESC()
LogicOp = D3D12_LOGIC_OP.D3D12_LOGIC_OP_NOOP,
RenderTargetWriteMask = D3D12_COLOR_WRITE_ENABLE.D3D12_COLOR_WRITE_ENABLE_ALL
};
SetRenderTarget(def);
_RenderTarget = new D3D12_RENDER_TARGET_BLEND_DESC[8];
for (var i = 0; i < 8; i++)
_RenderTarget[i] = def;
}
}

Expand Down Expand Up @@ -1121,7 +1123,7 @@ public D3D12_CPU_DESCRIPTOR_HANDLE Offset(int offsetScaledByIncrementSize)
// BOOL DepthEnable; D3D12_DEPTH_WRITE_MASK DepthWriteMask; D3D12_COMPARISON_FUNC DepthFunc; BOOL StencilEnable; UINT8 StencilReadMask;
// UINT8 StencilWriteMask; D3D12_DEPTH_STENCILOP_DESC FrontFace; D3D12_DEPTH_STENCILOP_DESC BackFace; } D3D12_DEPTH_STENCIL_DESC;
[PInvokeData("d3d12.h", MSDNShortId = "NS:d3d12.D3D12_DEPTH_STENCIL_DESC")]
[StructLayout(LayoutKind.Sequential)]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
public struct D3D12_DEPTH_STENCIL_DESC
{
/// <summary>Specifies whether to enable depth testing. Set this member to <b>TRUE</b> to enable depth testing.</summary>
Expand Down

0 comments on commit 3973194

Please sign in to comment.