Inconsistent Figure Behavior if Saved While Figure is Visible vs Saved While Figure is Hidden
Show older comments
I have run into an issue where I get a different saved png output if I save a figure while it is set to visible compared to when I save the same figure as it is set to invisible. The visibility component is important, as I intent for this section of code to live in a function that will be used in a parfor which by nature does not allow for figures to be visible.
The sample code uses two sets of axes to plot a PNG background image with a geoscatter layer on top of it. The image layer does not seem to be affected by this issue, but the geoscatter shows a change in the point size, a scaling of the colorbar, and a shift of the plotted data between the two methods. This is demonstrated by the two plots saved by the sample code. The first output 'Visible.png' behaves as expected and is exactly what I see if I manually save the figure, but by simply turning off the visibility and resaving this as 'Hidden.png' I get a noticeably different output.
I do not know if this is a bug, or if there is some lower level setting that I am overlooking somewhere. Ive gone through every local resource I have available to me and have so far come up empty.


Accepted Answer
More Answers (0)
Categories
Find more on Geographic Plots in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!