CallShader function

Invokes another shader from within a shader.

Syntax

This intrinsic function definition is equivalent to the following function template:

template<param_t>
void CallShader(uint ShaderIndex, inout param_t Parameter);

Parameters

ShaderIndex

An unsigned integer representing the index into the callable shader table specified in the call to DispatchRays.

Parameter

The user-defined parameters to pass to the callable shader. This parameter structure must match the parameter structure used in the callable shader pointed to in the shader table.

Return Value

void

Remarks

This function can be called from the following raytracing shader types:

See also