22 #ifndef AGS_ENGINE_MAIN_GRAPHICS_MODE_H 23 #define AGS_ENGINE_MAIN_GRAPHICS_MODE_H 25 #include "ags/engine/gfx/gfx_defines.h" 26 #include "ags/shared/util/geometry.h" 27 #include "ags/shared/util/scaling.h" 28 #include "ags/shared/util/string.h" 32 using AGS::Shared::String;
33 using AGS::Engine::GraphicResolution;
34 using AGS::Engine::DisplayMode;
35 using AGS::Engine::WindowMode;
37 Size get_desktop_size();
45 bool find_nearest_supported_mode(
const AGS::Engine::IGfxModeList &modes,
const Size &wanted_size,
46 const int color_depth,
const Size *ratio_reference,
const Size *upper_bound,
47 AGS::Engine::DisplayMode &dm,
int *mode_index =
nullptr);
57 kFrame_Undefined = -1,
69 WindowMode Mode = AGS::Engine::kWnd_Windowed;
73 : Size(sz), Scale(0), Mode(mode) {}
75 : Scale(scale), Mode(mode) {}
76 WindowSetup(WindowMode mode) : Scale(0), Mode(mode) {}
95 FrameScaleDef FsGameFrame =
97 FrameScaleDef WinGameFrame =
100 bool Windowed =
false;
113 ColorDepthOption(
int bits,
bool forced =
false) : Bits(bits), Forced(forced) {
121 FrameScaleDef Frame = kFrame_Undefined;
130 bool graphics_mode_create_renderer(
const String &driver_id);
132 bool graphics_mode_set_dm_any(
const Size &game_size,
const WindowSetup &ws,
140 FrameScaleDef graphics_mode_get_render_frame();
142 bool graphics_mode_set_render_frame(
const FrameScaleDef &frame_setup);
146 bool graphics_mode_set_filter(
const String &filter_id);
148 void graphics_mode_on_window_changed(
const Size &sz);
150 void graphics_mode_shutdown();
Definition: achievements_tables.h:27
Definition: graphics_mode.h:87
Definition: graphics_mode.h:50
Definition: graphics_mode.h:119
Definition: graphics_mode.h:80
Definition: gfx_defines.h:60
Graphics::Surface * scale(const Graphics::Surface &srcImage, int xSize, int ySize)
Definition: graphics_mode.h:65
Definition: graphics_mode.h:107
Definition: geometry.h:144
Definition: gfx_defines.h:33