diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-07-19 00:32:31 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-07-19 00:32:31 +0400 |
commit | db14b97be6917d961c893ba6e0188c927ffa67b0 (patch) | |
tree | a03051a686a7ad779120dd4bcfeff0c7d22f4f60 /source/blender/editors/transform | |
parent | 64234612479f02ed38deca2395a4c0ba4a2ee94a (diff) |
mask transform aspect correction wasn't working properly, also fix for own recent commit which made cyclic report not show
Diffstat (limited to 'source/blender/editors/transform')
-rw-r--r-- | source/blender/editors/transform/transform.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c index 0be871add75..5232371fcaf 100644 --- a/source/blender/editors/transform/transform.c +++ b/source/blender/editors/transform/transform.c @@ -174,8 +174,14 @@ void convertViewVec(TransInfo *t, float r_vec[3], int dx, int dy) if (t->options & CTX_MASK) { /* clamp w/h, mask only */ - divx = divy = maxf(divx, divy); - mulx = muly = minf(mulx, muly); + if (mulx / divx < muly / divy) { + divx = divy = divx; + mulx = muly = mulx; + } + else { + divx = divy = divy; + mulx = muly = muly; + } } r_vec[0] = mulx * (dx) / divx; |