summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Staplin <gstaplin@apple.com>2008-11-09 18:35:10 -0700
committerJeremy Huddleston <jeremyhu@freedesktop.org>2008-11-13 01:19:43 -0800
commit33edd32702d963802e64d382124eabb9d0352fa8 (patch)
tree271bee93af06ac4355984dac238005023ac490b4
parent1523476afa6657c20eba112e3ee051d45e721164 (diff)
XQuartz: Disable 2 calls to miSetVisualTypesAndMasks that seem to be unnecessary, and possibly wrong (with regard to masks and bits per RGB).
Use the settings queried from the system in xprScreen.c, rather than those 2 calls. The 2 calls increased the total number of visuals a great deal (when using GLXEXT), and not all of the visuals were usable with GLX. Some of the visuals aren't usable with GLX still, such as DirectColor, but that seems to be acceptable based on my understanding of the manual that states "a subset of visuals are made available for OpenGL rendering." (cherry picked from commit 373b8a5f32509722e06d8776109e6c3f06645ee0)
-rw-r--r--hw/xquartz/darwin.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/hw/xquartz/darwin.c b/hw/xquartz/darwin.c
index 0dd127963..2959a44eb 100644
--- a/hw/xquartz/darwin.c
+++ b/hw/xquartz/darwin.c
@@ -221,10 +221,17 @@ static Bool DarwinAddScreen(int index, ScreenPtr pScreen, int argc, char **argv)
// TODO: Make PseudoColor visuals not suck in TrueColor mode
// if(dfb->depth > 8)
// miSetVisualTypesAndMasks(8, PseudoColorMask, 8, PseudoColor, 0, 0, 0);
+
+#if 0
+ /*
+ * These aren't used anymore. xpr/xprScreen.c initializes the dfb struct
+ * above based on the display properties.
+ */
if(dfb->depth > 15)
miSetVisualTypesAndMasks(15, LARGE_VISUALS, 5, TrueColor, 0x7c00, 0x03e0, 0x001f);
if(dfb->depth > 24)
miSetVisualTypesAndMasks(24, LARGE_VISUALS, 8, TrueColor, 0x00ff0000, 0x0000ff00, 0x000000ff);
+#endif
miSetPixmapDepths();