diff options
author | Richard Grenville <[email protected]> | 2013-12-10 22:06:02 +0800 |
---|---|---|
committer | Richard Grenville <[email protected]> | 2013-12-10 22:06:02 +0800 |
commit | 44a13b4e767eef1985a4a34723b7cc279e1dc160 (patch) | |
tree | 901b608ef59ace1f0b4a4759b8e353238b209c7e /opengl.c | |
parent | 640ef0437814dbc4df57a275cbadecb368ad0950 (diff) | |
download | tdebase-44a13b4e767eef1985a4a34723b7cc279e1dc160.tar.gz tdebase-44a13b4e767eef1985a4a34723b7cc279e1dc160.zip |
Feature: Add XRender-GLX hybird backend
- Add new backend "xr_glx_hybird", which uses X Render for all
compositing but GLX on the last step of rendering to screen. This
makes GLX-backend-specific VSync methods usable while may avoid
certain bugs with GLX backend. The idea comes from ali1234.
Experimental.
- GLX backend: Stop using or rendering to depth buffer.
- Use glFinish() instead of glFlush() before VSync. It probably uses
more CPU but could be more reliable than glFlush().
Diffstat (limited to 'opengl.c')
-rw-r--r-- | opengl.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -124,7 +124,8 @@ glx_init(session_t *ps, bool need_render) { if (need_render) { glx_on_root_change(ps); - // glEnable(GL_DEPTH_TEST); + glDisable(GL_DEPTH_TEST); + glDepthMask(GL_FALSE); glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE); glDisable(GL_BLEND); @@ -880,7 +881,7 @@ glx_set_clip(session_t *ps, XserverRegion reg, const reg_data_t *pcache_reg) { glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); - glDepthMask(GL_TRUE); + // glDepthMask(GL_TRUE); } cxfree(rects_free); |