Bumpy shadows and BunnyScript

posted in Rabbit Droppings
Published September 02, 2004
Advertisement
The lighting project I've been working on is just about finished now. I've added bump mapping to the scene and specular highlights. I should have a demo complete by the end of the week.

(click to enlarge)

The project got a bit delayed by the fact that I felt the need to write a new scripting language to handle per-mesh calculations. A kind of per-object shader language I suppose. Since there are a lot of matrix calculations that are only performed once per mesh, it seemed wasteful to do them in a vertex program, and I wanted to keep the C++ code separate from the shaders as much as possible.

In the end I wrote a C-like language which compiles to bytecode, which can then be read through a virtual machine. After that I spent ages getting the VM to run at a sensible speed. It was worth it in the end though. The language (BunnyScript) is pretty general purpose, so I can see it being useful to other things such as AI.

I guess I could have just used a language that was already available - why bother to reinvent the wheel etc - but I've always wanted to write my own. Plus, I'm fairly confident that mine is faster than most other interpreted languages, which is a good thing because the programs are being run thousands of times per frame.
Next Entry It's done
0 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Advertisement

Latest Entries

New Job

1188 views

It's done

1017 views

More shadows

998 views

Work and Shadows

955 views
Advertisement