---
scribo/ChangeLog | 4 ++++
scribo/binarization/sauvola_ms.hh | 2 +-
2 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/scribo/ChangeLog b/scribo/ChangeLog
index b03b8e4..7b779f7 100644
--- a/scribo/ChangeLog
+++ b/scribo/ChangeLog
@@ -1,5 +1,9 @@
2010-06-25 Guillaume Lazzara <z(a)lrde.epita.fr>
+ * binarization/sauvola_ms.hh: Fix an invalid test.
+
+2010-06-25 Guillaume Lazzara <z(a)lrde.epita.fr>
+
* upsampling/eagle.hh: Add a new upsampling algorithm.
2010-06-23 Arthur Crepin-Leblond <crepin(a)stockholm.lrde.epita.fr>
diff --git a/scribo/binarization/sauvola_ms.hh b/scribo/binarization/sauvola_ms.hh
index 0390180..8964324 100644
--- a/scribo/binarization/sauvola_ms.hh
+++ b/scribo/binarization/sauvola_ms.hh
@@ -158,7 +158,7 @@ namespace scribo
w_local_w = w_local;
// Make sure the window fits in the image domain.
- if (w >= static_cast<const unsigned>(integral_sum_sum_2.ncols()))
+ if (w_local_w >= static_cast<const unsigned>(integral_sum_sum_2.ncols()))
{
w_local_w = std::min(integral_sum_sum_2.ncols(), integral_sum_sum_2.nrows()) -
integral_sum_sum_2.border();
w_local_h = w_local_w;
--
1.5.6.5