Game Development Reference
In-Depth Information
chapter 15
Compressing Data to
Reduce Memory Footprint
The programmer's primary weapon in the never-ending battle against slow
systems is to change the intramodular structure. Our first response should
be to reorganize the modules' data structures.
Frederick P. Brooks
Games are being produced with multiple gigabytes of game assets, and it is pro-
jected that file sizes will increase at an exponential rate in the years to come. One
of the largest issues for building reusable and efficient tools comes down to scala-
bility, and how to build tools that can manage countless assets. One way to achieve
this goal is through the use of data compression to reduce the file size of each game
asset.
A variety of software development projects employ data compression, and almost
all operating systems and platforms have libraries and tools available to perform
data compression for different types of situations and datasets. Fortunately, .NET
2.0 introduced some new data compression components that make the whole
process very easy.
As for a definition, data compression removes redundancy from data, which can
come in a lot of different forms depending on the type of data in question. On a
small scale, repeated bit sequences (11111111) or repeated byte sequences
(XXXXXXXX) can be transformed. On a larger scale, redundancies tend to come
155
Search Nedrilad ::




Custom Search