Autodesk / Autodesk/maya-usd

Duplicate with Transform (Shift + D) incorrect with moved mayaUsdProxyShape transform

Open
#3,620 0 comments 0 reactions 1 assignee Claimed by @santosg87 View on GitHub
bug
Dominant language
Wolfram Language
Stars
905
Forks
223
Avg merge
2d 9h
Merged PRs (30d)
17

Description

**Describe the bug**

If the `mayaUsdProxyShape`'s transform is not at origin (not identity matrix) then whever Duplicate with Transform is used then it will incorrectly 'double transform' the the transformation that is applied to the Stage Proxy transform.

**Steps to reproduce**
Steps to reproduce the behavior:
1. Create empty Maya USD Proxy
2. Translate the stage itself, up by 5 units in Y axis
3. Create a Cube Prim in USD stage
4. Press Shift + D
6. Move the duplicate Cube to the right, e.g. 2 units
7. Press Shift + D to duplicate with transform.

Note how the third cube appears higher.

![image](https://github.com/Autodesk/maya-usd/assets/2439881/2e823fd3-4aaf-45a2-8376-d8f44283f9cc)

The cube three has the Y = 5 also applied locally, even though it should've accounted for its parent transforms.
It should've only really applied the diff between start and end matrix of the transformation since last "Shift + D".

![image](https://github.com/Autodesk/maya-usd/assets/2439881/fc9ee574-5e68-4b44-a874-ab655b82822a)

**Expected behavior**

Proxy Shape's transform should be accounted for and not apply as double transforms.

![image](https://github.com/Autodesk/maya-usd/assets/2439881/013b561b-21c9-43a3-8142-a21bc953e5c9)

**Specs (if applicable):**

- OS & version: Windows 10
- Maya version: 2024.2
- Maya USD: 0.27.0

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.