public static void ClearDepthStencilView(this ID3D11DeviceContext context, ID3D11DepthStencilView depthStencilView, D3D11_CLEAR_FLAG flags, float depth, byte stencil) { if (context == null) { throw new ArgumentNullException(nameof(context)); } if (depthStencilView == null) { throw new ArgumentNullException(nameof(depthStencilView)); } context.ClearDepthStencilView(depthStencilView, (uint)flags, depth, stencil); }
public static void ClearDepthStencilView(this IComObject <ID3D11DeviceContext> context, IComObject <ID3D11DepthStencilView> depthStencilView, D3D11_CLEAR_FLAG flags, float depth, byte stencil) => ClearDepthStencilView(context?.Object, depthStencilView?.Object, flags, depth, stencil);