1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-24 18:27:42 +00:00
serenity/Userland/Libraries/LibGfx/ICC
Nico Weber 7f5e9a0236 LibGfx/ICC: Support for A curves and CLUT in LutAToBTagData::evaluate()
`lerp_nd()` is very similar to PDF::SampleFunction::evaluate(). But we
know that the result is a FloatVector3 in the ICC code (at least for
now), so we can save a bunch of redundant computation by returning
all three channels of the LUT at once.

This is enough for images using mAB with A curve / CLUT if the
profile connecting space is PCSXYZ, such as for Upper_Right.jpg
from https://www.color.org/version4html.xalter like so:

    % Build/lagom/icc --name sRGB --reencode-to serenity-sRGB.icc
    % Build/lagom/bin/image -o out.png \
        --convert-to-color-profile serenity-sRGB.icc \
        ~/Downloads/Upper_Right.jpg
2023-12-02 22:26:13 +01:00
..
BinaryFormat.h ICC: Rename XYZ and XYZNumber fields to uppercase 2023-04-29 06:49:36 +02:00
BinaryWriter.cpp LibGfx: Drop tags of unknown type instead of writing invalid icc files 2023-02-24 19:42:00 +01:00
BinaryWriter.h LibGfx: Add start of an ICC profile writer 2023-02-17 20:05:50 -07:00
DistinctFourCC.h AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
Profile.cpp LibGfx/ICC: Implement conversion to PCS for AToB*Tags using mAB 2023-10-26 11:07:43 +02:00
Profile.h LibGfx: Add method to get String data from an ICC Profile tag 2023-07-20 08:02:12 +01:00
Tags.cpp LibGfx: Split ICC/Profile.{h,cpp} into several files 2023-01-28 00:27:07 +00:00
Tags.h LibGfx: Add v2 "ncol" tag, expand comment 2023-02-14 19:28:13 +01:00
TagTypes.cpp LibGfx/ICC: Ensure Macintosh ScriptCode length is within expected range 2023-11-12 07:58:39 +01:00
TagTypes.h LibGfx/ICC: Support for A curves and CLUT in LutAToBTagData::evaluate() 2023-12-02 22:26:13 +01:00
WellKnownProfiles.cpp ICC: Add comment with a link to WellKnownProfiles.cpp 2023-04-29 06:49:36 +02:00
WellKnownProfiles.h LibGfx: Forward-declare TagData in WellKnownProfiles 2023-07-20 06:56:41 +01:00