summaryrefslogtreecommitdiffstats
path: root/src/glx
diff options
context:
space:
mode:
authorAdam Jackson <[email protected]>2012-01-03 14:39:28 -0500
committerAdam Jackson <[email protected]>2012-01-04 11:23:55 -0500
commit2af17433b5b037af99198acfac567c57618286c3 (patch)
tree43ea02282c13fdfc06bbf1e1156416c8afd36e70 /src/glx
parent892a2542a3f0753a7064c710b96f077dd5490624 (diff)
drisw: Fix drawable creation against non-default screens
We don't want to match the visual against the default screen. If the drawable is on a non-default screen then the appropriate visual might not exist on the default screen. Conversely, if the same visual is available on multiple screens then simply selecting for the right VID is sufficient, since the server has promised that the same visual is compatible with multiple screens. Reviewed-by: Ian Romanick <[email protected]> Signed-off-by: Adam Jackson <[email protected]>
Diffstat (limited to 'src/glx')
-rw-r--r--src/glx/drisw_glx.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/glx/drisw_glx.c b/src/glx/drisw_glx.c
index 2d83a50352b..833ea7d4cc1 100644
--- a/src/glx/drisw_glx.c
+++ b/src/glx/drisw_glx.c
@@ -87,9 +87,8 @@ XCreateDrawable(struct drisw_drawable * pdp,
XChangeGC(dpy, pdp->swapgc, GCGraphicsExposures, &gcvalues);
/* visual */
- visTemp.screen = DefaultScreen(dpy);
visTemp.visualid = visualid;
- visMask = (VisualScreenMask | VisualIDMask);
+ visMask = VisualIDMask;
pdp->visinfo = XGetVisualInfo(dpy, visMask, &visTemp, &num_visuals);
/* create XImage */