Game engine source code

Technical note.

The game engine for City In A Bottle is now open source (GPL).
The code is hosted at the NodeBox development site.

For people that are already familiar with NodeBox, the engine has adopted the same API (i.e. drawing commands) as NodeBox so it's very easy to get started.

The game engine is written entirely in Python and built on top of Pyglet. Graphics are rendered in OpenGL. So far we have code for drawing images and primitives (Bézier paths, including all the path mathematics from NodeBox), extension classes for working with layers and motion tweening, matrix transformations and basic hit testing, a few GLSL shaders (colorize, blur, gradient, multiply) and offscreen rendering. Integration with PD for sound is coming up, as are some GUI controls (slider etc.)

There's still a lot to do but the code is already operational for rendering NodeBox-like visuals... at hardware-accelerated speed. There's no documentation yet so you'll have to dig into the source.

Tom

blog comments powered by Disqus