|
Nameless Engine
|
#include <ShaderResourceBinding.h>
Public Member Functions | |
| virtual std::optional< Error > | useNewTexture (std::unique_ptr< TextureHandle > pTextureToUse)=0 |
Public Member Functions inherited from ne::ShaderResourceBindingBase | |
| virtual std::optional< Error > | changeUsedPipelines (const std::unordered_set< Pipeline * > &pipelinesToUse)=0 |
| std::string | getShaderResourceName () const |
Protected Member Functions | |
| ShaderTextureResourceBinding (const std::string &sShaderResourceName) | |
Protected Member Functions inherited from ne::ShaderResourceBindingBase | |
| ShaderResourceBindingBase (const std::string &sShaderResourceName) | |
| virtual std::optional< Error > | onAfterAllPipelinesRefreshedResources ()=0 |
References some texture from shader code (can also a single texture in the array of textures).
|
protected |
Initializes the binding.
| sShaderResourceName | Name of the resource we are referencing (should be exactly the same as the resource name written in the shader file we are referencing). |
|
pure virtual |
Makes the binding to reference the new (specified) texture.
draw function while this function is not finished (i.e. make sure the CPU will not queue a new frame while this function is not finished).| pTextureToUse | Texture to reference. |
Implemented in ne::GlslShaderTextureResourceBinding, and ne::HlslShaderTextureResourceBinding.