Monday, May 28, 2007

How to add picture in TeX files

To add the picture in one single page, add the epsfig.sty pakage then add

\begin{figure}[t]

\centering

\includegraphics[keepaspectratio=true,height=1.6in,clip=true]{filename.eps}

\caption{tenhinh}

\end{figure}


(from anh Du*.)
More information about this from here.

Read this or this.
To add the picture in between the page, with a box surrounding, add the epsf.sty package then add

\epsfysize=2in

\begin{center}

\mbox{\epsfbox{filename.eps}}

\end{center}


or

\epsfysize=2in

\begin{center}

\epsffile{agreaterthan0.eps}

\end{center}


Without centering:

\epsfysize=2in

\epsffile{agreaterthan0.eps}


or

\epsfysize=2in

\mbox{\epsfbox{filename.eps}}



A useful package to change ps to eps can be obtained here.

Further help for LaTeX can be found The LaTeX Help Page.


One more trick: this time from Mr.Tung Le, add \includegraphics[0,0][400,300]{whatever.bmp}
More information can be read here.

No comments: