|
|
|
|
@ -68,10 +68,13 @@ CoverSwitchEffect::CoverSwitchEffect() |
|
|
|
|
captionFont.setPointSize(captionFont.pointSize() * 2); |
|
|
|
|
|
|
|
|
|
QString shadersDir = "kwin/shaders/1.10/"; |
|
|
|
|
#ifndef KWIN_HAVE_OPENGLES |
|
|
|
|
if (GLPlatform::instance()->glslVersion() >= kVersionNumber(1, 40)) |
|
|
|
|
shadersDir = "kwin/shaders/1.40/"; |
|
|
|
|
#ifdef KWIN_HAVE_OPENGLES |
|
|
|
|
const qint64 coreVersionNumber = kVersionNumber(3, 0); |
|
|
|
|
#else |
|
|
|
|
const qint64 coreVersionNumber = kVersionNumber(1, 40); |
|
|
|
|
#endif |
|
|
|
|
if (GLPlatform::instance()->glslVersion() >= coreVersionNumber) |
|
|
|
|
shadersDir = "kwin/shaders/1.40/"; |
|
|
|
|
const QString fragmentshader = KGlobal::dirs()->findResource("data", shadersDir + "coverswitch-reflection.glsl"); |
|
|
|
|
m_reflectionShader = ShaderManager::instance()->loadFragmentShader(ShaderManager::GenericShader, fragmentshader); |
|
|
|
|
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*))); |
|
|
|
|
|