Various utility functions related to engines.
Functions | |
void | initCommonGFX (bool is3D) |
void | initGraphicsModes (const Graphics::ModeList &modes) |
void | initGraphics (int width, int height) |
void | initGraphics (int width, int height, const Graphics::PixelFormat *format) |
void | initGraphics (int width, int height, const Common::List< Graphics::PixelFormat > &formatList) |
void | initGraphics3d (int width, int height) |
int | initGraphicsAny (const Graphics::ModeWithFormatList &modes, int start=0) |
void initCommonGFX | ( | bool | is3D | ) |
Set up the graphics mode of the backend.
is3D | set to true if the game to be launched uses 3D graphics |
void initGraphicsModes | ( | const Graphics::ModeList & | modes | ) |
Send a list of graphics modes to the backend so it can make a decision about the best way to set up the display hardware.
Engines that switch between different virtual screen sizes during the game should call this function prior to any call to initGraphics. Engines that use only a single screen size do not need to call this function.
void initGraphics | ( | int | width, |
int | height | ||
) |
Set up the screen size and graphics mode of the backend.
Shows various warnings on certain backend graphics transaction failures (aspect switch, fullscreen switch, etc.).
An error dialog will be generated when the backend is not able to switch to the specified mode.
Defaults to CLUT8 (256 color palette) if only width and height provided. If graphics format is explicitly set to nullptr, uses the preferred format of the backend. Finds the best compatible format if a list of graphics formats is provided.
void initGraphics | ( | int | width, |
int | height, | ||
const Graphics::PixelFormat * | format | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void initGraphics | ( | int | width, |
int | height, | ||
const Common::List< Graphics::PixelFormat > & | formatList | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void initGraphics3d | ( | int | width, |
int | height | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
int initGraphicsAny | ( | const Graphics::ModeWithFormatList & | modes, |
int | start = 0 |
||
) |
Inits any of the modes in "modes". "modes" is in the order of preference. Return value is index in modes of resulting mode.