summaryrefslogtreecommitdiff
path: root/3d.c
diff options
context:
space:
mode:
Diffstat (limited to '3d.c')
-rw-r--r--3d.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/3d.c b/3d.c
index 18191dd..0d4ba60 100644
--- a/3d.c
+++ b/3d.c
@@ -230,7 +230,7 @@ tdPaintWindowWithDepth (CompWindow *w,
Bool wasCulled;
Bool status;
int wx, wy, ww, wh;
- int bevel;
+ int bevel, cull;
CompScreen *s = w->screen;
CompVector point, tPoint;
@@ -246,6 +246,8 @@ tdPaintWindowWithDepth (CompWindow *w,
bevel = tdGetBevel (s);
+ glGetIntegerv (GL_CULL_FACE_MODE, &cull);
+
if (ww && wh && !(mask & PAINT_WINDOW_OCCLUSION_DETECTION_MASK))
{
TD_WINDOW (w);
@@ -400,7 +402,7 @@ tdPaintWindowWithDepth (CompWindow *w,
WRAP (tds, s, paintWindow, tdPaintWindow);
}
- glCullFace (GL_BACK);
+ glCullFace (cull);
if (!wasCulled)
glDisable (GL_CULL_FACE);