GimpCMYK

GimpCMYK — Definitions and Functions relating to CMYK colors.

Synopsis




                    GimpCMYK;
void                gimp_cmyk_set                       (GimpCMYK *cmyk,
                                                         gdouble cyan,
                                                         gdouble magenta,
                                                         gdouble yellow,
                                                         gdouble black);
void                gimp_cmyk_set_uchar                 (GimpCMYK *cmyk,
                                                         guchar cyan,
                                                         guchar magenta,
                                                         guchar yellow,
                                                         guchar black);
void                gimp_cmyk_get_uchar                 (const GimpCMYK *cmyk,
                                                         guchar *cyan,
                                                         guchar *magenta,
                                                         guchar *yellow,
                                                         guchar *black);
void                gimp_cmyka_set                      (GimpCMYK *cmyka,
                                                         gdouble cyan,
                                                         gdouble magenta,
                                                         gdouble yellow,
                                                         gdouble black,
                                                         gdouble alpha);
void                gimp_cmyka_set_uchar                (GimpCMYK *cmyka,
                                                         guchar cyan,
                                                         guchar magenta,
                                                         guchar yellow,
                                                         guchar black,
                                                         guchar alpha);
void                gimp_cmyka_get_uchar                (const GimpCMYK *cmyka,
                                                         guchar *cyan,
                                                         guchar *magenta,
                                                         guchar *yellow,
                                                         guchar *black,
                                                         guchar *alpha);

Description

Definitions and Functions relating to CMYK colors.

Details

GimpCMYK

typedef struct {
  gdouble c, m, y, k, a;
} GimpCMYK;


gimp_cmyk_set ()

void                gimp_cmyk_set                       (GimpCMYK *cmyk,
                                                         gdouble cyan,
                                                         gdouble magenta,
                                                         gdouble yellow,
                                                         gdouble black);

Very basic initialiser for the internal GimpCMYK structure. Channel values are doubles in the range 0 to 1.

cmyk : A GimpCMYK structure which will hold the specified CMYK value.
cyan : The Cyan channel of the CMYK value
magenta : The Magenta channel
yellow : The Yellow channel
black : The blacK channel

gimp_cmyk_set_uchar ()

void                gimp_cmyk_set_uchar                 (GimpCMYK *cmyk,
                                                         guchar cyan,
                                                         guchar magenta,
                                                         guchar yellow,
                                                         guchar black);

The same as gimp_cmyk_set(), except that channel values are unsigned chars in the range 0 to 255.

cmyk : A GimpCMYK structure which will hold the specified CMYK value.
cyan : The Cyan channel of the CMYK value
magenta : The Magenta channel
yellow : The Yellow channel
black : The blacK channel

gimp_cmyk_get_uchar ()

void                gimp_cmyk_get_uchar                 (const GimpCMYK *cmyk,
                                                         guchar *cyan,
                                                         guchar *magenta,
                                                         guchar *yellow,
                                                         guchar *black);

Retrieve individual channel values from a GimpCMYK structure. Channel values are pointers to unsigned chars in the range 0 to 255.

cmyk : A GimpCMYK structure which will hold the specified CMYK value.
cyan : The Cyan channel of the CMYK value
magenta : The Magenta channel
yellow : The Yellow channel
black : The blacK channel

gimp_cmyka_set ()

void                gimp_cmyka_set                      (GimpCMYK *cmyka,
                                                         gdouble cyan,
                                                         gdouble magenta,
                                                         gdouble yellow,
                                                         gdouble black,
                                                         gdouble alpha);

Initialiser for the internal GimpCMYK structure. Channel values are doubles in the range 0 to 1.

cmyka : A GimpCMYK structure which will hold the specified CMYKA value.
cyan : The Cyan channel of the CMYK value
magenta : The Magenta channel
yellow : The Yellow channel
black : The blacK channel
alpha : The Alpha channel

gimp_cmyka_set_uchar ()

void                gimp_cmyka_set_uchar                (GimpCMYK *cmyka,
                                                         guchar cyan,
                                                         guchar magenta,
                                                         guchar yellow,
                                                         guchar black,
                                                         guchar alpha);

The same as gimp_cmyka_set(), except that channel values are unsigned chars in the range 0 to 255.

cmyka : A GimpCMYK structure which will hold the specified CMYKA value.
cyan : The Cyan channel of the CMYK value
magenta : The Magenta channel
yellow : The Yellow channel
black : The blacK channel
alpha : The Alpha channel

gimp_cmyka_get_uchar ()

void                gimp_cmyka_get_uchar                (const GimpCMYK *cmyka,
                                                         guchar *cyan,
                                                         guchar *magenta,
                                                         guchar *yellow,
                                                         guchar *black,
                                                         guchar *alpha);

Retrieve individual channel values from a GimpCMYK structure. Channel values are pointers to unsigned chars in the range 0 to 255.

cmyka : A GimpCMYK structure which will hold the specified CMYKA value.
cyan : The Cyan channel of the CMYK value
magenta : The Magenta channel
yellow : The Yellow channel
black : The blacK channel
alpha : The Alpha channel