6

I have created some vector graphic in Adobe Illustrator that I want to include in my latex document.

Whenever I export the vector from Illustrator with compatibility set to PDF 1.4 or above, the figure is missing certain elements or objects in the compiled latex output. Drop shadow is an example of such a missing object.

If I export it with PDF 1.3 compatibility, however, it works fine. Setting the compatibility to PDF 1.3 is not a solution because it messes with the quality of many of my figures.

The objects are only missing with some pdf viewers, though. They are not missing with Google Chrome, but are missing with Preview on MacOS. Viewing the included pdf's directly, works fine too. It is only in the compiled latex output objects are missing.

I am using pdfTeX 3.14159265-2.6-1.40.18 (TeX Live 2017).

Any ideas?

EDIT:

An example of the included pdf is this, and the produced output is this.

\documentclass[12pt, a4paper, english]{report}
\usepackage[utf8]{inputenc}
\usepackage{caption, graphicx}


\begin{document}
testing...

\begin{figure}[htb!]
  \centering
  \includegraphics[width=9cm]{osa}
  \caption{test-figure}
  \label{some-label}
\end{figure}
\end{document}

1 Answers1

1

Including pdfs which contain semi-transparent shapes often causes problems with the compiled document in Mac Preview.

I tested a couple of workarounds and the following two seems to work for your image, however they will both result in a rasterized image:

  • based on https://tex.stackexchange.com/a/166123/36296 you could use ghostscript to sanitize the image

    ps2pdfwr -dCompatibilityLevel=1.4 -dHaveTransparency=false osa.pdf sanitized.pdf
    
  • convert the image to ps (psd2ps osa.pdf) and back (pdf2ps oas.ps)

enter image description here