Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Compiles a PIX pipeline state stream description to produce static profiling data.
Syntax
HRESULT CompilePipelineState(
IPixShaderProfilingAdapter * adapter,
PIX_SHADER_COMPILER_ABI_VERSION adapterAbiVersion,
const PIX_PIPELINE_STATE_STREAM_DESC * pipelineStateDesc,
UINT32 sourceShaderCount,
const PIX_SHADER_PROFILING_SOURCE_SHADER * sourceShaders,
const PIX_APPLICATION_DESC * applicationDesc,
IPixProgressNotifications * notifications,
IPixCancellationToken * cancellationToken,
REFIID riid,
void ** compilation);
Parameters
adapter [in]
The adapter to target
adapterAbiVersion [in]
The backend compiler ABI version to target, or PIX_SHADER_COMPILER_ABI_VERSION::LATEST to target the latest ABI version available for the adapter family.
pipelineStateDesc [in]
The PIX pipeline state stream description
sourceShaderCount [in]
The number of source shaders to compile, or zero to use the shader bytecode in the pipeline state
sourceShaders [in]
The source shaders to compile, or nullptr when sourceShaderCount is zero
applicationDesc [in]
Application description, which is provided to the backend compiler (optional)
notifications [in]
Notification callback for progress updates (optional)
cancellationToken [in]
Cancellation token to cancel the compilation (optional)
riid [in]
The interface IID of the document to be returned. Expected: IPixShaderProfilingCompilation.
compilation [out]
The pointer to the returned interface
Returns
S_OK if the compilation was successful, otherwise an error code
E_PIX_SHADER_COMPILER_ABI_UNSUPPORTED if the adapter's offline compiler does not support the explicitly requested ABI version.
Remarks
When source shaders are provided, each compiled shader replaces the shader bytecode subobject for its stage. If the pipeline state supplies a root signature it replaces any root signature provided in the HLSL. An embedded root signature is used only when the pipeline state does not supply one. When no source shaders are provided, the pipeline state must contain IL shader bytecode and frontend compilation is bypassed, so the returned result does not have frontend compiler details. The cached pipeline state subobject is ignored if provided.