SOUR is a custom 3D file format designed to bridge the gap between Blender and Away3D. Aren’t there other formats which Blender exports and Away3D reads? Yes there are: OBJ, 3DS, MD2, MD5, AC3D, DAE. However, none of these formats except for DAE can save vertex tangents, and the DAE export script for Blender doesn’t save them.

What are vertex tangents, and why do they matter? Let me break it down.

What’s a Vertex Tangent?

You may know that 3D models are made of triangles. Each triangle has three points, called vertices. A vertex is a point in 3D space. Like a point in 2D space, a vertex has an X and a Y coordinate, but for 3D space, a vertex also needs a Z coordinate. There is other information related to each of a triangle’s three vertices too. I won’t go too deep into it except to say that the other information is used to light the 3D shapes correctly, and that part of that information about each vertex includes a second set of three numbers called a “vertex tangent”.

Vertex tangents are very important for “normal mapping”, a technique used to make a low-detail version of a 3D model look like it’s a high-detail version. Using normal mapping reduces the amount of power your graphics card needs to render a given 3D model, and thus increases performance without sacrificing much quality.

Back to Away3D and SOUR

Since none of the currently existing Blender export formats save vertex tangents, when Away3D reads the models, it realizes that there are no vertex tangents and attempts to figure them out itself. This is all well and good if the program used to create the 3D model’s normal map and Away3D are using the same vertex tangent generation math. Blender and Away3D don’t. The result is ugly seams on models using normal maps.

sour1_1

SOUR solves this problem by saving vertex tangent information into the 3D file. Away3D never gets a chance to generate (not incorrect but) mismatching vertex tangents, and the models look spiffy.

sour1_2

SOUR has a few other features too:

  • indexed & compressed to save space
  • bone or keyshape-based vertex animation
  • also exports vertex normals
  • has a Blender export script, an Away3D parser, and a Github page

If you do a Google search for “normal map seams”, you’ll find that Away3D isn’t even remotely the only engine which suffers from the nonstandard normal map generation problem. JMonkey, OGRE, XNA, and others all have this issue. I would love to see SOUR used more widely. If you have any suggestions for the format, leave them in the comments.