3D Animation Workshop: Lesson 108: Scan The Skies! | 2 | WebReference

3D Animation Workshop: Lesson 108: Scan The Skies! | 2

Lesson 108 - Scan The Skies! - Part 2

Let the game load and start playing. It takes about 40 seconds to load on a 56K-dialup connection. Once you've loaded it the first time, it will reload quickly each time thereafter.

You can display your frame rate while playing by pressing the "f" key. Rates of 20-25 frames per second and above will be very satisfactory.

The key to getting this game to run fast without hardware acceleration is in the bare bones graphics. I had to come up with ideas that dispensed with texture maps and sophisticated geometry. I made extensive use of PointSet objects for animated explosions, most with color changes. These render so fast that I could probably have use three times as many without slowing down the action. I also used a wireframe IndexLineSet to create the enclosing globe object needed to understand where you are looking. This also renders very fast.

But the most important factor affecting the frame rate is the size of the rendering window. The smaller it is, the faster the game runs. It would be terrible if we always had to design for the "lowest common denominator," the slowest system that that our audience is likely to have. There are a number of possible solutions. One would be to allow users to choose between differently sized applet windows, perhaps using buttons or a dropdown list of options. This is definitely possible with Shout3D 2.0, but there is a far better alternative.

We can define the applet window as some percentage of the browser window, and allow the applet to resize flexibly as the user adjusts the size of the browser. That way, each player can customize the game completely. Users with fast systems can stretch the game to full-screen, while those with older processors can squeeze the game down until they get the desired frame rate. This is really quite remarkable.

To check this out, go on the next page of this lesson.

To Continue to Part 3, or Return to Part 1, Use Arrow Buttons

Created: December 18, 2000
Revised: December 18, 2000

URL: http://webreference.com/3d/lesson108/2.html