Drop option to select direct rendering

Review Request #102074 - Created July 24, 2011 and submitted

Information
Martin Flöser
kde-workspace
master
Reviewers
kwin
The advanced compositing option "direct rendering" could only correctly be honored in the case of proprietary NVIDIA drivers. In all cases playing with the setting was most likely harmful as it could result in inconsistent states and the option not to be honored at all.

This patch resolves this issue by moving the detection whether to use a direct rendering context completely into the hands of the set environment variables or the helper program:
* if LIBGL_ALWAYS_INDIRECT is set, we use an indirect context
* if KWIN_DIRECT_GL is set, we use a direct context
* if none of the two are set, we use the helper program, if it returns 0 we create a direct context, otherwise we set LIBGL_ALWAYS_INDIRECT and create an indirect context

If a user really wants to influence the behavior (and I doubt that) the environment variables can be used.
* without any environment variable a direct rendering context is created on my R600
* with LIBGL_ALWAYS_INDIRECT an indirect rendering context is created on my R600

other possible combinations (e.g. NVIDIA) not tested.
Commit Hook
This review has been submitted with commit fcf6eaa9290a0f1f19683e621595e114b908ddea by Martin Gräßlin to branch master.
Loading...