Pictures, Images & Diagrams

LaTeX has several mechanisms for incorporating line drawings and images into a finished document. The basic method for doing this is covered in Graphics within LaTeX documents. The notes on this page give a few more specifics on software and techniques for drawwing/image file generation and conversion.

  • pdflatex requires either .jpg or .pdf formats. If you have an application that generates .eps files, then you must use the command-line utility epstopdf to convert the .eps file into a .pdf file. Check the resulting PDF file using Acrobat.
  • In MATLAB, for example, you can generate a .eps file for the current figure by typing
    print -deps myplot.eps
    For colour pictures, use
    print -depsc myplot.eps
    Then use epstopdf myplot.eps to generate myplot.pdf
  • For converting many different image file formats, IrfanView is highly recommended.
  • An excellent drawing package is MayuraDraw. To incorporate Encapsulated PostScript (eps) files from MayuraDraw into LaTeX, see Graphics within LaTeX documents. Save the file as a .pdx file, and use "export" to export to an Encapsulated PostScript (.eps) file. Then convert to .pdf using epstopdf.

    Not all Mayura fonts work with LaTeX: for best results, use font TimesNewRomanPS-BoldItalicMT for text. To create an encapsulated PostScript file select export with the following options:

    • Substitute PostScript fonts
    • Do not include screen preview
    • Do not include fonts
    Mayura Draw is shareware.

  • Another free drawing package is Inkscape. It can save in a multitude of formats, including using "pstricks" macros.
  • Another drawing package is Dia, for creating diagrams (as you might have guessed). You should download the Win32 setup program for Windows. It includes various standard symbols from various fields. Create a new diagram using File-New, and save in .dia format. To export to LaTeX format, right-click on the diagram and select Export, then select extension type Encapsulated Postscript (EPS).
  • A free drawing and image manipulation program is GIMP, the Gnu Image Manipulation Program. A windows version is available at GIMP for Windows. Again, the EPS format should be used for exporting drawings and images for LaTeX. GIMP is quite large, and MayuraDraw is probably a better choice in many circumstances.
  • The "pstricks" package allows you to create complex diagrams in LaTeX documents using object-drawing LaTeX macros. It uses a LaTeX syntax for defining the diagram and the PostScript language for rendering the diagram. It is very powerful, but can be a bit tedious. 
  • potrace is a small utility for transforming bitmapped graphics into vector graphics.
  • If you wish to purchase a commercial drawing package, I can recommend SmartDraw.