Re: about gimp_rgb_to_hsl and gimp_colorize

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



It have been solved with this:

    GimpHSL hsl;
    gimp_rgb_to_hsl (&rbvals.color, &hsl);
    if (hsl.h == -1) // GIMP_HSL_UNDEFINED
      hsl.h = 0;
    gimp_colorize(drawable->drawable_id, hsl.h * 360, hsl.s * 100, hsl.l
* 100);

sorry for disturbs.

On Wed, 2012-06-06 at 12:57 +0800, hejian wrote:
> I am trying to write a plugin, this is the code snippet:
> 
>     GimpHSL hsl;
>     gimp_rgb_to_hsl (&rbvals.color, &hsl);
>     gimp_colorize(drawable->drawable_id, hsl.h, hsl.s, hsl.l);
> 
> It will got this error:
> 
> Calling error for procedure 'gimp-colorize':
> Procedure 'gimp-colorize' has been called with value '-1.000000' for
> argument 'hue' (#2, type gdouble). This value is out of range.
> 
> any suggestion is appreciated.
> 


_______________________________________________
gimp-developer-list mailing list
gimp-developer-list@xxxxxxxxx
https://mail.gnome.org/mailman/listinfo/gimp-developer-list


[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux