Building an engine, introduction

This is the first part in a set of articles where I will describe the process of developing an iPhone game. The first few articles will focus on the creation of a somewhat generic 3d engine. Of course, I’m describing my own engine (Qixis::Engine), but most of the concepts are valid for all 3d engines. Also, keep in mind that I’m still learning a lot on this subject. I don’t know everything, but will describe what I know and make corrections along the way, as I learn more.

The plan so far is to take a look at at least the following subjects:

  • Basic engine architecture
    • Basic building blocks
    • Building a scene graph
    • Adding basic automatic animation
    • Resource management
  • Basic rendering
    • Building scene nodes to show something on the screen
    • Materials
    • Optimising the renderstate
    • Optimising rendering
    • Frustum culling
    • Optimising troublesome scene nodes
    • … this is where my engine is at this moment

The articles are probably not going to be tutorials explaining basic OpenGL ES or iPhone programming; there are some excellent tutorials covering these subjects and if I can learn most of what I need to know from them, so can you. For a quick start, here are some excellent resources covering the basics:

If these seem overwhelming now, don’t worry. Things will become clear along the way. When I started this project, I didn’t know a Vector from a View Frustum…

Why?

Building a 3d engine isn’t a trivial task and there are some rather good off-the-shelf solutions. Why didn’t I use one of those, like SIO2 or Oolong or Irrlicht, or…?

Mainly because building a 3d engine isn’t a trivial task. It’s a fun project and I learned (and still am learning) a lot during this project. I’m writing these articles because I couldn’t really find anything good on basic 3d engine architecture and hope to make my own small contribution this way.

As I’m writing this, the engine is not finished yet. The basic plumbing is there, but a lot of the solutions I chose are naive and can use some more optimisation. I don’t believe in premature optimisation however, so optimisation will probably a topic for a future article.

Feedback

Writing articles is not something I regularly do. Also, English is not my primary language. Any feedback is more than welcome, both on technical subjects and the writing itself. The preferred way is to just add a reply to an article. My e-mail address can be found on the ‘about’ page of this site.