Commit Graph

29 Commits (1c8233ad6dc55a2de55eed1db3412171ddd5d2eb)

Author SHA1 Message Date
Casian Andrei 54ee2bf564 Fix many color correction problems with OpenGL ES
On GLES, check for OES_texture_3D extension for color correction

Remove a block of ugly hack code that was supposedly needed to build
with OpenGL ES.

Convert the lookup texture data to uint8 on OpenGL ES before sending it
via glTexImage3D, because uint16 is not supported.

Check if the shaders have been reinitialized successfuly when trying to
activate color correction, prevent black screens when there are issues
with the shaders.

BUG: 315419
REVIEW: 111225
2013-07-23 19:48:47 +03:00
Fredrik Höglund 7e22bd314c kwin: Add support for rendering quads using an index buffer
This reduces the size of the geometry that needs to be uploaded by
one-third, and allows kwin to take advantage of the post-transform
cache in the GPU.
2013-06-05 00:41:24 +02:00
Fredrik Höglund 479ea5db61 kwin: Resolve functions for GL_ARB_copy_buffer 2013-06-05 00:41:24 +02:00
Fredrik Höglund 5e7b2a34a8 kwin: Resolve functions for GL_ARB_draw_elements_base_vertex 2013-06-05 00:41:23 +02:00
Martin Gräßlin ad1203e3b2 Add defines from EXT_robustness
Seem to be missing in the headers used on build.kde.org.
2013-05-23 08:38:16 +02:00
Fredrik Höglund 2f87b7542f kwin/es: Resolve functions for GL_EXT_robustness 2013-05-21 00:22:57 +02:00
Fredrik Höglund adc581d2ab kwin: Resolve functions for GL_ARB_robustness
Only the subset of functions available in core contexts is resolved,
except for glGetnTexImageARB() and glGetnUniformivARB(), which are
not used by kwin.

Instead of setting the function pointers to NULL when the extension isn't
supported, kwin provides its own implementations that call the non-robust
versions of the functions.  This is so callers don't have to check if the
extension is supported before calling the functions.
2013-05-21 00:22:55 +02:00
Fredrik Höglund e65f717b47 kwin/es: Resolve functions for GL_EXT_map_buffer_range 2013-05-08 18:36:50 +02:00
Fredrik Höglund b6585c2d8b kwin/es: Resolve functions for GL_OES_mapbuffer 2013-05-08 18:36:45 +02:00
Fredrik Höglund 11b9323f3d kwin: Resolve functions for GL_ARB_map_buffer_range 2013-05-08 18:36:38 +02:00
Fredrik Höglund 08d3b6cc3a kwin: Resolve more functions from ARB_vertex_buffer_object
This patch resolves:
    glMapBuffer()
    glUnmapBuffer()
    glBufferSubData()
    glGetBufferSubData()
2013-05-08 18:36:04 +02:00
Fredrik Höglund e0003db385 kwin: Resolve functions for GL_EXT_gpu_shader4 2013-05-08 18:33:02 +02:00
Fredrik Höglund 2bcad53bbb kwin: Resolve functions for GL_ARB_vertex_array_object 2013-05-08 18:33:02 +02:00
Fredrik Höglund d116ef6655 kwin/egl: Add defines for EGL_KHR_create_context 2013-05-08 18:33:01 +02:00
Fredrik Höglund aab026af93 kwin: Resolve functions for GLX_ARB_create_context 2013-05-08 18:12:43 +02:00
Martin Gräßlin 7ab5df9de8 Define GL_UNPACK_* for gles if not defined
Should fix build error in build.kde.org.
2013-03-11 12:36:40 +01:00
Ralf Jung 96bc979ca8 Fix buffer swap prototypes
BUG: 309647
REVIEW: 107302
2012-11-18 12:50:31 +01:00
Martin Gräßlin ba08ff6a14 Fix build error when GLES is not available
Note to me: always rebuild with all possible build options if something
is changed.

Sorry for the inconvenience and thanks to the early report of the issue.

BUG: 307866
FIXED-IN: 4.10
2012-10-06 13:44:12 +02:00
Martin Gräßlin 476adac337 Do not resolve glx functions specified in GLX 1.3
According to the OpenGL ABI for Linux GLX 1.3 is a minimum requirement.
Therefore we do not need to resolve the symbols which are present in that
version.

KWin did always require at least 1.3, for all the resolved functions
there were checks in the Scene, but they might have been incorrect.
Instead now the GLX version is checked and OpenGL compositing is blocked
if there is not at least GLX 1.3.

REVIEW: 106704
2012-10-04 17:17:51 +02:00
Martin Gräßlin 15d714d82c Do not resolve glBlendColor
glBlendColor has been added to OpenGL 1.2 which means it is part of
the OpenGL ABI defined for Linux.

See http://www.opengl.org/registry/ABI/ section 3.4.
2012-10-04 17:17:45 +02:00
Martin Gräßlin a401558a43 Provide OpenGL over Egl
The Egl backend is decoupled from the OpenGL ES build option which makes
it possible to use it as a replacement for glx.

To make this possible a new build flag is added when egl is available at
compile time and any egl specific code is now ifdefed with this flag
instead of the gles flag. In addition at runtime a windowing system enum
value is passed to the various detect methods to have egl/glx specific
detection for e.g. function pointer resolving.

By default egl is used if compiled with OpenGL ES, otherwise glx is used.
But in the non-gles case the windowing system can be selected through the
new environment variable KWIN_OPENGL_INTERFACE. Setting this variable to
"egl" the EglOnXBackend is used.

REVIEW: 106632
2012-10-04 17:17:01 +02:00
Thomas Lübking fc665106c9 Swap vsync order, trade in 1frame lag
REVIEW: 103058
2012-05-17 11:41:26 +02:00
Christoph Thielecke 99b233e2ed define missing defines if nessary 2012-03-22 15:10:30 +01:00
Pierre-Loup A. Griffais 7fff9705b4 kwin-gles: define EGL_POST_SUB_BUFFER_SUPPORTED_NV if it's not there
This fixes the build with older versions of eglext.h.

REVIEW: 102915
2011-10-19 20:15:40 +02:00
Pierre-Loup A. Griffais 2570e9ec61 kwin-gles: add support for EGL_NV_post_sub_buffer
The EGL path had no support for presenting sub-regions of the screen, we can
leverage EGL_NV_post_sub_buffer for that. This wouldn't be a win if we didn't
have to opt-out of flipping.

REVIEW: 102889
2011-10-17 20:27:23 +02:00
Martin Gräßlin 225c362a04 Add support for framebuffer blit extension
Resolving of blit function and method in GLRenderTarget to blit
from the framebuffer to the RenderTarget.

REVIEW: 102354
2011-08-20 10:58:27 +02:00
Martin Gräßlin 9c2d6f8fdc Drop hacks for gcc-3.3.3
According to Thiago minimum supported gcc is 4.2.
2011-08-14 08:59:51 +02:00
Martin Gräßlin f5a187d224 Remove KWIN_HAVE_OPENGL from kwingl(es)utils
Yes building an OpenGL support library requires OpenGL...
2011-08-13 16:46:43 +02:00
Martin Gräßlin 57d11c134a Move kwineffects library into own directory
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
2011-02-19 10:01:31 +01:00