9 #ifndef DUNE_SHADER_RESOURCE
10 #define DUNE_SHADER_RESOURCE
29 virtual void to_vs(ID3D11DeviceContext* context, UINT slot);
32 virtual void to_gs(ID3D11DeviceContext* context, UINT slot);
35 virtual void to_ps(ID3D11DeviceContext* context, UINT slot);
38 virtual void to_cs(ID3D11DeviceContext* context, UINT slot);
51 ID3D11SamplerState* state;
53 void create(ID3D11Device* device,
const D3D11_SAMPLER_DESC& desc);
56 void to_vs(ID3D11DeviceContext* context, UINT slot);
57 void to_ps(ID3D11DeviceContext* context, UINT slot);
virtual void to_vs(ID3D11DeviceContext *context, UINT slot)
Upload the shader resource to register slot of a vertex shader.
Definition: shader_resource.cpp:14
virtual void to_ps(ID3D11DeviceContext *context, UINT slot)
Upload the shader resource to register slot of a pixel shader.
Definition: shader_resource.cpp:24
void to_vs(ID3D11DeviceContext *context, UINT slot)
Upload the shader resource to register slot of a vertex shader.
Definition: shader_resource.cpp:44
A shader resource wrapper.
Definition: shader_resource.h:24
virtual void destroy()=0
Destroy the shader_resource and free all memory.
A wrapper class for a sampler state.
Definition: shader_resource.h:49
virtual void to_cs(ID3D11DeviceContext *context, UINT slot)
Upload the shader resource to register slot of a compute shader.
Definition: shader_resource.cpp:29
void to_ps(ID3D11DeviceContext *context, UINT slot)
Upload the shader resource to register slot of a pixel shader.
Definition: shader_resource.cpp:49
void destroy()
Destroy the shader_resource and free all memory.
Definition: shader_resource.cpp:39
virtual void to_gs(ID3D11DeviceContext *context, UINT slot)
Upload the shader resource to register slot of a geometry shader.
Definition: shader_resource.cpp:19