GraphicsDevice.GetRenderTargets Method

Gets a render target surface.

Namespace: Microsoft.Xna.Framework.Graphics
Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll)

Syntax

public RenderTargetBinding[] GetRenderTargets ()

Return Value

An array of bound render targets.

Exceptions

Exception type Condition
ArgumentOutOfRangeException An invalid render target index was requested. On Xbox 360, there is only one render target available and renderTargetIndex must be zero.

Remarks

The GraphicsDevice can support multiple render targets.

See Also

Reference

GraphicsDevice Class
GraphicsDevice Members
Microsoft.Xna.Framework.Graphics Namespace

Platforms

Xbox 360, Windows 7, Windows Vista, Windows XP