Friday, July 29, 2011

Software: From Simple to Complicated

A few years ago, I started a small software library.  A set of common routines.  Seeing how useful it was, I decided to expand it -- make it more general.  Apply good software development techniques so that it may prove to be more flexible.

For example, at the beginning I hardcoded the ability to use a single 1024x1024 texture for everything.  This meant I had no need to worry about which texture was currently bound (only one) and no need to manage memory (one fixed amount of memory used).  Then I expanded this system to load multiple textures using a plist for the parameters.

For the added flexibility, I was able to create textures and use them as objects.  Yet; as far as making prototypes go it didn't speed things up.  Memory became an issue to manage.  And now mipmapping and other little technological ideas for the sake of technology start to creep in when ideas should be driving the technology.

In the end; I should conclude the organization for generic code is only needed when called for.  If it works, and works well, why change it?

No comments:

Post a Comment