What steps will reproduce the problem?
1. Export your textured mesh from Cinema4D using the Wavefront Exporter
2. Load it into your app using the WavefronOBJ loader
3. The r- and s-values seem to be flipped which causes the renderer to repeat
the left-most row
of your texture all over the polygon (since r, which is mostly 0.0, is used as
the s-value).
What is the expected output? What do you see instead?
Texture coords would have to be added in the right order.
Please provide any additional information below.
When working with Cinema4D you will have to alter the following lines to get
things working:
Replace the texture coord assignments inside the processOneVertex function (in
OpenGLWavefrontObject.m) with this line:
textureCoords[(vertexNode->actualVertex * componentsPerTextureCoord) + i] =
allTextureCoords[(vertexNode->textureCoords * componentsPerTextureCoord) + i] ;
Be aware that there are two occurences (in my case they're in line 33 and 44)!
This will cause the texture coordinates to be assigned in the order they appear
in your
Cinema4D OBJ export.
Original issue reported on code.google.com by stk...@gmail.com on 6 Feb 2010 at 12:01
Original issue reported on code.google.com by
stk...@gmail.com
on 6 Feb 2010 at 12:01