Friday, October 12, 2007

Re-arranged yet again

After re-arranging the display device and render device code to what I thought was better I’ve re-arranged it yet again. While looking at render targets, the default render target in particular I realized that the default render target gets its pixel format from the display device’s pixel format. This is done when the render device is first open which based on my previous code is before the display device’s pixel format is known. All in all I think all the OpenGL initialization code is better placed in the display device.

I’ve started working on primitives. OpenGL’s C interface makes managing vertex and index buffers very simple, so simple in fact that it feels like I’ve missed something. I like it!

I’m still now just working on the code without testing it as I need to implement a few more classes before I can see what I’m actually doing.

No comments: