diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
commit | 26a029d407be480d791972afb5975cf62c9360a6 (patch) | |
tree | f435a8308119effd964b339f76abb83a57c29483 /image/test/reftest/color-management/trc-type.html | |
parent | Initial commit. (diff) | |
download | firefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz firefox-26a029d407be480d791972afb5975cf62c9360a6.zip |
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'image/test/reftest/color-management/trc-type.html')
-rw-r--r-- | image/test/reftest/color-management/trc-type.html | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/image/test/reftest/color-management/trc-type.html b/image/test/reftest/color-management/trc-type.html new file mode 100644 index 0000000000..f13052bbf4 --- /dev/null +++ b/image/test/reftest/color-management/trc-type.html @@ -0,0 +1,53 @@ +<!DOCTYPE html> +<html> +<body> + <!-- All of these images should render the same + they all have icc profiles with different + but equivalent tone reproduction curves. + + The profiles were generated with the following code and added to the images using pngcrush. + + cmsHPROFILE profile = cmsCreate_sRGBProfile(); + + cmsAddTag(profile, icSigDeviceMfgDescTag, (LPVOID) "(lcms moz internal)"); + cmsAddTag(profile, icSigDeviceModelDescTag, (LPVOID) "linear"); + cmsAddTag(profile, icSigProfileDescriptionTag, (LPVOID) "linear"); + + GAMMATABLE linear_trc; + linear_trc.nEntries = 0; + + cmsAddTag(profile, icSigRedTRCTag, &linear_trc); + cmsAddTag(profile, icSigGreenTRCTag, &linear_trc); + cmsAddTag(profile, icSigBlueTRCTag, &linear_trc); + + _cmsSaveProfile(profile, "linear_gen.icc"); + + GAMMATABLE linear_curve_trc; + linear_curve_trc.nEntries = 1; + linear_curve_trc.GammaTable[0] = 0x0100; + + cmsAddTag(profile, icSigRedTRCTag, &linear_curve_trc); + cmsAddTag(profile, icSigGreenTRCTag, &linear_curve_trc); + cmsAddTag(profile, icSigBlueTRCTag, &linear_curve_trc); + + _cmsSaveProfile(profile, "linear_curve_gen.icc"); + + GAMMATABLE *linear_table_trc = malloc(sizeof(GAMMATABLE) + sizeof(short)*2); + linear_table_trc->nEntries = 2; + linear_table_trc->GammaTable[0] = 0x0; + linear_table_trc->GammaTable[1] = 0xffff; + + cmsAddTag(profile, icSigRedTRCTag, linear_table_trc); + cmsAddTag(profile, icSigGreenTRCTag, linear_table_trc); + cmsAddTag(profile, icSigBlueTRCTag, linear_table_trc); + + _cmsSaveProfile(profile, "linear_table_gen.icc"); + + free(linear_table_trc); + + --> + <img src="color-curv.png"> + <img src="color-table.png"> + <img src="color-lin.png"> +</body> +</html> |