Skip to content

Commit efed966

Browse files
committed
revise icc_import docs
see libvips/pyvips#426
1 parent 5482ead commit efed966

File tree

1 file changed

+24
-20
lines changed

1 file changed

+24
-20
lines changed

libvips/colour/icc_transform.c

Lines changed: 24 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1432,17 +1432,19 @@ vips_icc_is_compatible_profile(VipsImage *image,
14321432
* Import an image from device space to D65 LAB with an ICC profile. If @pcs is
14331433
* set to #VIPS_PCS_XYZ, use CIE XYZ PCS instead.
14341434
*
1435-
* If @embedded is set, the input profile is taken from the input image
1436-
* metadata. If there is no embedded profile,
1437-
* @input_profile is used as a fall-back.
1438-
* You can test for the
1439-
* presence of an embedded profile with
1440-
* vips_image_get_typeof() with #VIPS_META_ICC_NAME as an argument. This will
1441-
* return %GType 0 if there is no profile.
1435+
* The input profile is searched for in three places:
14421436
*
1443-
* If @embedded is not set, the input profile is taken from
1444-
* @input_profile. If @input_profile is not supplied, the
1445-
* metadata profile, if any, is used as a fall-back.
1437+
* 1. If @embedded is set, libvips will try to use any profile in the input
1438+
* image metadata. You can test for the presence of an embedded profile
1439+
* with vips_image_get_typeof() with #VIPS_META_ICC_NAME as an argument.
1440+
* This will return %GType 0 if there is no profile.
1441+
*
1442+
* 2. Otherwise, if @input_profile is set, libvips will try to load a
1443+
* profile from the named file. This can aslso be the name of one of the
1444+
* built-in profiles.
1445+
*
1446+
* 3. Otherwise, libvips will try to pick a compatible profile from the set
1447+
* of built-in profiles.
14461448
*
14471449
* If @black_point_compensation is set, LCMS black point compensation is
14481450
* enabled.
@@ -1521,17 +1523,19 @@ vips_icc_export(VipsImage *in, VipsImage **out, ...)
15211523
* profile-connection space with the input profile and then to the output
15221524
* space with the output profile.
15231525
*
1524-
* If @embedded is set, the input profile is taken from the input image
1525-
* metadata, if present. If there is no embedded profile,
1526-
* @input_profile is used as a fall-back.
1527-
* You can test for the
1528-
* presence of an embedded profile with
1529-
* vips_image_get_typeof() with #VIPS_META_ICC_NAME as an argument. This will
1530-
* return %GType 0 if there is no profile.
1526+
* The input profile is searched for in three places:
1527+
*
1528+
* 1. If @embedded is set, libvips will try to use any profile in the input
1529+
* image metadata. You can test for the presence of an embedded profile
1530+
* with vips_image_get_typeof() with #VIPS_META_ICC_NAME as an argument.
1531+
* This will return %GType 0 if there is no profile.
1532+
*
1533+
* 2. Otherwise, if @input_profile is set, libvips will try to load a
1534+
* profile from the named file. This can aslso be the name of one of the
1535+
* built-in profiles.
15311536
*
1532-
* If @embedded is not set, the input profile is taken from
1533-
* @input_profile. If @input_profile is not supplied, the
1534-
* metadata profile, if any, is used as a fall-back.
1537+
* 3. Otherwise, libvips will try to pick a compatible profile from the set
1538+
* of built-in profiles.
15351539
*
15361540
* If @black_point_compensation is set, LCMS black point compensation is
15371541
* enabled.

0 commit comments

Comments
 (0)