HDK
|
#include <glslfxResourceLayout.h>
Classes | |
struct | Element |
Specifies a resource element. More... | |
struct | Member |
Specifies a member of an aggregate resource element. More... | |
struct | TextureElement |
Specifies a texture element. More... | |
Public Types | |
enum | InOut { InOut::NONE, InOut::STAGE_IN, InOut::STAGE_OUT } |
enum | Kind { Kind::NONE, Kind::VALUE, Kind::BLOCK, Kind::QUALIFIER, Kind::UNIFORM_VALUE, Kind::UNIFORM_BLOCK, Kind::UNIFORM_BLOCK_CONSTANT_PARAMS, Kind::BUFFER_READ_ONLY, Kind::BUFFER_READ_WRITE } |
Specifies the kind of resource element. More... | |
enum | TextureType { TextureType::TEXTURE, TextureType::SHADOW_TEXTURE, TextureType::ARRAY_TEXTURE } |
Specifies the type of a texture element. More... | |
using | MemberVector = std::vector< Member > |
using | ElementVector = std::vector< Element > |
using | TextureElementVector = std::vector< TextureElement > |
Public Member Functions | |
HioGlslfxResourceLayout () | |
~HioGlslfxResourceLayout () | |
Static Public Member Functions | |
static HIO_API void | ParseLayout (ElementVector *result, TfToken const &shaderStage, VtDictionary const &layoutDict) |
The resource layout for stages in a shader pipeline.
The main geometric shader pipelines for meshes, curves, points, volumes, as well as compute shaders for subdivision refinement, etc. are expressed as GLSL source code and aspects of the main shader pipeline that are generated at runtime also are expressed as GLSL source code.
This class provides an intermediate representation for shader resources that are needed to provide access to external data like buffers and textures and also interstage data like input and output variables and input and output interface blocks.
A method is provided to parse resource data from HioGlslfx resource layout dictionaries so that resource layout definitions can continue to be authored alongside related GLSL shader source.
The dictionary layouts have been designed to match the concepts and syntax used by GLSL.
Definition at line 80 of file glslfxResourceLayout.h.
using HioGlslfxResourceLayout::ElementVector = std::vector<Element> |
Definition at line 148 of file glslfxResourceLayout.h.
using HioGlslfxResourceLayout::MemberVector = std::vector<Member> |
Definition at line 118 of file glslfxResourceLayout.h.
using HioGlslfxResourceLayout::TextureElementVector = std::vector<TextureElement> |
Definition at line 179 of file glslfxResourceLayout.h.
|
strong |
Specifies whether a resource element is a shader input, a shader output (i.e. an input or output variable or input or output interface block), or neither (i.e. a buffer or texture).
Enumerator | |
---|---|
NONE | |
STAGE_IN | |
STAGE_OUT |
Definition at line 86 of file glslfxResourceLayout.h.
|
strong |
Specifies the kind of resource element.
Enumerator | |
---|---|
NONE | |
VALUE | |
BLOCK | |
QUALIFIER | |
UNIFORM_VALUE | |
UNIFORM_BLOCK | |
UNIFORM_BLOCK_CONSTANT_PARAMS | |
BUFFER_READ_ONLY | |
BUFFER_READ_WRITE |
Definition at line 93 of file glslfxResourceLayout.h.
|
strong |
Specifies the type of a texture element.
Enumerator | |
---|---|
TEXTURE | |
SHADOW_TEXTURE | |
ARRAY_TEXTURE |
Definition at line 151 of file glslfxResourceLayout.h.
HioGlslfxResourceLayout::HioGlslfxResourceLayout | ( | ) |
HioGlslfxResourceLayout::~HioGlslfxResourceLayout | ( | ) |
|
static |
Parses GLSLFX resource layout elements from the specified layoutDict and appends the parsed elements to result.