Second part of cleaning up the lib directory: the effects library
now lives in libkwineffects/ directory.
For existing effects nothing changes as the install path is unchanged.
The change obsoletes the lib/ directory.
As glplatform.h has not yet been exported I dared to export it and
adjust the places where it is used.
CCMAIL: kwin@kde.org
add a new function fallbackPainting to GLVertexBufferPrivate class
replace the hard-coded index values for vertex and texCoords attributes in corePainting
Reviewed by: Martin Gräßlin <mgraesslin@kde.org>
This solves the regression with NVIDIA drivers resulting in a black screen.
Apparently NVIDIA does not support glXCopySubBuffer and the copying of pixels
fails with a shader bound.
So unbinding the shader before copying the pixels and rebinding the shader
afterwards resolves the issue.
This allows to remove the temporary hack to make NVIDIA work, again.
KWin's new shaders fail with NVIDIA and present just a black screen
for the ortho shader (generic shader seems to work). Temporarily
disabling the shaders to force a fallback to old rendering code.
Of course the bug in the shader needs to be fixed.
KWin's new shaders fail with NVIDIA and present just a black screen
for the ortho shader (generic shader seems to work). Temporarily
disabling the shaders to force a fallback to old rendering code.
Of course the bug in the shader needs to be fixed.
When rendering opaque (RGB-only) windows the alpha ends up to be 0
with blending disabled. This breaks subsequent rendering steps which
require blenden (e.g. Lanczos). Therefore a uniform is used to ensure
that the alpha channel is set to 1.
The vertex buffer implementation uses the shader manager to decide
whether core painting should be used or not. Shader manager is only
used by shaders using vertex attributes instead of gl_Vertex etc.
ShaderManager supports a new concept to load just a fragment shader from file
and use a built-in shader for the vertex shader. This allows an effect to use
a custom fragment shader.
The ShaderManager provides the built-in shaders for scene and effects.
Scene and effects can simply push one of those built-in shaders or a
custom one on a stack ensuring that the previously bound shader will be
rebound when the shader is poped again.
The class will be extended to not only have built-in shaders but also to
load custom shaders and being the only way to bind a shader at all.