https://svn.lrde.epita.fr/svn/oln/trunk/olena
Index: ChangeLog
from Roland Levillain <roland(a)lrde.epita.fr>
* oln/core/abstract/image/dimension/1d.hh
* oln/core/abstract/image/dimension/2d.hh
* oln/core/abstract/image/dimension/3d.hh
* oln/core/abstract/image/dimension/hierarchy.hh
* oln/core/1d/grid1d.hh, oln/core/2d/grid2d.hh,
* oln/core/3d/grid3d.hh, oln/core/2d/array2d.hh,
* oln/core/2d/dpoint2d.hh, oln/core/2d/point2d.hh,
* tests/image1d.cc, tests/image2d.cc, tests/image3d.cc,
* tests/image_entry.cc, tests/io_pnm.cc, tests/Makefile.am:
Aesthetic changes.
oln/core/1d/grid1d.hh | 2 +-
oln/core/2d/array2d.hh | 9 +--------
oln/core/2d/dpoint2d.hh | 1 +
oln/core/2d/grid2d.hh | 2 +-
oln/core/2d/point2d.hh | 5 -----
oln/core/3d/grid3d.hh | 2 +-
oln/core/abstract/image/dimension/1d.hh | 2 +-
oln/core/abstract/image/dimension/2d.hh | 2 +-
oln/core/abstract/image/dimension/3d.hh | 2 +-
oln/core/abstract/image/dimension/hierarchy.hh | 6 +++---
tests/Makefile.am | 4 +++-
tests/image1d.cc | 6 +++---
tests/image2d.cc | 6 +++---
tests/image3d.cc | 6 +++---
tests/image_entry.cc | 2 +-
tests/io_pnm.cc | 1 -
16 files changed, 24 insertions(+), 34 deletions(-)
Index: oln/core/abstract/image/dimension/1d.hh
--- oln/core/abstract/image/dimension/1d.hh (revision 621)
+++ oln/core/abstract/image/dimension/1d.hh (working copy)
@@ -37,7 +37,7 @@
namespace abstract
{
- /// Class of 1-D images.
+ /// Class of 1D images.
template <typename E>
struct image1d :
public virtual image<E>,
Index: oln/core/abstract/image/dimension/2d.hh
--- oln/core/abstract/image/dimension/2d.hh (revision 621)
+++ oln/core/abstract/image/dimension/2d.hh (working copy)
@@ -37,7 +37,7 @@
namespace abstract
{
- /// Class of 2-D images.
+ /// Class of 2D images.
template <typename E>
struct image2d :
public virtual image<E>,
Index: oln/core/abstract/image/dimension/3d.hh
--- oln/core/abstract/image/dimension/3d.hh (revision 621)
+++ oln/core/abstract/image/dimension/3d.hh (working copy)
@@ -37,7 +37,7 @@
namespace abstract
{
- /// Class of 3-D images.
+ /// Class of 3D images.
template <typename E>
struct image3d :
public virtual image<E>,
Index: oln/core/abstract/image/dimension/hierarchy.hh
--- oln/core/abstract/image/dimension/hierarchy.hh (revision 621)
+++ oln/core/abstract/image/dimension/hierarchy.hh (working copy)
@@ -91,7 +91,7 @@
class grid2d;
class grid3d;
- /// 1-D case.
+ /// 1D case.
template <typename E>
struct case_< image_hierarchy_wrt_dimension, E, 1 > :
where_< mlc::eq_< oln_type_of(E, grid), oln::grid1d > >
@@ -99,7 +99,7 @@
typedef abstract::image1d<E> ret;
};
- /// 2-D case.
+ /// 2D case.
template <typename E>
struct case_< image_hierarchy_wrt_dimension, E, 2 > :
where_< mlc::eq_< oln_type_of(E, grid), oln::grid2d > >
@@ -107,7 +107,7 @@
typedef abstract::image2d<E> ret;
};
- /// 3-D case.
+ /// 3D case.
template <typename E>
struct case_< image_hierarchy_wrt_dimension, E, 3 > :
where_< mlc::eq_< oln_type_of(E, grid), oln::grid3d > >
Index: oln/core/1d/grid1d.hh
--- oln/core/1d/grid1d.hh (revision 621)
+++ oln/core/1d/grid1d.hh (working copy)
@@ -48,7 +48,7 @@
typedef mlc::uint_<1> dimvalue_type;
};
- /// A 1-dimension grid.
+ /// A 1D grid.
struct grid1d : public stc_get_supers(grid1d)
{
protected:
Index: oln/core/2d/grid2d.hh
--- oln/core/2d/grid2d.hh (revision 621)
+++ oln/core/2d/grid2d.hh (working copy)
@@ -48,7 +48,7 @@
typedef mlc::uint_<2> dimvalue_type;
};
- /// A 2-dimension rectangular grid.
+ /// A 2D rectangular grid.
struct grid2d : public stc_get_supers(grid2d)
{
protected:
Index: oln/core/3d/grid3d.hh
--- oln/core/3d/grid3d.hh (revision 621)
+++ oln/core/3d/grid3d.hh (working copy)
@@ -47,7 +47,7 @@
typedef mlc::uint_<3> dimvalue_type;
};
- /// A 3-dimension cubic grid.
+ /// A 3D cubic grid.
struct grid3d : public stc_get_supers(grid3d)
{
protected:
Index: oln/core/2d/array2d.hh
--- oln/core/2d/array2d.hh (revision 621)
+++ oln/core/2d/array2d.hh (working copy)
@@ -43,9 +43,7 @@
public:
/// Ctor.
- array2d(coord_t imin, coord_t jmin,
- coord_t imax, coord_t jmax);
-
+ array2d(coord_t imin, coord_t jmin, coord_t imax, coord_t jmax);
/// Ctor.
array2d(coord_t ilen, coord_t jlen);
@@ -53,7 +51,6 @@
~array2d();
value_t operator()(coord_t i, coord_t j) const;
-
value_t& operator()(coord_t i, coord_t j);
bool has(coord_t i, coord_t j) const;
@@ -70,13 +67,11 @@
private:
void allocate_();
-
void deallocate_();
};
-
# ifndef OLN_INCLUDE_ONLY
template <typename value_t, typename coord_t>
@@ -94,7 +89,6 @@
}
template <typename value_t, typename coord_t>
- /// Ctor.
array2d<value_t, coord_t>::array2d(coord_t ilen, coord_t jlen) :
imin_(0),
jmin_(0),
@@ -108,7 +102,6 @@
}
template <typename value_t, typename coord_t>
- /// Dtor.
array2d<value_t, coord_t>::~array2d()
{
deallocate_();
Index: oln/core/2d/dpoint2d.hh
--- oln/core/2d/dpoint2d.hh (revision 621)
+++ oln/core/2d/dpoint2d.hh (working copy)
@@ -91,6 +91,7 @@
};
+
# ifndef OLN_INCLUDE_ONLY
template <typename C>
Index: oln/core/2d/point2d.hh
--- oln/core/2d/point2d.hh (revision 621)
+++ oln/core/2d/point2d.hh (working copy)
@@ -124,11 +124,6 @@
{
}
-// template <typename C>
-// point2d_<C>::~point2d_()
-// {
-// }
-
template <typename C>
C point2d_<C>::row() const { return v_[0]; }
Index: tests/image1d.cc
--- tests/image1d.cc (revision 621)
+++ tests/image1d.cc (working copy)
@@ -36,18 +36,18 @@
int
main()
{
- // Fill a 1-d image using its iterator.
+ // Fill a 1D image using its iterator.
oln::image1d<char> ima1(3);
oln_type_of_(oln::image1d<char>, piter) p1(ima1.topo());
for_all(p1)
ima1(p1) = 1;
- // Fill a 1-d image using a classic loop.
+ // Fill a 1D image using a classic loop.
oln::image1d<int> ima2(ima1.topo());
for (unsigned i = 0; i < 3; ++i)
ima2(oln::point1d(i)) = 2;
- // Fill a 1-d image using the routine oln::level::fill.
+ // Fill a 1D image using the routine oln::level::fill.
oln::image1d<long> ima3(ima1.topo());
oln::level::fill(ima3, 3);
Index: tests/image2d.cc
--- tests/image2d.cc (revision 621)
+++ tests/image2d.cc (working copy)
@@ -36,19 +36,19 @@
int
main()
{
- // Fill a 2-d image using its iterator.
+ // Fill a 2D image using its iterator.
oln::image2d<char> ima1(3, 3);
oln_type_of_(oln::image2d<char>, piter) p1(ima1.topo());
for_all(p1)
ima1(p1) = 1;
- // Fill a 2-d image using a classic loop.
+ // Fill a 2D image using a classic loop.
oln::image2d<int> ima2(ima1.topo());
for (unsigned i = 0; i < 3; ++i)
for (unsigned j = 0; j < 3; ++j)
ima2(oln::point2d(i, j)) = 2;
- // Fill a 2-d image using the routine oln::level::fill.
+ // Fill a 2D image using the routine oln::level::fill.
oln::image2d<long> ima3(ima1.topo());
oln::level::fill(ima3, 3);
Index: tests/image3d.cc
--- tests/image3d.cc (revision 621)
+++ tests/image3d.cc (working copy)
@@ -36,20 +36,20 @@
int
main()
{
- // Fill a 3-d image using its iterator.
+ // Fill a 3D image using its iterator.
oln::image3d<char> ima1(3, 3, 3);
oln_type_of_(oln::image3d<char>, piter) p1(ima1.topo());
for_all(p1)
ima1(p1) = 1;
- // Fill a 3-d image using a classic loop.
+ // Fill a 3D image using a classic loop.
oln::image3d<int> ima2(ima1.topo());
for (unsigned i = 0; i < 3; ++i)
for (unsigned j = 0; j < 3; ++j)
for (unsigned k = 0; k < 3; ++k)
ima2(oln::point3d(i, j, k)) = 2;
- // Fill a 3-d image using the routine oln::level::fill.
+ // Fill a 3D image using the routine oln::level::fill.
oln::image3d<long> ima3(ima1.topo());
oln::level::fill(ima3, 3);
Index: tests/image_entry.cc
--- tests/image_entry.cc (revision 621)
+++ tests/image_entry.cc (working copy)
@@ -72,7 +72,7 @@
namespace my
{
- // A very simple 1-D image.
+ // A very simple 1D image.
class image : public oln::get_super_types<my::image>::ret
{
public:
Index: tests/io_pnm.cc
--- tests/io_pnm.cc (revision 621)
+++ tests/io_pnm.cc (working copy)
@@ -34,7 +34,6 @@
int
main()
{
- // Fill a 2-d image using its iterator.
oln::image2d<bool> ima =
oln::io::load_pbm("../img/chien.pbm");
oln::image2d<unsigned char> ima2 =
oln::io::load_pgm("../img/lena32.pgm");
}
Index: tests/Makefile.am
--- tests/Makefile.am (revision 621)
+++ tests/Makefile.am (working copy)
@@ -46,6 +46,9 @@
npoints_SOURCES = npoints.cc
window2d_SOURCES = window2d.cc
+# I/O.
+io_pnm_SOURCES = io_pnm.cc
+
# Morphers.
identity_morpher_SOURCES = identity_morpher.cc
add_neighborhood_morpher_SOURCES = add_neighborhood_morpher.cc
@@ -53,7 +56,6 @@
# Algorithms.
fill_SOURCES = fill.cc
-io_pnm_SOURCES = io_pnm.cc
TESTS = $(check_PROGRAMS)