diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-04-23 04:21:22 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-04-23 04:22:25 +0300 |
commit | 3302fbaeb1d5f58d926c06b6153ec5d6f1a9b0be (patch) | |
tree | 5be399e227415fef745bcdb2b7f20a578628718b /source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp | |
parent | 64b4b719ebd5201d27aa25d7fa2d765eabded9b0 (diff) |
Cleanup: style, use braces for compositor
Diffstat (limited to 'source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp')
-rw-r--r-- | source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp b/source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp index 63640d43973..90bc859a1bb 100644 --- a/source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp +++ b/source/blender/compositor/operations/COM_PlaneCornerPinOperation.cpp @@ -43,13 +43,16 @@ static bool check_corners(float corners[4][2]) sub_v2_v2v2(v2, corners[next], corners[i]); cur_cross = cross_v2v2(v1, v2); - if (fabsf(cur_cross) <= FLT_EPSILON) + if (fabsf(cur_cross) <= FLT_EPSILON) { return false; + } - if (cross == 0.0f) + if (cross == 0.0f) { cross = cur_cross; - else if (cross * cur_cross < 0.0f) + } + else if (cross * cur_cross < 0.0f) { return false; + } } return true; @@ -205,9 +208,11 @@ void *PlaneCornerPinWarpImageOperation::initializeTileData(rcti *rect) bool PlaneCornerPinWarpImageOperation::determineDependingAreaOfInterest( rcti *input, ReadBufferOperation *readOperation, rcti *output) { - for (int i = 0; i < 4; ++i) - if (getInputOperation(i + 1)->determineDependingAreaOfInterest(input, readOperation, output)) + for (int i = 0; i < 4; ++i) { + if (getInputOperation(i + 1)->determineDependingAreaOfInterest(input, readOperation, output)) { return true; + } + } /* XXX this is bad, but unavoidable with the current design: * we don't know the actual corners and matrix at this point, |