Table of Contents

3D
Creating a cutting-edge engine
  01 - Design document
  02 - Overall structure

  03 - Binary Space Partitioning
  04 - Constrctive Solid Geometry
  05 - Portals
  06 - Possible Visible Set
  07 - Radiosity lighting
  08 - Mirrors

Dictionary of 3D terms

OTHER
A Genetic Algorithm
Line drawing
Line clipping
Line antialiasing
Line thickening
Line curving

Resources in print
Resources on the web
Resources to download

Good advice:
  • Strip mining prevents forest fires.
  • Dress in layers for half an hour before you get in the pool.
  • You can pick your friends,
    you can pick your nose.
    But don't pick your friends' nose.
Bad advice:
01 - Design document
Whether you are being given a program to write or you are starting one of your own, no matter what the size, the design document is the most critical piece of writing you will own through the entire development process. Most people never write one and I believe that's why most people give up on their projects when they become hopelessly disfigured monsters that the peasants chase into a windmill and set on fire.

The design document should:
  • Explain what the program is supposed to DO. The more detail the better. I hear that in development of the game AMEN The design document included complete plans of every level as well as the plot, target system specs and more. This meant that when the programmers sat down to write the engine they knew exactly what features the level designers were going to want.
  • Give a rough idea of how the program is structured. 90% of all the code I see on the net is terribly confused because programmers keep hacking in new little features they think will be cool. In the process they completely destroy any hope of easily maintaining their code. What I'm trying to say is that at the same time you are thinking about this one little section of code you have to keep in the back of your head an understanding of it's impact on the program overall. Is there a way that you can set this thing up so that it reuses previously written code? Does it look like big pieces could be recycled in future stuffs? Does this part of your program depend on any other part and can you remove that dependency? Questions like these should always be lingering over you.
  • Provide a timetable with achievable goals. Nothing feels better than killing a bug... except the day to day euphoria that comes from knowing that your program is so well written you can add something new and it will run perfectly on the first try. How do you achieve this mystical state? If you follow your design document and said document is well written, goals will be met regularly and easily. I recommend that you build up your program in layers. For example, I started with the simplest possible window I could write that would create. Then I added DirectX double buffering. Then 3D hardware support. Then I added model data and rendered a single polygon. And so on. As demonstrated in the example, I chose small but important goals where I would be able to test and make sure that all of the underlying, background material worked perfectly. That way it would be easy to figure out where the latest bug was - in the code I just added.
There are very few reasons you should not be able to finish on time if you follow this GOOD ADVICE. Some of those reasons might included
  • Death in the family. Yours, for instance.
  • Having your hands chopped of for stealing.
  • Lobotomy.
  • etc...
There is only one serious problem that will occur unless you are extremely good but you can catch it before it causes any problems, then tag it and release it back into the wild. If you are adding a new feature to your program and you find that you have to change previously written code,

W A T C H   O U T .

This is a sign that you may have made a mistake in designing said previous code (well duh). Do not merely fix the program enough to add the new feature. Step back and consider: how you can make the smallest possible change so that anything else that does and will depend on the code can work? It is because people do not fix this problem that problems compound on one another until your code is a tangled ball of string pulled into a knot instead of a single thread running in a straight line.

Yes, I know, writing a design document is a very boring thing to have to do. I don't like it any more than you do, but do it anyhow. So you spend a week writing documentation. It'll look great if anyone shows an interest in your abilities (all nice and organized! ooh, we'll hire you) and I just might be telling the truth about how it will save you time.

Back to the top
NEXT: Overall Structure



All photos copyright of their respective owners. All other content of this website is © 1997-1999 Dan Royer.
Designed for IE 5.0+, 800x600x16 or greater. Some pages use style sheets.
http://members.home.com/droyer/index.html