MantisBT - ParaView
View Issue Details
0015843ParaView(No Category)public2015-11-18 20:312016-01-08 15:32
Alan Scott 
Utkarsh Ayachit 
normalminorhave not tried
closedfixed 
5.0 
5.05.0 
TBD
crash
0015843: RC1 5.0 fails running normal, new, powerful Mesa
I have a remote build of PV 5.5.0, RC1. When I run ParaView, I get the following in the output window:

Warning: In /projects/viz/paraview/src/ParaView/5.0.0-junk/ParaView4/VTK/Rendering/OpenGL2/vtkOpenGLRenderWindow.cxx, line 549
vtkOSOpenGLRenderWindow (0x1451d00): VTK is designed to work with OpenGL version 3.2 but it appears it has been given a context that does not support 3.2. VTK will run in a compatibility mode designed to work with OpenGL 2.1 but some features may not work.

I then try to open a cylinder, and get the following on the client side:


ERROR: In /projects/viz/paraview/src/ParaView/5.0.0-junk/ParaView4/VTK/Rendering/OpenGL2/vtkShaderProgram.cxx, line 370
vtkShaderProgram (0x4005bd0): 0:2(12): error: extension `GL_EXT_gpu_shader4' unsupported in fragment shader



ERROR: In /projects/viz/paraview/src/ParaView/5.0.0-junk/ParaView4/VTK/Common/Core/vtkDataArrayTemplate.txx, line 142
vtkUnsignedCharArray (0x62558d0): Unable to allocate 3757531591590 elements of size 1 bytes.

Server side looks like this:

Connecting to client (reverse connection requested)...
Connection URL: csrc://ceerws2213:11111
Client connected.
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4
GL_Version: 3.0 Mesa 11.0.4

and
Warning: In /projects/viz/paraview/src/ParaView/5.0.0-junk/ParaView4/VTK/Rendering/OpenGL2/vtkOpenGLRenderWindow.cxx, line 549
vtkOSOpenGLRenderWindow (0xb26ba0): VTK is designed to work with OpenGL version 3.2 but it appears it has been given a context that does not support 3.2. VTK will run in a compatibility mode designed to work with OpenGL 2.1 but some features may not work.


ERROR: In /projects/viz/paraview/src/ParaView/5.0.0-junk/ParaView4/VTK/Rendering/OpenGL2/vtkShaderProgram.cxx, line 370
vtkShaderProgram (0x4005bd0): 0:2(12): error: extension `GL_EXT_gpu_shader4' unsupported in fragment shader





However!!!!!!!!!!!!

Mesa 11.0.4 is OpenGL 4.1 compliant!

So, what's going on?

Due to stupid stuff in Mesa (internet search says something about patents), Mesa 11.0.4 implements OpenGL 4.1, but a glGetString(GL_VERSION) returns that it is only OGL 3.0 compliant.

Hack to get around it: set MESA_GL_VERSION_OVERRIDE=3.2

But, we must have ParaView work as follows:
* Work with new Mesa, without having to set an environment variable.
* Work with older versions of Mesa (at least for a while), and never, never crash.

No tags attached.
related to 0015842closed Utkarsh Ayachit 5.0.0 RC1 crashes on older graphics cards 
Issue History
2015-11-18 20:31Alan ScottNew Issue
2015-11-18 20:32Alan ScottRelationship addedrelated to 0015842
2015-11-18 20:35Alan ScottNote Added: 0035471
2015-11-18 20:35Alan ScottTarget Version => 5.0
2015-12-01 14:55Ken MartinNote Added: 0035495
2015-12-09 11:09Utkarsh AyachitNote Added: 0035526
2015-12-09 11:09Utkarsh AyachitStatusbacklog => gatekeeper review
2015-12-09 11:09Utkarsh AyachitFixed in Version => git-master
2015-12-09 11:09Utkarsh AyachitResolutionopen => fixed
2015-12-09 11:09Utkarsh AyachitAssigned To => Utkarsh Ayachit
2015-12-14 09:35Utkarsh AyachitStatusgatekeeper review => customer review
2015-12-14 15:22Alan ScottNote Added: 0035553
2015-12-14 15:22Alan ScottStatuscustomer review => closed
2016-01-08 15:32Utkarsh AyachitFixed in Versiongit-master => 5.0

Notes
(0035471)
Alan Scott   
2015-11-18 20:35   
OK to make project Sandia if appropriate.
(0035495)
Ken Martin   
2015-12-01 14:55   
Yes, so MESA seems like an odd beast in that Mesa supports recent OpenGL versions but some of its drivers do not. I believe the pure software driver works fine. This page shows a nice list of drivers that do support all that we need

https://secure.freedesktop.org/~imirkin/glxinfo/glxinfo.html#v=Mesa%2011.0.0 [^]

but we still need to gracefully handle the case where Mesa is using a hardware accelerated driver that is tied to old hardware. I have made the SupportsOpenGL() method work in VTK/OpenGL2 so that PV should be able to gracefully query for support prior to trying to render and handle it nicely. With that we should be able to track down what Mesa drivers are causing issues.
(0035526)
Utkarsh Ayachit   
2015-12-09 11:09   
https://gitlab.kitware.com/paraview/paraview/merge_requests/511 [^]

commit de35af0f480253442ea209e62dc311bda919296e
Author: Utkarsh Ayachit <utkarsh.ayachit@kitware.com>
Date: Wed Dec 9 11:00:41 2015 -0500

    BUG 0015843: Add support to test OpenGL version.
    
    Added checks during initialization of a session to validate OpenGL
    version support. If not adequate a dialog will be popped up warning
    about the same. If the OpenGL version of server side alone is
    inadequate, then remote rendering is disabled. If OpenGL version on
    client is inadequate, then we pop up a dialog and abort.
(0035553)
Alan Scott   
2015-12-14 15:22   
Much better.

Tested Linux, master, remote server (Chama).