# xformOp attribute orient vs. rotateXYZ

Hello!

I am curious about the difference in the attributes orient and rotateXYZ. Is it just the quaternions vs. euler component or is there another concept behind?

Still a bit confused that all prim wrapper are using orient, but the replicator domain randomizations are only about rotateXYZ. This makes it a bit harder to combine those two for example physx and replicator.

Best, Christof

Hi @christof.schuetzenhoefer -
The `orient` attribute and `rotateXYZ` attribute are indeed different ways of representing rotations, and they use different formats.

The `orient` attribute uses quaternions to represent rotations. Quaternions are a type of complex number that can be used to represent rotations in 3D space. They have four components: one real component and three imaginary components. Quaternions are often used in 3D graphics and physics simulations because they can represent rotations without suffering from gimbal lock, a problem that can occur when using Euler angles.

On the other hand, the `rotateXYZ` attribute uses Euler angles to represent rotations. Euler angles are a set of three angles that specify the orientation of a rigid body in 3D space. They are simpler to understand and use than quaternions, but they can suffer from gimbal lock.

The reason that the replicator domain randomizations use `rotateXYZ` instead of `orient` is likely because Euler angles are simpler to work with and understand. However, if you need to use quaternions for your rotations, you can convert between Euler angles and quaternions using the appropriate mathematical formulas.

In terms of combining PhysX and replicator, you would need to ensure that the rotations are represented in a consistent manner. If PhysX uses quaternions and replicator uses Euler angles, you would need to convert between the two formats as necessary.

1 Like

Thank you for the explanation!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.