From f010791231c95eed49c63ce3f2e6809b8c932f27 Mon Sep 17 00:00:00 2001 From: oy Date: Sun, 24 Feb 2013 19:43:09 +0100 Subject: [PATCH] added options for the threaded stuff in the menu and set version --- src/game/client/components/menus_settings.cpp | 27 +++++++++++++++++-- src/game/version.h | 4 +-- 2 files changed, 27 insertions(+), 4 deletions(-) diff --git a/src/game/client/components/menus_settings.cpp b/src/game/client/components/menus_settings.cpp index 467ef5001..b2434d910 100644 --- a/src/game/client/components/menus_settings.cpp +++ b/src/game/client/components/menus_settings.cpp @@ -619,6 +619,7 @@ void CMenus::RenderSettingsGraphics(CUIRect MainView) static int s_GfxFsaaSamples = g_Config.m_GfxFsaaSamples; static int s_GfxTextureQuality = g_Config.m_GfxTextureQuality; static int s_GfxTextureCompression = g_Config.m_GfxTextureCompression; + static int s_GfxThreaded = g_Config.m_GfxThreaded; CUIRect ModeList; MainView.VSplitLeft(300.0f, &MainView, &ModeList); @@ -699,8 +700,25 @@ void CMenus::RenderSettingsGraphics(CUIRect MainView) g_Config.m_GfxFsaaSamples = (g_Config.m_GfxFsaaSamples+1)%17; CheckSettings = true; } + + MainView.HSplitTop(20.0f, &Button, &MainView); + if(DoButton_CheckBox(&g_Config.m_GfxThreaded, Localize("Threaded rendering"), g_Config.m_GfxThreaded, &Button)) + { + g_Config.m_GfxThreaded ^= 1; + CheckSettings = true; + } - MainView.HSplitTop(40.0f, &Button, &MainView); + MainView.HSplitTop(20.0f, &Button, &MainView); + if(g_Config.m_GfxThreaded) + { + Button.VSplitLeft(20.0f, 0, &Button); + if(DoButton_CheckBox(&g_Config.m_GfxAsyncRender, Localize("Handle rendering async from updates"), g_Config.m_GfxAsyncRender, &Button)) + { + g_Config.m_GfxAsyncRender ^= 1; + CheckSettings = true; + } + } + MainView.HSplitTop(20.0f, &Button, &MainView); if(DoButton_CheckBox(&g_Config.m_GfxTextureQuality, Localize("Quality Textures"), g_Config.m_GfxTextureQuality, &Button)) { @@ -730,7 +748,8 @@ void CMenus::RenderSettingsGraphics(CUIRect MainView) s_GfxVsync == g_Config.m_GfxVsync && s_GfxFsaaSamples == g_Config.m_GfxFsaaSamples && s_GfxTextureQuality == g_Config.m_GfxTextureQuality && - s_GfxTextureCompression == g_Config.m_GfxTextureCompression) + s_GfxTextureCompression == g_Config.m_GfxTextureCompression && + s_GfxThreaded == g_Config.m_GfxThreaded) m_NeedRestartGraphics = false; else m_NeedRestartGraphics = true; @@ -807,6 +826,10 @@ void CMenus::RenderSettingsSound(CUIRect MainView) if(DoButton_CheckBox(&g_Config.m_SndNonactiveMute, Localize("Mute when not active"), g_Config.m_SndNonactiveMute, &Button)) g_Config.m_SndNonactiveMute ^= 1; + MainView.HSplitTop(20.0f, &Button, &MainView); + if(DoButton_CheckBox(&g_Config.m_ClThreadsoundloading, Localize("Threaded sound loading"), g_Config.m_ClThreadsoundloading, &Button)) + g_Config.m_ClThreadsoundloading ^= 1; + // sample rate box { char aBuf[64]; diff --git a/src/game/version.h b/src/game/version.h index 3d909e368..ee41dbe82 100644 --- a/src/game/version.h +++ b/src/game/version.h @@ -3,7 +3,7 @@ #ifndef GAME_VERSION_H #define GAME_VERSION_H #include "generated/nethash.cpp" -#define GAME_VERSION "0.6 trunk" +#define GAME_VERSION "0.6.2" #define GAME_NETVERSION "0.6 " GAME_NETVERSION_HASH -static const char GAME_RELEASE_VERSION[8] = {'0', '.', '6', '1', 0}; +static const char GAME_RELEASE_VERSION[8] = {'0', '.', '6', '2', 0}; #endif