Commit a3c4e92a authored by Guillaume Lazzara's avatar Guillaume Lazzara
Browse files

Rename point_at_index and index_of_point.

	* scribo/binarization/internal/niblack_functor_fast.hh,
	* scribo/binarization/internal/niblack_threshold_functor.hh,
	* scribo/binarization/internal/sauvola_functor.hh,
	* scribo/binarization/internal/sauvola_threshold_functor.hh,
	* scribo/binarization/internal/singh_functor.hh,
	* scribo/binarization/internal/wolf_functor_fast.hh,
	* scribo/binarization/sauvola_ms.hh,
	* scribo/util/init_integral_image.hh,
	* scribo/util/integral_sub_sum_sum2_functor.hh: Here.
parent 18a13882
2013-03-01 Guillaume Lazzara <z@lrde.epita.fr>
Rename point_at_index and index_of_point.
* scribo/binarization/internal/niblack_functor_fast.hh,
* scribo/binarization/internal/niblack_threshold_functor.hh,
* scribo/binarization/internal/sauvola_functor.hh,
* scribo/binarization/internal/sauvola_threshold_functor.hh,
* scribo/binarization/internal/singh_functor.hh,
* scribo/binarization/internal/wolf_functor_fast.hh,
* scribo/binarization/sauvola_ms.hh,
* scribo/util/init_integral_image.hh,
* scribo/util/integral_sub_sum_sum2_functor.hh: Here.
2013-03-01 Guillaume Lazzara <z@lrde.epita.fr>
* scribo/text/recognition.hh: Fix tesseract includes.
......
// Copyright (C) 2012 EPITA Research and Development Laboratory (LRDE)
// Copyright (C) 2012, 2013 EPITA Research and Development Laboratory
// (LRDE)
//
// This file is part of Olena.
//
......@@ -104,11 +105,11 @@ namespace scribo
if (more_offset == - 3)
more_offset = 0; // No offset needed.
next_line3 = input.delta_index(dpoint2d(+2,0))
next_line3 = input.delta_offset(dpoint2d(+2,0))
+ 2 * input.border() + more_offset;
offset1 = input.delta_index(dpoint2d(+1,0));
offset2 = input.delta_index(dpoint2d(+2,0));
offset1 = input.delta_offset(dpoint2d(+1,0));
offset2 = input.delta_offset(dpoint2d(+2,0));
initialize(output, input);
po = &output(output.domain().pmin());
......
// Copyright (C) 2011, 2012 EPITA Research and Development Laboratory
// (LRDE)
// Copyright (C) 2011, 2012, 2013 EPITA Research and Development
// Laboratory (LRDE)
//
// This file is part of Olena.
//
......@@ -97,10 +97,10 @@ namespace scribo
const I& input = exact(input_);
mln_precondition(input.is_valid());
next_line3 = input.delta_index(dpoint2d(+2,0)) + 2 * input.border() - 1;
next_line3 = input.delta_offset(dpoint2d(+2,0)) + 2 * input.border() - 1;
offset1 = input.delta_index(dpoint2d(+1,0));
offset2 = input.delta_index(dpoint2d(+2,0));
offset1 = input.delta_offset(dpoint2d(+1,0));
offset2 = input.delta_offset(dpoint2d(+2,0));
initialize(output, input);
po = &output(output.domain().pmin());
......
// Copyright (C) 2011, 2012 EPITA Research and Development Laboratory
// (LRDE)
// Copyright (C) 2011, 2012, 2013 EPITA Research and Development
// Laboratory (LRDE)
//
// This file is part of Olena.
//
......@@ -107,11 +107,11 @@ namespace scribo
if (more_offset == - 3)
more_offset = 0; // No offset needed.
next_line3 = input.delta_index(dpoint2d(+2,0))
next_line3 = input.delta_offset(dpoint2d(+2,0))
+ 2 * input.border() + more_offset;
offset1 = input.delta_index(dpoint2d(+1,0));
offset2 = input.delta_index(dpoint2d(+2,0));
offset1 = input.delta_offset(dpoint2d(+1,0));
offset2 = input.delta_offset(dpoint2d(+2,0));
initialize(output, input);
po = &output(output.domain().pmin());
......
// Copyright (C) 2011, 2012 EPITA Research and Development Laboratory
// (LRDE)
// Copyright (C) 2011, 2012, 2013 EPITA Research and Development
// Laboratory (LRDE)
//
// This file is part of Olena.
//
......@@ -99,10 +99,10 @@ namespace scribo
const I& input = exact(input_);
mln_precondition(input.is_valid());
next_line3 = input.delta_index(dpoint2d(+2,0)) + 2 * input.border() - 1;
next_line3 = input.delta_offset(dpoint2d(+2,0)) + 2 * input.border() - 1;
offset1 = input.delta_index(dpoint2d(+1,0));
offset2 = input.delta_index(dpoint2d(+2,0));
offset1 = input.delta_offset(dpoint2d(+1,0));
offset2 = input.delta_offset(dpoint2d(+2,0));
initialize(output, input);
po = &output(output.domain().pmin());
......
// Copyright (C) 2012 EPITA Research and Development Laboratory (LRDE)
// Copyright (C) 2012, 2013 EPITA Research and Development Laboratory
// (LRDE)
//
// This file is part of Olena.
//
......@@ -105,11 +106,11 @@ namespace scribo
if (more_offset == - 3)
more_offset = 0; // No offset needed.
next_line3 = input.delta_index(dpoint2d(+2,0))
next_line3 = input.delta_offset(dpoint2d(+2,0))
+ 2 * input.border() + more_offset;
offset1 = input.delta_index(dpoint2d(+1,0));
offset2 = input.delta_index(dpoint2d(+2,0));
offset1 = input.delta_offset(dpoint2d(+1,0));
offset2 = input.delta_offset(dpoint2d(+2,0));
initialize(output, input);
po = &output(output.domain().pmin());
......
// Copyright (C) 2012 EPITA Research and Development Laboratory (LRDE)
// Copyright (C) 2012, 2013 EPITA Research and Development Laboratory
// (LRDE)
//
// This file is part of Olena.
//
......@@ -115,11 +116,11 @@ namespace scribo
if (more_offset == - 3)
more_offset = 0; // No offset needed.
next_line3 = input.delta_index(dpoint2d(+2,0))
next_line3 = input.delta_offset(dpoint2d(+2,0))
+ 2 * input.border() + more_offset;
offset1 = input.delta_index(dpoint2d(+1,0));
offset2 = input.delta_index(dpoint2d(+2,0));
offset1 = input.delta_offset(dpoint2d(+1,0));
offset2 = input.delta_offset(dpoint2d(+2,0));
initialize(output, input);
po = &output(output.domain().pmin());
......
// Copyright (C) 2009, 2010, 2011, 2012 EPITA Research and Development
// Laboratory (LRDE)
// Copyright (C) 2009, 2010, 2011, 2012, 2013 EPITA Research and
// Development Laboratory (LRDE)
//
// This file is part of Olena.
//
......@@ -247,7 +247,7 @@ namespace scribo
# ifdef SCRIBO_LOCAL_THRESHOLD_DEBUG
f.full_msk.element(p) = f.full_msk.element(f.parent.element(p));
point2d sqp = f.parent.point_at_index(f.parent.element(p)) * ratio;
point2d sqp = f.parent.point_at_offset(f.parent.element(p)) * ratio;
unsigned v = debug_scale_proba(point3d(i - 2, sqp.row(), sqp.col()));
for (unsigned l = 0; l < ratio; ++l)
......
// Copyright (C) 2009, 2010, 2011 EPITA Research and Development
// Copyright (C) 2009, 2010, 2011, 2013 EPITA Research and Development
// Laboratory (LRDE)
//
// This file is part of Olena.
......@@ -99,14 +99,14 @@ namespace scribo
J integral_sum_sum_2(output_domain, border);
V2* p_integ = integral_sum_sum_2.buffer();
const int up = integral_sum_sum_2.delta_index(dpoint2d(-1, 0));
const int up = integral_sum_sum_2.delta_offset(dpoint2d(-1, 0));
const unsigned nrows = scale * integral_sum_sum_2.nrows();
const unsigned ncols = scale * integral_sum_sum_2.ncols();
unsigned row = 0;
unsigned b_offset = integral_sum_sum_2.delta_index(dpoint2d(border,
unsigned b_offset = integral_sum_sum_2.delta_offset(dpoint2d(border,
border));
// First row (special case)
......
// Copyright (C) 2011 EPITA Research and Development Laboratory (LRDE)
// Copyright (C) 2011, 2013 EPITA Research and Development Laboratory
// (LRDE)
//
// This file is part of Olena.
//
......@@ -110,7 +111,7 @@ namespace scribo
area = scale * scale;
b_next = 2 * border;
unsigned b_offset = sub.delta_index(dpoint2d(border, border));
unsigned b_offset = sub.delta_offset(dpoint2d(border, border));
p_sub = sub.buffer() + b_offset;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment