LiteFX::Rendering::ShaderRecordCollection::withShaderRecord¶
withShaderRecord overloads
Synopses¶
Declared in <litefx/rendering_api.hpp>
Adds a new shader record based on the name of a shader module in the parent shader program.
[[dllimport, dllexport]] ShaderRecordCollection&& withShaderRecord(StringView shaderName);
Adds a new shader record to the shader record collection.
[[dllimport, dllexport]] ShaderRecordCollection&& withShaderRecord(ShaderRecord<>::shader_group_type shaderGroup);
Adds a new shader record based on the name of a shader module in the parent shader program.
template<typename TLocalData>
requires (std::alignment_of_v<TLocalData> == SHADER_RECORD_LOCAL_DATA_ALIGNMENT)
ShaderRecordCollection&& withShaderRecord(
StringView shaderName,
TLocalData payload);
Adds a new shader record to the shader record collection.
template<typename TLocalData>
requires (std::alignment_of_v<TLocalData> == SHADER_RECORD_LOCAL_DATA_ALIGNMENT)
ShaderRecordCollection&& withShaderRecord(
ShaderRecord<TLocalData>::shader_group_type shaderGroup,
TLocalData payload);
Return Value¶
A reference to the current shader record collection.
Template Parameters¶
| Name | Description |
|---|---|
| TLocalData | The type of the shader record local data. |
Parameters¶
| Name | Description |
|---|---|
| shaderName | The name of the shader module. |
| shaderGroup | The shader module or hit group. |
| payload | The shader-local data of the shader record. |