I'm trying to export figures into pdf, and the results looks good in Preview, but very bad in Adobe pdf reader. I'm using Mathematica version 8 on Mac 10.8.5. The Preview version is 6.0.1 (765.6) and the Adobe PDF Reader version is

For a simple three point polygon, it looks good in both pdf viewer

Graphics3D[{Red, Opacity[0.15], EdgeForm[Lighter[Black, 0.8]], 
  Polygon[{{1, 0, 0}, {1, 1, 1}, {0, 0, 1}}]}, Boxed -> False]
Export["~/Downloads/12345.pdf", %, ImageResolution -> 100]

enter image description here

but for polygon with more points, it looks very bad in Adobe reader

Graphics3D[{Red, Opacity[0.15], EdgeForm[Lighter[Black, 0.8]], 
  Polygon@Join[{{-1, 0, 0}}, 
    Table[{-1, t, Cos[t]^2}, {t, 0, \[Pi]/2, 0.01}]]}, 
 BoxRatios -> {1, 1, 0.5}, Boxed -> False, ViewPoint -> Right]
Export["~/Downloads/1234.pdf", %, ImageResolution -> 100]

enter image description here

Why they looks different in the two pdf viewer and is there a way to fix it so that pdf figure works in both pdf viewers?

  • $\begingroup$ Looks bad in Adobe Reader? Strange... usually, my issues are with Preview. FWIW, it looks equally bad on both viewers here (same versions, with mma 9.0.1). $\endgroup$ – rm -rf Oct 4 '13 at 22:48
  • $\begingroup$ For a workaround, I tried the Export["1234.svg", %] instead, then used inskscape to convert to PDF and the problem does not seem to show up on my screen. But you can try it, as a workaround. Here are the steps mathematica.stackexchange.com/questions/29797/… $\endgroup$ – Nasser Oct 4 '13 at 23:49
  • 2
    $\begingroup$ Mathematica 8 often produces PDF files with syntactic errors in the code. You can use free Poppler utilities to fix this. $\endgroup$ – Alexey Popkov Oct 4 '13 at 23:54
  • $\begingroup$ Another useful tool for converting svg to something more useful is cairosvg. $\endgroup$ – shrx Oct 5 '13 at 10:18
  • $\begingroup$ I'd agree that this looks like an (opacity-related?) bug in Mathematica v. 9.0.1 on Mac OS X. $\endgroup$ – cormullion Oct 5 '13 at 18:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.