Article View: comp.windows.x
Article #38297Re: Having hard time using XGetImage with glDrawPixels in OpenGL
From: Andre Beck
Date: Mon, 19 May 1997 00:00
Date: Mon, 19 May 1997 00:00
36 lines
2256 bytes
2256 bytes
Shuky Rosinger wrote: > > Hi all, > > I am having a very hard time drawing pixel data with glDrawPixels onto > an OpenGL scene. I use glDrawPixels with GL_RGB, GL_UNSIGNED_BYTE. The > image is retrieved with XGetImage. > > The resulting image in the OpenGL scene is somehow not synchronized (has > the effect of a TV has bad horizontal sync or vertical sync). > > I am using Linux with Mesa 2.2. I use 16bpp display with visual of depth > 16. > > Does anyone know what I am doing wrong or what I have to do to make it > work? * Prior to calling XGetImage(3X), call XSync(3X). * Are you drawing to a window or pixmap ? When drawing to a window, it is almost unpredictable what you will get back with XGetImage(3X). If, e.g. the window is partially overlapped by others and/or off-screen, you wont get anything from there - these areas are clipped already upon drawing. -- "Security issues are discussed throughout this memo." -- RFC 1984 +-o-+--------------------------------------------------------+-o-+ | o | \\\- Brain Inside -/// | o | | o | ^^^^^^^^^^^^^^ | o | | o | Andre' Beck (ABPSoft) beck@ibh-dd.de XLink PoP Dresden | o | +-o-+--------------------------------------------------------+-o-+
Technical Details
Message-ID:
<33806114.77C48518@ibh-dd.de>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<337FFE27.E564C73@numbat.cs.rmit.edu.au>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f6cac,610edefeb235a8b3 X-Google-Attributes: gidf6cac,public X-Google-Thread: 1667f1,610edefeb235a8b3 X-Google-Attributes: gid1667f1,public X-Google-Thread: 103734,610edefeb235a8b3 X-Google-Attributes: gid103734,public X-Google-Thread: f4bda,610edefeb235a8b3 X-Google-Attributes: gidf4bda,public X-Google-Thread: f65bb,610edefeb235a8b3 X-Google-Attributes: gidf65bb,public X-Google-Thread: 1082b0,610edefeb235a8b3 X-Google-Attributes: gid1082b0,public From: Andre Beck <beck@ibh-dd.de> Subject: Re: Having hard time using XGetImage with glDrawPixels in OpenGL Date: 1997/05/19 Message-ID: <33806114.77C48518@ibh-dd.de> X-Deja-AN: 242394059 References: <337FFE27.E564C73@numbat.cs.rmit.edu.au> Organization: ABPSoft @Home Newsgroups: comp.windows.x,comp.os.linux.x,comp.graphics.api.opengl,comp.windows.x.i386unix,fj.windows.x,de.comp.os.linux.x