MATLAB: Do I receive an “Error Loading OpenGL” message when using the PEAKS command

7500atilaptopMATLABopenglradeon

Since I started using the VillageTronic VTBook card in my laptop to enable a 3rd monitor (laptop screen + 2 others) I occasionally get a message saying there is an error loading OpenGL. After that, anything I do that would cause a dialog box to open hangs Matlab.
The problem seems triggered by the PEAKS function.
>> peaks(30)
Warning: Error occurred while loading OpenGL.
If I issue the OPENGL NEVERSELECT command first before plotting, then I receive no error. If I use the OPENGL SOFTWARE command then I get the same warning as above plus an additional line:
>> peaks(30)
Warning: Error occurred while loading OpenGL.
> In opengl at 75
My graphics card information is:
Version = 1.3.4145 WinXP Release
Vendor = ATI Technologies Inc.
Renderer = MOBILITY RADEON 7500 DDR x86/SSE2
When I type OPENGL INFO to get my graphics card information I received a segmentation violation:
------------------------------------------------------------------------
Segmentation violation detected at Fri May 04 09:17:10 2007
------------------------------------------------------------------------
Register State:
EAX = 00000000 EBX = 00000002
ECX = 00000000 EDX = 00d1dcd8
ESI = 024fd450 EDI = 00000390
EBP = 026859f8 ESP = 00d1dcb8
EIP = 00000000 FLG = 00010246
Stack Trace:
[0] atioglxx.dll:0x69062f1e(560, 420, 0x024fd0c0, 0x024fd0c0)
...

Best Answer

This error is caused by incompatibility issues between MATLAB and the ATI Mobility Radeon 7500 graphics card. To work around this issue, try installing the latest driver or change your graphics card. See the Related Solution listed at the bottom of the page for more details.
<http://www.mathworks.com/support/solutions/data/1-14K4HB.html?solution=1-14K4HB>
Alternatively, a workaround for this is to change the renderer you are using by one of the following two methods:
1) To use either the 'Zbuffer' or 'painters' renderers, please type the following:
set(gcf, 'Renderer','Zbuffer');
or
set(gcf, 'Renderer','painters');
2) Disable the autoselection of OpenGL in MATLAB by typing:
opengl neverselect