HgiShaderFunctionParamDesc Struct Reference

Describes a param passed into a shader or between shader stages. More...

Public Attributes

std::string nameInShader
 
std::string type
 
int32_t location
 
int32_t interstageSlot
 
HgiInterpolationType interpolation
 
HgiSamplingType sampling
 
HgiStorageType storage
 
std::string role
 
std::string arraySize
 

Detailed Description

Describes a param passed into a shader or between shader stages.

  • nameInShader: The name written from the codegen into the shader file for the param.
  • type: Type of the param within the shader file.
  • location: For OpenGL, optionally specify the layout location. For Metal, if no role is specified, this generates the role
  • interstageSlot: Optionally specify an index for interstage parameters.
  • interpolation: Optionally specify the interpolation: Default, Flat or NoPerspective.
  • sampling: Optionally specify the sampling: Default, Centroid or Sample.
  • storage: Optionally specify the storage type: Default, Patch.
  • role: Optionally a role can be specified, like position, uv, color.
  • arraySize: If specified, generates an array type parameter with given size.

Definition at line 163 of file shaderFunctionDesc.h.


The documentation for this struct was generated from the following file: