On 08/10/2010 04:44 PM, tom fogal wrote: > "Kevin H. Hobbs" <hob...@ohiou.edu> writes: >> >> VTK_USE_X:BOOL=ON is set the test segfaults. > > What does VTK_USE_X change/end up doing? >
Most of the action seems to happen in Rendering/CMakeLists.txt where on linux with VTK_USE_X=ON : vtkXGPUInfoList.cxx is added to the list of sources. vtkXRenderWindowInteractor.cxx is added to the list of sources. cmake options for 3Dconnexion are exposed vtkTestGLX.cmake is included a try compile is made on CheckglXGetProcAddressARB.cxx if OPENGL_gl_LIBRARY is also set vtkXOpenGLRenderWindow.cxx is added to the list of sources. and ${OPENGL_gl_LIBRARY} is added to the required libraries. I'm leaving out stuff that seems to be for wrapping tcl and python. a bunch of likely X11 directories are added to the search path. cmake looks for X11 libraries > It seems like the test should only be calling OSMesa functions. > However, maybe the VTK_USE_X macro forces some "always do this X init" > kind of stuff, even when an X context isn't needed? > > -tom > It's certainly possible. The test only does : vtkRenderWindow *renWin = vtkRenderWindow::New(); renWin->OffScreenRenderingOn(); And I've always found that I have to do : // Graphics Factory vtkGraphicsFactory * graphics_factory = vtkGraphicsFactory::New(); graphics_factory->SetOffScreenOnlyMode( 1); graphics_factory->SetUseMesaClasses( 1 ); // Imaging Factory vtkImagingFactory * imaging_factory = vtkImagingFactory::New(); imaging_factory->SetUseMesaClasses( 1 ); // Render Window vtkRenderWindow * render_window = vtkRenderWindow::New(); render_window->SetOffScreenRendering( 1 ); in order to get an offscreen program to run without DISPLAY set. VTK does have another "offscreen" mode pbuffers or something that still requires a display but can't be overwritten with another window. Maybe this is what's being used in the VTK test. However even if I add the factory lines to VTK's test the segfault happens the same way.
signature.asc
Description: OpenPGP digital signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev