* mln/fun/v2v/rgb_to_int_u.hh,
* mln/fun/v2v/rgb_to_luma.hh: Here.
---
milena/ChangeLog | 8 ++++++++
milena/mln/fun/v2v/rgb_to_int_u.hh | 5 +++++
milena/mln/fun/v2v/rgb_to_luma.hh | 5 +++++
3 files changed, 18 insertions(+), 0 deletions(-)
diff --git a/milena/ChangeLog b/milena/ChangeLog
index 74f08aa..48c3768 100644
--- a/milena/ChangeLog
+++ b/milena/ChangeLog
@@ -1,5 +1,13 @@
2013-04-19 Guillaume Lazzara <z(a)lrde.epita.fr>
+ Specify conversion formulas for rgb to integer conversion
+ functions.
+
+ * mln/fun/v2v/rgb_to_int_u.hh,
+ * mln/fun/v2v/rgb_to_luma.hh: Here.
+
+2013-04-19 Guillaume Lazzara <z(a)lrde.epita.fr>
+
Create sub-modules in image geometry module.
* doc/mln/geom/geom.dox: Add cropping sub-module.
diff --git a/milena/mln/fun/v2v/rgb_to_int_u.hh b/milena/mln/fun/v2v/rgb_to_int_u.hh
index a6a6feb..de9972d 100644
--- a/milena/mln/fun/v2v/rgb_to_int_u.hh
+++ b/milena/mln/fun/v2v/rgb_to_int_u.hh
@@ -50,6 +50,11 @@ namespace mln
\tparam n Defines the number of bits of the integer
destination type.
+ This function computes the mean of the three RGB components:
+ \verbatim
+ luma = (red + green + blue) / 3;
+ \endverbatim
+
\ingroup modfunv2v convert
*/
template <unsigned n>
diff --git a/milena/mln/fun/v2v/rgb_to_luma.hh b/milena/mln/fun/v2v/rgb_to_luma.hh
index 92c603a..3b6ddc2 100644
--- a/milena/mln/fun/v2v/rgb_to_luma.hh
+++ b/milena/mln/fun/v2v/rgb_to_luma.hh
@@ -46,6 +46,11 @@ namespace mln
\brief Conversion function from a RGB value to an integer
value type.
+ This function use the following formula:
+ \verbatim
+ luma = 0.299 * red + 0.587 * green + 0.114 * blue;
+ \endverbatim
+
\ingroup modfunv2v convert
*/
template <typename T_luma>
--
1.7.2.5
Show replies by date