Hi,

I try to get the world coordinates of an object, but I fail.
I am using the following code:


Matrix planeMatrix;
transNode->getToWorld(planeMatrix);
Pnt3f planeCenter;
// local origin
planeCenter[0] = 0;
planeCenter[1] = 0;
planeCenter[2] = 0;
Vec3f planeCenterW;
planeMatrix.multMatrixVec(planeCenter, planeCenterW);

Unfortunately planeCenterW = (0,0,0), which AFAIK it should not as planeMatrix =
1.0  0.0  0.0  2.8
0.0 -1.0  0.0 13.1
0.0  0.0 -1.0  0.0
0.0  0.0  0.0  1.0

What am I doing wrong and how do I get the world coordinates of the local origin
of my object.

tia
Reimar

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to