Welcome to the TeXnik website (under construction) Graphic |
|||||||||||||||||||||||||
|
converting to another format |
DeclareGraphicsExtensions | DeclareGraphicsRule | Double page float | EPS Images | Extension | Full Page Graphic | gif-Images | Graphic on chapter-page | Graphics as empty rectangles | Graphics config file | Graphics over full Page | Graphics side by side | Height/Width not greater than textwidth or textheight | jpeg-images | Max Width/Height not greater than textwidth or textheight | Multiple graphics side by side | Rotating Images | wmf images | Width/Height not greater than textwidth or textheight | Have a look at the float pages, too. Docs: Graphics in LaTeX2e Using Imported Graphics in LaTeX2e Rotating DeclareGraphicsExtensionsWhen having the same graphic with different extensions in the same directory it may be useful to predefine what extension should be used depending to the running program. If we run for example vlatex nad pdlaftex, we can predefine what extension should be used:\usepackage{graphicx} \usepackage{ifvtex} \ifvtex \DeclareGraphicsExtensions{.eps} \else \DeclareGraphicsExtensions{.png} \fiand in the text we use \includegraphics
without an extension
GIF-Images To convert gif-Images by yourself use convert or giftopnm file.gif | pnmtops -noturn -nocenter >file.epsconvert is really easy to use, but still not the best in every case. Search for special programs in the net.
wmf Images If you use Windows and want to convert your wmf-Format into eps then have a loo at http://520060481190-0001.bei.t-online.de/WMF2EPS/index.htm
wmf Images If you use Windows and want to convert your wmf-Format into eps then have a loo at http://520060481190-0001.bei.t-online.de/WMF2EPS/index.htm
DeclareGraphicsRule With this command the graphicx-package allows better controlling of the imported graphic files. \DeclareGraphicsRule knows four arguments:
file.NN ":
\usepackage{graphicx} \usepackage{ifpdf} \ifpdf \includegraphics[% type=mps,ext=.NN,read=.NN,command=#1% ]{file}% \else \includegraphics[% type=eps,ext=.NN,read=.NN,command=#1% ]{file}% \fiThe key "command" can be omitted, because the default is already correct, but "type", "ext", and "read" are necessary. Also the file argument should be not have an extension. Or if read does not expand to nothing, then the extension can be moved into the file argument: \includegraphics[% type=mps,% or "eps" read=\relax,% or "\noexpand\empty" % ext={},command=#1,% the defaults are ok ]{file.NN} Look also in floats/eps
converting to another format Use the following Shell-Script when you want to convert a lot of files to another format. It converts all files in the current directory with extension "wmf, png, jpg, jpeg, tif, tiff" to eps. #!/bin/sh # wmf->eps echo "make_epses:" for i in ${1}*.wmf ; do STEM=`basename $i wmf` echo "converting $STEM"wmf wmftoeps $i ${STEM}eps done # png,jpg, jpeg, tif, tiff -> eps for j in png jpg jpeg tif tiff ; do for i in ${1}*.${j} ; do STEM=`basename $i $j` if [ -f $i ] ; then echo "converting $STEM"$j convert $i ${STEM}eps fi done done
jpeg images Choose the program jpeg2ps for converting the jpeg files to ps-files. The info from ctan:
Purpose of jpeg2ps
|