diff --git a/src/scenes/opengl/lanczosfilter.cpp b/src/scenes/opengl/lanczosfilter.cpp index 919b950a95..d275e65aaf 100644 --- a/src/scenes/opengl/lanczosfilter.cpp +++ b/src/scenes/opengl/lanczosfilter.cpp @@ -76,14 +76,8 @@ void LanczosFilter::init() return; } } - QFile ff(gl->glslVersion() >= kVersionNumber(1, 40) ? - QStringLiteral(":/scenes/opengl/shaders/1.40/lanczos-fragment.glsl") : - QStringLiteral(":/scenes/opengl/shaders/1.10/lanczos-fragment.glsl")); - if (!ff.open(QIODevice::ReadOnly)) { - qCDebug(KWIN_OPENGL) << "Failed to open lanczos shader"; - return; - } - m_shader.reset(ShaderManager::instance()->generateCustomShader(ShaderTrait::MapTexture, QByteArray(), ff.readAll())); + + m_shader.reset(ShaderManager::instance()->generateShaderFromFile(ShaderTrait::MapTexture, QString(), QStringLiteral(":/scenes/opengl/shaders/lanczos.frag"))); if (m_shader->isValid()) { ShaderBinder binder(m_shader.data()); m_uKernel = m_shader->uniformLocation("kernel"); diff --git a/src/scenes/opengl/lanczosresources.qrc b/src/scenes/opengl/lanczosresources.qrc index 8fbd27d16a..4f3b85e087 100644 --- a/src/scenes/opengl/lanczosresources.qrc +++ b/src/scenes/opengl/lanczosresources.qrc @@ -1,6 +1,6 @@ - shaders/1.10/lanczos-fragment.glsl - shaders/1.40/lanczos-fragment.glsl + shaders/lanczos.frag + shaders/lanczos_core.frag diff --git a/src/scenes/opengl/shaders/1.10/lanczos-fragment.glsl b/src/scenes/opengl/shaders/lanczos.frag similarity index 100% rename from src/scenes/opengl/shaders/1.10/lanczos-fragment.glsl rename to src/scenes/opengl/shaders/lanczos.frag diff --git a/src/scenes/opengl/shaders/1.40/lanczos-fragment.glsl b/src/scenes/opengl/shaders/lanczos_core.frag similarity index 100% rename from src/scenes/opengl/shaders/1.40/lanczos-fragment.glsl rename to src/scenes/opengl/shaders/lanczos_core.frag