Pass through resource view element size in D3D11 pipeline state

* This lets us calculate the offset and visible length when opening a
  buffer view from a resource binding.
This commit is contained in:
baldurk
2016-04-23 13:03:41 +02:00
parent e89fab7802
commit 5867d7ada1
4 changed files with 24 additions and 3 deletions
+2 -1
View File
@@ -82,7 +82,7 @@ struct D3D11PipelineState
{
ResourceView() : View(), Resource(),
Format(),
Structured(false), BufferStructCount(0),
Structured(false), BufferStructCount(0), ElementSize(0),
ElementOffset(0), ElementWidth(0),
FirstElement(0), NumElements(0),
Flags(0),
@@ -96,6 +96,7 @@ struct D3D11PipelineState
bool32 Structured;
uint32_t BufferStructCount;
uint32_t ElementSize;
// Buffer (SRV)
uint32_t ElementOffset;