mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-07 12:50:38 +08:00
Compare commits
9 Commits
continuous
...
continuous
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6f6ddbce28 | ||
|
|
4cb425d2bb | ||
|
|
bf5fd40d64 | ||
|
|
6bc613bdb4 | ||
|
|
a982562658 | ||
|
|
96a9172e36 | ||
|
|
34d7664342 | ||
|
|
b0a79df86f | ||
|
|
9e107e900c |
@@ -1124,7 +1124,10 @@ void CL_FinishTimeDemo( void )
|
|||||||
time = host.realtime - cls.td_starttime;
|
time = host.realtime - cls.td_starttime;
|
||||||
if( !time ) time = 1.0;
|
if( !time ) time = 1.0;
|
||||||
|
|
||||||
Con_Printf( "%i frames %5.3f seconds %5.3f fps\n", frames, time, frames / time );
|
Con_Printf( "timedemo result: %i frames %5.3f seconds %5.3f fps\n", frames, time, frames / time );
|
||||||
|
|
||||||
|
if( Sys_CheckParm( "-timedemo" ))
|
||||||
|
CL_Quit_f();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -1983,7 +1983,7 @@ void Con_DrawConsole( void )
|
|||||||
|
|
||||||
if( cls.state == ca_connecting || cls.state == ca_connected )
|
if( cls.state == ca_connecting || cls.state == ca_connected )
|
||||||
{
|
{
|
||||||
if( !cl_allow_levelshots.value )
|
if( !cl_allow_levelshots.value && !cls.timedemo )
|
||||||
{
|
{
|
||||||
if(( Cvar_VariableInteger( "cl_background" ) || Cvar_VariableInteger( "sv_background" )) && cls.key_dest != key_console )
|
if(( Cvar_VariableInteger( "cl_background" ) || Cvar_VariableInteger( "sv_background" )) && cls.key_dest != key_console )
|
||||||
con.vislines = con.showlines = 0;
|
con.vislines = con.showlines = 0;
|
||||||
@@ -1993,7 +1993,7 @@ void Con_DrawConsole( void )
|
|||||||
{
|
{
|
||||||
con.showlines = 0;
|
con.showlines = 0;
|
||||||
|
|
||||||
if( host_developer.value >= DEV_EXTENDED )
|
if( host_developer.value >= DEV_EXTENDED && !cls.timedemo )
|
||||||
Con_DrawNotify(); // draw notify lines
|
Con_DrawNotify(); // draw notify lines
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2025,7 +2025,7 @@ void Con_DrawConsole( void )
|
|||||||
{
|
{
|
||||||
if( con.vislines )
|
if( con.vislines )
|
||||||
Con_DrawSolidConsole( con.vislines );
|
Con_DrawSolidConsole( con.vislines );
|
||||||
else if( cls.state == ca_active && ( cls.key_dest == key_game || cls.key_dest == key_message ))
|
else if( cls.state == ca_active && ( cls.key_dest == key_game || cls.key_dest == key_message ) && !cls.timedemo )
|
||||||
Con_DrawNotify(); // draw notify lines
|
Con_DrawNotify(); // draw notify lines
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -127,6 +127,7 @@ void Sys_PrintUsage( void )
|
|||||||
O("-noenginejoy ", "disable engine builtin joystick support")
|
O("-noenginejoy ", "disable engine builtin joystick support")
|
||||||
O("-noenginemouse ", "disable engine builtin mouse support")
|
O("-noenginemouse ", "disable engine builtin mouse support")
|
||||||
O("-nosound ", "disable sound output")
|
O("-nosound ", "disable sound output")
|
||||||
|
O("-timedemo ", "run timedemo and exit")
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
"\nPlatform-specific options:\n"
|
"\nPlatform-specific options:\n"
|
||||||
@@ -1158,6 +1159,7 @@ Host_Main
|
|||||||
int EXPORT Host_Main( int argc, char **argv, const char *progname, int bChangeGame, pfnChangeGame func )
|
int EXPORT Host_Main( int argc, char **argv, const char *progname, int bChangeGame, pfnChangeGame func )
|
||||||
{
|
{
|
||||||
static double oldtime, newtime;
|
static double oldtime, newtime;
|
||||||
|
string demoname;
|
||||||
|
|
||||||
host.starttime = Sys_DoubleTime();
|
host.starttime = Sys_DoubleTime();
|
||||||
|
|
||||||
@@ -1254,6 +1256,9 @@ int EXPORT Host_Main( int argc, char **argv, const char *progname, int bChangeGa
|
|||||||
Cbuf_ExecStuffCmds(); // execute stuffcmds (commandline)
|
Cbuf_ExecStuffCmds(); // execute stuffcmds (commandline)
|
||||||
SCR_CheckStartupVids(); // must be last
|
SCR_CheckStartupVids(); // must be last
|
||||||
|
|
||||||
|
if( Sys_GetParmFromCmdLine( "-timedemo", demoname ))
|
||||||
|
Cbuf_AddTextf( "timedemo %s\n", demoname );
|
||||||
|
|
||||||
oldtime = Sys_DoubleTime() - 0.1;
|
oldtime = Sys_DoubleTime() - 0.1;
|
||||||
|
|
||||||
if( Host_IsDedicated( ))
|
if( Host_IsDedicated( ))
|
||||||
|
|||||||
@@ -444,6 +444,7 @@ static void NET_InitializeCriticalSections( void )
|
|||||||
void NET_ResolveThread( void )
|
void NET_ResolveThread( void )
|
||||||
{
|
{
|
||||||
struct sockaddr_storage addr;
|
struct sockaddr_storage addr;
|
||||||
|
qboolean res;
|
||||||
|
|
||||||
RESOLVE_DBG( "[resolve thread] starting resolve for " );
|
RESOLVE_DBG( "[resolve thread] starting resolve for " );
|
||||||
RESOLVE_DBG( nsthread.hostname );
|
RESOLVE_DBG( nsthread.hostname );
|
||||||
@@ -453,13 +454,14 @@ void NET_ResolveThread( void )
|
|||||||
RESOLVE_DBG( " with gethostbyname\n" );
|
RESOLVE_DBG( " with gethostbyname\n" );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if( NET_GetHostByName( nsthread.hostname, nsthread.family, &addr ))
|
if(( res = NET_GetHostByName( nsthread.hostname, nsthread.family, &addr )))
|
||||||
RESOLVE_DBG( "[resolve thread] success\n" );
|
RESOLVE_DBG( "[resolve thread] success\n" );
|
||||||
else
|
else
|
||||||
RESOLVE_DBG( "[resolve thread] failed\n" );
|
RESOLVE_DBG( "[resolve thread] failed\n" );
|
||||||
mutex_lock( &nsthread.mutexres );
|
mutex_lock( &nsthread.mutexres );
|
||||||
nsthread.addr = addr;
|
nsthread.addr = addr;
|
||||||
nsthread.busy = false;
|
nsthread.busy = false;
|
||||||
|
nsthread.result = res ? NET_EAI_OK : NET_EAI_NONAME;
|
||||||
RESOLVE_DBG( "[resolve thread] returning result\n" );
|
RESOLVE_DBG( "[resolve thread] returning result\n" );
|
||||||
mutex_unlock( &nsthread.mutexres );
|
mutex_unlock( &nsthread.mutexres );
|
||||||
RESOLVE_DBG( "[resolve thread] exiting thread\n" );
|
RESOLVE_DBG( "[resolve thread] exiting thread\n" );
|
||||||
@@ -544,6 +546,7 @@ static net_gai_state_t NET_StringToSockaddr( const char *s, struct sockaddr_stor
|
|||||||
memset( &nsthread.addr, 0, sizeof( nsthread.addr ));
|
memset( &nsthread.addr, 0, sizeof( nsthread.addr ));
|
||||||
|
|
||||||
detach_thread( nsthread.thread );
|
detach_thread( nsthread.thread );
|
||||||
|
asyncfailed = false;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -128,7 +128,7 @@ static qboolean SDLash_IsInstanceIDAGameController( SDL_JoystickID joyId )
|
|||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
#else
|
#else
|
||||||
if( SDL_GameControllerFromInstanceID( joyId ) )
|
if( SDL_GameControllerFromInstanceID( joyId ) != NULL )
|
||||||
return true;
|
return true;
|
||||||
return false;
|
return false;
|
||||||
#endif
|
#endif
|
||||||
@@ -148,7 +148,7 @@ static void SDLash_KeyEvent( SDL_KeyboardEvent key )
|
|||||||
#else
|
#else
|
||||||
int keynum = key.keysym.sym;
|
int keynum = key.keysym.sym;
|
||||||
#endif
|
#endif
|
||||||
qboolean numLock = SDL_GetModState() & KMOD_NUM;
|
qboolean numLock = FBitSet( SDL_GetModState(), KMOD_NUM );
|
||||||
|
|
||||||
#if XASH_ANDROID
|
#if XASH_ANDROID
|
||||||
if( keynum == SDL_SCANCODE_VOLUMEUP || keynum == SDL_SCANCODE_VOLUMEDOWN )
|
if( keynum == SDL_SCANCODE_VOLUMEUP || keynum == SDL_SCANCODE_VOLUMEDOWN )
|
||||||
@@ -159,7 +159,7 @@ static void SDLash_KeyEvent( SDL_KeyboardEvent key )
|
|||||||
|
|
||||||
if( SDL_IsTextInputActive() && down && cls.key_dest != key_game )
|
if( SDL_IsTextInputActive() && down && cls.key_dest != key_game )
|
||||||
{
|
{
|
||||||
if( SDL_GetModState() & KMOD_CTRL )
|
if( FBitSet( SDL_GetModState(), KMOD_CTRL ))
|
||||||
{
|
{
|
||||||
if( keynum >= SDL_SCANCODE_A && keynum <= SDL_SCANCODE_Z )
|
if( keynum >= SDL_SCANCODE_A && keynum <= SDL_SCANCODE_Z )
|
||||||
{
|
{
|
||||||
@@ -176,7 +176,7 @@ static void SDLash_KeyEvent( SDL_KeyboardEvent key )
|
|||||||
|
|
||||||
if( isprint( keynum ) )
|
if( isprint( keynum ) )
|
||||||
{
|
{
|
||||||
if( SDL_GetModState() & KMOD_SHIFT )
|
if( FBitSet( SDL_GetModState(), KMOD_SHIFT ))
|
||||||
{
|
{
|
||||||
keynum = Key_ToUpper( keynum );
|
keynum = Key_ToUpper( keynum );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -158,8 +158,8 @@ void *SW_LockBuffer( void )
|
|||||||
void *pixels;
|
void *pixels;
|
||||||
int stride;
|
int stride;
|
||||||
|
|
||||||
if( SDL_LockTexture(sw.tex, NULL, &pixels, &stride ) )
|
if( SDL_LockTexture(sw.tex, NULL, &pixels, &stride ) < 0 )
|
||||||
Sys_Error("%s", SDL_GetError());
|
Sys_Error( "%s: %s", __func__, SDL_GetError( ));
|
||||||
return pixels;
|
return pixels;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -272,7 +272,7 @@ static void R_InitVideoModes( void )
|
|||||||
int j;
|
int j;
|
||||||
SDL_DisplayMode mode;
|
SDL_DisplayMode mode;
|
||||||
|
|
||||||
if( SDL_GetDisplayMode( displayIndex, i, &mode ) )
|
if( SDL_GetDisplayMode( displayIndex, i, &mode ) < 0 )
|
||||||
{
|
{
|
||||||
Msg( "SDL_GetDisplayMode: %s\n", SDL_GetError() );
|
Msg( "SDL_GetDisplayMode: %s\n", SDL_GetError() );
|
||||||
continue;
|
continue;
|
||||||
@@ -419,12 +419,16 @@ static qboolean WIN_SetWindowIcon( HICON ico )
|
|||||||
{
|
{
|
||||||
SDL_SysWMinfo wminfo;
|
SDL_SysWMinfo wminfo;
|
||||||
|
|
||||||
if( SDL_GetWindowWMInfo( host.hWnd, &wminfo ))
|
SDL_VERSION( &wminfo.version );
|
||||||
|
|
||||||
|
if( SDL_GetWindowWMInfo( host.hWnd, &wminfo ) == SDL_TRUE )
|
||||||
{
|
{
|
||||||
SendMessage( wminfo.info.win.window, WM_SETICON, ICON_SMALL, (LONG_PTR)ico );
|
SendMessage( wminfo.info.win.window, WM_SETICON, ICON_SMALL, (LONG_PTR)ico );
|
||||||
SendMessage( wminfo.info.win.window, WM_SETICON, ICON_BIG, (LONG_PTR)ico );
|
SendMessage( wminfo.info.win.window, WM_SETICON, ICON_BIG, (LONG_PTR)ico );
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Con_Reportf( S_ERROR "%s: %s", __func__, SDL_GetError( ));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -492,8 +496,8 @@ void GL_UpdateSwapInterval( void )
|
|||||||
{
|
{
|
||||||
ClearBits( gl_vsync.flags, FCVAR_CHANGED );
|
ClearBits( gl_vsync.flags, FCVAR_CHANGED );
|
||||||
|
|
||||||
if( SDL_GL_SetSwapInterval( gl_vsync.value ) )
|
if( SDL_GL_SetSwapInterval( gl_vsync.value ) < 0 )
|
||||||
Con_Reportf( S_ERROR "SDL_GL_SetSwapInterval: %s\n", SDL_GetError( ) );
|
Con_Reportf( S_ERROR "SDL_GL_SetSwapInterval: %s\n", SDL_GetError( ));
|
||||||
}
|
}
|
||||||
#endif // SDL_VERSION_ATLEAST( 2, 0, 0 )
|
#endif // SDL_VERSION_ATLEAST( 2, 0, 0 )
|
||||||
}
|
}
|
||||||
@@ -542,7 +546,7 @@ GL_UpdateContext
|
|||||||
static qboolean GL_UpdateContext( void )
|
static qboolean GL_UpdateContext( void )
|
||||||
{
|
{
|
||||||
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
|
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
|
||||||
if( SDL_GL_MakeCurrent( host.hWnd, glw_state.context ))
|
if( SDL_GL_MakeCurrent( host.hWnd, glw_state.context ) < 0 )
|
||||||
{
|
{
|
||||||
Con_Reportf( S_ERROR "GL_UpdateContext: %s\n", SDL_GetError());
|
Con_Reportf( S_ERROR "GL_UpdateContext: %s\n", SDL_GetError());
|
||||||
return GL_DeleteContext();
|
return GL_DeleteContext();
|
||||||
@@ -599,7 +603,7 @@ static qboolean VID_SetScreenResolution( int width, int height, window_mode_t wi
|
|||||||
want.w = width;
|
want.w = width;
|
||||||
want.h = height;
|
want.h = height;
|
||||||
|
|
||||||
if( SDL_GetClosestDisplayMode( 0, &want, &got ) < 0 )
|
if( SDL_GetClosestDisplayMode( 0, &want, &got ) == NULL )
|
||||||
{
|
{
|
||||||
Con_Printf( S_ERROR "%s: SDL_GetClosestDisplayMode: %s", __func__, SDL_GetError( ));
|
Con_Printf( S_ERROR "%s: SDL_GetClosestDisplayMode: %s", __func__, SDL_GetError( ));
|
||||||
return false;
|
return false;
|
||||||
@@ -1047,7 +1051,7 @@ qboolean R_Init_Video( const int type )
|
|||||||
// refdll can request some attributes
|
// refdll can request some attributes
|
||||||
GL_SetupAttributes( );
|
GL_SetupAttributes( );
|
||||||
|
|
||||||
if( SDL_GL_LoadLibrary( EGL_LIB ) )
|
if( SDL_GL_LoadLibrary( EGL_LIB ) < 0 )
|
||||||
{
|
{
|
||||||
Con_Reportf( S_ERROR "Couldn't initialize OpenGL: %s\n", SDL_GetError());
|
Con_Reportf( S_ERROR "Couldn't initialize OpenGL: %s\n", SDL_GetError());
|
||||||
return false;
|
return false;
|
||||||
@@ -1086,7 +1090,11 @@ rserr_t R_ChangeDisplaySettings( int width, int height, window_mode_t window_mod
|
|||||||
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
|
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
|
||||||
SDL_DisplayMode displayMode;
|
SDL_DisplayMode displayMode;
|
||||||
|
|
||||||
SDL_GetCurrentDisplayMode( 0, &displayMode );
|
if( SDL_GetCurrentDisplayMode( 0, &displayMode ) < 0 )
|
||||||
|
{
|
||||||
|
Con_Printf( S_ERROR "SDL_GetCurrentDisplayMode: %s", SDL_GetError( ));
|
||||||
|
return rserr_invalid_mode;
|
||||||
|
}
|
||||||
|
|
||||||
// check our desktop attributes
|
// check our desktop attributes
|
||||||
refState.desktopBitsPixel = SDL_BITSPERPIXEL( displayMode.format );
|
refState.desktopBitsPixel = SDL_BITSPERPIXEL( displayMode.format );
|
||||||
@@ -1115,8 +1123,11 @@ rserr_t R_ChangeDisplaySettings( int width, int height, window_mode_t window_mod
|
|||||||
VID_RestoreScreenResolution();
|
VID_RestoreScreenResolution();
|
||||||
|
|
||||||
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
|
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
|
||||||
if( SDL_SetWindowFullscreen( host.hWnd, 0 ))
|
if( SDL_SetWindowFullscreen( host.hWnd, 0 ) < 0 )
|
||||||
|
{
|
||||||
|
Con_Printf( S_ERROR "SDL_SetWindowFullscreen: %s", SDL_GetError( ));
|
||||||
return rserr_invalid_fullscreen;
|
return rserr_invalid_fullscreen;
|
||||||
|
}
|
||||||
#if SDL_VERSION_ATLEAST( 2, 0, 5 )
|
#if SDL_VERSION_ATLEAST( 2, 0, 5 )
|
||||||
SDL_SetWindowResizable( host.hWnd, SDL_TRUE );
|
SDL_SetWindowResizable( host.hWnd, SDL_TRUE );
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -1014,7 +1014,7 @@ static void APIENTRY GL2_TexImage2D( GLenum target, GLint level, GLint internalf
|
|||||||
}
|
}
|
||||||
internalformat = format;
|
internalformat = format;
|
||||||
}
|
}
|
||||||
if( internalformat == GL_LUMINANCE8_ALPHA8 || internalformat == GL_RGB )
|
if( internalformat == GL_LUMINANCE8_ALPHA8 || internalformat == GL_RGB || internalformat == GL_RGB8 || internalformat == GL_RGB5 )
|
||||||
internalformat = GL_RGBA;
|
internalformat = GL_RGBA;
|
||||||
rpglTexImage2D( target, level, internalformat, width, height, border, format, type, data );
|
rpglTexImage2D( target, level, internalformat, width, height, border, format, type, data );
|
||||||
if( data != pixels )
|
if( data != pixels )
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ CVAR_DEFINE_AUTO( r_novis, "0", 0, "ignore vis information (perfomance test)" );
|
|||||||
CVAR_DEFINE_AUTO( r_nocull, "0", 0, "ignore frustrum culling (perfomance test)" );
|
CVAR_DEFINE_AUTO( r_nocull, "0", 0, "ignore frustrum culling (perfomance test)" );
|
||||||
CVAR_DEFINE_AUTO( r_lockpvs, "0", FCVAR_CHEAT, "lockpvs area at current point (pvs test)" );
|
CVAR_DEFINE_AUTO( r_lockpvs, "0", FCVAR_CHEAT, "lockpvs area at current point (pvs test)" );
|
||||||
CVAR_DEFINE_AUTO( r_lockfrustum, "0", FCVAR_CHEAT, "lock frustrum area at current point (cull test)" );
|
CVAR_DEFINE_AUTO( r_lockfrustum, "0", FCVAR_CHEAT, "lock frustrum area at current point (cull test)" );
|
||||||
CVAR_DEFINE_AUTO( r_traceglow, "1", FCVAR_GLCONFIG, "cull flares behind models" );
|
CVAR_DEFINE_AUTO( r_traceglow, "0", FCVAR_GLCONFIG, "cull flares behind models" );
|
||||||
CVAR_DEFINE_AUTO( gl_round_down, "2", FCVAR_GLCONFIG|FCVAR_READ_ONLY, "round texture sizes to nearest POT value" );
|
CVAR_DEFINE_AUTO( gl_round_down, "2", FCVAR_GLCONFIG|FCVAR_READ_ONLY, "round texture sizes to nearest POT value" );
|
||||||
CVAR_DEFINE( r_vbo, "gl_vbo", "0", FCVAR_ARCHIVE, "draw world using VBO (known to be glitchy)" );
|
CVAR_DEFINE( r_vbo, "gl_vbo", "0", FCVAR_ARCHIVE, "draw world using VBO (known to be glitchy)" );
|
||||||
CVAR_DEFINE( r_vbo_dlightmode, "gl_vbo_dlightmode", "1", FCVAR_ARCHIVE, "vbo dlight rendering mode (0-1)" );
|
CVAR_DEFINE( r_vbo_dlightmode, "gl_vbo_dlightmode", "1", FCVAR_ARCHIVE, "vbo dlight rendering mode (0-1)" );
|
||||||
@@ -859,7 +859,9 @@ void GL_InitExtensionsGLES( void )
|
|||||||
#endif
|
#endif
|
||||||
case GL_DEBUG_OUTPUT:
|
case GL_DEBUG_OUTPUT:
|
||||||
if( glw_state.extended )
|
if( glw_state.extended )
|
||||||
GL_CheckExtension( "GL_KHR_debug", NULL, NULL, extid, 0 );
|
GL_CheckExtension( "GL_KHR_debug", debugoutputfuncs, "gl_debug_output", extid, 0 );
|
||||||
|
else
|
||||||
|
GL_SetExtension( extid, false );
|
||||||
break;
|
break;
|
||||||
// case GL_TEXTURE_COMPRESSION_EXT: NOPE
|
// case GL_TEXTURE_COMPRESSION_EXT: NOPE
|
||||||
// case GL_SHADER_GLSL100_EXT: NOPE
|
// case GL_SHADER_GLSL100_EXT: NOPE
|
||||||
@@ -1123,6 +1125,7 @@ void GL_InitExtensions( void )
|
|||||||
|
|
||||||
// force everything to happen in the main thread instead of in a separate driver thread
|
// force everything to happen in the main thread instead of in a separate driver thread
|
||||||
pglEnable( GL_DEBUG_OUTPUT_SYNCHRONOUS_ARB );
|
pglEnable( GL_DEBUG_OUTPUT_SYNCHRONOUS_ARB );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// enable all the low priority messages
|
// enable all the low priority messages
|
||||||
@@ -1375,7 +1378,7 @@ void GL_SetupAttributes( int safegl )
|
|||||||
#ifdef XASH_NANOGL
|
#ifdef XASH_NANOGL
|
||||||
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MAJOR_VERSION, 1 );
|
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MAJOR_VERSION, 1 );
|
||||||
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MINOR_VERSION, 1 );
|
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MINOR_VERSION, 1 );
|
||||||
#elif defined( XASH_WES ) || defined( XASH_REGAL )
|
#else
|
||||||
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MAJOR_VERSION, 2 );
|
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MAJOR_VERSION, 2 );
|
||||||
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MINOR_VERSION, 0 );
|
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_MINOR_VERSION, 0 );
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ static void R_ParseDetailTextures( const char *filename )
|
|||||||
if( Q_stricmp( tex->name, texname ))
|
if( Q_stricmp( tex->name, texname ))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
tex->dt_texturenum = GL_LoadTexture( detail_path, NULL, 0, TF_FORCE_COLOR );
|
tex->dt_texturenum = GL_LoadTexture( detail_path, NULL, 0, TF_FORCE_COLOR|TF_NOFLIP_TGA );
|
||||||
|
|
||||||
// texture is loaded
|
// texture is loaded
|
||||||
if( tex->dt_texturenum )
|
if( tex->dt_texturenum )
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ CVAR_DEFINE_AUTO( sw_surfcacheoverride, "0", 0, "");
|
|||||||
static CVAR_DEFINE_AUTO( sw_waterwarp, "1", FCVAR_GLCONFIG, "nothing");
|
static CVAR_DEFINE_AUTO( sw_waterwarp, "1", FCVAR_GLCONFIG, "nothing");
|
||||||
static CVAR_DEFINE_AUTO( sw_notransbrushes, "0", FCVAR_GLCONFIG, "do not apply transparency to water/glasses (faster)");
|
static CVAR_DEFINE_AUTO( sw_notransbrushes, "0", FCVAR_GLCONFIG, "do not apply transparency to water/glasses (faster)");
|
||||||
CVAR_DEFINE_AUTO( sw_noalphabrushes, "0", FCVAR_GLCONFIG, "do not draw brush holes (faster)");
|
CVAR_DEFINE_AUTO( sw_noalphabrushes, "0", FCVAR_GLCONFIG, "do not draw brush holes (faster)");
|
||||||
CVAR_DEFINE_AUTO( r_traceglow, "1", FCVAR_GLCONFIG, "cull flares behind models" );
|
CVAR_DEFINE_AUTO( r_traceglow, "0", FCVAR_GLCONFIG, "cull flares behind models" );
|
||||||
CVAR_DEFINE_AUTO( sw_texfilt, "0", FCVAR_GLCONFIG, "texture dither");
|
CVAR_DEFINE_AUTO( sw_texfilt, "0", FCVAR_GLCONFIG, "texture dither");
|
||||||
static CVAR_DEFINE_AUTO( r_novis, "0", 0, "" );
|
static CVAR_DEFINE_AUTO( r_novis, "0", 0, "" );
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user