C# SDL::www.sjonesart.com/gl.php

I have been playing around in C# of late. By all accounts it has the same sorts of speed as C++, and from what I can see it has the same beautifully constructed syntax found in Java. The tutorials are primarily embedded in code comments. Personally I would rather have have access to a running program clearly written that I could deconstruct and decypher, than a screed of explanations peppered with uncompileable code snippets. That said, I am running Mono on XP with a reasonably current graphics card and cannot claim to know how the code will compile in other environments.

01: Setting Up Mono, MonoDevelop, Tao.SDL/OpenGL on XP

The document can be accessed from here. After following the tutorial you will have a working environment able to compile Tao.SDL/OpenGL programs in C#.

02: First Foray int SDL/OpenGL

The code is here. After following this tutorial you will have a program that displays a rotating colored cube, and writes mouse motion and key presses to the console window.

03: First Person Shooter using Quarternion Camera

The code is here. This tutorial builds upon the last, which means you will need the last tutorial if you want to compile this one. It adds a camera that rotates about the y and x axis, it moves forward/back and strafes.

04: VBO setup

The code is here. This tutorial builds upon the last, which mans you will need the last tutorial if you want to compile this one. It replaces the spinning cube with a pane made from two triangles and implemented using VBOs.

05: Shader Setup

The code is here. Basically the first steps needed to use shaders, that is, creating, compiling them, and linking them so they run.

06: Blender 2.59 exporter 12_9_11

I have recently updated the Blender exporter for the 2.59 version. The tangent exporter part needs explanation because there is a lot of bs spoken about tangent space. Normals are not stored in tangent space they are stored as if the smooth normal of the vertex, for all vertices on the model, was pointing (0,0,1) or up the z axis. The normal map stores offsets, x and y variations off that supposed normal to encode perturbations of the model_s surface. The tangent space is simply a base frame created about the point (vertex to be more accurate, then interpolated) where light hits the model, which base frame is used to rotate the the light vector (etc) so that it shines upon the normal in the normal map as it would shine upon the normal on the model. All the carry on with texture coordinates is to create a base frame to act as a transformation matrix. But you don_t need all that... nine. Consider the earth as if it had normals all over it. If you use the normal as the z axis of the base frame, and you cross that with true y (0, 1, 0) you get a tangent always parallel to the equator. This tangent is the x axis of the base frame. If you cross the normal and the tangent you get the bitangent which is the y axis of the base frame. This base frame is truly orthogonal, and truly centered about the smoothed normal. Texture space tangents, on the contrary, are either centered about face normals and therefore do not accurately stop light vectors that should fall below the horizon, or they are not orthogonal because the normals need to be bent from face normals into smooth vertex normals while leaving uv coords and therefore tangent and bitangent mapped to the face.

This exporter works by creating lists of faces. Each face is a class which contains 3 (tri) or 4 (quad) sets of attribute data. Copy and past the code into Blender_s text window and hit alt p. You must specify a file path where you want the xml file written… find it after the imports.

The python script is here