After another days hard work I finally created my first cornell box, since yesterday I added a more cap
able camera model and implemented the shading code. All the pieces are now slowly coming together. A small thing I still need is to associcate a material to each triangle, but that should be a quickie. The data is already exported from 3D Studio MAX so I just need some more textures and initialization code. The only large thing missing is support for uniform grid spatial paritioning, which is present in Purcells original paper. I’ll start implementing that next year, that is, the day after tommorow.I will celebrate new years eve here at the dorm with my girlfriend, Lars, Brian, Janus and a bunch of other people. It’s gonna be a blast. Happy new year everyone!
Monthly Archives: December 2004
Update
Another days wo
rk, and I now have this. It does not look like that much have changed since yesterday, but it has! I can now handle an arbitrary amount of triangles and I have clean separation between the various stages of the pipeline. I was able to remove alot of redundant textures and Cg programs so the above screenshot, although more advanced under the hood, actually takes the same amount of videram as the previous one, and this one even has four times the triangle count.My major headache is the Cg compiler (1.3 beta 2) which has a comparable amount of bugs to your avarage country sized rain forest. Nested conditionals are apparently very hard to compile into fp30 code, and the arbfp1 code is simply incorrect. I sometimes has to add code updating some component of a vector just before a conditional which updates that same vector anyways (or kills the fragment) – so the first update is utter useless, but apparently required to make it compile right. Go figure. I would just like to add that I normally consider compiler/API complains as a sign of someone not understanding the tool they use. In this case though, I am the one complaining, and I am fairly sure that my complaints are justified. If you, however, know why my cgc is behaving this weird I would really like to hear from you.
Oh, and the above cube is of course exported from 3D Studio MAX using my own exporter, loaded from disk using my own engine, and then restructered and fed to the GPU :).
Exercising the GPU
I’m currently torturing the GeForce FX 5650GO card in my laptop with something it is not used to. As exam project for a course I am implementing a ray tracer almos
t entirely on the GPU and after several days of on-and-off work I have finally produced my first proper screenshot: I am using the technique described by Timothy Purcell in his Ph.D. dissertation from March 2004. To produce the screenshot I use 32MiB videoram in 13 32bit floating point textures and has a grand total of 14 Cg programs loaded. Nearly 500 lines of Cg code are used. Many of these numbers would be significantly reduced on a pixel shader model 3.0 card (the GeForce 6800 to name one), and I could really need multiple render targets, but hey, that is life.On other “news” I returned to Ã…rhus yesterday from my 9 days stay at my parents. My dad and sister gave me a lift and we ended up in IKEA where I bough a new bookcase which I assembled in the evening, now all I need is to fill it with all my books and junk.
Thank you Poland
You dare bribe Santa? I’m gonna shove coal so far up your stocking you’ll be coughing up diamonds!
I am going home to my parents for christmas today, my uncle is coming to pick me up in ten minutes, just wanted to wish everybody a merry christmas.
He knows when you’re on the can,
He’ll hunt you down and blast your ass from here to Pakistan.
You better not breathe, you better not move,
You’re better off dead, I’m telling you, dude.
Santa Claus is gunning you down!
(Futurama: XMas Story)