For those who don’t keep up with the gaming world, Team Fortress 2 is the latest first person shooter multiplayer game produced by Valve Corporation. It has gotten positive reviews for many attributes such as balance and gameplay, but one thing that really makes it stand out from other shooter games is its unique style of animation. Instead of trying to make everything look as realistic as possible, Valve went for what they call “Non-Photorealistic Rendering” - in other words, the game essentially looks like a cartoon:
Some of the characteristics of the shading style include warm-to-cool hue shifts, bright rim highlights, and omission of high frequency detail. But how does this artistic vision translate into lines of game code?
In this paper released by Valve, three developers outline the methods used to render the game’s graphics. Not surprisingly, the entire process is very mathematical: they introduce two large and complicated formulas, and they explain all the variables and how they influence the final result. The two main calculations are for the view-dependent (position of lights, angle between lights and surfaces) and view-independent (color of lights, natural color of a surface) contributions. The graphics are rendered one pixel at a time (hence the name “pixel shading” for this process), meaning that these calculations must be performed millions of times during a typical game. These calculations are generally performed by a video card, and based on the complexity of each individual evaluation, it’s not surprising that newer games have steep minimum video card requirements to run well.
The types of calculations performed here complement what we did in the first assignment. Our job was to locate surfaces as efficiently as possible, but we just let some given black box program handle the rest without giving it much thought. This paper presents an interesting view of another equally important graphical rendering step - how to make the rendered objects actually look colorful and appealing, and also in a reasonable amount of time.
In the “Future Work” section of the paper, the authors mention some possible enhancements to their current shading techniques. However, they state that are waiting until more powerful hardware is widely available, because the extensive calculations would make individual pixel calculations take too long. Perhaps an additional solution could be to devise more efficient algorithms that produce nearly identical results with less work?







Leave a Comment
You must be logged in to post a comment.
* You can follow any responses to this entry through the RSS 2.0 feed.