From 808809b061e2ffa57b7d09cedbd57a190855100c Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Wed, 7 Jun 2006 14:01:31 +0000 Subject: [PATCH] updated Pixmap vs. XImage info --- docs/xlibdriver.html | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/docs/xlibdriver.html b/docs/xlibdriver.html index 6bb6532533b..d95f4d579c6 100644 --- a/docs/xlibdriver.html +++ b/docs/xlibdriver.html @@ -70,17 +70,26 @@ Here are some examples:

Double Buffering

-Mesa can use either an X Pixmap or XImage as the backbuffer when in -double buffer mode. Using GLX, the default is to use an XImage. The -MESA_BACK_BUFFER environment variable can override this. The valid -values for MESA_BACK_BUFFER are: Pixmap and XImage -(only the first letter is checked, case doesn't matter). +Mesa can use either an X Pixmap or XImage as the back color buffer when in +double-buffer mode. +The default is to use an XImage. +The MESA_BACK_BUFFER environment variable can override this. +The valid values for MESA_BACK_BUFFER are: Pixmap and +XImage (only the first letter is checked, case doesn't matter).

-A pixmap is faster when drawing simple lines and polygons while an -XImage is faster when Mesa has to do pixel-by-pixel rendering. If you -need depth buffering the XImage will almost surely be faster. +Using XImage is almost always faster than a Pixmap since it resides in +the application's address space. +When glXSwapBuffers() is called, XPutImage() or XShmPutImage() is used +to transfer the XImage to the on-screen window. +

+

+A Pixmap may be faster when doing remote rendering of a simple scene. +Some OpenGL features will be very slow with a Pixmap (for example, blending +will require a round-trip message for pixel readback.) +

+

Experiment with the MESA_BACK_BUFFER variable to see which is faster for your application.