* icdar/2009/hsc/clean_input.hh: Use pcenter().
* icdar/2009/hsc/ws_to_wsl.hh: Update call to
make::p_vertices_with_mass_centers.
---
milena/sandbox/ChangeLog | 9 +++++++++
milena/sandbox/icdar/2009/hsc/clean_input.hh | 2 +-
milena/sandbox/icdar/2009/hsc/ws_to_wsl.hh | 14 +++++++-------
3 files changed, 17 insertions(+), 8 deletions(-)
diff --git a/milena/sandbox/ChangeLog b/milena/sandbox/ChangeLog
index 34e60e0..48984a8 100644
--- a/milena/sandbox/ChangeLog
+++ b/milena/sandbox/ChangeLog
@@ -1,3 +1,12 @@
+2011-05-18 Guillaume Lazzara <z(a)lrde.epita.fr>
+
+ Make code for icdar 2009 compile.
+
+ * icdar/2009/hsc/clean_input.hh: Use pcenter().
+
+ * icdar/2009/hsc/ws_to_wsl.hh: Update call to
+ make::p_vertices_with_mass_centers.
+
2010-06-21 Yann Jacquelet <jacquelet(a)lrde.epita.fr>
Add milena library components.
diff --git a/milena/sandbox/icdar/2009/hsc/clean_input.hh
b/milena/sandbox/icdar/2009/hsc/clean_input.hh
index 1c5b572..c243a14 100644
--- a/milena/sandbox/icdar/2009/hsc/clean_input.hh
+++ b/milena/sandbox/icdar/2009/hsc/clean_input.hh
@@ -34,7 +34,7 @@ namespace mln
ok(l) = true; // into bg
continue;
}
- int center_col = box[l].center().col();
+ int center_col = box[l].pcenter().col();
if (center_col >= max_col - 3 ||
center_col <= 3)
ok(l) = true;
diff --git a/milena/sandbox/icdar/2009/hsc/ws_to_wsl.hh
b/milena/sandbox/icdar/2009/hsc/ws_to_wsl.hh
index c488f9f..35b8675 100644
--- a/milena/sandbox/icdar/2009/hsc/ws_to_wsl.hh
+++ b/milena/sandbox/icdar/2009/hsc/ws_to_wsl.hh
@@ -136,7 +136,7 @@ namespace mln
def::coord col() const
{
mln_invariant(valid_);
- return static_cast<def::coord>(0.49999f + mean_[1]); // col = coord #1
+ return static_cast<def::coord>(0.49999f + mean_[1]); // col = coord #1
}
/// Get the covariance matrix.
@@ -184,7 +184,7 @@ namespace mln
algebra::mat<2,2,float> cov_, cov_1_;
float lambda1_, lambda2_;
};
-
+
template <typename L>
@@ -264,7 +264,7 @@ namespace mln
typedef util::graph G;
G gr = make::region_adjacency_graph(ws, c8(), n_basins);
-
+
util::array<mahalanobis> m;
m = mahalanobis_from_images(ws, small, n_basins);
@@ -311,7 +311,7 @@ namespace mln
literal::red);
typedef p_vertices< G, fun::i2v::array<point2d> > pv_t;
- pv_t pv = make::p_vertices_with_mass_centers(ws, n_basins, gr);
+ pv_t pv = make::p_vertices_with_mass_centers(ws, gr);
debug::draw_graph(cool, pv,
literal::green,
@@ -321,7 +321,7 @@ namespace mln
}
#endif // LOG
-
+
util::array<unsigned>
v_left (n_basins + 1),
v_right(n_basins + 1);
@@ -373,7 +373,7 @@ namespace mln
}
-
+
util::array<L> parent(n_basins + 1);
// Computing parent.
@@ -433,7 +433,7 @@ namespace mln
unsigned s = input.nrows() / small.nrows();
image2d<L> ws_nol = morpho::elementary::dilation(ws, c8());
-
+
mln_piter(box2d) p(input.domain());
for_all(p)
if (input(p))
--
1.5.6.5