SDL/OpenGL - A good start
I've been putting off learning OpenGL for a long time now. I haven't had a particularly compelling use case, and since my laptop can't run it for crap anyway I didn't worry about it. Most of my graphical code is 2D.
But, yesterday the bug got me, and I decided to really dig into it for once. I'm using SDL as my main lib for setting up everything. At the end of the day (around, oh, 6 AM or so) I had a pretty solid beginning. I started building some functions for handling lists of quads and tris, and was diving into Blender again (an on-and-off love-hate relationship) to find a decent export format to use. I settled on .obj; it is a clean and useful format. I got some small part of a loader finished and went to bed.
Today I've got the loader complete, in a sense. For now it only handles quads, not tris or polys. Adding support for those will only be a modification in one section of the loader, though, because of how .obj organizes itself.
It also doesn't support multiple objects yet, which .obj does. That will come in time.
So, I'm wrapping up for the day and so far I have:
- A basic object struct that contains tri, quad, and poly lists. It will be expanded later.
- Some basic rendering functions for quads and tris.
- Support for loading .obj format, including face normals and texture UV data.
Not bad for about a day and a half's work.
Next up will be adding some basic UI stuff (trivial control stuff via SDL) and building up my scene heirarchy.