
URL: https://svn.lrde.org/svn/oln/trunk/milena ChangeLog: 2007-10-17 Simon Nivault <simon.nivault@lrde.epita.fr> Update typo. * mln/core/dpoint3d.hh: Rename constants. * mln/fun/all.hh: New. * mln/fun/i2v/all_to.hh: New. * mln/fun/p2b/all.hh: New. * mln/fun/p2v/all.hh: New. * mln/fun/v2v/all.hh: New. * mln/fun/x2x/all.hh: New. --- core/dpoint3d.hh | 13 +++--- fun/all.hh | 63 ++++++++++++++++++++++++++++++++ fun/i2v/all.hh | 67 ++++------------------------------ fun/i2v/all_to.hh | 105 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ fun/p2b/all.hh | 56 ++++++++++++++++++++++++++++ fun/p2v/all.hh | 58 +++++++++++++++++++++++++++++ fun/v2v/all.hh | 60 ++++++++++++++++++++++++++++++ fun/x2x/all.hh | 58 +++++++++++++++++++++++++++++ 8 files changed, 414 insertions(+), 66 deletions(-) Index: trunk/milena/mln/core/dpoint3d.hh =================================================================== --- trunk/milena/mln/core/dpoint3d.hh (revision 1347) +++ trunk/milena/mln/core/dpoint3d.hh (revision 1348) @@ -57,13 +57,12 @@ { // FIXME: Doc! - const dpoint3d segolene = make::dpoint3d( 0, 0, -1); - const dpoint3d sarkosy = make::dpoint3d( 0, 0, +1); - // FIXME: More serious directions :) - const dpoint3d top = make::dpoint3d( 0, -1, 0); - const dpoint3d bottom = make::dpoint3d( 0, +1, 0); - const dpoint3d back = make::dpoint3d(-1, 0, 0); - const dpoint3d front = make::dpoint3d(+1, 0, 0); + const dpoint3d sagittal_dec = make::dpoint3d( 0, 0, -1); + const dpoint3d sagittal_inc = make::dpoint3d( 0, 0, +1); + const dpoint3d axial_dec = make::dpoint3d( 0, -1, 0); + const dpoint3d axial_inc = make::dpoint3d( 0, +1, 0); + const dpoint3d coronal_dec = make::dpoint3d(-1, 0, 0); + const dpoint3d coronal_inc = make::dpoint3d(+1, 0, 0); } // end of namespace mln Index: trunk/milena/mln/fun/i2v/all.hh =================================================================== --- trunk/milena/mln/fun/i2v/all.hh (revision 1347) +++ trunk/milena/mln/fun/i2v/all.hh (revision 1348) @@ -25,18 +25,14 @@ // reasons why the executable file might be covered by the GNU General // Public License. -#ifndef MLN_FUN_ALL_HH -# define MLN_FUN_ALL_HH +#ifndef MLN_FUN_I2V_ALL_HH +# define MLN_FUN_I2V_ALL_HH -/*! \file mln/fun/i2v/all.hh +/*! \file mln/fun_i2v/all.hh * - * \brief FIXME. + * \brief File that includes all functions from index to value. */ -# include <mln/core/concept/function.hh> - - -// FIXME: Usually all.hh is the file to include all files in the current directory... namespace mln { @@ -44,64 +40,17 @@ namespace fun { + /// Namespace of functions from index to value. namespace i2v { - - template <typename T> - struct all : public Function_i2v< all<T> > - { - typedef T result; - all(T t); - template <typename U> - T operator()(const U&) const; - private: - T t_; - }; - - } // end of namespace mln::fun::i2v - - } // end of namespace mln::fun - - template <typename T> - fun::i2v::all<T> all(T t); - - -# ifndef MLN_INCLUDE_ONLY - - namespace fun - { - - namespace i2v - { - - template <typename T> - all<T>::all(T t) - : t_(t) - { } - - template <typename T> - template <typename U> - T - all<T>::operator()(const U&) const - { - return t_; } - } // end of namespace mln::fun::i2v - - } // end of namespace mln::fun - - template <typename T> - fun::i2v::all<T> all(T t) - { - fun::i2v::all<T> tmp(t); - return tmp; } -# endif // ! MLN_INCLUDE_ONLY -} // end of namespace mln +# include <mln/fun/i2v/all_to.hh> + -#endif // ! MLN_FUN_ALL_HH +#endif // ! MLN_FUN_I2V_ALL_HH Index: trunk/milena/mln/fun/i2v/all_to.hh =================================================================== --- trunk/milena/mln/fun/i2v/all_to.hh (revision 0) +++ trunk/milena/mln/fun/i2v/all_to.hh (revision 1348) @@ -0,0 +1,105 @@ +// Copyright (C) 2007 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_FUN_ALL_TO_HH +# define MLN_FUN_ALL_TO_HH + +/*! \file mln/fun/i2v/all_to.hh + * + * \brief FIXME. + */ + +# include <mln/core/concept/function.hh> + + +namespace mln +{ + + namespace fun + { + + namespace i2v + { + + template <typename T> + struct all_to : public Function_i2v< all_to<T> > + { + typedef T result; + all_to(T t); + template <typename U> + T operator()(const U&) const; + private: + T t_; + }; + + } // end of namespace mln::fun::i2v + + } // end of namespace mln::fun + + template <typename T> + fun::i2v::all_to<T> all_to(T t); + + +# ifndef MLN_INCLUDE_ONLY + + namespace fun + { + + namespace i2v + { + + template <typename T> + all_to<T>::all_to(T t) + : t_(t) + { + } + + template <typename T> + template <typename U> + T + all_to<T>::operator()(const U&) const + { + return t_; + } + + } // end of namespace mln::fun::i2v + + } // end of namespace mln::fun + + template <typename T> + fun::i2v::all_to<T> all_to(T t) + { + fun::i2v::all_to<T> tmp(t); + return tmp; + } + +# endif // ! MLN_INCLUDE_ONLY + +} // end of namespace mln + + +#endif // ! MLN_FUN_ALL_TO_HH Index: trunk/milena/mln/fun/x2x/all.hh =================================================================== --- trunk/milena/mln/fun/x2x/all.hh (revision 0) +++ trunk/milena/mln/fun/x2x/all.hh (revision 1348) @@ -0,0 +1,58 @@ +// Copyright (C) 2007 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_FUN_X2X_ALL_HH +# define MLN_FUN_X2X_ALL_HH + +/*! \file mln/fun_x2x/all.hh + * + * \brief File that includes all functions from vector to vector. + */ + + +namespace mln +{ + + namespace fun + { + + /// Namespace of functions from vector to vector. + namespace x2x + { + } + } + +} + + +# include <mln/fun/x2x/composed.hh> +# include <mln/fun/x2x/rotation.hh> +# include <mln/fun/x2x/translation.hh> + + + +#endif // ! MLN_FUN_X2X_ALL_HH Index: trunk/milena/mln/fun/p2b/all.hh =================================================================== --- trunk/milena/mln/fun/p2b/all.hh (revision 0) +++ trunk/milena/mln/fun/p2b/all.hh (revision 1348) @@ -0,0 +1,56 @@ +// Copyright (C) 2007 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_FUN_P2B_ALL_HH +# define MLN_FUN_P2B_ALL_HH + +/*! \file mln/fun_p2b/all.hh + * + * \brief File that includes all functions from point to boolean. + */ + + +namespace mln +{ + + namespace fun + { + + /// Namespace of functions from point to boolean. + namespace p2b + { + } + } + +} + + +# include <mln/fun/p2b/chess.hh> + + + +#endif // ! MLN_FUN_P2B_ALL_HH Index: trunk/milena/mln/fun/all.hh =================================================================== --- trunk/milena/mln/fun/all.hh (revision 0) +++ trunk/milena/mln/fun/all.hh (revision 1348) @@ -0,0 +1,63 @@ +// Copyright (C) 2007 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_FUN_ALL_HH +# define MLN_FUN_ALL_HH + +/*! \file mln/fun/all.hh + * + * \brief File that includes all fun-related routines. + */ + + +namespace mln +{ + + /// Namespace of image processing routines related to pixel funs. + namespace fun + { + + /// Internal namespace of functions. + namespace internal + { + } + } + +} + + +# include <mln/fun/c.hh> +# include <mln/fun/ops.hh> +# include <mln/fun/i2v/all.hh> +# include <mln/fun/p2b/all.hh> +# include <mln/fun/p2v/all.hh> +# include <mln/fun/v2v/all.hh> +# include <mln/fun/x2x/all.hh> + + + +#endif // ! MLN_FUN_ALL_HH Index: trunk/milena/mln/fun/p2v/all.hh =================================================================== --- trunk/milena/mln/fun/p2v/all.hh (revision 0) +++ trunk/milena/mln/fun/p2v/all.hh (revision 1348) @@ -0,0 +1,58 @@ +// Copyright (C) 2007 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_FUN_P2V_ALL_HH +# define MLN_FUN_P2V_ALL_HH + +/*! \file mln/fun_p2v/all.hh + * + * \brief File that includes all functions from point to value. + */ + + +namespace mln +{ + + namespace fun + { + + /// Namespace of functions from point to value. + namespace p2v + { + } + } + +} + + +# include <mln/fun/p2v/elifs.hh> +# include <mln/fun/p2v/iota.hh> +# include <mln/fun/p2v/ternary.hh> + + + +#endif // ! MLN_FUN_P2V_ALL_HH Index: trunk/milena/mln/fun/v2v/all.hh =================================================================== --- trunk/milena/mln/fun/v2v/all.hh (revision 0) +++ trunk/milena/mln/fun/v2v/all.hh (revision 1348) @@ -0,0 +1,60 @@ +// Copyright (C) 2007 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_FUN_V2V_ALL_HH +# define MLN_FUN_V2V_ALL_HH + +/*! \file mln/fun_v2v/all.hh + * + * \brief File that includes all functions from value to value. + */ + + +namespace mln +{ + + namespace fun + { + + /// Namespace of functions from value to value. + namespace v2v + { + } + } + +} + + +# include <mln/fun/v2v/abs.hh> +# include <mln/fun/v2v/enc.hh> +# include <mln/fun/v2v/id.hh> +# include <mln/fun/v2v/linear.hh> +# include <mln/fun/v2v/saturate.hh> + + + +#endif // ! MLN_FUN_V2V_ALL_HH