0

The following displays the .png figure in the pdf but not the .eps figure:

\documentclass[12pt]{article}

\usepackage{graphicx}
\usepackage{epstopdf}

\begin{document}

\begin{figure}[htb]
    \includegraphics[width=5.0in]{mcs.eps}
\end{figure}

\begin{figure}[htb]
    \includegraphics[width=5.0in]{Broncos.png}
\end{figure}

\end{document}

Space is reserved in the pdf for the .eps figure even though it is not displayed. I am using MikTeX 2.9 and TeXMaker 5.0.4. Any thoughts would be appreciated.

Craig
  • 1
  • Welcome to TeX.SX! Because .png is natively supported by the PDF format, whereas .eps is not, so it requires additional packages to convert it to a supported format (PDF). Also, off-topic: you can select the code and click the {} button to format as a code block in your post. – Phelype Oleinik Feb 04 '20 at 18:35
  • Thanks for the quick reply, Phelype. Here are the packages I am using in my full code: \usepackage{amsmath} \usepackage{amssymb} \usepackage{fullpage} \usepackage{graphics} \usepackage{graphicx} \usepackage{listings} \usepackage{verbatim} \usepackage{setspace} \usepackage{psfrag} \usepackage{epstopdf} What am I missing? – Craig Feb 04 '20 at 18:36
  • @Craig Sorry, I forgot to mention in my comment that the conversion of .eps to .png is done automatically by graphicx you don't need any other packages to do that. Your code works fine for me... – Phelype Oleinik Feb 04 '20 at 18:39
  • you say you are using pdflatex but then say you are using psfrag, which requires latex not pdflatex? – David Carlisle Feb 04 '20 at 18:41
  • you also should not need epstopdf package (graphicx calls that automatically if needed) – David Carlisle Feb 04 '20 at 18:42
  • Thanks for the replies, all. I have tried both PDFLatex and Latex, but when I use the latter I receive this warning, "Drivers other than pdftex' andluatex' are not supported" and it does not compile. – Craig Feb 04 '20 at 18:44
  • normally pdflatex can handle eps-files (it automatically convert it to pdf). If it doesn't work for yours there is perhaps a problem with the eps itself and you should it make available somewhere. Also you should show the log-file of your document. – Ulrike Fischer Feb 04 '20 at 22:17

0 Answers0