コード例 #1
0
ファイル: shaders.cpp プロジェクト: 0bsidian/GtkRadiant
// Hydra: now returns false if the ORIGINAL shader could not be activated
// (missing texture, or incorrect shader script), true otherwise
// the shader is still activated in all cases.
bool CShader::Activate(){
	Try_Activate();
	if ( !m_pTexture ) {
		m_pTexture = QERApp_Texture_ForName2( SHADER_NOTEX );
		RegisterActivate();
		return false;
	}
	return true;
}
コード例 #2
0
ファイル: IShaders.cpp プロジェクト: FS-NulL/Q3Radiant
void CShader::Activate()
{
	Try_Activate();
	if (!m_pTexture)
	{
		// use the shadernotex.jpg
		//++timo TODO: detect shadernotex.jpg not found and give an error message!
		m_pTexture = QERApp_Texture_ForName2( "textures/radiant/shadernotex" );
		RegisterActivate();
	}
}