Hardware based OpenGL on Linux
96 次查看(过去 30 天)
显示 更早的评论
I am unable to get hardware based OpenGL since the change to HG2 (i.e., R2014b and R2015a) on Linux. Prior to that, I can use hardware based OpenGL. Specifically,
>> opengl info
Version: '3.0 Mesa 10.6.5'
Vendor: 'Intel Open Source Technology Center'
Renderer: 'Mesa DRI Intel(R) Sandybridge Mobile '
MaxTextureSize: 8192
Visual: 'Visual 0xac, (RGBA 32 bits (8 8 8 8), Z depth 16 bits, Hardware acceleration, Double buffer, Antialias 4 samples)'
Software: 'true'
SupportsGraphicsSmoothing: 1
SupportsDepthPeelTransparency: 1
SupportsAlignVertexCenters: 1
Extensions: {199x1 cell}
MaxFrameBufferSize: 8192
I was expecting/wanting "Software" to be false.
$ ldd /opt/tmw/matlab/bin/glnxa64/glren.so | grep libGL
libGL.so.1 => /usr/lib/libGL.so.1 (0x00007f0a3b871000)
libGLU.so.1 => /usr/lib/libGLU.so.1 (0x00007f0a3b5ef000)
suggests that MATLAB is finding the system libraries (which is what TMW says I want) and TMW confirms that the library versions libGL.so.1.2.0 and libGLU.so.1.3.1 are compatible. I have been in contact with TMW technical support and they have decided it is not a MATLAB issue despite
$ glxinfo | grep render
direct rendering: Yes
OpenGL renderer string: Mesa DRI Intel(R) Sandybridge Mobile
suggesting hardware based OpenGL is working outside MATLAB. I have done most of my testing on Arch Linux with an Intel graphics card, but have also tried ATI and Nvidia cards. I recently installed MATLAB into a Debian 7 chroot with the Intel card. Despite Debian 7 being listed as a supported OS, I still have no luck.
Can anyone get MATLAB R2014b/R2015a to use hardware based OpenGL on Linux? Any ideas of where I should look?
2 个评论
Pedro Brito
2015-9-4
编辑:Pedro Brito
2015-9-4
I'm having the same problem, just installed R2015a, I'm also running Arch Linux:
Version: '3.0 Mesa 10.6.5'
Vendor: 'Intel Open Source Technology Center'
Renderer: 'Mesa DRI Intel(R) HD Graphics 5500 (Broadwell GT2) '
MaxTextureSize: 8192
Visual: 'Visual 0xd5, (RGBA 32 bits (8 8 8 8), Z depth 16 bits, Hardware acceleration, Double buffer, Antialias 8 samples)'
Software: 'true'
SupportsGraphicsSmoothing: 1
SupportsDepthPeelTransparency: 1
SupportsAlignVertexCenters: 1
Extensions: {207x1 cell}
MaxFrameBufferSize: 8192
and
direct rendering: Yes
OpenGL renderer string: Mesa DRI Intel(R) HD Graphics 5500 (Broadwell GT2)
and
libGL.so.1 => /usr/lib/libGL.so.1 (0x00007f7033bc4000)
libGLU.so.1 => /usr/lib/libGLU.so.1 (0x00007f7033942000)
Maurizio
2016-5-4
I have the same problem with Matlab R2015a.
Version: '3.0 Mesa 10.1.3'
Vendor: 'Intel Open Source Technology Center'
Renderer: 'Mesa DRI Intel(R) Haswell Desktop '
MaxTextureSize: 8192
Visual: 'Visual 0x20, (RGBA 32 bits (8 8 8 8), Z depth 16 bits, Hardware acceleration, Double buffer, Antialias 8 samples)'
Software: 'true'
SupportsGraphicsSmoothing: 1
SupportsDepthPeelTransparency: 1
SupportsAlignVertexCenters: 1
Extensions: {188x1 cell}
MaxFrameBufferSize: 8192
and the output
$ ldd /opt/Matlab/bin/glnxa64/glren.so | grep libGL
libGL.so.1 => /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1 (0x00007fb5c1c5f000)
libGLU.so.1 => /usr/lib/x86_64-linux-gnu/libGLU.so.1 (0x00007fb5c19f1000)
and
$ glxinfo | grep render
direct rendering: Yes
OpenGL renderer string: Mesa DRI Intel(R) Haswell Desktop
Did you find a way to solve it? Also, I would be interested if you encountered any other problems possibly related to the graphic card while plotting simple 2D graphs ((randomly) crash of Matlab, computer freezes, etc.)?
回答(3 个)
Willi Mutschler
2020-4-12
Hi,
I am on Ubuntu 20.04 beta and running the nvidia on-demand prime profile, and get the same error. I can solve this (see the Archwiki) by starting matlab from terminal:
export MESA_LOADER_DRIVER_OVERRIDE=i965; matlab
Or (additionaly) you can change the EXEC in /usr/share/applications/matlab.desktop to:
Exec=env MESA_LOADER_DRIVER_OVERRIDE=i965 matlab -desktop
4 个评论
Willie Smit
2021-3-4
编辑:Willie Smit
2021-3-4
export MESA_LOADER_DRIVER_OVERRIDE=i965; matlab
worked for me on Matlab 2019b and Ubuntu 20.04. Thanks WM.
Willi Mutschler
2020-4-26
I also ran into this issue on my Dell XPS 13 9360 which neither has a NVIDIA or AMD card, but an on-board intel graphics card.
I filed a bug report with MATHWORKS and they proposed two solutions:
- Create a file with the name 'java.opts' in the directory where MATLAB is executed (for me this is in '/usr/local/MATLAB/R2020a/bin/glnxa64') with the following line: -Djogl.disable.openglarbcontext=1
- If this does not work, then the above solution using export MESA_LOADER_DRIVER_OVERRIDE=i965 is working.
For me both solve my issue.
0 个评论
Rick Irons
2016-5-4
In the three cases listed previously hardware accelerated versions of Mesa are in fact being used. The problem is that the value of the OpenGL info 'software' field is actually incorrect. This issue has been fixed in R2016a.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Startup and Shutdown 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!