mirror of
https://github.com/TTimo/GtkRadiant.git
synced 2025-02-13 23:51:38 +00:00
avoid “unused” warning because usage is in debug code only
This commit is contained in:
parent
e179e2b4a4
commit
c832a55910
1 changed files with 2 additions and 2 deletions
|
@ -431,18 +431,18 @@ int WINAPI QERApp_LoadShadersFromDir( const char *path ){
|
||||||
|
|
||||||
if ( strstr( pShader->getShaderFileName(), around ) != NULL || g_str_has_prefix( pShader->getName(), prefix ) ) {
|
if ( strstr( pShader->getShaderFileName(), around ) != NULL || g_str_has_prefix( pShader->getName(), prefix ) ) {
|
||||||
count++;
|
count++;
|
||||||
|
#ifdef _DEBUG
|
||||||
// request the shader, this will load the texture if needed and set "inuse"
|
// request the shader, this will load the texture if needed and set "inuse"
|
||||||
//++timo FIXME: should we put an Activate member on CShader?
|
//++timo FIXME: should we put an Activate member on CShader?
|
||||||
// this QERApp_Shader_ForName call is a kind of hack
|
// this QERApp_Shader_ForName call is a kind of hack
|
||||||
IShader *pFoo = QERApp_Shader_ForName( pShader->getName() );
|
IShader *pFoo = QERApp_Shader_ForName( pShader->getName() );
|
||||||
#ifdef _DEBUG
|
|
||||||
// check we activated the right shader
|
// check we activated the right shader
|
||||||
// NOTE: if there was something else loaded, the size of g_Shaders may have changed and strange behaviours are to be expected
|
// NOTE: if there was something else loaded, the size of g_Shaders may have changed and strange behaviours are to be expected
|
||||||
if ( pFoo != pShader ) {
|
if ( pFoo != pShader ) {
|
||||||
Sys_FPrintf( SYS_WRN, "WARNING: unexpected pFoo != pShader in QERApp_LoadShadersFromDir\n" );
|
Sys_FPrintf( SYS_WRN, "WARNING: unexpected pFoo != pShader in QERApp_LoadShadersFromDir\n" );
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
pFoo = NULL; // leo: shut up the compiler
|
QERApp_Shader_ForName( pShader->getName() );
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue