25 #ifndef OPENSUBDIV3_OSD_D3D11_LEGACY_GREGORY_PATCH_TABLE_H
26 #define OPENSUBDIV3_OSD_D3D11_LEGACY_GREGORY_PATCH_TABLE_H
28 #include "../version.h"
30 #include "../far/patchTable.h"
31 #include "../osd/nonCopyable.h"
34 struct ID3D11ShaderResourceView;
36 struct ID3D11DeviceContext;
39 namespace OPENSUBDIV_VERSION {
44 :
private NonCopyable<D3D11LegacyGregoryPatchTable> {
48 template<
typename DEVICE_CONTEXT>
51 return Create(farPatchTable, context->GetDeviceContext());
56 ID3D11DeviceContext *deviceContext);
59 int numVertices,
int numVertexElements,
60 ID3D11DeviceContext *pd3d11DeviceContext);
67 return _vertexValenceSRV;
71 return _quadOffsetsSRV;
76 return _quadOffsetsBase[1];
78 return _quadOffsetsBase[0];
85 ID3D11Buffer* _vertexValenceBuffer;
86 ID3D11Buffer* _quadOffsetsBuffer;
87 ID3D11ShaderResourceView* _vertexSRV;
88 ID3D11ShaderResourceView* _vertexValenceSRV;
89 ID3D11ShaderResourceView* _quadOffsetsSRV;
90 int _quadOffsetsBase[2];
98 using namespace OPENSUBDIV_VERSION;
102 #endif // OPENSUBDIV3_OSD_D3D11_LEGACY_GREGORY_PATCH_TABLE_H
int GetQuadOffsetsBase(Far::PatchDescriptor::Type type)
ID3D11ShaderResourceView * GetVertexValenceSRV() const
D3D11LegacyGregoryPatchTable()
ID3D11ShaderResourceView * GetVertexSRV() const
ID3D11ShaderResourceView * GetQuadOffsetsSRV() const
void UpdateVertexBuffer(ID3D11Buffer *vbo, int numVertices, int numVertexElements, ID3D11DeviceContext *pd3d11DeviceContext)
static D3D11LegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
~D3D11LegacyGregoryPatchTable()
Container for arrays of parametric patches.