What is Togra?

Togra is a high-level approach to 3D application scripting using Python and OpenGL.

Rather than providing direct access to OpenGL calls, Togra allows users to script a call graph, then evaluates this call graph in C. This gives easy, fast 3D graphics.

The aim of Togra is to make 3D application generation accessible to as many people as possible, with as shallow a learning curve as possible. It's also a chance for me to play around with cool 3D stuff ;-)

Togra is currently very alpha, but already supports a wide range of features, including:

Static and dynamic meshes

Textures and video textures

Path-based animation

Event-based 3D programming (including animation-based, mouse and keyboard events)

Integration with the fantastic GStreamer framework

partial integration with ODE, a cool library for physics simulation

prototyping support via interface shells which call back into Python

Togra news

Notes on Dynamic behaviour

I've put some notes on ideas for dynamic behaviour in the wiki. I'll add to these as I flesh out how to implement them.

New Wiki, New Tutorial

I've created a Wiki for Togra here. To celebrate, I also made a tutorial on how to create new Togra Classes. Find it in the wiki!

New interface generator

I am currently in the process of converting all of Togra to use a code generator for the boring python interface code. This is going really well, and a number of features are now working in the new version. I hope to have everything ported across, as well as a bunch of new features, by the end of September. To try it out, 'make new_GTK'.

The reason I'm doing this is to make development of future features easier. tip.py (my custom interface constructor) reads an XML description of the class and generates python-to-C conversion code, getters and setters, managed arrays and a bunch of other stuff. Later on I'm going to use it to automatically add support for advanced python features like arbitrary runtime variable/function getting and setting.

If the ease at which the existing interfaces and classes can be brought across is anything to go by, then adding new features should be incredibly easy after this task is complete. My eventual aim is to have a system where would-be hackers can cut their teeth using the interface shells and develop potential new classes in Python, then convert those classes to C with minimal pain.

Togra is hosted by: