aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/drivers
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2014-11-29 12:44:10 +0100
committermarha <marha@users.sourceforge.net>2014-11-29 12:44:10 +0100
commit0dbe845b2f4ba08924d6fcb9634d09dc3dde13d6 (patch)
tree4fc0c706447f18bc522bb503273ec9e10f6c2ba5 /mesalib/src/mesa/drivers
parentd17578910169acabae7e67a3da8f26b5ed608ce6 (diff)
parentd6d5581d5fba846c8476ad4d593da662306765d7 (diff)
downloadvcxsrv-0dbe845b2f4ba08924d6fcb9634d09dc3dde13d6.tar.gz
vcxsrv-0dbe845b2f4ba08924d6fcb9634d09dc3dde13d6.tar.bz2
vcxsrv-0dbe845b2f4ba08924d6fcb9634d09dc3dde13d6.zip
Merge remote-tracking branch 'origin/released'
Conflicts: xorg-server/hw/xwin/winclip.c xorg-server/hw/xwin/winengine.c xorg-server/hw/xwin/winfont.c xorg-server/hw/xwin/wingc.c xorg-server/hw/xwin/wingetsp.c xorg-server/hw/xwin/winmisc.c xorg-server/hw/xwin/winnativegdi.c xorg-server/hw/xwin/winpfbdd.c xorg-server/hw/xwin/winpixmap.c xorg-server/hw/xwin/winpolyline.c xorg-server/hw/xwin/winscrinit.c xorg-server/hw/xwin/winsetsp.c xorg-server/hw/xwin/winwindow.c
Diffstat (limited to 'mesalib/src/mesa/drivers')
-rw-r--r--mesalib/src/mesa/drivers/common/meta.c9
-rw-r--r--mesalib/src/mesa/drivers/common/meta.h3
2 files changed, 12 insertions, 0 deletions
diff --git a/mesalib/src/mesa/drivers/common/meta.c b/mesalib/src/mesa/drivers/common/meta.c
index 7a8e627ba..87532c1df 100644
--- a/mesalib/src/mesa/drivers/common/meta.c
+++ b/mesalib/src/mesa/drivers/common/meta.c
@@ -680,6 +680,12 @@ _mesa_meta_begin(struct gl_context *ctx, GLbitfield state)
_mesa_Ortho(0.0, ctx->DrawBuffer->Width,
0.0, ctx->DrawBuffer->Height,
-1.0, 1.0);
+
+ if (ctx->Extensions.ARB_clip_control) {
+ save->ClipOrigin = ctx->Transform.ClipOrigin;
+ save->ClipDepthMode = ctx->Transform.ClipDepthMode;
+ _mesa_ClipControl(GL_LOWER_LEFT, GL_NEGATIVE_ONE_TO_ONE);
+ }
}
if (state & MESA_META_CLIP) {
@@ -1081,6 +1087,9 @@ _mesa_meta_end(struct gl_context *ctx)
_mesa_LoadMatrixf(save->ProjectionMatrix);
_mesa_MatrixMode(save->MatrixMode);
+
+ if (ctx->Extensions.ARB_clip_control)
+ _mesa_ClipControl(save->ClipOrigin, save->ClipDepthMode);
}
if (state & MESA_META_CLIP) {
diff --git a/mesalib/src/mesa/drivers/common/meta.h b/mesalib/src/mesa/drivers/common/meta.h
index 2c9517b14..6ecf3c005 100644
--- a/mesalib/src/mesa/drivers/common/meta.h
+++ b/mesalib/src/mesa/drivers/common/meta.h
@@ -136,6 +136,9 @@ struct save_state
GLfloat ModelviewMatrix[16];
GLfloat ProjectionMatrix[16];
GLfloat TextureMatrix[16];
+ /** GL_ARB_clip_control */
+ GLenum ClipOrigin; /**< GL_LOWER_LEFT or GL_UPPER_LEFT */
+ GLenum ClipDepthMode; /**< GL_NEGATIVE_ONE_TO_ONE or GL_ZERO_TO_ONE */
/** MESA_META_CLIP */
GLbitfield ClipPlanesEnabled;