2

I want to position an image in the background of a beamer slide. I don't need to condition the background on an overlay specification. I just want the same background for every appearance of the frame. I tried using a tikzpicture,

\setbeamertemplate{background canvas}{\begin{tikzpicture}
    \node at (0pt,0pt) {};
    \node at (-5cm,-5cm) {\includegraphics[width=.8\paperwidth]{lecturing2}};

This works to some extent, but I can't control left-right positioning. I added the node at 0pt,0pt because I suspected that the whole thing was getting centered after I tried to position it.

1
  • Before \begin{tikzpicture} add \hspace{some length} eg \hspace{2cm} Feb 17, 2019 at 20:05

1 Answer 1

5

background images are usually centered. based on beamer background image centered and transparent background image- you can center your image as follows:

\documentclass{beamer}
\usepackage{tikz}

\usebackgroundtemplate{%
  \vbox to \paperheight{\vfil\hbox to \paperwidth{\hfil%
\tikz\node[opacity=0.3,inner sep=0pt] {\includegraphics[width=0.8\paperwidth]{example-image-duck}};
                        \hfil}\vfil}
                       }

\begin{document}

\begin{frame}
my favorite duck! quack, quack!
\end{frame}

\end{document}

enter image description here

however, if you like to determine distance form slide bordrers to image, than you try the following:

\documentclass{beamer}
\usepackage{tikz}

\usebackgroundtemplate{%
  \vbox to \paperheight{\vspace*{12mm}\hbox to \paperwidth{\hspace*{8mm}%
\tikz\node[opacity=0.3,inner sep=0pt] {\includegraphics[height=0.5\paperheight]{example-image-duck}};}
                       }}

\begin{document}

\begin{frame}
my favorite duck! quack, quack!
\end{frame}

\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .