Chapter 9: Graphics

"I've seen things you people wouldn't believe. Attack ships on fire off the shoulder of Orion. I watched c-beams glitter in the dark near Tanhauser Gate. All those moments will be lost in time, like tears in rain. Time to die." —Blade Runner

Introduction

Programming graphics is of the utmost importance in games programming. In most circumstances this is the most time-consuming part of your game loop, and it is essential that it is as efficient as possible. In this chapter you will learn the major aspects of programming 2D graphics in Java. We will first take a look at creating and loading graphics. Then we will look at manipulating graphics, beginning with rendering, where you will be introduced to making a game loop. We will then look at some important new features to Java 1.4, such as the BufferStrategy class and full-screen exclusive mode. We will also pay particular attention to applications and applets throughout the chapter, showing you the few differences in getting your games working in terms of graphics.



Java 1.4 Game Programming
Java 1.4 Game Programming (Wordware Game and Graphics Library)
ISBN: 1556229631
EAN: 2147483647
Year: 2003
Pages: 237

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net