O'Reilly logo

Libgdx Cross-platform Game Development Cookbook by Alberto Cejas Sánchez, David Saltares Márquez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Frame buffers and image composition

Knowing how to render textures, animated characters, and particle effects at arbitrary positions already gives you great power to build incredibly rich and elaborate game worlds. However, some effects may be tricky to achieve, if not impossible, just by using these tools.

Let's imagine you want to implement smooth crossfade screen transitions in your game. When we talk about screens, we are referring to the main menu, game, victory, and so on. We will progressively decrease the alpha value of the old screen, while the new screen comes into play with an increasing alpha value. This cannot be accomplished by passing the corresponding transparency value to each screen, simply because the second we encounter overlapping ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required