Struct RenderOutputDescription
Describes the output formats of the Render Targets and the Depth-Stencil Buffer.
[DataContract]
public struct RenderOutputDescription : IEquatable<RenderOutputDescription>
- Implements
- Inherited Members
- Extension Methods
Constructors
RenderOutputDescription(PixelFormat, PixelFormat, MultisampleCount)
Initializes a new instance of the RenderOutputDescription structure.
public RenderOutputDescription(PixelFormat renderTargetFormat, PixelFormat depthStencilFormat = PixelFormat.None, MultisampleCount multisampleCount = MultisampleCount.None)
Parameters
renderTargetFormatPixelFormatThe pixel format of the Render Target. Specify None to disable the Render Targets.
depthStencilFormatPixelFormatThe depth format of the Depth-Stencil Buffer. Specify None to disable the Depth-Stencil Buffer.
multisampleCountMultisampleCountThe number of samples to use when multi-sampling. Specify None to disable multi-sampling.
RenderOutputDescription(ReadOnlySpan<PixelFormat>, PixelFormat, MultisampleCount)
Initializes a new instance of the RenderOutputDescription structure.
public RenderOutputDescription(ReadOnlySpan<PixelFormat> renderTargetFormats, PixelFormat depthStencilFormat = PixelFormat.None, MultisampleCount multisampleCount = MultisampleCount.None)
Parameters
renderTargetFormatsReadOnlySpan<PixelFormat>The pixel formats for up to 8 Render Targets. If a Render Target is set to None, it is considered disabled. Specify an empty span or all set to None to disable the Render Targets.
depthStencilFormatPixelFormatThe depth format of the Depth-Stencil Buffer. Specify None to disable the Depth-Stencil Buffer.
multisampleCountMultisampleCountThe number of samples to use when multi-sampling. Specify None to disable multi-sampling.
Exceptions
- ArgumentOutOfRangeException
Cannot specify the format for more than 8 Render Targets in
renderTargetFormats.
Fields
DefaultDepthStencilFormat
Default value for DepthStencilFormat.
public const PixelFormat DefaultDepthStencilFormat = None
Field Value
DefaultMultiSampleCount
Default value for MultisampleCount.
public const MultisampleCount DefaultMultiSampleCount = None
Field Value
DefaultRenderTargetCount
Default value for RenderTargetCount.
public const int DefaultRenderTargetCount = 0
Field Value
DefaultRenderTargetFormat
Default value for the Render Targets pixel formats (RenderTargetFormat0 to RenderTargetFormat7).
public const PixelFormat DefaultRenderTargetFormat = None
Field Value
DefaultScissorTestEnable
Default value for ScissorTestEnable.
public const bool DefaultScissorTestEnable = false
Field Value
DepthStencilFormat
The depth format of the Depth-Stencil Buffer.
public PixelFormat DepthStencilFormat
Field Value
Remarks
Specify None to disable the Depth-Stencil Buffer.
MaximumRenderTargetCount
The maximum number of Render Targets configurable by the graphics pipeline.
public const int MaximumRenderTargetCount = 8
Field Value
MultisampleCount
The number of samples to use when multi-sampling.
public MultisampleCount MultisampleCount
Field Value
Remarks
Specify None to disable multi-sampling.
RenderTargetCount
The number of Render Targets.
public int RenderTargetCount
Field Value
RenderTargetFormat0
The pixel format of the Render Target at index 0.
public PixelFormat RenderTargetFormat0
Field Value
RenderTargetFormat1
The pixel format of the Render Target at index 1.
public PixelFormat RenderTargetFormat1
Field Value
RenderTargetFormat2
The pixel format of the Render Target at index 2.
public PixelFormat RenderTargetFormat2
Field Value
RenderTargetFormat3
The pixel format of the Render Target at index 3.
public PixelFormat RenderTargetFormat3
Field Value
RenderTargetFormat4
The pixel format of the Render Target at index 4.
public PixelFormat RenderTargetFormat4
Field Value
RenderTargetFormat5
The pixel format of the Render Target at index 5.
public PixelFormat RenderTargetFormat5
Field Value
RenderTargetFormat6
The pixel format of the Render Target at index 6.
public PixelFormat RenderTargetFormat6
Field Value
RenderTargetFormat7
The pixel format of the Render Target at index 7.
public PixelFormat RenderTargetFormat7
Field Value
ScissorTestEnable
A value indicating whether to enable scissor-rectangle culling. All pixels ouside an active scissor rectangle are culled.
public bool ScissorTestEnable
Field Value
Properties
RenderTargetFormats
Gets the pixel formats of the Render Targets.
public readonly Span<PixelFormat> RenderTargetFormats { get; }
Property Value
Remarks
There is a maximum of eight Render Targets. If a Render Target is set to None, it is considered disabled.
Methods
CaptureState(CommandList)
Captures the description of the pipeline render output from a Command List.
public void CaptureState(CommandList commandList)
Parameters
commandListCommandListThe Command List from which to capture the pipeline render output configuration.
Equals(RenderOutputDescription)
Indicates whether the current object is equal to another object of the same type.
public readonly bool Equals(RenderOutputDescription other)
Parameters
otherRenderOutputDescriptionAn object to compare with this object.
Returns
Equals(object)
Indicates whether this instance and a specified object are equal.
public override readonly bool Equals(object obj)
Parameters
objobjectThe object to compare with the current instance.
Returns
- bool
true if
objand this instance are the same type and represent the same value; otherwise, false.
GetHashCode()
Returns the hash code for this instance.
public override readonly int GetHashCode()
Returns
- int
A 32-bit signed integer that is the hash code for this instance.
Operators
operator ==(RenderOutputDescription, RenderOutputDescription)
public static bool operator ==(RenderOutputDescription left, RenderOutputDescription right)
Parameters
leftRenderOutputDescriptionrightRenderOutputDescription
Returns
operator !=(RenderOutputDescription, RenderOutputDescription)
public static bool operator !=(RenderOutputDescription left, RenderOutputDescription right)
Parameters
leftRenderOutputDescriptionrightRenderOutputDescription