Jump to content

[SOLVED] How to convert local coordinates to world coordinates.


photo

Recommended Posts

So, normally what I would do is simply multiply the vector by the matrix, doing that in Unigine appears to produce incorrect results

Vec3 a = p->getTransform().getTranslate() + p->getTransform().getAxisZ(); // = {-13.0793009, 36.1701622, -14.3145294}
Vec3 b = ((Vec3(0,0,1)) * p->getTransform()); // = {-0.228823692, 0.184904218, -0.955745995}

It seems to me that these should be equal, but they are not. what am I doing wrong?

  • Like 3
Link to comment
  • silent changed the title to [SOLVED] How to convert local coordinates to world coordinates.
×
×
  • Create New...