MRtrix3 / mrtrix3

MRtrix3 provides a set of tools to perform various advanced diffusion MRI analyses, including constrained spherical deconvolution (CSD), probabilistic tractography, track-density imaging, and apparent fibre density
http://www.mrtrix.org
Mozilla Public License 2.0
290 stars 179 forks source link

GLSL issue on CentOS 6 #50

Closed IanLuff closed 10 years ago

IanLuff commented 10 years ago

I've just built mrtrix3 on CentOS 6 and get the following error when launching mrview:

GLSL log [vertex shader]: 0:1(10): error: GLSL 3.30 is not supported. Supported versions are: 1.10, and 1.20

mrview [ERROR]: error compiling vertex shader

which seems a bit surprising given that OpenGL version > 3 is a requirement.

Any pointers?

I can provide the list of libraries the binary links to if required.

jdtournier commented 10 years ago

OpenGL > 3.3 is a run-time requirement, but not a hard compile-time requirement. You should have got a warning about it when you ran the configure script, though. The reason why we don't prevent a build in this case is to allow building the binaries on a headless server, which obviously won't have an OpenGL environment at all, but could be used to create packages or do nightly builds, etc.

I should also point out that OpenGL is a bit strange on that front. The basic OpenGL 1.1 is the only thing that is required to compile the code - all the additional versions and extensions are actually loaded at run-time. This quite different from traditional libraries where the compilation simply won't work if the right version isn't there.

So in your case, it looks like your CentOS environment doesn't support OpenGL 3 at all. You can check what version you actually have with this command:

glxinfo | grep 'OpenGL version string'

Note also that you will not be able to run MRView over a remote X11 connection or within a virtual machine - these scenarios don't cater for OpenGL3 at all. If you really need to run MRView remotely, you might be able to run it over xvnc or a similar protocol, but this is just a guess. In any case, it shouldn't really matter all that much since it's quite easy to install MRtrix locally on all platforms anyway.

IanLuff commented 10 years ago

Thanks for the explanation. I should have realised it was a runtime issue.

I was running in a VNC session. CentOS 6's support for OpenGL in VNC is more comprehensive than CentOS 5, but it's still version 2 and there are omissions. For the record:

glxinfo | grep 'OpenGL version string' OpenGL version string: 2.1 Mesa 9.2.0-devel

I'll try using a real display.

jdtournier commented 10 years ago

OK, you should still be able to remote display over VNC if you have a decent graphics card and driver installed (e.g. NVIDIA with proprietary drivers, AMD with fglrx drivers), and the VNC session is able to make use of it. I just came across this discussion which might give you some pointers: http://serverfault.com/questions/174003/how-can-opengl-graphics-be-displayed-remotely-using-vnc

IanLuff commented 10 years ago

Thanks again. VirtualGL would be my next step if it runs OK on the hardware.

jdtournier commented 10 years ago

OK, I'll close this for now then.