title: What is the difference between a "resource" and a "resource view"?
body: <p>In Vulkan, a memory resource is accessed via "pointer-like" metadata contained in a "view", which describes how the memory resource should be interpreted. A descriptor is data which specifies to a shader "where" this memory will be located.</p>
  
  <p>In DirectX 12, a resource is short for "memory resource" (see: <a href="https://www.3dgep.com/learning-directx12-1/" rel="nofollow noreferrer">https://www.3dgep.com/learning-directx12-1/</a>). A resource view is a wrapping around a resource which allows specific usage. For instance, a "shader resource view" (SRV) allows the resource to be accessed by a shader, while a "unordered access view" is similar to a SRV, except it allows for the data to be accessed in any order. </p>
  
  <p>A "constant buffer view" (CBV) allows shaders to access data which will be more persistent/constant than usual. The DirectX 12 docs don't seem to differentiate between a CBV and a constant buffer. For example, the article titled <a href="https://docs.microsoft.com/en-us/windows/uwp/graphics-concepts/constant-buffer-view--cbv-" rel="nofollow noreferrer">"Constant Buffer View"</a> says: </p>
  
  <blockquote>
    <p>Constant buffers contain shader constant data. The value of them is that the data persists, and can be accessed by any GPU shader, until it is necessary to change the data.</p>
  </blockquote>
  
  <p>The word "view" is not mentioned anywhere, almost as if there is no difference between a resource, and a resource view. Another place where this happens in the docs is in the article on <a href="https://docs.microsoft.com/en-us/windows/desktop/direct3d12/resource-binding-flow-of-control" rel="nofollow noreferrer">resource bindings</a>:</p>
  
  <blockquote>
    <p>The most common resources are:</p>
    
    <ul>
    <li>Constant buffer views (CBVs)</li>
    <li>Unordered access views (UAVs)</li>
    <li>Shader resource views (SRVs)</li>
    <li>Samplers</li>
    </ul>
  </blockquote>
  
  <p>When listing common resources, the article mentions resource views, again as if they are the same thing.</p>
  
  <p><strong>What is the difference between a resource, and a resource view in DirectX 12?</strong></p>