I read some introductory text, but the concept of "shaders" bothers me. What the heck is a shader? I remember checking it on wikipedia before, but the best I could understand is that it's some kind of routine executed on the GPU against a vertex, or maybe they can be executed per-pixel too? Just guessing from the names "vertex shader" and "pixel shader". But what is a "fragment shader"? No idea. Wikipedia: "A pixel shader is a shader program, often executed on a graphics processing unit. It adds 3D shading and lighting effects to pixels in an image, for example those in video games. Microsoft's Direct X and Open GL support pixel shaders. In OpenGL a pixel shader is called a fragment shader." Ah, just a synonym.
Now, I have to admit it would be very sexy to display some 3D models of my own. But seriously, no more cubes! I've done so many of them. Always a cube on a new platform, then I get bored and make another cube a year later on another platform. Na-ah, should be a proper model at least now if I try this at all. But how do I get models with some data easy enough to load? I'm scared. Stuff I imagine I will need to load:
- bitmaps of the textures
- list of meshes
- which texture goes with which mesh
- coordinates of vertices in each mesh
- which vertices form polygons
Then to spin a 3D object...
- load object & textures
- do opengl magic to let it know about list of vertices and polygons
- maybe enter into some texture modes before each mesh? dunno.
- to spin, perhaps alter the object space -> world space transformation matrix?
- will opengl remember my vertex list etc. or do I tell it again on each frame? no idea.
So you can see I'm a bit confused about this. Let's see if there is some simple modeling tool for mac.