summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/x11/xm_span.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/x11/xm_span.c')
-rw-r--r--src/mesa/drivers/x11/xm_span.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/src/mesa/drivers/x11/xm_span.c b/src/mesa/drivers/x11/xm_span.c
index ab66c5e1f12..294b93a57cc 100644
--- a/src/mesa/drivers/x11/xm_span.c
+++ b/src/mesa/drivers/x11/xm_span.c
@@ -42,7 +42,6 @@
* generate BadMatch errors if the drawable isn't mapped.
*/
-#ifndef XFree86Server
static int caught_xgetimage_error = 0;
static int (*old_xerror_handler)( XMesaDisplay *dpy, XErrorEvent *ev );
static unsigned long xgetimage_serial;
@@ -87,7 +86,6 @@ static int check_xgetimage_errors( void )
/* return 0=no error, 1=error caught */
return caught_xgetimage_error;
}
-#endif
/*
@@ -97,7 +95,6 @@ static unsigned long read_pixel( XMesaDisplay *dpy,
XMesaDrawable d, int x, int y )
{
unsigned long p;
-#ifndef XFree86Server
XMesaImage *pixel = NULL;
int error;
@@ -113,9 +110,6 @@ static unsigned long read_pixel( XMesaDisplay *dpy,
if (pixel) {
XMesaDestroyImage( pixel );
}
-#else
- (*dpy->GetImage)(d, x, y, 1, 1, ZPixmap, ~0L, (pointer)&p);
-#endif
return p;
}
@@ -3763,7 +3757,6 @@ static void put_values_ci_ximage( PUT_VALUES_ARGS )
/***** Pixel reading *****/
/**********************************************************************/
-#ifndef XFree86Server
/**
* Do clip testing prior to calling XGetImage. If any of the region lies
* outside the screen's bounds, XGetImage will return NULL.
@@ -3806,7 +3799,6 @@ clip_for_xgetimage(struct gl_context *ctx, XMesaPixmap pixmap, GLuint *n, GLint
}
return 0;
}
-#endif
/*
@@ -3824,7 +3816,6 @@ get_row_ci(struct gl_context *ctx, struct gl_renderbuffer *rb,
y = YFLIP(xrb, y);
if (xrb->pixmap) {
-#ifndef XFree86Server
XMesaImage *span = NULL;
int error;
int k = clip_for_xgetimage(ctx, xrb->pixmap, &n, &x, &y);
@@ -3850,11 +3841,6 @@ get_row_ci(struct gl_context *ctx, struct gl_renderbuffer *rb,
if (span) {
XMesaDestroyImage( span );
}
-#else
- (*xmesa->display->GetImage)(xrb->drawable,
- x, y, n, 1, ZPixmap,
- ~0L, (pointer)index);
-#endif
}
else if (xrb->ximage) {
XMesaImage *img = xrb->ximage;
@@ -3882,14 +3868,6 @@ get_row_rgba(struct gl_context *ctx, struct gl_renderbuffer *rb,
/* Read from Pixmap or Window */
XMesaImage *span = NULL;
int error;
-#ifdef XFree86Server
- span = XMesaCreateImage(xmesa->xm_visual->BitsPerPixel, n, 1, NULL);
- span->data = (char *)MALLOC(span->height * span->bytes_per_line);
- error = (!span->data);
- (*xmesa->display->GetImage)(xrb->drawable,
- x, YFLIP(xrb, y), n, 1, ZPixmap,
- ~0L, (pointer)span->data);
-#else
int k;
y = YFLIP(xrb, y);
k = clip_for_xgetimage(ctx, xrb->pixmap, &n, &x, &y);
@@ -3900,7 +3878,6 @@ get_row_rgba(struct gl_context *ctx, struct gl_renderbuffer *rb,
span = XGetImage( xmesa->display, xrb->pixmap,
x, y, n, 1, AllPlanes, ZPixmap );
error = check_xgetimage_errors();
-#endif
if (span && !error) {
switch (xmesa->pixelformat) {
case PF_Truecolor: