Commit ecfe33cd authored by Thierry Geraud's avatar Thierry Geraud
Browse files

De-activate hsl stuff in value rgb.

	* mln/value/rgb.hh: De-activate hsl stuff.
	It shall be moved elsewhere.
	* mln/trait/value_.hh (mln_dim): New macro.
	Layout; sort short macros by name.
	* mln/fun/c.hh (todo): New.


git-svn-id: https://svn.lrde.epita.fr/svn/oln/trunk@3788 4aad255d-cdde-0310-9447-f3009e2ae8c0
parent 36d7df77
2009-05-12 Thierry Geraud <thierry.geraud@lrde.epita.fr>
De-activate hsl stuff in value rgb.
* mln/value/rgb.hh: De-activate hsl stuff.
It shall be moved elsewhere.
* mln/trait/value_.hh (mln_dim): New macro.
Layout; sort short macros by name.
* mln/fun/c.hh (todo): New.
2009-05-11 Fabien Freling <fabien.freling@lrde.epita.fr>
 
Fix full2image() domain for cropped images.
......@@ -33,6 +33,9 @@
///
/// Encapsulate a plain (C language-like) pointer to function
/// into a functor.
///
/// \todo Fix category: super is not defined!
/// See mln/value/builtin/integers.hh for an example.
# include <mln/fun/internal/selector.hh>
# include <mln/metal/unqualif.hh>
......
......@@ -53,11 +53,12 @@
# define mln_trait_value_quant_(V) mln::trait::value_< V >::quant
# define mln_nbits(V) mln::trait::value_< V >::nbits
# define mln_card(V) mln::trait::value_< V >::card
# define mln_min(V) mln::trait::value_< V >::min()
# define mln_max(V) mln::trait::value_< V >::max()
# define mln_dim(V) mln::trait::value_< V >::dim
# define mln_epsilon(V) mln::trait::value_< V >::epsilon()
# define mln_max(V) mln::trait::value_< V >::max()
# define mln_min(V) mln::trait::value_< V >::min()
# define mln_nbits(V) mln::trait::value_< V >::nbits
/// Give the summation type for values of type \c T.
......
......@@ -42,7 +42,7 @@
# include <mln/value/ops.hh>
# include <mln/fun/v2v/hsl_to_rgb.hh>
// # include <mln/fun/v2v/hsl_to_rgb.hh>
# include <mln/value/concept/vectorial.hh>
# include <mln/value/int_u.hh>
# include <mln/algebra/vec.hh>
......@@ -55,24 +55,24 @@ namespace mln
namespace fun
{
// namespace fun
// {
namespace v2v
{
// namespace v2v
// {
template <typename T_rgb>
struct f_hsl_to_rgb_;
// template <typename T_rgb>
// struct f_hsl_to_rgb_;
typedef f_hsl_to_rgb_< value::rgb<8> > f_hsl_to_rgb_3x8_t;
typedef f_hsl_to_rgb_< value::rgb<16> > f_hsl_to_rgb_3x16_t;
// typedef f_hsl_to_rgb_< value::rgb<8> > f_hsl_to_rgb_3x8_t;
// typedef f_hsl_to_rgb_< value::rgb<16> > f_hsl_to_rgb_3x16_t;
extern f_hsl_to_rgb_3x8_t f_hsl_to_rgb_3x8;
extern f_hsl_to_rgb_3x16_t f_hsl_to_rgb_3x16;
// extern f_hsl_to_rgb_3x8_t f_hsl_to_rgb_3x8;
// extern f_hsl_to_rgb_3x16_t f_hsl_to_rgb_3x16;
}
// }
}
// }
namespace literal
......@@ -103,11 +103,11 @@ namespace mln
}
// Forward declaration.
namespace value
{
template <typename H, typename S, typename L> class hsl_;
}
// // Forward declaration.
// namespace value
// {
// template <typename H, typename S, typename L> class hsl_;
// }
namespace convert
......@@ -128,13 +128,13 @@ namespace mln
template <unsigned m>
void from_to_(const value::int_u<m>& from, value::rgb<m>& to);
// hsl -> rgb8.
template <typename H, typename S, typename L>
void from_to_(const value::hsl_<H,S,L>&, value::rgb<8>& to);
// // hsl -> rgb8.
// template <typename H, typename S, typename L>
// void from_to_(const value::hsl_<H,S,L>&, value::rgb<8>& to);
// hsl -> rgb16.
template <typename H, typename S, typename L>
void from_to_(const value::hsl_<H,S,L>&, value::rgb<16>& to);
// // hsl -> rgb16.
// template <typename H, typename S, typename L>
// void from_to_(const value::hsl_<H,S,L>&, value::rgb<16>& to);
// rgb -> bool.
template <unsigned m>
......@@ -397,8 +397,8 @@ namespace mln
} // end of namespace mln
// Needed by from_to_.
# include <mln/fun/v2v/rgb_to_hsl.hh>
// // Needed by from_to_.
// # include <mln/fun/v2v/rgb_to_hsl.hh>
# ifndef MLN_INCLUDE_ONLY
......@@ -787,19 +787,19 @@ namespace mln
to = value::rgb<m>(from, from, from);
}
template <typename H, typename S, typename L>
void
from_to_(const value::hsl_<H,S,L>& from, value::rgb<8>& to)
{
to = fun::v2v::f_hsl_to_rgb_3x8(from);
}
template <typename H, typename S, typename L>
void
from_to_(const value::hsl_<H,S,L>& from, value::rgb<16>& to)
{
to = fun::v2v::f_hsl_to_rgb_3x16(from);
}
// template <typename H, typename S, typename L>
// void
// from_to_(const value::hsl_<H,S,L>& from, value::rgb<8>& to)
// {
// to = fun::v2v::f_hsl_to_rgb_3x8(from);
// }
// template <typename H, typename S, typename L>
// void
// from_to_(const value::hsl_<H,S,L>& from, value::rgb<16>& to)
// {
// to = fun::v2v::f_hsl_to_rgb_3x16(from);
// }
template <unsigned m>
void
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment