Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Transparent Elements in Beamer Presentations

2,553 views
Skip to first unread message

Wildemar Wildenburger

unread,
Feb 1, 2008, 1:32:50 PM2/1/08
to
Hi there :)

I've been using beamer for some time now and I like it a lot. Recently I
have come accros a presentation that impressed me a lot (visually,
although the content sure is interesting as well). See it here:
<URL:http://xlr.sourceforge.net/Concept%20Programming%20Presentation.pdf>

It has a certain warmth to it that I find very appealing. Mainly it's
the grainy, paperlike background and how the elements on the slides take
on the same grainy quality. Beamer, in comparison is much more sober and
even sterile sometimes.

So I tried to use a similar background in beamer only to find that all
shadings/gradients in beamer are done without transparency. For example,
the shadow of a box goes from black to white while I would want it to go
from black to transparent. Also, I'd like all (or some) elements exept
text to be semi-transparent, so that the background shines through and
everything looks like drawn on paper.

Is something like this possible in beamer? I wouldn't mind getting into
writing themes for this.

/W

vvvv

unread,
Feb 1, 2008, 9:18:25 PM2/1/08
to
That example does have some good graphics. There are probably a
couple ways to do this. It does appear to me that the slide on page
41 is an overlay with a transparency. ****Maybe somebody in this
forum knows how to do transparencies in LaTeX. I found a
transparent.dtx package on the Internet, but I have never used it and
it might apply only to colors.

I can suggest other approaches. One would be to use a good graphics
program to overlay the 3D objects and create a fake shadow by "spray
painting" (GIMP is free and can do this if you have some artistic
talent). I think that some graphics are sold that have an overlay
(like the LEGO picture) that contains the shadow, and the shadow
blends with whatever is under it. This can also be done in GIMP and
exported as a regular .png to be used in LaTeX. For the photographs
that have shadow, I can tell by the loading that shadow under slide 27
was "spray painted" on the background image, then the photograph was
displayed over the shadow area. That same background image with the
shadow is used several times. The last part that would be difficult
without an overlay done by LaTeX is the "Failed" graphic on slide
23.

For the LEGO example on slide 12, I might use a CAD program (I use
Newtek Lightwave or you could try a public domain POV raytrace) to
place 3D CAD models on a flat surface that has the paper texture
mapped to it, and then render the image with a spot light and an area
light. This image is then included as a background image without
anything special in LaTeX.

I'll see what happens when I display a regular .png that is designed
to have a transparency in GIMP.

vvvv

unread,
Feb 1, 2008, 9:54:13 PM2/1/08
to
If you compile with pdflatex (as opposed to pslatex or latex), LaTeX
will handle transparencies like any other good program. To build a
transparency or to convert one from an existing image, use GIMP (free
program). If the image is clearly delineated with a white background,
use the menu command in GIMP: Layer/Transparency/Color to Alpha, then
it will use white as the default and make anything white invisible.
Save the file as .png and your are ready to go. If you want to make a
different color invisible, use that menu command and then double click
the big, empty, white box below the picture and then set the color by
pointing or entering an RGB number. I think nearby shades are coded
as partially invisible.

The next issue to place the graphic where you want it. If the picture
goes in a relatively normal place on the slide. If you want the
graphic over the text, you might try using the \vskip command.

Here is a sample that puts my transparent image over text (you'll have
to supply your own image)

\documentclass{beamer}
\mode<presentation>
{

\usetheme{Dresden}

\setbeamercovered{transparent}
}
\setbeamercolor{background canvas}{bg=red}
\begin{document}
\begin{frame}
a dfasdf asdf asdf sdf sadf asdf sdf asdf sadf asdf asdf asdf asdf
asdf asdf asdf asdf asdf asdf asdf a a dfasdf asdf asdf sdf sadf asdf
sdf asdf sadf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf a

\vskip-40pt\includegraphics[scale=.2,trim=0 0 0 0,clip=true]{/Pictures/
transparent.png}%
\end{frame}
\end{document}


ALSO*** you can make your own background using your own photographs or
find some "paper" backgrounds by searching for "paper textures" or
"fabric textures"
http://www.3dlinks.com/Shop/Details.cfm?ProductID=417
http://local.wasp.uwa.edu.au/~pbourke/texture_colour/paper/
http://www.cgtextures.com/


You can then add blue (or colored) regions in GIMP by creating a new
layer in one of the paper images, Use the Dialogs/Layers menu command
to highlight the new layer, highlight a rectangular region, using the
"paint can" to fill the region with color, use the Layer/Mask option
and choose the option to use grayscale of layer. Try using a similar
trick to create shadows for photographs.

vvvv

unread,
Feb 1, 2008, 9:59:20 PM2/1/08
to
Also, don't pick random colors. search for "color palettes" and use a
color scheme designed by somebody who understands color (not me!)
http://www.colourlovers.com/palettes

Kjell Magne Fauske

unread,
Feb 2, 2008, 6:58:58 AM2/2/08
to
On Feb 1, 7:32 pm, Wildemar Wildenburger

Most of the effects in the presentation can also be done in Beamer
with some help from PGF and TikZ (or even a recent version of
PSTricks).

Beamer uses PGF for its graphics, but PGF and TikZ have changed a lot
since Beamer was written. The CVS version of PGF has very good support
for transparency, fadings and shadows. I don't know when a new version
will be released, but if you are interested you can check out a copy
of PGF from Sourceforge:
http://sourceforge.net/projects/pgf/

You can also find a recent build of the manual here :
http://www.fauskes.net/media/pgf/
(see chapter 17 and 35)

Some examples of overlays and transparency using Beamer and TikZ can
be found here:

http://www.fauskes.net/pgftikzexamples/tag/transparency/
http://www.fauskes.net/pgftikzexamples/tag/beamer/

Note that the above examples use the current version of PGF.


- Kjell Magne Fauske

Basil Abou El-Komboz

unread,
Feb 2, 2008, 2:33:09 PM2/2/08
to

Very nice page,
thanks for posting the links! :-)

Greetings,
Basil Abou El-Komboz

Hans Meine

unread,
Feb 4, 2008, 4:41:00 AM2/4/08
to
Kjell Magne Fauske wrote:
> Most of the effects in the presentation can also be done in Beamer
> with some help from PGF and TikZ (or even a recent version of
> PSTricks).
>
> Beamer uses PGF for its graphics, but PGF and TikZ have changed a lot
> since Beamer was written. The CVS version of PGF has very good support
> for transparency, fadings and shadows.
+1, but be aware that transparency support is not very good in today's PDF
viewers - many people reported acroread to become confused with colorspaces
(i.e. colors would become too bright etc.) after each occurence of real
transparency.


Good luck!
Hans

Kjell Magne Fauske

unread,
Feb 4, 2008, 5:34:43 AM2/4/08
to
On Feb 4, 10:41 am, Hans Meine <me...@informatik.uni-hamburg.de>
wrote:

>
> +1, but be aware that transparency support is not very good in today's PDF
> viewers - many people reported acroread to become confused with colorspaces
> (i.e. colors would become too bright etc.) after each occurence of real
> transparency.
>
> Good luck!
> Hans

For those wanting to know more about this, there is an interesting
thread about the topic on the pdftex mailing list:
http://tug.org/pipermail/pdftex/2007-December/007457.html

In the thread a workaround is mentioned. Insert the following code in
the document preamble:

\pdfpageattr {/Group << /S /Transparency /I true /CS /DeviceRGB>>}

This prevents the color shifting when using acroread. However, the
text still looks slightly fuzzy on my screen.

- Kjell Magne Fauske

0 new messages