summaryrefslogtreecommitdiff
path: root/xc/programs/Xserver/hw/vfb/InitOutput.c
diff options
context:
space:
mode:
Diffstat (limited to 'xc/programs/Xserver/hw/vfb/InitOutput.c')
-rw-r--r--xc/programs/Xserver/hw/vfb/InitOutput.c41
1 files changed, 39 insertions, 2 deletions
diff --git a/xc/programs/Xserver/hw/vfb/InitOutput.c b/xc/programs/Xserver/hw/vfb/InitOutput.c
index 7d2b6a879..378728c0c 100644
--- a/xc/programs/Xserver/hw/vfb/InitOutput.c
+++ b/xc/programs/Xserver/hw/vfb/InitOutput.c
@@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization
from The Open Group.
*/
-/* $XFree86: xc/programs/Xserver/hw/vfb/InitOutput.c,v 3.20 2001/12/14 19:59:45 dawes Exp $ */
+/* $XFree86: xc/programs/Xserver/hw/vfb/InitOutput.c,v 3.22 2003/01/15 02:34:07 torrey Exp $ */
#if defined(WIN32)
#include <X11/Xwinsock.h>
@@ -113,6 +113,7 @@ typedef enum { NORMAL_MEMORY_FB, SHARED_MEMORY_FB, MMAPPED_FILE_FB } fbMemType;
static fbMemType fbmemtype = NORMAL_MEMORY_FB;
static char needswap = 0;
static int lastScreen = -1;
+static Bool Render = TRUE;
#define swapcopy16(_dst, _src) \
if (needswap) { CARD16 _s = _src; cpswaps(_s, _dst); } \
@@ -223,6 +224,22 @@ void
DarwinHandleGUI(int argc, char *argv[])
{
}
+
+void GlxExtensionInit();
+void GlxWrapInitVisuals(void *procPtr);
+
+void
+DarwinGlxExtensionInit()
+{
+ GlxExtensionInit();
+}
+
+void
+DarwinGlxWrapInitVisuals(
+ void *procPtr)
+{
+ GlxWrapInitVisuals(procPtr);
+}
#endif
void
@@ -240,6 +257,10 @@ ddxUseMsg()
{
ErrorF("-screen scrn WxHxD set screen's width, height, depth\n");
ErrorF("-pixdepths list-of-int support given pixmap depths\n");
+#ifdef RENDER
+ ErrorF("+/-render turn on/of RENDER extension support"
+ "(default on)\n");
+#endif
ErrorF("-linebias n adjust thin line pixelization\n");
ErrorF("-blackpixel n pixel value for black\n");
ErrorF("-whitepixel n pixel value for white\n");
@@ -311,6 +332,18 @@ ddxProcessArgument (argc, argv, i)
return ret;
}
+ if (strcmp (argv[i], "+render") == 0) /* +render */
+ {
+ Render = TRUE;
+ return 1;
+ }
+
+ if (strcmp (argv[i], "-render") == 0) /* -render */
+ {
+ Render = FALSE;
+ return 1;
+ }
+
if (strcmp (argv[i], "-blackpixel") == 0) /* -blackpixel n */
{
Pixel pix;
@@ -910,7 +943,7 @@ vfbScreenInit(index, pScreen, argc, argv)
ret = fbScreenInit(pScreen, pbits, pvfb->width, pvfb->height,
dpix, dpiy, pvfb->paddedWidth,pvfb->bitsPerPixel);
#ifdef RENDER
- if (ret)
+ if (ret && Render)
fbPictureInit (pScreen, 0, 0);
#endif
break;
@@ -977,6 +1010,10 @@ InitOutput(screenInfo, argc, argv)
vfbPixmapDepths[vfbScreens[i].depth] = TRUE;
}
+ /* for RENDER we need 32bpp */
+ if (Render)
+ vfbPixmapDepths[32] = TRUE;
+
for (i = 1; i <= 32; i++)
{
if (vfbPixmapDepths[i])