Commit 36692ab6 authored by Scott Petrovic's avatar Scott Petrovic

fix loading correct resource for fragment shader

parent 06fc7bac
......@@ -712,8 +712,6 @@ QByteArray KisOpenGLCanvas2::buildFragmentShader()
filename = "simple_texture_legacy.frag";
}
QString fileKey = QString("krita/shaders/%1")
.arg(filename);
if (haveDisplayFilter) {
shaderText.append("#define USE_OCIO\n");
......@@ -729,7 +727,7 @@ QByteArray KisOpenGLCanvas2::buildFragmentShader()
}
{
QFile prefaceFile(KoResourcePaths::findResource("data", fileKey));
QFile prefaceFile(":/" + filename);
prefaceFile.open(QIODevice::ReadOnly);
shaderText.append(prefaceFile.readAll());
}
......@@ -775,6 +773,10 @@ void KisOpenGLCanvas2::initializeDisplayShader()
// highq
d->displayUniformLocationTexelSize = d->displayShader->uniformLocation("texelSize");
// TODO: The trilinear filtering mode is having issues when that is set in the application. It sometimes causes Krita to crash
// I cannot tell where that is at in here... Scott P (11/8/2015)
// lod
d->displayUniformLocationFixedLodLevel =
KisOpenGL::supportsGLSL13() ?
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment