Hi Christian,
Hi Marc,
are you aware of scoped_channel_value? Here a small example:
// Create a double channel with range [-0.5 .. 0.5]
struct double_minus_half { static double apply() { return -0.5; } };
struct double_plus_half { static double apply() { return 0.5; } };
typedef scoped_channel_value<double, double_minus_half,
double_plus_half> bits64custom_t;
// channel_convert its maximum should map to the maximum
bits64custom_t x = channel_traits<bits64custom_t>::max_value();
assert(x == 0.5);
bits16 y = channel_convert<bits16>(x);
assert(y == 65535);
Let me know. If that doesn't help I'll dig deeper into your problem.
Regards,
Christian
> _______________________________________________
On Tue, May 29, 2012 at 6:28 AM, Marc-Antoine ARNAUD <mrn@mikrosimage.eu> wrote:
> Hi guys,
>
>
> I currently working on TuttleOFX projet, and using Boost GIL to perform some
> image process.
> I wan't using color_converted_view to process clamping values on a view,
> witth a specific ColorConvert (CC) functor.
>
> But with the actual code
> [https://github.com/tuttleofx/TuttleOFX/blob/master/libraries/terry/src/terry/clamp.hpp]
> , the pixel_clamp contructor was corretly called, but our functor (void
> operator()( const SPixel& src, DPixel& dst ) const) wasn't.
> Does someone have the same bug ?
> Are they more documentation anywhere on this function ( I'm refering on this
> link:http://stlab.adobe.com/gil/html/group___image_view_transformations_color_convert.html )
>
>
> Thanks,
> --
> Marc-Antoine
>
> Boost-users mailing list
> Boost-users@lists.boost.org
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
_______________________________________________
Boost-users mailing list
Boost-users@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users