diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-10-23 20:21:55 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-10-23 20:21:55 +0400 |
commit | fec81d9b56075f46f6dde196ac85140872cff74e (patch) | |
tree | 6ee12fcc0b04ba3041f1b7e4d17281136375beb1 /source/blender/compositor/operations/COM_DilateErodeOperation.cpp | |
parent | c623ba5e4b2aa68a5717ba17500c14217bc417aa (diff) |
use min_ max_ functions in more places.
also fix minor error in MOD decimate when the modifier did nothing the reported face count would be wrong.
Diffstat (limited to 'source/blender/compositor/operations/COM_DilateErodeOperation.cpp')
-rw-r--r-- | source/blender/compositor/operations/COM_DilateErodeOperation.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/compositor/operations/COM_DilateErodeOperation.cpp b/source/blender/compositor/operations/COM_DilateErodeOperation.cpp index 9c09c9bf034..f0fffa770f8 100644 --- a/source/blender/compositor/operations/COM_DilateErodeOperation.cpp +++ b/source/blender/compositor/operations/COM_DilateErodeOperation.cpp @@ -344,28 +344,28 @@ void *DilateStepOperation::initializeTileData(rcti *rect) for (y = 0; y < bheight; y++) { for (x = 0; x < bwidth - 1; x++) { p = rectf + (bwidth * y + x); - *p = MAX2(*p, *(p + 1)); + *p = max(*p, *(p + 1)); } } for (y = 0; y < bheight; y++) { for (x = bwidth - 1; x >= 1; x--) { p = rectf + (bwidth * y + x); - *p = MAX2(*p, *(p - 1)); + *p = max(*p, *(p - 1)); } } for (x = 0; x < bwidth; x++) { for (y = 0; y < bheight - 1; y++) { p = rectf + (bwidth * y + x); - *p = MAX2(*p, *(p + bwidth)); + *p = max(*p, *(p + bwidth)); } } for (x = 0; x < bwidth; x++) { for (y = bheight - 1; y >= 1; y--) { p = rectf + (bwidth * y + x); - *p = MAX2(*p, *(p - bwidth)); + *p = max(*p, *(p - bwidth)); } } } |