Table of Contents

Interface IGpuRenderTarget

Namespace
Xui.GPU.Hardware
Assembly
Xui.Core.dll

Represents a GPU render target backed by a texture. Rendered output can be read back to CPU for display.

public interface IGpuRenderTarget : IDisposable
Inherited Members

Properties

Height

Gets the height of the render target in pixels.

int Height { get; }

Property Value

int

Texture

Gets the underlying texture.

IGpuTexture Texture { get; }

Property Value

IGpuTexture

Width

Gets the width of the render target in pixels.

int Width { get; }

Property Value

int

Methods

ReadbackPixelsBgra(byte[])

Reads back the rendered pixels to a CPU byte array. The pixel format is BGRA (Blue, Green, Red, Alpha), 4 bytes per pixel.

void ReadbackPixelsBgra(byte[] destination)

Parameters

destination byte[]

A byte array of size Width * Height * 4 to receive the pixels.