NegInfinity/ProjectExodus

Unity Rotation to Unreal

Opened this issue · 1 comments

Hi ! I got the awnser for the coordinate from Unity to Unreal
X : Unity(x) -> UE4(y) * 100.0f
Y : Unity(y) -> UE4(z) * 100.0f
Z : Unity(z) -> UE4(x) * 100.0f

But for rotation I try to search in the UnrealUtilities.cpp but I coudn't find the awnser. Every vector is for the POS but I try to search for any ROT or DIR function but nothing I don't understand.

Thanks for your fabulous work !

@DiabloFox Hi. Sorry for a big delay with the response.

The project converts object matrix stored within the object and reconstructs it on Unreal side. It means, it does not perform conversion between different rotational systems (yaw/pitch/roll, euler angles) in different engines, and simply takes a matrix, splits it into 4 vectors (position, local x, local y, local z), converts THOSE and then puts them back together into a matrix on unreal side.

Rotational values are then derived from the matrix by the engine.

Strictly speaking object transform is usually stored as either as a matrix, or in some other cases - as a position vector, (local) scale vector, and rotataional quaternion. And those are used for storing rotation, translation and scale. Euler angles, Yaw/pitch/roll rotations and the like are provided for user convenience, but are stored as an object transform.

Hopefully that answers the question.