MATLAB graphics issue: Figure/plot is not displaying or updating correctly

I am facing an issue with MATLAB graphics where my figure/plot does not appear as expected. The code executes without any major errors, but the graphical output is either not displayed correctly, does not update properly, or appears different from what I expect.
I have already tried using figure, hold on, drawnow, and close all, but the issue still persists.
What could be causing this graphics issue in MATLAB, and what is the recommended way to fix it?

 Accepted Answer

Graphics issues such as figures not displaying correctly, failing to update, or appearing differently than expected can sometimes be related to the graphics rendering configuration or graphics drivers rather than the plotting code itself. As a troubleshooting step, please run:
opengl info
and review the output. If the issue appears to be graphics-related, try switching MATLAB to software OpenGL using:
opengl('save','software')
then restart MATLAB and check whether the behavior changes. It may also be helpful to test with a simple example such as:
figure;
plot(1:10);

2 Comments

troubleshooting steps worked for me, thanks
Product Version Notes for R2025a includes:
The opengl function issues a warning that it will be removed in a future release. Calling the function has no effect and returns no output.
MATLAB no longer uses OpenGL technology to render graphics, so you no longer need to set the renderer in your graphics workflows.
As of R2026a, it was entirely removed.
One guesses you then tried rendererinfo instead and it provided some useful feedback?
It would probably be helpful to indicate, what, specifically, was the issue and how it was resolved to help anybody else who may come across this thread going forward....

Sign in to comment.

More Answers (0)

Categories

Products

Release

R2025b

Asked:

on 19 Aug 2026

Edited:

dpb
on 19 Aug 2026

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!