# C1.Util.DX.Direct3D11.DeviceContext.ClearDepthStencilView

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_Util_DX_Direct3D11_DeviceContext_ClearDepthStencilView_" data-uid="C1.Util.DX.Direct3D11.DeviceContext.ClearDepthStencilView*">ClearDepthStencilView Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_Util_DX_Direct3D11_DeviceContext_ClearDepthStencilView_" data-uid="C1.Util.DX.Direct3D11.DeviceContext.ClearDepthStencilView*"></a>
<h4 id="C1_Util_DX_Direct3D11_DeviceContext_ClearDepthStencilView_C1_Util_DX_Direct3D11_DepthStencilView_C1_Util_DX_Direct3D11_DepthStencilClearFlags_System_Single_System_Byte_" data-uid="C1.Util.DX.Direct3D11.DeviceContext.ClearDepthStencilView(C1.Util.DX.Direct3D11.DepthStencilView,C1.Util.DX.Direct3D11.DepthStencilClearFlags,System.Single,System.Byte)">ClearDepthStencilView(DepthStencilView, DepthStencilClearFlags, float, byte)</h4>
<div class="markdown level1 summary"><p>void ID3D11DeviceContext::ClearDepthStencilView([In] ID3D11DepthStencilView* pDepthStencilView,[In] D3D11_CLEAR_FLAG ClearFlags,[In] float Depth,[In] unsigned char Stencil)</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public void ClearDepthStencilView(DepthStencilView depthStencilViewRef, DepthStencilClearFlags clearFlags, float depth, byte stencil)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub ClearDepthStencilView(depthStencilViewRef As DepthStencilView, clearFlags As DepthStencilClearFlags, depth As Single, stencil As Byte)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.Util.DX.Direct3D11.DepthStencilView.html">DepthStencilView</a></td>
      <td><span class="parametername">depthStencilViewRef</span></td>
      <td></td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.Util.DX.Direct3D11.DepthStencilClearFlags.html">DepthStencilClearFlags</a></td>
      <td><span class="parametername">clearFlags</span></td>
      <td></td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.single">float</a></td>
      <td><span class="parametername">depth</span></td>
      <td></td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.byte">byte</a></td>
      <td><span class="parametername">stencil</span></td>
      <td></td>
    </tr>
  </tbody>
</table>
</div>
