0

I would like to insert a background image contained in my_background_file.png in the title page of a presentation. Why doesn't the following code properly work? I simply get a title page, without any image on the background.

\documentclass{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

\title{YYYY}
\author{D.S.}
\institute{Some University}
\usepackage{transparent}
\usepackage{eso-pic}
\newcommand\BackgroundPic{%
\put(0,0){%
\parbox[b][\paperheight]{\paperwidth}{%
\vfill
\centering
{\transparent{0.4} \includegraphics[width=\paperwidth,height=\paperheight,%
keepaspectratio]{my_background_file.png}}%
\vfill
}}}

\begin{document}
\AddToShipoutPicture*{\BackgroundPic}
    \titlepage
\end{document}

What's wrong with that?

2
  • So your title page looks as it's supposed to except the image itself is missing. Did I get this right?
    – Nepumuk
    Dec 12, 2020 at 10:04
  • Yes, you did @Nepumuk Dec 12, 2020 at 10:11

1 Answer 1

1

Try this.

\documentclass{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

\title{YYYY}
\author{D.S.}
\institute{Some University}
\usepackage{transparent}


\usebackgroundtemplate{%
\transparent{0.4}\includegraphics[width=\paperwidth,height=\paperheight]{example-image-A}
}

\begin{document}
    \titlepage
\end{document}

ee

To change the background of each frame you could try this code:

\documentclass{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

\title{YYYY}
\author{D.S.}
\institute{Some University}
\usepackage{transparent}


\begin{document}

{%
\usebackgroundtemplate{%
\transparent{0.4}\includegraphics[width=\paperwidth,height=\paperheight]{example-image-A}}
\begin{frame}
    \titlepage
\end{frame}
}

{%
\usebackgroundtemplate{%
\transparent{0.4}\includegraphics[width=\paperwidth,height=\paperheight]{example-image-B}}
\begin{frame}
    One
\end{frame}
}

{%
\usebackgroundtemplate{%
\transparent{0.4}\includegraphics[width=\paperwidth,height=\paperheight]{example-image-C}}
\begin{frame}
    Two
\end{frame}
}
\end{document}

fff

2

You must log in to answer this question.

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