* apps/Makefile.am,
* apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc,
* apps/mesh-segm-skel/mesh-complex-max-curv.cc,
* apps/mesh-segm-skel/mesh-complex-segm.cc,
* apps/mesh-segm-skel/mesh-complex-skel.cc,
* apps/mesh-segm-skel/mesh-max-curv.cc,
* apps/mesh-segm-skel/mesh-pinv-curv.cc,
* apps/mesh-segm-skel/mesh-segm.cc,
* apps/mesh-segm-skel/mesh-skel.cc,
* mesh/Makefile.am:
s/statues/mesh-segm-skel/.
* apps/mesh-segm-skel/io.hh,
* apps/mesh-segm-skel/save_bin_alt.hh,
* apps/mesh-segm-skel/trimesh/misc.hh:
Likewise.
Adjust header guards.
---
milena/ChangeLog | 21 ++++++++++++++++++++
milena/apps/Makefile.am | 2 +-
milena/apps/mesh-segm-skel/io.hh | 8 +++---
.../mesh-segm-skel/mesh-complex-max-curv-segm.cc | 2 +-
.../apps/mesh-segm-skel/mesh-complex-max-curv.cc | 2 +-
milena/apps/mesh-segm-skel/mesh-complex-segm.cc | 2 +-
milena/apps/mesh-segm-skel/mesh-complex-skel.cc | 2 +-
milena/apps/mesh-segm-skel/mesh-max-curv.cc | 2 +-
milena/apps/mesh-segm-skel/mesh-pinv-curv.cc | 2 +-
milena/apps/mesh-segm-skel/mesh-segm.cc | 2 +-
milena/apps/mesh-segm-skel/mesh-skel.cc | 2 +-
milena/apps/mesh-segm-skel/save_bin_alt.hh | 6 ++--
milena/apps/mesh-segm-skel/trimesh/misc.hh | 6 ++--
milena/mesh/Makefile.am | 12 +++++-----
14 files changed, 46 insertions(+), 25 deletions(-)
diff --git a/milena/ChangeLog b/milena/ChangeLog
index dc2e0a1..223d040 100644
--- a/milena/ChangeLog
+++ b/milena/ChangeLog
@@ -1,5 +1,26 @@
2009-09-04 Roland Levillain <roland(a)lrde.epita.fr>
+ Adjust names w.r.t. apps/mesh-segm-skel/.
+
+ * apps/Makefile.am,
+ * apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc,
+ * apps/mesh-segm-skel/mesh-complex-max-curv.cc,
+ * apps/mesh-segm-skel/mesh-complex-segm.cc,
+ * apps/mesh-segm-skel/mesh-complex-skel.cc,
+ * apps/mesh-segm-skel/mesh-max-curv.cc,
+ * apps/mesh-segm-skel/mesh-pinv-curv.cc,
+ * apps/mesh-segm-skel/mesh-segm.cc,
+ * apps/mesh-segm-skel/mesh-skel.cc,
+ * mesh/Makefile.am:
+ s/statues/mesh-segm-skel/.
+ * apps/mesh-segm-skel/io.hh,
+ * apps/mesh-segm-skel/save_bin_alt.hh,
+ * apps/mesh-segm-skel/trimesh/misc.hh:
+ Likewise.
+ Adjust header guards.
+
+2009-09-04 Roland Levillain <roland(a)lrde.epita.fr>
+
Rename apps/statues/ as apps/mesh-segm-skel/.
* apps/statues/: Rename directory as...
diff --git a/milena/apps/Makefile.am b/milena/apps/Makefile.am
index e1555f6..3e41536 100644
--- a/milena/apps/Makefile.am
+++ b/milena/apps/Makefile.am
@@ -17,4 +17,4 @@
## Process this file through Automake to produce Makefile.in.
-SUBDIRS = statues
+SUBDIRS = mesh-segm-skel
diff --git a/milena/apps/mesh-segm-skel/io.hh b/milena/apps/mesh-segm-skel/io.hh
index 978ad40..4f8f084 100644
--- a/milena/apps/mesh-segm-skel/io.hh
+++ b/milena/apps/mesh-segm-skel/io.hh
@@ -25,10 +25,10 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-#ifndef APPS_STATUES_IO_HH
-# define APPS_STATUES_IO_HH
+#ifndef APPS_MESH_SEGM_SKEL_IO_HH
+# define APPS_MESH_SEGM_SKEL_IO_HH
-/// \file apps/statues/io.hh
+/// \file apps/mesh-segm-skel/io.hh
/// \brief I/O routines adapted from TriMesh's ones.
#include <algorithm>
@@ -202,4 +202,4 @@ inline void write_off_binary(TriMesh *mesh,
}
/// \}
-#endif // ! APPS_STATUES_IO_HH
+#endif // ! APPS_MESH_SEGM_SKEL_IO_HH
diff --git a/milena/apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc b/milena/apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc
index 4c08227..477ccdf 100644
--- a/milena/apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc
+++ b/milena/apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-complex-max-curv-segm.cc
+/// \file apps/mesh-segm-skel/mesh-complex-max-curv-segm.cc
/// \brief A program computing the maximal curvature values from the
/// surface of the (triangle) mesh of a statue, then performing a
/// WST-based segmentation, using a complex-based image.
diff --git a/milena/apps/mesh-segm-skel/mesh-complex-max-curv.cc b/milena/apps/mesh-segm-skel/mesh-complex-max-curv.cc
index 9924a91..8d79839 100644
--- a/milena/apps/mesh-segm-skel/mesh-complex-max-curv.cc
+++ b/milena/apps/mesh-segm-skel/mesh-complex-max-curv.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-complex-max-curv.cc
+/// \file apps/mesh-segm-skel/mesh-complex-max-curv.cc
/// \brief A program computing the max curvature at each (2-)face of
/// the surface of the (triangle) mesh of a statue, using a
/// complex-based image.
diff --git a/milena/apps/mesh-segm-skel/mesh-complex-segm.cc b/milena/apps/mesh-segm-skel/mesh-complex-segm.cc
index 041ec7c..8d349fe 100644
--- a/milena/apps/mesh-segm-skel/mesh-complex-segm.cc
+++ b/milena/apps/mesh-segm-skel/mesh-complex-segm.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-complex-segm.cc
+/// \file apps/mesh-segm-skel/mesh-complex-segm.cc
/// \brief A program performing a WST-based segmentation of the
/// surface of the (triangle) mesh of a statue, using a complex-based
/// image.
diff --git a/milena/apps/mesh-segm-skel/mesh-complex-skel.cc b/milena/apps/mesh-segm-skel/mesh-complex-skel.cc
index 1834e2d..a4df815 100644
--- a/milena/apps/mesh-segm-skel/mesh-complex-skel.cc
+++ b/milena/apps/mesh-segm-skel/mesh-complex-skel.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-complex-skel.cc
+/// \file apps/mesh-segm-skel/mesh-complex-skel.cc
/// \brief A program computing a skeleton of the surface of the
/// (triangle) mesh of a statue (by thinning), using a complex-based
/// image.
diff --git a/milena/apps/mesh-segm-skel/mesh-max-curv.cc b/milena/apps/mesh-segm-skel/mesh-max-curv.cc
index ee7f9e3..b612478 100644
--- a/milena/apps/mesh-segm-skel/mesh-max-curv.cc
+++ b/milena/apps/mesh-segm-skel/mesh-max-curv.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-max-curv.cc
+/// \file apps/mesh-segm-skel/mesh-max-curv.cc
/// \brief A program computing the max curvature at each (2-)face of
/// a mesh.
diff --git a/milena/apps/mesh-segm-skel/mesh-pinv-curv.cc b/milena/apps/mesh-segm-skel/mesh-pinv-curv.cc
index 91802b3..69a9492 100644
--- a/milena/apps/mesh-segm-skel/mesh-pinv-curv.cc
+++ b/milena/apps/mesh-segm-skel/mesh-pinv-curv.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-pinv-curv.cc
+/// \file apps/mesh-segm-skel/mesh-pinv-curv.cc
/// \brief A program computing the pseudo-inverse curvature at each
/// (2-)face of a mesh.
diff --git a/milena/apps/mesh-segm-skel/mesh-segm.cc b/milena/apps/mesh-segm-skel/mesh-segm.cc
index da4b24d..bf87249 100644
--- a/milena/apps/mesh-segm-skel/mesh-segm.cc
+++ b/milena/apps/mesh-segm-skel/mesh-segm.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-segm.cc
+/// \file apps/mesh-segm-skel/mesh-segm.cc
/// \brief A program performing a WST-based segmentation of the
/// surface of the (triangle) mesh of a statue.
diff --git a/milena/apps/mesh-segm-skel/mesh-skel.cc b/milena/apps/mesh-segm-skel/mesh-skel.cc
index 68dfb85..0b96199 100644
--- a/milena/apps/mesh-segm-skel/mesh-skel.cc
+++ b/milena/apps/mesh-segm-skel/mesh-skel.cc
@@ -25,7 +25,7 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-/// \file apps/statues/mesh-skel.cc
+/// \file apps/mesh-segm-skel/mesh-skel.cc
/// \brief A program computing a skeleton of the surface of the
/// (triangle) mesh of a statue.
diff --git a/milena/apps/mesh-segm-skel/save_bin_alt.hh b/milena/apps/mesh-segm-skel/save_bin_alt.hh
index e422578..034b840 100644
--- a/milena/apps/mesh-segm-skel/save_bin_alt.hh
+++ b/milena/apps/mesh-segm-skel/save_bin_alt.hh
@@ -25,8 +25,8 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-#ifndef APPS_STATUES_SAVE_BIN_ALT_HH
-# define APPS_STATUES_SAVE_BIN_ALT_HH
+#ifndef APPS_MESH_SEGM_SKEL_SAVE_BIN_ALT_HH
+# define APPS_MESH_SEGM_SKEL_SAVE_BIN_ALT_HH
/*--------------------------------------------------------------------.
| FIXME: Copied and adjusted (in a hurry) from mln/io/off/save.hh, |
@@ -186,4 +186,4 @@ namespace mln
} // end of namespace mln
-#endif // ! APPS_STATUES_SAVE_BIN_ALT_HH
+#endif // ! APPS_MESH_SEGM_SKEL_SAVE_BIN_ALT_HH
diff --git a/milena/apps/mesh-segm-skel/trimesh/misc.hh b/milena/apps/mesh-segm-skel/trimesh/misc.hh
index 1ef56cb..5084632 100644
--- a/milena/apps/mesh-segm-skel/trimesh/misc.hh
+++ b/milena/apps/mesh-segm-skel/trimesh/misc.hh
@@ -29,8 +29,8 @@
// FIXME: Split this file.
// FIXME: Address license-related issues?
-#ifndef MILENA_APPS_STATUES_MISC_HH
-# define MILENA_APPS_STATUES_MISC_HH
+#ifndef MILENA_APPS_MESH_SEGM_SKEL_MISC_HH
+# define MILENA_APPS_MESH_SEGM_SKEL_MISC_HH
# include <algorithm> // For std::swap.
# include <utility> // For std::pair.
@@ -659,4 +659,4 @@ namespace mln
} // end of namespace mln
-#endif // ! MILENA_APPS_STATUES_MISC_HH
+#endif // ! MILENA_APPS_MESH_SEGM_SKEL_MISC_HH
diff --git a/milena/mesh/Makefile.am b/milena/mesh/Makefile.am
index e023f4d..558d28f 100644
--- a/milena/mesh/Makefile.am
+++ b/milena/mesh/Makefile.am
@@ -52,9 +52,9 @@ dist_mesh_DATA += $(more_meshes)
## Pseudo-inverse curvature of meshes. ##
## ------------------------------------ ##
-mesh_pinv_curv = $(top_builddir)/milena/apps/statues/mesh-pinv-curv
-mesh_pinv_curv: $(top_srcdir)/milena/apps/statues/mesh-pinv-curv.cc
- cd $(top_builddir)/milena/apps/statues/mesh-pinv-curv && \
+mesh_pinv_curv = $(top_builddir)/milena/apps/mesh-segm-skel/mesh-pinv-curv
+mesh_pinv_curv: $(top_srcdir)/milena/apps/mesh-segm-skel/mesh-pinv-curv.cc
+ cd $(top_builddir)/milena/apps/mesh-segm-skel/mesh-pinv-curv && \
$(MAKE) $(AM_MAKEFLAGS) mesh_pinv_curv
# FIXME: *-pinv-curv.off files should not be regenerated
@@ -70,9 +70,9 @@ dist_mesh_DATA += $(pinv_curv)
## Maximum curvature of meshes. ##
## ----------------------------- ##
-mesh_max_curv = $(top_builddir)/milena/apps/statues/mesh-max-curv
-mesh_max_curv: $(top_srcdir)/milena/apps/statues/mesh-max-curv.cc
- cd $(top_builddir)/milena/apps/statues/mesh-max-curv && \
+mesh_max_curv = $(top_builddir)/milena/apps/mesh-segm-skel/mesh-max-curv
+mesh_max_curv: $(top_srcdir)/milena/apps/mesh-segm-skel/mesh-max-curv.cc
+ cd $(top_builddir)/milena/apps/mesh-segm-skel/mesh-max-curv && \
$(MAKE) $(AM_MAKEFLAGS) mesh_max_curv
# FIXME: *-max-curv.off files should not be regenerated
--
1.6.4.2
* green/mln/accu/stat/histo1d/histo1d.hh : Improve documentation.
* green/tests/accu/stat/histo1d/histo1d.cc
(test_14bits_classifying) : Test gausian filtering.
* green/mln/io/plot/save_histo_sh.hh : Test new gnuplot style.
---
trunk/milena/sandbox/ChangeLog | 10 ++++++++++
.../milena/sandbox/green/mln/accu/stat/histo1d.hh | 15 ++++++++-------
.../sandbox/green/mln/io/plot/save_histo_sh.hh | 3 ++-
.../green/tests/accu/stat/histo1d/histo1d.cc | 13 +++++++------
4 files changed, 27 insertions(+), 14 deletions(-)
diff --git a/trunk/milena/sandbox/ChangeLog b/trunk/milena/sandbox/ChangeLog
index b29bcef..584044a 100644
--- a/trunk/milena/sandbox/ChangeLog
+++ b/trunk/milena/sandbox/ChangeLog
@@ -1,5 +1,15 @@
2009-09-07 Yann Jacquelet <jacquelet(a)lrde.epita.fr>
+ Make some test on 14 bits grayscale image.
+
+ * green/mln/accu/stat/histo1d/histo1d.hh : Improve documentation.
+ * green/tests/accu/stat/histo1d/histo1d.cc
+ (test_14bits_classifying) : Test gausian filtering.
+ * green/mln/io/plot/save_histo_sh.hh : Test new gnuplot style.
+
+
+2009-09-07 Yann Jacquelet <jacquelet(a)lrde.epita.fr>
+
Improve histo1d testing with 14 bits grayscale image.
* green/mln/fun : New directory.
diff --git a/trunk/milena/sandbox/green/mln/accu/stat/histo1d.hh b/trunk/milena/sandbox/green/mln/accu/stat/histo1d.hh
index 4cd07fa..541b749 100644
--- a/trunk/milena/sandbox/green/mln/accu/stat/histo1d.hh
+++ b/trunk/milena/sandbox/green/mln/accu/stat/histo1d.hh
@@ -34,7 +34,7 @@
///
/// This source implements the discrete histogram version. The number of beans
/// is infer from the number of greylevels. A typical int_u8 image has got
-/// 256 bins. An int_u16 image has got 65535 bins.
+/// 256 bins. An int_u<14> image has got 16384 bins.
/// The following sample is a typical use of the histogram.
///
/// #include <mln/value/int_u8.hh>
@@ -124,10 +124,10 @@ namespace mln
///
/// Param V defines the space in which we count the values.
/// For instance, this histogram works image2d<int_u8> or
- /// image1d<int_u16>. The histogram count the occurrence of each value.
+ /// image1d<int_u<14> >. The histogram count the occurrence of each value.
/// The number of bins depends of the greyscale values, for 8 bits there
- /// is 256 bins, for 16 bits there is 65536 bins. Note that over
- /// quantification works too.
+ /// is 256 bins, for 14 bits there is 16384 bins. Note that over
+ /// quantification works too (up to 14 bits).
///
/// \ingroup modaccuvalues
@@ -159,7 +159,7 @@ namespace mln
void init();
- /// \brief Update the histogram with the RGB pixel t.
+ /// \brief Update the histogram with the greylevel of the pixel t.
/// \param[in] t a greylevel pixel of type V.
///
/// The end user shouldn't call this method. In place of it, he can
@@ -216,6 +216,9 @@ namespace mln
// mln_min(comp) --> 0
// mln_max(comp) --> 2^(n-1) [127 for n=7][255 for n=8] ...
+ count_.init_(box1d(point1d(mln_min(comp)),
+ point1d(mln_max(comp))));
+
// std::cout << "min : " << mln_min(comp) << std::endl;
// std::cout << "max : " << mln_max(comp) << std::endl;
@@ -226,8 +229,6 @@ namespace mln
// v_point1d(mln_max(comp))));
// this does not work as image1d is friendly close to box1d
- count_.init_(box1d(point1d(mln_min(comp)),
- point1d(mln_max(comp))));
trace::exiting("mln::accu::stat::histo1d<V>::histo1d");
}
diff --git a/trunk/milena/sandbox/green/mln/io/plot/save_histo_sh.hh b/trunk/milena/sandbox/green/mln/io/plot/save_histo_sh.hh
index 6bf1fbf..e2d26e1 100644
--- a/trunk/milena/sandbox/green/mln/io/plot/save_histo_sh.hh
+++ b/trunk/milena/sandbox/green/mln/io/plot/save_histo_sh.hh
@@ -100,7 +100,8 @@ namespace mln
out << std::endl;
out << "gnuplot <<EOF" << std::endl;
out << "set terminal x11 persist 1" << std::endl;
- out << "plot '-' with points pointtype 20" << std::endl;
+ out << "plot '-' with impulses" << std::endl;
+ //out << "plot '-' with points pointtype 20" << std::endl;
//out << "plot '-' with points pointtype 0" << std::endl;
//out << "plot '-' with histograms" << std::endl;
//out << "plot '-' smooth unique" << std::endl;
diff --git a/trunk/milena/sandbox/green/tests/accu/stat/histo1d/histo1d.cc b/trunk/milena/sandbox/green/tests/accu/stat/histo1d/histo1d.cc
index b09fab8..e959cbd 100644
--- a/trunk/milena/sandbox/green/tests/accu/stat/histo1d/histo1d.cc
+++ b/trunk/milena/sandbox/green/tests/accu/stat/histo1d/histo1d.cc
@@ -631,8 +631,8 @@ void test_14bits_classifying()
std::cout << "(14 bits) SMOOTHING HISTOGRAM" << std::endl;
- double ws[41];
- gaussian_filter(ws, 41, 6.0);
+ double ws[401];
+ gaussian_filter(ws, 401, 50.0);
img_smooth = mln::linear::convolve(img_res, mln::make::w_window1d(ws));
mln::io::plot::save_histo_sh(img_smooth, "histo1_14bits.sh");
@@ -678,25 +678,26 @@ void test_14bits_classifying()
int main()
{
+ /*
test_8bits_instantiation_without_argument();
test_8bits_initialization();
test_8bits_take_argument();
test_8bits_take_other();
test_8bits_operator_equal();
test_8bits_integration();
-
- //test_8bits_classifying();
+ */
+ test_8bits_classifying();
// PROBLEME AVEC LES COORDONNEES PAR DEFAUT QUI SONT EN SIGNED SHORT
// SEE mln/core/def/coord.hh
-
+ /*
test_14bits_instantiation_without_argument();
test_14bits_initialization();
test_14bits_take_argument();
test_14bits_take_other();
test_14bits_operator_equal();
test_14bits_integration();
-
+ */
test_14bits_classifying();
return 0;
--
1.5.6.5