exportgraphics overlay bug when saving
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello,
I'm using exportgraphics to save my figures in high quality. However they do not save in the same manner as they display.
I joined a screenshot of what the figure looks like when it's produced (before saving), and the purple star and red triangle are on top of all the other markers. I payed attention to the order with which I was plotting the different datasets to have them on top. However when I save the figure, the red triangle is behind the other markers. (see png of the screenshot and pdf of the saved figure).
Any ideas on why the display changes and how to fix it ?
Here is the line of code I use to save the figure
exportgraphics(fig,[REPS.rep_out,'fig_map.pdf'],'ContentType','vector','BackgroundColor','none')
Thanks a lot
0 Kommentare
Antworten (1)
Richard Quist
am 24 Nov. 2021
I suspect you're seeing a difference in behavior between the painters renderer (used when generating "true vector" output when ContentType is 'vector') and the onscreen OpenGL renderer. Setting the onscreen figure renderer to painters will likely show the same issue, but then you can try adjusting the line to raise the marker up, perhaps by setting the ZData of the line that has the red marker
0 Kommentare
Siehe auch
Kategorien
Mehr zu Printing and Saving finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!