Changeset View
Changeset View
Standalone View
Standalone View
ps/trunk/source/ps/GameSetup/GameSetup.cpp
Show First 20 Lines • Show All 590 Lines • ▼ Show 20 Lines | static void InitRenderer() | ||||
TIMER(L"InitRenderer"); | TIMER(L"InitRenderer"); | ||||
// create renderer | // create renderer | ||||
new CRenderer; | new CRenderer; | ||||
// create terrain related stuff | // create terrain related stuff | ||||
new CTerrainTextureManager; | new CTerrainTextureManager; | ||||
g_RenderingOptions.ReadConfigAndSetupHooks(); | |||||
g_Renderer.Open(g_xres, g_yres); | g_Renderer.Open(g_xres, g_yres); | ||||
// Setup lighting environment. Since the Renderer accesses the | // Setup lighting environment. Since the Renderer accesses the | ||||
// lighting environment through a pointer, this has to be done before | // lighting environment through a pointer, this has to be done before | ||||
// the first Frame. | // the first Frame. | ||||
g_Renderer.SetLightEnv(&g_LightEnv); | g_Renderer.SetLightEnv(&g_LightEnv); | ||||
// I haven't seen the camera affecting GUI rendering and such, but the | // I haven't seen the camera affecting GUI rendering and such, but the | ||||
▲ Show 20 Lines • Show All 430 Lines • ▼ Show 20 Lines | if (!ogl_HaveExtension("GL_ARB_texture_env_crossbar")) | ||||
DEBUG_DISPLAY_ERROR( | DEBUG_DISPLAY_ERROR( | ||||
L"The GL_ARB_texture_env_crossbar extension doesn't appear to be available on your computer." | L"The GL_ARB_texture_env_crossbar extension doesn't appear to be available on your computer." | ||||
L" Shadows are not available and overall graphics quality might suffer." | L" Shadows are not available and overall graphics quality might suffer." | ||||
L" You are advised to try installing newer drivers and/or upgrade your graphics card."); | L" You are advised to try installing newer drivers and/or upgrade your graphics card."); | ||||
g_ConfigDB.SetValueBool(CFG_HWDETECT, "shadows", false); | g_ConfigDB.SetValueBool(CFG_HWDETECT, "shadows", false); | ||||
} | } | ||||
ogl_WarnIfError(); | ogl_WarnIfError(); | ||||
g_RenderingOptions.ReadConfigAndSetupHooks(); | |||||
InitRenderer(); | InitRenderer(); | ||||
InitInput(); | InitInput(); | ||||
ogl_WarnIfError(); | ogl_WarnIfError(); | ||||
// TODO: Is this the best place for this? | // TODO: Is this the best place for this? | ||||
if (VfsDirectoryExists(L"maps/")) | if (VfsDirectoryExists(L"maps/")) | ||||
▲ Show 20 Lines • Show All 584 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator