libgimpcolor: pass intent to babl_space from icc creation

parent 0dfed0ec
...@@ -1466,9 +1466,10 @@ gimp_color_profile_new_d50_gray_lab_trc (void) ...@@ -1466,9 +1466,10 @@ gimp_color_profile_new_d50_gray_lab_trc (void)
* Since: 2.10 * Since: 2.10
**/ **/
const Babl * const Babl *
gimp_color_profile_get_format (GimpColorProfile *profile, gimp_color_profile_get_format (GimpColorProfile *profile,
const Babl *format, const Babl *format,
GError **error) GimpColorRenderingIntent intent,
GError **error)
{ {
const Babl *space; const Babl *space;
const gchar *babl_error = NULL; const gchar *babl_error = NULL;
...@@ -1479,6 +1480,7 @@ gimp_color_profile_get_format (GimpColorProfile *profile, ...@@ -1479,6 +1480,7 @@ gimp_color_profile_get_format (GimpColorProfile *profile,
space = babl_space_from_icc ((const gchar *) profile->priv->data, space = babl_space_from_icc ((const gchar *) profile->priv->data,
profile->priv->length, profile->priv->length,
intent,
&babl_error); &babl_error);
if (! space) if (! space)
......
...@@ -113,6 +113,7 @@ gboolean gimp_color_profile_is_linear (GimpColorProfile * ...@@ -113,6 +113,7 @@ gboolean gimp_color_profile_is_linear (GimpColorProfile *
const Babl * gimp_color_profile_get_format (GimpColorProfile *profile, const Babl * gimp_color_profile_get_format (GimpColorProfile *profile,
const Babl *format, const Babl *format,
GimpColorRenderingIntent intent,
GError **error); GError **error);
const Babl * gimp_color_profile_get_lcms_format (const Babl *format, const Babl * gimp_color_profile_get_lcms_format (const Babl *format,
guint32 *lcms_format); guint32 *lcms_format);
......
...@@ -203,6 +203,7 @@ gimp_color_transform_new (GimpColorProfile *src_profile, ...@@ -203,6 +203,7 @@ gimp_color_transform_new (GimpColorProfile *src_profile,
priv->src_space_format = gimp_color_profile_get_format (src_profile, priv->src_space_format = gimp_color_profile_get_format (src_profile,
src_format, src_format,
BABL_ICC_INTENT_RELATIVE_COLORIMETRIC,
&error); &error);
if (! priv->src_space_format) if (! priv->src_space_format)
{ {
...@@ -213,6 +214,7 @@ gimp_color_transform_new (GimpColorProfile *src_profile, ...@@ -213,6 +214,7 @@ gimp_color_transform_new (GimpColorProfile *src_profile,
priv->dest_space_format = gimp_color_profile_get_format (dest_profile, priv->dest_space_format = gimp_color_profile_get_format (dest_profile,
dest_format, dest_format,
rendering_intent,
&error); &error);
if (! priv->dest_space_format) if (! priv->dest_space_format)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment