Horde3D
http://horde3d.org/forums/

y/z up axis converter problem
http://horde3d.org/forums/viewtopic.php?f=11&t=2282
Page 1 of 1

Author:  wiseguy [ 06.09.2015, 11:31 ]
Post subject:  y/z up axis converter problem

Hello.

I was reading thru the code for H3D collada converter and found a strange line of code regarding adjusting for Z_UP flag in collada.
Code:
if( !_daeDoc.y_up )
{   
   swap( v.pos.y, v.pos.z );
   v.pos.z *= -1;
}

Swap of z and y coordinate is obvious, but the negation of z is strange.

I was importing a Blender model with a modified H3D converter for my own engine and everything worked fine, skeletal animations, meshes. The only thing wrong was that the model was pointing in the negative z direction when it should point in positive z direction. Can than be because of that line of code?

Author:  Volker [ 06.09.2015, 21:56 ]
Post subject:  Re: y/z up axis converter problem

Probably yes. I think the reason for this line was left handed vs. right handed coordinate system. But it has been a long time ago that I've ocupied myself with that code.

Page 1 of 1 All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/