Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have four images aligned in one slide and I want to show one picture at a time.

I was able to show the text using the code below

\begin{frame}
\frametitle{Table of Contents}
\begin{itemize}
\item<1-> Introduction
\item<2-> Algorithm for reducing finite automata
\item<3-> Reliability models
\item<4-> Reduction steps
\item<5-> References
\item<6-> Conclusion
\end{itemize}
\end{frame}

In the same way I want to show the images.

I have aligned the images as follows

\begin{frame}
\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc5.jpg}}
\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc6.jpg}}
\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc8.jpg}}
\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc7.jpg}}
\end{frame}
share|improve this question
    
I think for this you can have a look to 4 images on a frame appearing each a a time fine tuning beamer. –  Claudio Fiandrino Oct 21 '12 at 11:07
    
you can wrap them in \only<3>{.....} to show just on the third layer –  David Carlisle Oct 21 '12 at 11:08
    
It would be useful if you show the definition of \vcenteredhbox or add a pointer for it. –  egreg Oct 21 '12 at 11:13
add comment

2 Answers 2

Maybe with \alt and \phantom, assuming you used the custom definition for \vcenteredhbox, that I found here.

\documentclass{beamer}
\usepackage{graphicx}

\newcommand*{\vcenteredhbox}[1]{\begingroup
\setbox0=\hbox{#1}\parbox{\wd0}{\box0}\endgroup}


\newcommand{\thepic}{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pic.png}}

\begin{document}


\begin{frame}
 \vcenteredhbox{\thepic}
 \vcenteredhbox{\alt<2->{\thepic}{\phantom{\thepic}}}
 \vcenteredhbox{\alt<3->{\thepic}{\phantom{\thepic}}}
 \vcenteredhbox{\alt<4->{\thepic}{\phantom{\thepic}}}
\end{frame}

\end{document}

enter image description here

share|improve this answer
add comment

Maybe just uncover would be sufficient.

\documentclass[demo]{beamer}

\newcommand*{\vcenteredhbox}[1]{#1}

\begin{document}


\begin{frame}
\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc5.jpg}}
\uncover<2->{\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc6.jpg}}}
\uncover<3->{\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc8.jpg}}}
\uncover<4->{\vcenteredhbox{\includegraphics[width=5cm,height=5cm,keepaspectratio]{pc7.jpg}}}
\end{frame}

\end{document}

enter image description here

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.