diff options
Diffstat (limited to 'src/engine')
| -rw-r--r-- | src/engine/client/gfx.c | 14 | ||||
| -rw-r--r-- | src/engine/config_variables.h | 2 |
2 files changed, 15 insertions, 1 deletions
diff --git a/src/engine/client/gfx.c b/src/engine/client/gfx.c index f30e5099..c0c0d12a 100644 --- a/src/engine/client/gfx.c +++ b/src/engine/client/gfx.c @@ -134,10 +134,22 @@ int gfx_init() screen_width = 320; screen_height = 240; } + + /* set antialiasing */ + if(config.gfx_fsaa_samples) + glfwOpenWindowHint(GLFW_FSAA_SAMPLES, config.gfx_fsaa_samples); + + /* set refresh rate */ + if(config.gfx_refresh_rate) + glfwOpenWindowHint(GLFW_REFRESH_RATE, config.gfx_refresh_rate); + /* no resizing allowed */ + glfwOpenWindowHint(GLFW_WINDOW_NO_RESIZE, 1); + + /* open window */ if(config.gfx_fullscreen) { - int result = glfwOpenWindow(screen_width, screen_height, 8, 8, 8, 0, 0, 0, GLFW_FULLSCREEN); + int result = glfwOpenWindow(screen_width, screen_height, 8, 8, 8, 0, 24, 0, GLFW_FULLSCREEN); if(result != GL_TRUE) { dbg_msg("game", "failed to create gl context"); diff --git a/src/engine/config_variables.h b/src/engine/config_variables.h index 8fbab733..492d35fb 100644 --- a/src/engine/config_variables.h +++ b/src/engine/config_variables.h @@ -29,6 +29,8 @@ MACRO_CONFIG_INT(gfx_display_all_modes, 0, 0, 1) MACRO_CONFIG_INT(gfx_texture_compression, 0, 0, 1) MACRO_CONFIG_INT(gfx_high_detail, 1, 0, 1) MACRO_CONFIG_INT(gfx_texture_quality, 1, 0, 1) +MACRO_CONFIG_INT(gfx_fsaa_samples, 0, 0, 16) +MACRO_CONFIG_INT(gfx_refresh_rate, 0, 0, 0) MACRO_CONFIG_INT(key_screenshot, 267, 32, 512) |