Graphics, Figures & TablesMissing figures with pdflatex

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
GerryWolff
Posts: 6
Joined: Thu Jan 20, 2011 6:22 pm

Missing figures with pdflatex

Post by GerryWolff »

I wonder whether anyone could explain why figures are missing from my PDF output file when I'm using pdflatex.

Here is relevant code:

\usepackage[dvipdfm]{graphicx}
\includegraphics[width=0.9\textwidth]{figure_1a.eps}

I have also tried

\includegraphics[bb=0 0 446 459,scale=0.5]{figure_1a.eps}

and

\includegraphics[bb=0 0 446 459,scale=0.5]{figure_1a}

but it makes no difference

Everything else seems to be working fine.

Suggestions for what I should change will be very welcome.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

meho_r
Posts: 823
Joined: Tue Aug 07, 2007 5:28 pm

Missing figures with pdflatex

Post by meho_r »

Convert .eps files to .pdf and try again.

It is possible to do this automatically too:

Code: Select all

\documentclass{book}

\usepackage[pdftex]{graphicx}
\usepackage{epstopdf}

\begin{document}

\includegraphics[width=0.9\textwidth]{figure_1a}

\end{document}
User avatar
frabjous
Posts: 2064
Joined: Fri Mar 06, 2009 12:20 am

Missing figures with pdflatex

Post by frabjous »

Unless you're using the newest version of pdflatex (TeXlive 2010 or MikTeX 2.9), pdflatex does not support .eps images. Either compile with latex > dvips > ps2pdf instead, or else convert the images to pdf, either using the epstopdf command line tool, or the epstopdf package (requires the -shell-escape or -enable-write18 options).

if you still have trouble, search the forums, there are dozens of threads about this.

(Somehow I missed meho's post. Not sure how.)
Post Reply