MATLAB Answers

Artifacts in figures exported as PDF from Matlab

66 views (last 30 days)
Alexander Patrushev
Alexander Patrushev on 8 Sep 2011
Commented: Mohsin Shah on 5 Apr 2019
I have very annoying problem. I try to export high quality images with: print -painters -dpdf -r600 Test.pdf
and I used export_fig script as well, but there are always artifacts in figures like thin white lines over cells: Example


izaz ali shah
izaz ali shah on 6 Aug 2018
Hi guys... this is the problem of Pdf viewer, not Matlab. Use Adobe Acrobat reader, then follow the way like this, edit--->preferences-->page display--->rendering and unmark smooth line art.

Sign in to comment.

Answers (2)

Jan on 8 Sep 2011
This is most likely not a problem of Matlab, but of the PDF viewer. If you are using Acrobat Reader, try to disable:
Edit -> Preferences -> Page Display -> Rendering -> Smooth images


Show 7 older comments
Robert James
Robert James on 31 May 2017
The solution I've come up with to this 'white line artefact' problem is to leave everything in the Matlab image export setup as default and export eps figures (with artefacts). Following this I open these in the GIMP image manipulation program and here it provides the option to set any text or image anti-aliasing to none. This can then be exported as an EPS without any of the previous artefacts.
Not a very elegant solution I know, but useful for anyone who's needing to get their Matlab figures in a publication worthy format.
Mohsin Shah
Mohsin Shah on 18 Jul 2018
I checked it with the solution given by Jan but the line is still there in my figure
izaz ali shah
izaz ali shah on 6 Aug 2018
Jan is right but instead of smooth images, unmark smooth line art

Sign in to comment.

Le Kitsune
Le Kitsune on 15 Aug 2017
For me this tool is doing the trick to get rid of the white lines:


Sign in to comment.


Community Treasure Hunt

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

Start Hunting!