How does Blender Autodetect Texture Culture? I just asked(and found a solution) to a question here, which talks about how I encountered a texturing problem with my own Wavefront Model Parser. The problem was that some models that I was loading would be textured just fine, like models from Legend of Zelda. While other models would not be textured correctly, like Claptrap from borderlands. As it turns out, the issue was not with my parser, but due to the fact that those two models were crafted for two different API's. Nintendo uses OpenGL for Zelda/All Nintendo DS games. While DirectX is used for Borderlands. Why was this a problem? Well, OpenGL and DirectX have different texture-origins. OpenGL has its texture origin at the bottom left hand corner, while DirectX is top-left hand corner. In order to get my texture for Claptrap to render correctly I had to open the diffuse texture up in gimp and flip it vertically, thus inverting it for use with OpenGL.

This led me to an interesting question. I had opened both models in Blender before sending them into my own program. And Blender correctly textured them both. So how does Blender know which culture(OpenGL or DirectX) to use when attempting to texture a model?

I should also mention that both Models were in .obj format. The only difference is that one was created for OpenGL UV's in mind, while the other was DirectX UV's. I want to know how Blender decides which UV format/culture the .obj uses.
Blender's probably reading the instructions in the mtl (material library) file that accompanies the obj file.

According to the mtl specifications mtl files can include a parameter (-o) that instructs the program reading the file to reverse the texture's origin in the horizontal (u) or vertical (v) directions:

Quoting from the specification document:


  The -o option offsets the position of the texture map on the surface
  by shifting the position of the map origin. The default is 0, 0, 0. 
  
  "u" is the value for the horizontal direction of the texture 
  
  "v" is an optional argument.  "v" is the value for the vertical
  direction of the texture. 
  
  "w" is an optional argument.  "w" is the value used for the depth of a
  3D texture.


-o v   # This should reverse the texture's origin in the vertical direction


Open your OBJ's MTL files in a text editor and see if you can find anything that resembles this.