Struct TCOD_ViewportOptions

Struct Documentation

struct TCOD_ViewportOptions

Viewport options for the rendering context.

New in version 1.16.

Public Members

int tcod_version

Must be set to TCOD_COMPILEDVERSION.

bool keep_aspect

If true then the aspect ratio will be kept square when the console is scaled.

The view will be letter-boxed.

If false the console will be stretched to fill the screen.

Set this is true if your tileset is deigned for square pixels.

bool integer_scaling

If true then console scaling will be fixed to integer increments.

Has no effect if the console must be scaled down.

TCOD_ColorRGBA clear_color

The color to clear the screen with before rendering the console.

float align_x

Alignment of the console when it is letter-boxed: 0.0f renders the console in the upper-left corner, and 1.0f in the lower-right.

Values of 0.5f will center the console. Values outside of the range 0.0f to 1.0f are clamped.

float align_y