Files
test2/source
Philipp Oeser c67e96e8ea Fix #131585: UV translation wrong in header when constraints are used
For a bit of (somewhat related) history, check 8d590e4b86.

The real problem here is that for non square images, the
`applyAspectRatio` works with "wrong" vectors if translation constraints
(`CON_APPLY`) are used. Then, the passed vector might actually have axis
changed, e.g. constraining to the Y axis does not hold the Y translation
value in dvec[1], but in dvec[0]. This is expected by design, but
`applyAspectRatio` is not aware of this and does wrong things.

The easy way around this is to actually call `applyAspectRatio` before
the `CON_APPLY` stuff takes place.

NOTE: future improvement might be to split (or rename)
`removeAspectRatio` / `applyAspectRatio` becaues these functions also
handle the "conversion" to pixel values which is not obvious atm.

Pull Request: https://projects.blender.org/blender/blender/pulls/131608
2024-12-09 19:55:43 +01:00
..