API Reference: D3D12 Pipeline State¶
This is the API reference for the functions, classes, and enums in the renderdoc module which represents the underlying interface that the UI is built on top of. For more high-level information and instructions on using the python API, see Python API.
- class renderdoc.D3D12State¶
The full current D3D12 pipeline state.
- ampShader¶
The amplification shader stage.
- Type
- computeShader¶
The compute shader stage.
- Type
- descriptorHeaps¶
The descriptor heaps currently bound.
- Type
List[ResourceId]
- domainShader¶
The domain shader stage.
- Type
- geometryShader¶
The geometry shader stage.
- Type
- hullShader¶
The hull shader stage.
- Type
- inputAssembly¶
The input assembly pipeline stage.
- Type
- meshShader¶
The mesh shader stage.
- Type
- pipelineResourceId¶
The
ResourceIdof the pipeline state object.- Type
- pixelShader¶
The pixel shader stage.
- Type
- rasterizer¶
The rasterizer pipeline stage.
- Type
- resourceStates¶
The resource states for the currently live resources.
- Type
List[D3D12ResourceData]
- rootSignature¶
Details of the root signature structure and root parameters.
- Type
- streamOut¶
The stream-out pipeline stage.
- Type
- vertexShader¶
The vertex shader stage.
- Type
Vertex Input¶
- class renderdoc.D3D12InputAssembly¶
Describes the input assembler state in the PSO.
- indexBuffer¶
The bound index buffer.
- Type
- indexStripCutValue¶
The index value to use for cutting strips. Either
0,0xffffor0xffffffff. If the value is 0, strip cutting is disabled.- Type
int
- layouts¶
The input layout elements in this layout.
- Type
List[D3D12Layout]
- vertexBuffers¶
The bound vertex buffers
- Type
List[D3D12VertexBuffer]
- class renderdoc.D3D12Layout¶
Describes a single D3D12 input layout element for one vertex input.
- TightlyPacked¶
Value for
byteOffsetthat indicates this element is tightly packed.
- byteOffset¶
The byte offset from the start of the vertex data in the vertex buffer from
inputSlot.If the value is
TightlyPackedthen the element is packed tightly after the previous element, or 0 if this is the first element.- Type
int
- format¶
The format describing how the input data is interpreted.
- Type
- inputSlot¶
The vertex buffer input slot where the data is sourced from.
- Type
int
- instanceDataStepRate¶
If
perInstanceisTruethen this is how many times each instance data is used before advancing to the next instance.E.g. if this value is two, then two instances will be drawn with the first instance data, then two with the next instance data.
- Type
int
- perInstance¶
Trueif the vertex data is instance-rate.- Type
bool
- semanticIndex¶
The semantic index for this input.
- Type
int
- semanticName¶
The semantic name for this input.
- Type
str
- class renderdoc.D3D12VertexBuffer¶
Describes a single D3D12 vertex buffer binding.
- byteOffset¶
The byte offset from the start of the buffer to the beginning of the vertex data.
- Type
int
- byteSize¶
The number of bytes available in this vertex buffer.
- Type
int
- byteStride¶
The byte stride between the start of one set of vertex data and the next.
- Type
int
- resourceId¶
The
ResourceIdof the buffer bound to this slot.- Type
- class renderdoc.D3D12IndexBuffer¶
Describes the D3D12 index buffer binding.
- byteOffset¶
The byte offset from the start of the buffer to the beginning of the index data.
- Type
int
- byteSize¶
The number of bytes available in this index buffer.
- Type
int
- byteStride¶
The number of bytes for each index in the index buffer. Typically 2 or 4 bytes but it can be 0 if no index buffer is bound.
- Type
int
- resourceId¶
The
ResourceIdof the index buffer.- Type
Shader¶
- class renderdoc.D3D12Shader¶
Describes a D3D12 shader stage.
- reflection¶
The reflection data for this shader.
- Type
- resourceId¶
The
ResourceIdof the shader object itself.- Type
- stage¶
A
ShaderStageidentifying which stage this shader is bound to.- Type
Root Signature¶
- class renderdoc.D3D12RootSignature¶
Contains the root signature structure and root parameters.
- parameters¶
The parameters in this root signature.
- Type
List[D3D12RootParam]
- resourceId¶
The
ResourceIdof the root signature object.- Type
- staticSamplers¶
The static samplers defined in this root signature.
- Type
List[D3D12StaticSampler]
- class renderdoc.D3D12RootParam¶
Contains the structure and content of a single root parameter.
- constants¶
For a root constant parameter, the words defined.
- Type
bytes
- descriptor¶
For a root descriptor parameter, the descriptor itself.
- Type
- heap¶
For a root table parameter, the descriptor heap bound to this parameter. See
heapByteOffsetandtableRanges.- Type
- heapByteOffset¶
For a root table parameter, the byte offset into the descriptor heap bound to this parameter. See
heapandtableRanges.- Type
int
- reg¶
For a root parameter, the register of the binding.
- Type
int
- space¶
For a root parameter, the register space of the binding.
- Type
int
- tableRanges¶
For a root table parameter, the descriptor ranges that define this table. See
heapandheapByteOffset.- Type
List[D3D12RootTableRange]
- visibility¶
The shader stage that can access this parameter.
- Type
- class renderdoc.D3D12RootTableRange¶
Contains the structure of a single range within a root table definition.
- appended¶
Whether or not this table was appended after the previous, leading to an auto-calculated offset in
tableByteOffset.- Type
bool
- baseRegister¶
The first register in this range.
- Type
int
- category¶
The descriptor category specified in this range.
- Type
- count¶
The number of registers in this range.
- Type
int
- space¶
The register space of this range.
- Type
int
- tableByteOffset¶
The offset in bytes from the start of the table as defined in
D3D12RootParam.- Type
int
- class renderdoc.D3D12StaticSampler¶
Contains the details of a single static sampler in a root signature.
- descriptor¶
The details of the sampler descriptor itself.
- Type
- reg¶
The register number of this sampler.
- Type
int
- space¶
The register space of this sampler.
- Type
int
- visibility¶
The shader stage that can access this sampler.
- Type
Stream-out¶
- class renderdoc.D3D12StreamOut¶
Describes the stream-out state in the PSO.
- NoRasterization¶
Value for
rasterizedStreamthat indicates no stream is being rasterized.
- outputs¶
The bound stream-out buffer bindings.
- Type
List[D3D12StreamOutBind]
- rasterizedStream¶
Which stream-out stream is being used for rasterization.
If the value is
NoRasterizationthen no stream has been selected for rasterization.- Type
int
- class renderdoc.D3D12StreamOutBind¶
Describes a binding on the D3D12 stream-out stage.
- byteOffset¶
The byte offset in
resourceIdwhere the buffer view starts in the underlying buffer.- Type
int
- byteSize¶
How many bytes are in this stream-out buffer view.
- Type
int
- resourceId¶
The
ResourceIdof the buffer.- Type
- writtenCountByteOffset¶
The byte offset in
writtenCountResourceIdwhere the stream-out count will be written.- Type
int
- writtenCountResourceId¶
The
ResourceIdof the buffer where the written count will be stored.- Type
Rasterizer¶
- class renderdoc.D3D12Rasterizer¶
Describes the rasterization state of the D3D12 pipeline.
- sampleMask¶
The mask determining which samples are written to.
- Type
int
- state¶
The details of the rasterization state.
- Type
- class renderdoc.D3D12RasterizerState¶
Describes the rasterizer state in the PSO.
- baseShadingRate¶
The current base variable shading rate. This will always be 1x1 when variable shading is disabled.
- Type
Tuple[int,int]
- conservativeRasterization¶
The current
ConservativeRastermode.- Type
- depthBias¶
The fixed depth bias value to apply to z-values.
- Type
float
- depthBiasClamp¶
The clamp value for calculated depth bias from
depthBiasandslopeScaledDepthBias- Type
float
- depthClip¶
Trueif pixels outside of the near and far depth planes should be clipped.- Type
bool
- forcedSampleCount¶
A sample count to force rasterization to when UAV rendering or rasterizing, or 0 to not force any sample count.
- Type
int
- frontCCW¶
Trueif counter-clockwise polygons are front-facing.Falseif clockwise polygons are front-facing.- Type
bool
- lineRasterMode¶
The line rasterization mode.
- Type
- shadingRateCombiners¶
The shading rate combiners.
The combiners are applied as follows, according to the D3D spec:
intermediateRate = combiner[0] ( baseShadingRate, shaderExportedShadingRate )finalRate = combiner[1] ( intermediateRate, imageBasedShadingRate )Where the first input is from
baseShadingRateand the second is the exported shading rate from a vertex or geometry shader, which defaults to 1x1 if not exported.The intermediate result is then used as the first input to the second combiner, together with the shading rate sampled from the shading rate image.
- Type
- shadingRateImage¶
The image bound as a shading rate image.
- Type
- slopeScaledDepthBias¶
The slope-scaled depth bias value to apply to z-values.
- Type
float
Output Merger¶
- class renderdoc.D3D12OM¶
Describes the current state of the output-merger stage of the D3D12 pipeline.
- blendState¶
The current blend state details.
- Type
- depthReadOnly¶
Trueif depth access to the depth-stencil target is read-only.- Type
bool
- depthStencilState¶
The current depth-stencil state details.
- depthTarget¶
The currently bound depth-stencil target.
- Type
- multiSampleCount¶
The sample count used for rendering.
- Type
int
- multiSampleQuality¶
The MSAA quality level used for rendering.
- Type
int
- renderTargets¶
The bound render targets.
- Type
List[Descriptor]
- stencilReadOnly¶
Trueif stenncil access to the depth-stencil target is read-only.- Type
bool
- class renderdoc.D3D12DepthStencilState¶
Describes the state of the depth-stencil state in the PSO.
- backFace¶
The stencil state for back-facing polygons.
- Type
- depthBoundsEnable¶
Trueif depth bounds tests should be applied.- Type
bool
- depthEnable¶
Trueif depth testing should be performed.- Type
bool
- depthFunction¶
The
CompareFunctionto use for testing depth values.- Type
- depthWrites¶
Trueif depth values should be written to the depth target.- Type
bool
- frontFace¶
The stencil state for front-facing polygons.
- Type
- maxDepthBounds¶
The far plane bounding value.
- Type
float
- minDepthBounds¶
The near plane bounding value.
- Type
float
- stencilEnable¶
Trueif stencil operations should be performed.- Type
bool
- class renderdoc.D3D12BlendState¶
Describes the blend state in the PSO.
- alphaToCoverage¶
Trueif alpha-to-coverage should be used when blending to an MSAA target.- Type
bool
- blendFactor¶
The constant blend factor to use in blend equations.
- Type
Tuple[float,float,float,float]
- blends¶
The blend operations for each target.
- Type
List[ColorBlend]
- independentBlend¶
Trueif independent blending for each target should be used.Falseif the first blend should be applied to all targets.- Type
bool
Resource States¶
- class renderdoc.D3D12ResourceData¶
Contains the current state of a given resource.
- resourceId¶
The
ResourceIdof the resource.- Type
- states¶
The subresource states in this resource.
- Type
List[D3D12ResourceState]