Horde3D
http://horde3d.org/forums/

Coordinate systems, directx math -> opengl render
http://horde3d.org/forums/viewtopic.php?f=2&t=1092
Page 1 of 1

Author:  craigomatic [ 02.02.2010, 06:37 ]
Post subject:  Coordinate systems, directx math -> opengl render

Most of our existing codebase operates in a coordinate system where at the origin with zero rotation:

x increases to the right
y increases upwards
z increases into the screen

Reference image:
Attachment:
File comment: Reference image with all models being drawn correctly
directx-reference-image.JPG
directx-reference-image.JPG [ 19.93 KiB | Viewed 7006 times ]


Horde image:
Attachment:
File comment: h3d version of the same scene. The camera has been rotated 180 around the vertical axis (y) as otherwise all you see is the grey background! Ignore the missing material colours, lower position of the sphere and different poses on the characters
h3d-image.PNG
h3d-image.PNG [ 32.84 KiB | Viewed 7006 times ]


We're hoping to be able to continue with this style of coordinate system on top of Horde3d but are unsure of the correct way to massage the matrix across to give the correct visual.

I've tried a number of different approaches from scaling the camera matrix by 1,1,-1 to swapping out matrix columns, but feel like I'm stabbing in the dark somewhat.

Does anyone have any advice or feel like taking a look at the source? We're an open source virtual worlds platform, contributions are welcome :)

Link: http://vastpark.svn.cvsdude.com/public/branches/1.0.x/

Author:  marciano [ 03.02.2010, 22:51 ]
Post subject:  Re: Coordinate systems, directx math -> opengl render

Essentially, what you describe is left-handed (yours, d3d) against right-handed (gl, horde) coordinate systems. This link has a few pointers.

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