cleanup-2008 1950: Rename Point_Set as Site_Set.

https://svn.lrde.epita.fr/svn/oln/branches/cleanup-2008/milena Index: ChangeLog from Thierry Geraud <thierry.geraud@lrde.epita.fr> Rename Point_Set as Site_Set. * ., * tools, * tests, * tests/trait, * tests/trait/image, * tests/trait/value, * tests/trait/op, * tests/subsampling, * tests/debug, * tests/histo, * tests/core, * tests/literal, * tests/neighb, * tests/draw, * tests/metal, * tests/metal/math, * tests/level, * tests/level/approx, * tests/level/naive, * tests/arith, * tests/linear, * tests/linear/local, * tests/accu, * tests/value, * tests/value/builtin, * tests/border, * tests/test, * tests/convert, * tests/estim, * tests/pw, * tests/geom, * tests/fun/x2x, * tests/fun/vv2v, * tests/fun/v2v, * tests/binarization, * tests/set, * tests/win, * tests/algebra, * tests/morpho, * tests/display, * tests/io/pgm, * tests/io/fits, * tests/io/ppm, * tests/io/pbm, * tests/logical, * tests/canvas, * tests/canvas/browsing, * tests/norm, * tests/util, * tests/labeling, * mln/core/internal/point_set_base.hh, * mln/core/internal/image_base.hh, * mln/core/sub_image.hh, * mln/core/p_array_piter.hh, * mln/core/p_image2d.hh, * mln/core/pset_if.hh, * mln/core/concept/box.hh, * mln/core/concept/point_set.hh, * mln/core/concept/doc/image.hh, * mln/core/concept/doc/box.hh: Ignore .deps. * mln/core/concept/doc/point_set.hh, * mln/neighb/image.hh, * mln/value/stack.hh, * mln/test/predicate.hh, * mln/convert/to_image.hh, * mln/convert/to_std_set.hh, * mln/convert/to_window.hh, * mln/convert/to_p_set.hh, * mln/convert/to_p_array.hh, * mln/pw/image.hh, * mln/geom/pmin_pmax.hh, * mln/geom/bbox.hh, * mln/set/inter.hh, * mln/set/is_subset_of.hh, * mln/set/diff.hh, * mln/set/uni.hh, * mln/set/sym_diff.hh (Point_Set): Rename as... (Site_Set): ...this. * mln/trait/site_set: New directory. * mln/trait/site_set/props.hh: New. * mln/trait/site_set/print.hh: New. * mln/trait/site_sets.hh: New. convert/to_image.hh | 4 - convert/to_p_array.hh | 4 - convert/to_p_set.hh | 4 - convert/to_std_set.hh | 4 - convert/to_window.hh | 4 - core/concept/box.hh | 6 +- core/concept/doc/box.hh | 6 +- core/concept/doc/image.hh | 2 core/concept/doc/point_set.hh | 8 +-- core/concept/point_set.hh | 42 +++++++++--------- core/internal/image_base.hh | 2 core/internal/point_set_base.hh | 2 core/p_array_piter.hh | 8 +-- core/p_image2d.hh | 8 +-- core/pset_if.hh | 4 - core/sub_image.hh | 8 +-- geom/bbox.hh | 6 +- geom/pmin_pmax.hh | 10 ++-- neighb/image.hh | 2 pw/image.hh | 8 +-- set/diff.hh | 8 +-- set/inter.hh | 6 +- set/is_subset_of.hh | 6 +- set/sym_diff.hh | 6 +- set/uni.hh | 6 +- test/predicate.hh | 6 +- trait/site_set/print.hh | 93 ++++++++++++++++++++++++++++++++++++++++ trait/site_set/props.hh | 93 ++++++++++++++++++++++++++++++++++++++++ trait/site_sets.hh | 75 ++++++++++++++++++++++++++++++++ value/stack.hh | 2 30 files changed, 352 insertions(+), 91 deletions(-) Index: mln/trait/site_set/props.hh --- mln/trait/site_set/props.hh (revision 0) +++ mln/trait/site_set/props.hh (revision 0) @@ -0,0 +1,93 @@ +// Copyright (C) 2008 EPITA Research and Development Laboratory +// +// This file is part of the Olena Library. This library is free +// software; you can redistribute it and/or modify it under the terms +// of the GNU General Public License version 2 as published by the +// Free Software Foundation. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this library; see the file COPYING. If not, write to +// the Free Software Foundation, 51 Franklin Street, Fifth Floor, +// Boston, MA 02111-1307, USA. +// +// As a special exception, you may use this file as part of a free +// software library without restriction. Specifically, if other files +// instantiate templates or use macros or inline functions from this +// file, or you compile this file and link it with other files to +// produce an executable, this file does not by itself cause the +// resulting executable to be covered by the GNU General Public +// License. This exception does not however invalidate any other +// reasons why the executable file might be covered by the GNU General +// Public License. + +#ifndef MLN_TRAIT_SITE_SET_PROPS_HH +# define MLN_TRAIT_SITE_SET_PROPS_HH + +/*! \file mln/trait/site_set/props.hh + * + * \brief Properties of site set classes. + */ + +# include <string> +# include <mln/trait/undef.hh> + + +namespace mln +{ + + namespace trait + { + + namespace site_set + { + + struct nsites + { + struct any {}; + struct unknown : any { std::string name() const { return "nsites::unknown"; } }; + struct known : any { std::string name() const { return "nsites::known"; } }; + }; + + struct bbox + { + struct any {}; + struct unknown : any { std::string name() const { return "bbox::unknown"; } }; + struct known : any {}; + struct lazy : known { std::string name() const { return "bbox::lazy"; } }; + struct straight : known { std::string name() const { return "bbox::straight"; } }; + }; + + struct contents + { + struct any {}; + struct fixed : any { std::string name() const { return "contents::fixed"; } }; + struct dynamic : any {}; + struct growing : dynamic { std::string name() const { return "contents::growing"; } }; + struct free : dynamic { std::string name() const { return "contents::dynamic"; } }; + }; + + struct arity + { + struct any {}; + struct unique : any { std::string name() const { return "arity::unique"; } }; + struct multiple : any { std::string name() const { return "arity::multiple"; } }; + }; + + + // FIXME: support = psite::support + + + } // end of namespace mln::trait::site_set + + } // end of namespace mln::trait + + +} // end of namespace mln + + +#endif // ! MLN_TRAIT_SITE_SET_PROPS_HH Index: mln/trait/site_set/print.hh --- mln/trait/site_set/print.hh (revision 0) +++ mln/trait/site_set/print.hh (revision 0) @@ -0,0 +1,93 @@ +// Copyright (C) 2008 EPITA Research and Development Laboratory +// +// This file is part of the Olena Library. This library is free +// software; you can redistribute it and/or modify it under the terms +// of the GNU General Public License version 2 as published by the +// Free Software Foundation. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this library; see the file COPYING. If not, write to +// the Free Software Foundation, 51 Franklin Street, Fifth Floor, +// Boston, MA 02111-1307, USA. +// +// As a special exception, you may use this file as part of a free +// software library without restriction. Specifically, if other files +// instantiate templates or use macros or inline functions from this +// file, or you compile this file and link it with other files to +// produce an executable, this file does not by itself cause the +// resulting executable to be covered by the GNU General Public +// License. This exception does not however invalidate any other +// reasons why the executable file might be covered by the GNU General +// Public License. + +#ifndef MLN_TRAIT_SITE_SET_PRINT_HH +# define MLN_TRAIT_SITE_SET_PRINT_HH + +/*! \file mln/trait/site_set/print.hh + * + * \brief Print the collection of traits for a site set type. + */ + +# include <iostream> +# include <mln/trait/site_sets.hh> +# include <mln/metal/is_a.hh> + + + +namespace mln +{ + + // Fwd decl. + template <typename E> struct Site_Set; + + + namespace trait + { + + namespace site_set + { + + template <typename S> + void print(std::ostream& ostr); + + template <typename S> + void print(const Site_Set<S>& ima, std::ostream& ostr); + + +# ifndef MLN_INCLUDE_ONLY + + template <typename S> + inline + void print(std::ostream& ostr) + { + mlc_is_a(S, Site_Set)::check(); + typedef mln::trait::site_set_<S> the; + ostr << "{ " + << typename the::nsites() .name() << ", " + << typename the::bbox() .name() << ", " + << typename the::contents().name() << ", " + << typename the::arity() .name() << " }" << std::endl; + } + + template <typename S> + inline + void print(const Site_Set<S>&, std::ostream& ostr) + { + print<S>(ostr); + } + +# endif // ! MLN_INCLUDE_ONLY + + } // end of namespace mln::trait::site_set + + } // end of namespace mln::trait + +} // end of namespace mln + + +#endif // ! MLN_TRAIT_SITE_SET_PRINT_HH Index: mln/trait/site_sets.hh --- mln/trait/site_sets.hh (revision 0) +++ mln/trait/site_sets.hh (revision 0) @@ -0,0 +1,75 @@ +// Copyright (C) 2008 EPITA Research and Development Laboratory +// +// This file is part of the Olena Library. This library is free +// software; you can redistribute it and/or modify it under the terms +// of the GNU General Public License version 2 as published by the +// Free Software Foundation. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this library; see the file COPYING. If not, write to +// the Free Software Foundation, 51 Franklin Street, Fifth Floor, +// Boston, MA 02111-1307, USA. +// +// As a special exception, you may use this file as part of a free +// software library without restriction. Specifically, if other files +// instantiate templates or use macros or inline functions from this +// file, or you compile this file and link it with other files to +// produce an executable, this file does not by itself cause the +// resulting executable to be covered by the GNU General Public +// License. This exception does not however invalidate any other +// reasons why the executable file might be covered by the GNU General +// Public License. + +#ifndef MLN_TRAIT_SITE_SETS_HH +# define MLN_TRAIT_SITE_SETS_HH + +/*! \file mln/trait/site_sets.hh + * + * \brief Some base trait types for site sets. + */ + +# include <mln/trait/undef.hh> +# include <mln/trait/site_set/props.hh> + + +# define mln_trait_site_set_nsites(S) typename mln::trait::site_set_< S >::nsites +# define mln_trait_site_set_bbox(S) typename mln::trait::site_set_< S >::bbox +# define mln_trait_site_set_contents(S) typename mln::trait::site_set_< S >::contents +# define mln_trait_site_set_arity(S) typename mln::trait::site_set_< S >::arity + + + +namespace mln +{ + + namespace trait + { + + template <typename I> + struct undefined_site_set_ + { + typedef undef nsites; // Known or unknown. + typedef undef bbox; // Unknown, lazy, or straight. + typedef undef contents; // Fixed, growing, or free. + typedef undef arity; // Unique or multiple. + }; + + template <typename I> + struct site_set_ : undefined_site_set_<I> + { + }; + + } // end of namespace mln::trait + +} // end of namespace mln + + +# include <mln/trait/site_set/print.hh> + + +#endif // ! MLN_TRAIT_SITE_SETS_HH Index: mln/core/internal/point_set_base.hh --- mln/core/internal/point_set_base.hh (revision 1949) +++ mln/core/internal/point_set_base.hh (working copy) @@ -47,7 +47,7 @@ * \p P is a point site type. */ template <typename P, typename E> - struct point_set_base_ : public Point_Set<E> + struct point_set_base_ : public Site_Set<E> { /// Point_Site associated type. typedef P psite; Index: mln/core/internal/image_base.hh --- mln/core/internal/image_base.hh (revision 1949) +++ mln/core/internal/image_base.hh (working copy) @@ -97,7 +97,7 @@ public image_checked_<E> { - /// Point_Set associated type. + /// Site_Set associated type. typedef S pset; Index: mln/core/sub_image.hh --- mln/core/sub_image.hh (revision 1949) +++ mln/core/sub_image.hh (working copy) @@ -120,10 +120,10 @@ template <typename I, typename S> - sub_image<const I, S> operator|(const Image<I>& ima, const Point_Set<S>& pset); + sub_image<const I, S> operator|(const Image<I>& ima, const Site_Set<S>& pset); template <typename I, typename S> - sub_image<I, S> operator|(Image<I>& ima, const Point_Set<S>& pset); + sub_image<I, S> operator|(Image<I>& ima, const Site_Set<S>& pset); @@ -211,7 +211,7 @@ template <typename I, typename S> inline sub_image<const I, S> - operator|(const Image<I>& ima, const Point_Set<S>& pset) + operator|(const Image<I>& ima, const Site_Set<S>& pset) { sub_image<const I, S> tmp(exact(ima), exact(pset)); return tmp; @@ -220,7 +220,7 @@ template <typename I, typename S> inline sub_image<I, S> - operator|(Image<I>& ima, const Point_Set<S>& pset) + operator|(Image<I>& ima, const Site_Set<S>& pset) { sub_image<I, S> tmp(exact(ima), exact(pset)); return tmp; Index: mln/core/p_array_piter.hh --- mln/core/p_array_piter.hh (revision 1949) +++ mln/core/p_array_piter.hh (working copy) @@ -55,7 +55,7 @@ /// Coordinate associated type. template <typename S> - p_array_fwd_piter_(const Point_Set<S>& s); + p_array_fwd_piter_(const Site_Set<S>& s); /// Reference of the corresponding psite. const psite& to_psite() const; @@ -108,7 +108,7 @@ /// Coordinate associated type. template <typename S> - p_array_bkd_piter_(const Point_Set<S>& s); + p_array_bkd_piter_(const Site_Set<S>& s); /// Reference of the corresponding psite. const psite& to_psite() const; @@ -157,7 +157,7 @@ template <typename P> template <typename S> inline - p_array_fwd_piter_<P>::p_array_fwd_piter_(const Point_Set<S>& s) + p_array_fwd_piter_<P>::p_array_fwd_piter_(const Site_Set<S>& s) : vect_(exact(s).vect()) { invalidate(); @@ -241,7 +241,7 @@ template <typename P> template <typename S> inline - p_array_bkd_piter_<P>::p_array_bkd_piter_(const Point_Set<S>& s) + p_array_bkd_piter_<P>::p_array_bkd_piter_(const Site_Set<S>& s) : vect_(exact(s).vect()) { invalidate(); Index: mln/core/p_image2d.hh --- mln/core/p_image2d.hh (revision 1949) +++ mln/core/p_image2d.hh (working copy) @@ -74,12 +74,12 @@ /// Insert a point \p p. p_image2d<P>& insert(const P p); template <typename S> - p_image2d<P>& insert(const Point_Set<S>& set); + p_image2d<P>& insert(const Site_Set<S>& set); /// Remove a point \p p. p_image2d<P>& remove(const P p); template <typename S> - p_image2d<P>& remove(const Point_Set<S>& set); + p_image2d<P>& remove(const Site_Set<S>& set); /// Give the number of points. unsigned npoints() const; @@ -144,7 +144,7 @@ template <typename P> template <typename S> p_image2d<P>& - p_image2d<P>::insert(const Point_Set<S>& set_) + p_image2d<P>::insert(const Site_Set<S>& set_) { const S& set = exact(set_); mln_fwd_piter(S) p(set); @@ -178,7 +178,7 @@ template <typename P> template <typename S> p_image2d<P>& - p_image2d<P>::remove(const Point_Set<S>& set_) + p_image2d<P>::remove(const Site_Set<S>& set_) { const S& set = exact(set_); if (this->is_empty()) Index: mln/core/pset_if.hh --- mln/core/pset_if.hh (revision 1949) +++ mln/core/pset_if.hh (working copy) @@ -55,7 +55,7 @@ */ template <typename S, typename F> pset_if<S, F> - operator | (const Point_Set<S>& pset, const Function_p2b<F>& f); + operator | (const Site_Set<S>& pset, const Function_p2b<F>& f); @@ -119,7 +119,7 @@ template <typename S, typename F> inline pset_if<S, F> - operator | (const Point_Set<S>& pset, const Function_p2b<F>& f) + operator | (const Site_Set<S>& pset, const Function_p2b<F>& f) { pset_if<S, F> tmp(exact(pset), exact(f)); return tmp; Index: mln/core/concept/box.hh --- mln/core/concept/box.hh (revision 1949) +++ mln/core/concept/box.hh (working copy) @@ -47,7 +47,7 @@ * contents. */ template <typename E> - struct Box : public Point_Set<E> + struct Box : public Site_Set<E> { /* const point& pmin() const; @@ -65,7 +65,7 @@ /*! \brief Give the bounding box of this point set. * * Return the bounding box of this point set, so that is itself. - * This method is declared by the mln::Point_Set concept. + * This method is declared by the mln::Site_Set concept. * * \warning This method is final for all box classes. */ @@ -74,7 +74,7 @@ /*! \brief Give the number of points of this box. * * Return the number of points of this box. This method is - * declared by the mln::Point_Set concept. + * declared by the mln::Site_Set concept. * * \warning This method is final for all box classes. */ Index: mln/core/concept/point_set.hh --- mln/core/concept/point_set.hh (revision 1949) +++ mln/core/concept/point_set.hh (working copy) @@ -30,7 +30,7 @@ /*! \file mln/core/concept/point_set.hh * - * \brief Definition of the concept of mln::Point_Set. + * \brief Definition of the concept of mln::Site_Set. * * \todo Think about adding an 'insert' method (not so easy because of * pset_if...) @@ -46,12 +46,12 @@ { // Fwd decl. - template <typename E> struct Point_Set; + template <typename E> struct Site_Set; - /// Point_Set category flag type. + /// Site_Set category flag type. template <> - struct Point_Set<void> + struct Site_Set<void> { typedef Object<void> super; }; @@ -59,13 +59,13 @@ /*! \brief Base class for implementation classes of point sets. * - * \see mln::doc::Point_Set for a complete documentation of this + * \see mln::doc::Site_Set for a complete documentation of this * class contents. */ template <typename E> - struct Point_Set : public Object<E> + struct Site_Set : public Object<E> { - typedef Point_Set<void> category; + typedef Site_Set<void> category; /* typedef mesh; @@ -84,7 +84,7 @@ */ protected: - Point_Set(); + Site_Set(); }; @@ -93,10 +93,10 @@ * \param[in] lhs A point set. * \param[in] rhs Another point set. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Sl, typename Sr> - bool operator==(const Point_Set<Sl>& lhs, const Point_Set<Sr>& rhs); + bool operator==(const Site_Set<Sl>& lhs, const Site_Set<Sr>& rhs); @@ -105,10 +105,10 @@ * \param[in] lhs A point set (included?). * \param[in] rhs Another point set (includer?). * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Sl, typename Sr> - bool operator<=(const Point_Set<Sl>& lhs, const Point_Set<Sr>& rhs); + bool operator<=(const Site_Set<Sl>& lhs, const Site_Set<Sr>& rhs); @@ -118,10 +118,10 @@ * \param[in] lhs A point set (strictly included?). * \param[in] rhs Another point set (includer?). * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Sl, typename Sr> - bool operator<(const Point_Set<Sl>& lhs, const Point_Set<Sr>& rhs); + bool operator<(const Site_Set<Sl>& lhs, const Site_Set<Sr>& rhs); @@ -133,10 +133,10 @@ * * \return The modified output stream \p ostr. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename S> - std::ostream& operator<<(std::ostream& ostr, const Point_Set<S>& pset); + std::ostream& operator<<(std::ostream& ostr, const Site_Set<S>& pset); @@ -147,7 +147,7 @@ template <typename E> inline - Point_Set<E>::Point_Set() + Site_Set<E>::Site_Set() { typedef mln_mesh(E) mesh; @@ -172,7 +172,7 @@ template <typename Sl, typename Sr> inline - bool operator==(const Point_Set<Sl>& lhs_, const Point_Set<Sr>& rhs_) + bool operator==(const Site_Set<Sl>& lhs_, const Site_Set<Sr>& rhs_) { // FIXME: Same grid! const Sl& lhs = exact(lhs_); @@ -199,7 +199,7 @@ template <typename Sl, typename Sr> inline - bool operator<=(const Point_Set<Sl>& lhs_, const Point_Set<Sr>& rhs_) + bool operator<=(const Site_Set<Sl>& lhs_, const Site_Set<Sr>& rhs_) { // FIXME: Same grid! const Sl& lhs = exact(lhs_); @@ -221,7 +221,7 @@ template <typename Sl, typename Sr> inline - bool operator<(const Point_Set<Sl>& lhs_, const Point_Set<Sr>& rhs_) + bool operator<(const Site_Set<Sl>& lhs_, const Site_Set<Sr>& rhs_) { // FIXME: Same grid! const Sl& lhs = exact(lhs_); @@ -232,7 +232,7 @@ template <typename S> inline - std::ostream& operator<<(std::ostream& ostr, const Point_Set<S>& pset_) + std::ostream& operator<<(std::ostream& ostr, const Site_Set<S>& pset_) { const S& pset = exact(pset_); ostr << '{'; Index: mln/core/concept/doc/image.hh --- mln/core/concept/doc/image.hh (revision 1949) +++ mln/core/concept/doc/image.hh (working copy) @@ -117,7 +117,7 @@ /*! \brief Point set associated type. - * \invariant This type has to derive from mln::Point_Set. + * \invariant This type has to derive from mln::Site_Set. */ typedef void pset; Index: mln/core/concept/doc/box.hh --- mln/core/concept/doc/box.hh (revision 1949) +++ mln/core/concept/doc/box.hh (working copy) @@ -39,7 +39,7 @@ * \see mln::Box */ template <typename E> - struct Box : public Point_Set<E> + struct Box : public Site_Set<E> { /*! \brief Give the box "minimum" point. * @@ -60,7 +60,7 @@ /*! \brief Return the bounding box of this point set. * * Return the bounding box of this point set, so that is itself. - * This method is declared by the mln::Point_Set concept. + * This method is declared by the mln::Site_Set concept. * * \warning This method is final for all box classes. */ @@ -69,7 +69,7 @@ /*! \brief Return the number of points of this box. * * Return the number of points of this box. This method is - * declared by the mln::Point_Set concept. + * declared by the mln::Site_Set concept. * * \warning This method is final for all box classes. */ Index: mln/core/concept/doc/point_set.hh --- mln/core/concept/doc/point_set.hh (revision 1949) +++ mln/core/concept/doc/point_set.hh (working copy) @@ -26,7 +26,7 @@ // Public License. /*! \file mln/core/concept/doc/point_set.hh - * \brief This file documents the concept of mln::Point_Set. + * \brief This file documents the concept of mln::Site_Set. */ namespace mln @@ -35,12 +35,12 @@ namespace doc { - /*! \brief Documentation class for mln::Point_Set. + /*! \brief Documentation class for mln::Site_Set. * - * \see mln::Point_Set + * \see mln::Site_Set */ template <typename E> - struct Point_Set : public Object<E> + struct Site_Set : public Object<E> { /*! \brief Point associated type. */ Index: mln/neighb/image.hh --- mln/neighb/image.hh (revision 1949) +++ mln/neighb/image.hh (working copy) @@ -98,7 +98,7 @@ /// Point_Site associated type. typedef mln_psite(I) psite; - /// Point_Set associated type. + /// Site_Set associated type. typedef mln_pset(I) pset; /// Neighborhood associated type. Index: mln/value/stack.hh --- mln/value/stack.hh (revision 1949) +++ mln/value/stack.hh (working copy) @@ -151,7 +151,7 @@ /// Point_Site associated type. typedef mln_psite(I) psite; - /// Point_Set associated type. + /// Site_Set associated type. typedef mln_pset(I) pset; /// Value associated type. Index: mln/test/predicate.hh --- mln/test/predicate.hh (revision 1949) +++ mln/test/predicate.hh (working copy) @@ -60,7 +60,7 @@ * \param[in] f The predicate. */ template <typename S, typename F> - bool predicate(const Point_Set<S>& pset, const Function_p2b<F>& f); + bool predicate(const Site_Set<S>& pset, const Function_p2b<F>& f); # ifndef MLN_INCLUDE_ONLY @@ -94,7 +94,7 @@ template <typename S, typename F> inline - bool predicate_(const Point_Set<S>& pset, const F& f) + bool predicate_(const Site_Set<S>& pset, const F& f) { mln_piter(S) p(exact(pset)); for_all(p) @@ -119,7 +119,7 @@ template <typename S, typename F> inline - bool predicate(const Point_Set<S>& pset, const Function_p2b<F>& f) + bool predicate(const Site_Set<S>& pset, const Function_p2b<F>& f) { return impl::predicate_(exact(pset), exact(f)); } Index: mln/convert/to_image.hh --- mln/convert/to_image.hh (revision 1949) +++ mln/convert/to_image.hh (working copy) @@ -106,7 +106,7 @@ /// Convert a point set \p pset into a binary image. Width of the /// converted image will be pset.bbox + 2 * \p border. template <typename S> - mln_image_from(S, bool) to_image(const Point_Set<S>& pset, unsigned border = 1); + mln_image_from(S, bool) to_image(const Site_Set<S>& pset, unsigned border = 1); /// Convert a window \p win into a binary image. template <typename W> @@ -130,7 +130,7 @@ template <typename S> inline - mln_image_from(S, bool) to_image(const Point_Set<S>& pset_, unsigned border) + mln_image_from(S, bool) to_image(const Site_Set<S>& pset_, unsigned border) { const S& pset = exact(pset_); mln_image_from(S, bool) ima(pset.bbox().to_larger(border)); Index: mln/convert/to_std_set.hh --- mln/convert/to_std_set.hh (revision 1949) +++ mln/convert/to_std_set.hh (working copy) @@ -52,7 +52,7 @@ /// Convert a point set \p pset into a std::set of points. template <typename W> - std::set<mln_point(W)> to_std_set(const Point_Set<W>& setp); + std::set<mln_point(W)> to_std_set(const Site_Set<W>& setp); # ifndef MLN_INCLUDE_ONLY @@ -71,7 +71,7 @@ template <typename W> inline - std::set<mln_point(W)> to_std_set(const Point_Set<W>& setp) + std::set<mln_point(W)> to_std_set(const Site_Set<W>& setp) { typedef mln_point(W) P; std::set<P> s; Index: mln/convert/to_window.hh --- mln/convert/to_window.hh (revision 1949) +++ mln/convert/to_window.hh (working copy) @@ -77,7 +77,7 @@ /// Convert a point set \p pset into a window. template <typename S> - window<mln_dpoint(S)> to_window(const Point_Set<S>& pset); + window<mln_dpoint(S)> to_window(const Site_Set<S>& pset); /// Convert an std::set \p s of delta-points into a window. template <typename D> @@ -162,7 +162,7 @@ template <typename S> inline - window<mln_dpoint(S)> to_window(const Point_Set<S>& pset) + window<mln_dpoint(S)> to_window(const Site_Set<S>& pset) { return to_window(pw::cst(true) | pset); } Index: mln/convert/to_p_set.hh --- mln/convert/to_p_set.hh (revision 1949) +++ mln/convert/to_p_set.hh (working copy) @@ -69,7 +69,7 @@ /// Convert any point set \p ps into a 'mln::p_set' point set. template <typename S> - p_set<mln_psite(S)> to_p_set(const Point_Set<S>& ps); + p_set<mln_psite(S)> to_p_set(const Site_Set<S>& ps); # ifndef MLN_INCLUDE_ONLY @@ -135,7 +135,7 @@ template <typename S> inline - p_set<mln_psite(S)> to_p_set(const Point_Set<S>& ps_) + p_set<mln_psite(S)> to_p_set(const Site_Set<S>& ps_) { const S& ps = exact(ps_); p_set<mln_psite(S)> tmp; Index: mln/convert/to_p_array.hh --- mln/convert/to_p_array.hh (revision 1949) +++ mln/convert/to_p_array.hh (working copy) @@ -45,7 +45,7 @@ /// Convert a point set \p pset into a p_array (point set vector). template <typename S> - p_array<mln_psite(S)> to_p_array(const Point_Set<S>& pset); + p_array<mln_psite(S)> to_p_array(const Site_Set<S>& pset); /// Convert a window \p win centered at point \p p into a p_array @@ -60,7 +60,7 @@ template <typename S> inline - p_array<mln_psite(S)> to_p_array(const Point_Set<S>& pset_) + p_array<mln_psite(S)> to_p_array(const Site_Set<S>& pset_) { const S& pset = exact(pset_); p_array<mln_psite(S)> v; Index: mln/pw/image.hh --- mln/pw/image.hh (revision 1949) +++ mln/pw/image.hh (working copy) @@ -52,7 +52,7 @@ */ template <typename F, typename S> pw::image<F,S> - operator | (const Function_p2v<F>& f, const Point_Set<S>& ps); + operator | (const Function_p2v<F>& f, const Site_Set<S>& ps); @@ -128,7 +128,7 @@ image(); /// Constructor. - image(const Function_p2v<F>& f, const Point_Set<S>& ps); + image(const Function_p2v<F>& f, const Site_Set<S>& ps); /// Test if a pixel value is accessible at \p p. @@ -158,7 +158,7 @@ template <typename F, typename S> inline pw::image<F,S> - operator | (const Function_p2v<F>& f, const Point_Set<S>& ps) + operator | (const Function_p2v<F>& f, const Site_Set<S>& ps) { pw::image<F,S> tmp(f, ps); return tmp; @@ -192,7 +192,7 @@ template <typename F, typename S> inline - image<F,S>::image(const Function_p2v<F>& f, const Point_Set<S>& ps) + image<F,S>::image(const Function_p2v<F>& f, const Site_Set<S>& ps) { this->data_ = new internal::data_< pw::image<F,S> >(exact(f), exact(ps)); } Index: mln/geom/pmin_pmax.hh --- mln/geom/pmin_pmax.hh (revision 1949) +++ mln/geom/pmin_pmax.hh (working copy) @@ -51,14 +51,14 @@ /// Compute the minimum and maximum points of point set \p s. template <typename S> std::pair<mln_point(S), mln_point(S)> - pmin_pmax(const Point_Set<S>& s); + pmin_pmax(const Site_Set<S>& s); /// Compute the minimum and maximum points, \p pmin and \p max, /// of point set \p s. template <typename S> void - pmin_pmax(const Point_Set<S>& s, mln_point(S)& pmin, mln_point(S)& pmax); + pmin_pmax(const Site_Set<S>& s, mln_point(S)& pmin, mln_point(S)& pmax); /// Compute the minimum and maximum points when browsing with @@ -125,7 +125,7 @@ template <typename S> inline void - pmin_pmax_(const Point_Set<S>& s, mln_point(S)& pmin, mln_point(S)& pmax) + pmin_pmax_(const Site_Set<S>& s, mln_point(S)& pmin, mln_point(S)& pmax) { mln_piter(S) it(exact(s)); pmin_pmax(it, pmin, pmax); @@ -148,7 +148,7 @@ template <typename S> inline void - pmin_pmax(const Point_Set<S>& s, mln_point(S)& pmin, mln_point(S)& pmax) + pmin_pmax(const Site_Set<S>& s, mln_point(S)& pmin, mln_point(S)& pmax) { mln_precondition(exact(s).npoints() != 0); impl::pmin_pmax_(exact(s), pmin, pmax); @@ -157,7 +157,7 @@ template <typename S> inline std::pair<mln_point(S), mln_point(S)> - pmin_pmax(const Point_Set<S>& s) + pmin_pmax(const Site_Set<S>& s) { mln_precondition(exact(s).npoints() != 0); typedef mln_point(S) P; Index: mln/geom/bbox.hh --- mln/geom/bbox.hh (revision 1949) +++ mln/geom/bbox.hh (working copy) @@ -63,7 +63,7 @@ /// Compute the precise bounding box of a point set \p pset. template <typename S> - box_<mln_point(S)> bbox(const Point_Set<S>& pset); + box_<mln_point(S)> bbox(const Site_Set<S>& pset); /// Compute the precise bounding box of an image \p ima. @@ -102,7 +102,7 @@ template <typename S> inline - box_<mln_point(S)> bbox_(const Point_Set<S>& pset_) + box_<mln_point(S)> bbox_(const Site_Set<S>& pset_) { const S& pset = exact(pset_); typedef mln_point(S) P; @@ -122,7 +122,7 @@ template <typename S> inline - box_<mln_point(S)> bbox(const Point_Set<S>& pset) + box_<mln_point(S)> bbox(const Site_Set<S>& pset) { mln_precondition(exact(pset).npoints() != 0); box_<mln_point(S)> tmp = impl::bbox_(exact(pset)); Index: mln/set/inter.hh --- mln/set/inter.hh (revision 1949) +++ mln/set/inter.hh (working copy) @@ -57,11 +57,11 @@ /*! \brief Intersection between a couple of point sets. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Wl, typename Wr> p_set<mln_point(Wl)> - inter(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs); + inter(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs); # ifndef MLN_INCLUDE_ONLY @@ -87,7 +87,7 @@ template <typename Wl, typename Wr> inline p_set<mln_point(Wl)> - inter(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs) + inter(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs) { trace::entering("set::inter"); mln::metal::equal<mln_point(Wl), mln_point(Wr)>::check(); Index: mln/set/is_subset_of.hh --- mln/set/is_subset_of.hh (revision 1949) +++ mln/set/is_subset_of.hh (working copy) @@ -42,17 +42,17 @@ { /*! \brief Test if a point set is a subset of another point set. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Pl, typename Pr> bool - is_subset_of(const Point_Set<Pl>& lhs, const Point_Set<Pr>& rhs); + is_subset_of(const Site_Set<Pl>& lhs, const Site_Set<Pr>& rhs); # ifndef MLN_INCLUDE_ONL template <typename Pl, typename Pr> bool - is_subset_of(const Point_Set<Pl>& lhs_, const Point_Set<Pr>& rhs_) + is_subset_of(const Site_Set<Pl>& lhs_, const Site_Set<Pr>& rhs_) { trace::entering("set::is_subset_of"); Pl lhs = exact(lhs_); Index: mln/set/diff.hh --- mln/set/diff.hh (revision 1949) +++ mln/set/diff.hh (working copy) @@ -33,7 +33,7 @@ * \brief Set theoretic difference (non-symmetrical) of a couple of * sets. * - * \todo Add a diff(Point_Set& in_place, Function_p2b). + * \todo Add a diff(Site_Set& in_place, Function_p2b). */ # include <mln/convert/to_std_set.hh> @@ -59,11 +59,11 @@ /*! \brief Set theoretic difference of \p lhs and \p rhs. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Wl, typename Wr> p_set<mln_point(Wl)> - diff(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs); + diff(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs); # ifndef MLN_INCLUDE_ONLY @@ -90,7 +90,7 @@ template <typename Wl, typename Wr> inline p_set<mln_point(Wl)> - diff(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs) + diff(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs) { trace::entering("set::diff"); mln::metal::equal<mln_point(Wl), mln_point(Wr)>::check(); Index: mln/set/uni.hh --- mln/set/uni.hh (revision 1949) +++ mln/set/uni.hh (working copy) @@ -56,11 +56,11 @@ /*! \brief Union of a couple of point sets. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Wl, typename Wr> p_set<mln_point(Wl)> - uni(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs); + uni(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs); # ifndef MLN_INCLUDE_ONLY @@ -87,7 +87,7 @@ template <typename Wl, typename Wr> inline p_set<mln_point(Wl)> - uni(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs) + uni(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs) { trace::entering("set::uni"); mln::metal::equal<mln_point(Wl), mln_point(Wr)>::check(); Index: mln/set/sym_diff.hh --- mln/set/sym_diff.hh (revision 1949) +++ mln/set/sym_diff.hh (working copy) @@ -56,11 +56,11 @@ /*! \brief Set theoretic symmetrical difference of \p lhs and \p rhs. * - * \relates mln::Point_Set + * \relates mln::Site_Set */ template <typename Wl, typename Wr> p_set<mln_point(Wl)> - sym_diff(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs); + sym_diff(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs); # ifndef MLN_INCLUDE_ONLY @@ -86,7 +86,7 @@ template <typename Wl, typename Wr> inline p_set<mln_point(Wl)> - sym_diff(const Point_Set<Wl>& lhs, const Point_Set<Wr>& rhs) + sym_diff(const Site_Set<Wl>& lhs, const Site_Set<Wr>& rhs) { trace::entering("set::sym_diff"); mln::metal::equal<mln_point(Wl), mln_point(Wr)>::check();
participants (1)
-
Thierry Geraud