DarkBASIC Professional Help File

DX11 SET CAMERA VIEWPORT

Sets the viewport area of the specified camera.
The viewport is the area of its render target (or the backbuffer in the case of the main camera) to where a camera renders graphics.
You could for example use this to render different views to different areas of a render target, or the screen.

Syntax

    DX11 SET CAMERA VIEWPORT camera, x, y, width, height

Parameters

    camera

> Dword
> The camera to set the viewport of.

    x

> Dword
> The starting (top left) X coordinate of the viewport.

    y

> Dword
> The starting (top left) Y coordinate of the viewport.

    width

> Dword
> The width of the viewport, in pixels.

    height

> Dword
> The height of the viewport, in pixels.

Returns

This function does not return a value.

See also

CAMERA Functions Menu
DX11 Function Categories