# Translation when Rotating?

**URL:** <https://forum.aousd.org/t/translation-when-rotating/999>\
**Category:** USD\
**Tags:** python, beginner\
**Created:** [November 29, 2023, 7:54pm UTC](https://forum.aousd.org/t/translation-when-rotating/999 "2023-11-29T19:54:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dinonel](https://avatars.discourse-cdn.com/v4/letter/d/4bbf92/32.png) [@Dinonel](https://forum.aousd.org/u/Dinonel)\
**Post date:** [November 29, 2023, 7:54pm UTC](https://forum.aousd.org/t/translation-when-rotating/999/1 "2023-11-29T19:54:29Z")

</div>

Hi all, I have a very basic scene where I have a stage with my up-axis being z. There is a camera prim placed at (0, -30, 0) that has a RotateX(90) applied to it so that it matches the up-axis of the stage. The camera starts off by facing the origin, and then I move the aperture in a circle and offset the camera to get a certain effect. Now I would like to somehow keep the camera at the origin, which I thought I could achieve by rotating back in the opposite direction the aperture moves but I’m ending up with a net translation along the -x-axis. This is probably an issue with my axes but I was wondering if this raised any red flags for anyone that could help me with the issue. For reference, the camera is moving in a quarter-circle CCW from its starting position.

Edit:

I have attached a file that replicates what I am experiencing.  
[spherical\_to\_xyz\_rotation.usda](https://forum.aousd.org/uploads/short-url/9YZJa3uAGUItHgyDxEHeoBAL04X.usda) (43.6 KB)

---

<div class="post-metadata">

**Author:** ![Dinonel](https://avatars.discourse-cdn.com/v4/letter/d/4bbf92/32.png) [@Dinonel](https://forum.aousd.org/u/Dinonel)\
**Post date:** [November 30, 2023, 8:58pm UTC](https://forum.aousd.org/t/translation-when-rotating/999/2 "2023-11-30T20:58:12Z")

</div>

I had my axes swapped around… the problem has been solved
