renderTarget
Creates a new render target with the specified dimensions and properties.
Usage example:
// create a RenderTarget at the active content scale
val rt = renderTarget(640, 480) {
// add a color attachment
colorBuffer()
// add a depth attachment
depthBuffer()
}Return
A configured RenderTarget instance.
Parameters
The width of the render target in pixels. Must be greater than 0 and less than or equal to the maximum allowed texture size.
The height of the render target in pixels. Must be greater than 0 and less than or equal to the maximum allowed texture size.
A scaling factor to apply to the render target's content. The default of null results in the content scale being set to the active render target's content scale.
Specifies the multisampling configuration for the render target. Defaults to BufferMultisample.Disabled.
The session to which the render target belongs. Defaults to the currently active session.
A builder block for additional configuration of the render target.
Throws
If the specified width or height is out of the supported range.