Only use GLSL shader for lanczosfilter if ShaderManager is valid

This commit is contained in:
Martin Gräßlin 2011-04-29 16:39:15 +02:00
parent 818a936e99
commit 728f333e6a

View file

@ -604,6 +604,7 @@ bool LanczosShader::init()
{ {
GLPlatform *gl = GLPlatform::instance(); GLPlatform *gl = GLPlatform::instance();
if (gl->supports(GLSL) && if (gl->supports(GLSL) &&
ShaderManager::instance()->isValid() &&
GLRenderTarget::supported() && GLRenderTarget::supported() &&
!(gl->isRadeon() && gl->chipClass() < R600)) { !(gl->isRadeon() && gl->chipClass() < R600)) {
m_shader = ShaderManager::instance()->loadFragmentShader(ShaderManager::SimpleShader, ":/resources/lanczos-fragment.glsl"); m_shader = ShaderManager::instance()->loadFragmentShader(ShaderManager::SimpleShader, ":/resources/lanczos-fragment.glsl");