All,
I just thought I'd share this slight improvement to the code to help with
debugging why GPU rendering fails. Maybe this can get into the source?
In ParaView3/VTK/VolumeRendering/vtkOpenGLGPUVolumeRayCastMapper.cxx
vtkOpenGLGPUVolumeRayCastMapper::PreRender, I've added extra code to handle
an unsupported driver and report it to the user.
// If we can't load the necessary extensions, provide
// feedback on why it failed.
if(!this->LoadExtensionsSucceeded)
{
const char *gl_vendor=reinterpret_cast<const char
*>(glGetString(GL_VENDOR));
const char *gl_version=reinterpret_cast<const char
*>(glGetString(GL_VERSION));
vtkErrorMacro(
"Rendering failed because the following OpenGL extensions "
"are required but not supported: " <<
(this->UnsupportedRequiredExtensions->Stream.str()).c_str() <<
"\n or the " << gl_vendor << " " << gl_version << " OpenGL
implementation is not supported for GPU rendering"
);
return;
}
In 3.9.0 an error was reported about extensions but it did not indicate what
OpenGL driver it found (e.g. Mesa and ATI libraries are not handled). The
new error output looks like the following:
ERROR: In
/scratch/pmcintos/ParaView3/VTK/VolumeRendering/vtkOpenGLGPUVolumeRayCastMap
per.cxx, line 4207
vtkOpenGLGPUVolumeRayCastMapper (0x18a06460): Rendering failed because the
following OpenGL extensions are required but not supported:
or the Mesa Project 1.4 (2.1 Mesa 7.6.1) OpenGL implementation is not
supported for GPU rendering
Hope this helps someone :)
Cheers,
Paul
---
www.internetscooter.com
_______________________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the ParaView Wiki at:
http://paraview.org/Wiki/ParaView
Follow this link to subscribe/unsubscribe:
http://www.paraview.org/mailman/listinfo/paraview