Commit Graph

7 Commits (388edab9e59e1f8d77985a0121073de4e44b990f)

Author SHA1 Message Date
Martin Gräßlin 388edab9e5 Add support for OpenGL in VirtualBox
OpenGL is properly working if there is a direct rendering context.
If LIBGL_ALWAYS_INDIRECT is set VirtualBox falls back to Mesa's software
rasterizer. So in order to get OpenGL the driver is now whitelisted in
the opengltest.

GLPlatform is extended to recognize the VirtualBox driver and has new
methods to report whether it is a virtual machine and VirtualBox. The
detection is rather limited as we don't get access to the underlying
hardware, so we do not know whether the features are really supported.
We need to trust the driver here in announcing the right extensions.

The driver does not provide glxQueryDrawable although it is part of
GLX 1.3. A hack is added in the glxbackend to set the function pointer to
NULL. This can unfortunately not be done in glxResolveFunctions() as
QueryDrawable seems not to be provided by an extension (at least not
listed in the OpenGL registry) and getProcAddress resolves a function but
it only prints an OpenGL Warning to stderr.

As a note: the driver reports that it is using XSHM for
GLX_EXT_texture_from_pixmap.

REVIEW: 106821
2012-10-25 11:27:28 +02:00
Martin Gräßlin 711b434970 Detect latest Intel hardware in GLPlatform
Added support for IvyBridge and Haswell.

REVIEW: 106819
2012-10-25 11:27:14 +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
Martin Gräßlin e8a038d66f More getters for GlPlatform
A few more getters for parsed information are added to GlPlatform.
This includes the driver information retrieved through glGetString
and information like direct rendering and loose binding.

Additionally the methods to convert version, driver and chipClass
to string are added to the public interface.

These changes allow parts outside GlPlatform to get the same debug
information about the GL system.
2012-03-04 15:21:10 +01: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 1dd614ee4b Improved detection of OpenGL software emulation
Adding a new method to retrieve whether the OpenGL implementation
uses any kind of software emulation and no software emulation can
provide GLSL support, even if it claims so.

Thanks to Maurel for testing again and again proposed patches.

BUG: 271166
2011-05-06 18:16:38 +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