Mercurial > hg > svcore
diff data/model/PowerOfSqrtTwoZoomConstraint.cpp @ 383:94fc0591ea43 1.2-stable
* merge from trunk (1.2 ended up being tracked from trunk, but we may want
this branch for fixes later)
author | Chris Cannam |
---|---|
date | Wed, 27 Feb 2008 10:32:45 +0000 |
parents | 3a13b0d4934e |
children | d7f3dfe6f9a4 |
line wrap: on
line diff
--- a/data/model/PowerOfSqrtTwoZoomConstraint.cpp Fri Nov 30 17:36:14 2007 +0000 +++ b/data/model/PowerOfSqrtTwoZoomConstraint.cpp Wed Feb 27 10:32:45 2008 +0000 @@ -75,7 +75,13 @@ } // std::cerr << "Testing base " << base << std::endl; - if (base >= blockSize) { + + if (base == blockSize) { + result = base; + break; + } + + if (base > blockSize) { if (dir == RoundNearest) { if (base - blockSize < blockSize - prevBase) { dir = RoundUp;