GimpColorTransform

## GimpColorTransform GimpColorTransform — Definitions and Functions relating to LCMS. |

## Functions

GimpColorTransform * | gimp_color_transform_new ()
GimpColorTransform * | gimp_color_transform_new_proofing ()
void | gimp_color_transform_process_pixels ()
void | gimp_color_transform_process_buffer ()
gboolean | gimp_color_transform_can_gegl_copy ()

## Types and Values

enum | GimpColorTransformFlags

## Description

Definitions and Functions relating to LCMS.

## Functions

### gimp_color_transform_new ()

    GimpColorTransform *
    gimp_color_transform_new (GimpColorProfile *src_profile,
                              const Babl *src_format,
                              GimpColorProfile *dest_profile,
                              const Babl *dest_format,
                              GimpColorRenderingIntent rendering_intent,
                              GimpColorTransformFlags flags);

This function creates an color transform.

#### Parameters

src_profile | the source GimpColorProfile |
src_format | the source Babl format |
dest_profile | the destination GimpColorProfile |
dest_format | the destination Babl format |
rendering_intent | the rendering intent |
flags | transform flags |

#### Returns

the GimpColorTransform, or `NULL` if no transform is needed to convert between pixels of `src_profile` and `dest_profile` .

Since: 2.10

### gimp_color_transform_new_proofing ()

    GimpColorTransform *
    gimp_color_transform_new_proofing (GimpColorProfile *src_profile,
                                       const Babl *src_format,
                                       GimpColorProfile *dest_profile,
                                       const Babl *dest_format,
                                       GimpColorProfile *proof_profile,
                                       GimpColorRenderingIntent proof_intent,
                                       GimpColorRenderingIntent display_intent,
                                       GimpColorTransformFlags flags);

This function creates a simulation / proofing color transform.

#### Parameters

src_profile | the source GimpColorProfile |
src_format | the source Babl format |
dest_profile | the destination GimpColorProfile |
dest_format | the destination Babl format |
proof_profile | the proof GimpColorProfile |
proof_intent | the proof intent |
display_intent | the display intent |
flags | transform flags |

#### Returns

the GimpColorTransform, or `NULL`.

Since: 2.10

### gimp_color_transform_process_pixels ()

    void
    gimp_color_transform_process_pixels (GimpColorTransform *transform,
                                         const Babl *src_format,
                                         gconstpointer src_pixels,
                                         const Babl *dest_format,
                                         gpointer dest_pixels,
                                         gsize length);

This function transforms a contiguous line of pixels.

#### Parameters

transform | a GimpColorTransform |
src_format | Babl format of `src_pixels` |
src_pixels | pointer to the source pixels |
dest_format | Babl format of `dest_pixels` |
dest_pixels | pointer to the destination pixels |
length | number of pixels to process |

Since: 2.10

### gimp_color_transform_process_buffer ()

    void
    gimp_color_transform_process_buffer (GimpColorTransform *transform,
                                         GeglBuffer *src_buffer,
                                         const GeglRectangle *src_rect,
                                         GeglBuffer *dest_buffer,
                                         const GeglRectangle *dest_rect);

This function transforms buffer into another buffer.

#### Parameters

transform | a GimpColorTransform |
src_buffer | source GeglBuffer |
src_rect | rectangle in `src_buffer` |
dest_buffer | destination GeglBuffer |
dest_rect | rectangle in `dest_buffer` |

Since: 2.10

### gimp_color_transform_can_gegl_copy ()

    gboolean
    gimp_color_transform_can_gegl_copy (GimpColorProfile *src_profile,
                                        GimpColorProfile *dest_profile);

This function checks if a GimpColorTransform is needed at all.

#### Parameters

src_profile | source GimpColorProfile |
dest_profile | destination GimpColorProfile |

#### Returns

`TRUE` if pixels can be correctly converted between `src_profile` and `dest_profile` by simply using `gegl_buffer_copy()`, `babl_process()` or similar.

Since: 2.10

## Types and Values

### enum GimpColorTransformFlags

#### Members

GIMP_COLOR_TRANSFORM_FLAGS_NOOPTIMIZE |  |
GIMP_COLOR_TRANSFORM_FLAGS_GAMUT_CHECK |  |
GIMP_COLOR_TRANSFORM_FLAGS_BLACK_POINT_COMPENSATION |  |