Friday, May 30, 2008

Python ray tracing

I haven't really had time to do anything significant, but I have written an extremely primitive ray tracer in python.
It may seem like a stupid idea to make such a computing intensive task in Python, but that's part of the point... to optimize everything and get some decent speeds. The plan is to use numpy arrays and some inlined C code (with scipy.weave) to optimize the bottlenecks, but to really know where the bottlenecks are I have first to write a working ray tracer. However, in order to do that I need free time, and that's something I don't have right now (says he who is writing on his journal), and the free time I have had I have been spending stupidly deliberating on language choice..
Before 23:59 tonight, I have to turn in a little programming homework, to make an blur image filter. It's a pretty interesting homework for a first programming course, and we have had projects like that all semester.
I am taking a seminar on Mathematics for Computer Graphics, and for the final project I'll be writing a curve (splines) and surface (nurbs) renderer from scrath. So I will be posting that here =)

==Edit:

I forgot, here is a little dump from the raytracer:

Two spheres without any kind of lighting effect =P