[vtk-developers] GLXPixmap vs OSMesa

Jeff Lee jeff at cdnorthamerica.com
Thu Mar 10 17:01:49 EST 2005


Hi All,
I have been tooling around with glpixap for offscreen rendering.  I 
started with vtkXOpenGLRenderWindow and managed to strip out the osmesa 
stuff and replace its implementation with rendering to a glxpixmap 
instead (a'la John Schalf and Glenn Lehmann).  All of this works great, 
all I have to do is call SetOffScreenRendering(1) on the renderWindow, 
and then I can dump the image to a file.  Eventually I can have it such 
that switching between onscreen/offscreen will work similar to windows.  
I can also see a pbuffer implementation as a straightforward extension 
of this.

The question is, can anyone see any major drawbacks of dropping osmesa 
for this approach?  The benefits that I can see are;

   1. No more mangled mesa, this approach (glxPixmap)  works both in
      mesa and in hardware drivers.
   2. We can stop tiling the display to get high-resolution images.
   3. Similar behavior to that of vtkWin32OpenGLRenderWindow.
   4. Can further extend to hardware-accelerated pbuffers with drivers
      that support it.

Possible Drawbacks:

   1. Perhaps not everyone has a driver which supports glx1.3.
   2. glxpixmap is slow (not when compared to osmesa).

I would like to eventually replace what's in vtkXOpenGLRenderWindow with 
glxpixmap.  Does anyone have other arguments which I am perhaps not 
seeing, or reasons for not doing this?  Thanks in advance.
Regards,
Jeff

-- 
Jeff Lee
Senior Software Engineer
Computational Dynamics North America Ltd
21 Lafayette Street, Suite 230
Lebanon NH 03766 USA
fax:   603 643 9994
phone: 603 643 9993 x109
http://www.cd-adapco.com




More information about the vtk-developers mailing list