72

I'd like to insert a PDF, but make it "lighter" by setting the opacity to 10% ("background watermark"). How to do that? A solution that works with texlive 2011 would be great.

I use pdflatex and includegraphics to insert the image.

topskip
  • 37,020
  • 1
    I suggest you to take a look at PGF/Tikz http://mirrors.ctan.org/graphics/pgf/base/doc/generic/pgf/pgfmanual.pdf (search Referencing the Current Page Node - Absolute Positioning) – Lionel MANSUY Dec 11 '12 at 08:35
  • 1
    I hope there is a solution without loading the whole tikz-pgf bundle into my tiny document... – topskip Dec 11 '12 at 08:37
  • 1
    @topskip Certainly possible, all you have to do is use TikZ for a demo, \tracingall the resulting output and see what specials to use :-) – Joseph Wright Dec 11 '12 at 08:40
  • 2
    @JosephWright I guess my harddrive is too small for the resulting log file :) – topskip Dec 11 '12 at 08:47

2 Answers2

80

You could use the transparent package to set the opacity of your background image:

enter image description here

\documentclass{article}
\usepackage{lipsum}

\usepackage{graphicx}
\usepackage{transparent}
\usepackage{eso-pic}
\AddToShipoutPicture*{
    \put(0,0){
        \parbox[b][\paperheight]{\paperwidth}{%
            \vfill
            \centering
            {\transparent{0.4}\includegraphics[width=0.5\textwidth]{drawing}}%
            \vfill
        }
    }
}

\begin{document}
\lipsum
\end{document}

In case the transparency doesn't work with your image for some reason, you could instead put a semi-transparent white box over your image:

\documentclass{article}
\usepackage{lipsum}

\usepackage{graphicx}
\usepackage{transparent}
\usepackage{eso-pic}
\AddToShipoutPicture*{
    \put(0,0){
        \parbox[b][\paperheight]{\paperwidth}{%
            \vfill
            \centering
            \includegraphics[width=0.5\textwidth]{drawing}%
            \vfill
        }
    }
    \put(0,0){%
        \transparent{0.7}\textcolor{white}{\rule{\paperwidth}{\paperheight}}
    }
}

\begin{document}
\lipsum
\end{document}
Jake
  • 232,450
1

To use transparent with XeLaTeX, insert

\RequirePackage{pdfmanagement-testphase}
\DeclareDocumentMetadata{}

at the very beginning of the document (before \documentclass).

See this issue for more details.

robertspierre
  • 638
  • 3
  • 16