1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 09:58:11 +00:00
serenity/Userland/Libraries/LibGfx/ImageFormats
Nico Weber df79a2720b WebP/Lossy+Alpha: Implement filtering_method for ALPH chunk
The spec says "Decoders are not required to use this information in any
specified way" about this field, but that's probably a typo and belongs
in the previous section. At least, images in the wild look wrong
without this, for example
https://fjord.dropboxstatic.com/warp/conversion/dropbox/warp/en-us/dropbox/Integrations_4@2x.png?id=ce8269af-ef1a-460a-8199-65af3dd978a3&output_type=webp

Implementation-wise, this now copies both uncompressed and compressed
data to yet another buffer for processing the alpha, then does
filtering on that buffer, and then copies the filtered alpha data
into the final image. (The RGB data comes from a lossy webp.)
This is a bit wasteful and we could probably manage without that
local copy, but that'd make the code more convoluted, so this is
good enough for now, at least until we've added tests for this case.

No test, because I haven't yet found out how to create images in this
format.
2023-06-07 08:08:52 +02:00
..
BMPLoader.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
BMPLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
BMPWriter.cpp LibGfx: Move all image loaders and writers to a subdirectory 2023-03-21 22:39:25 +01:00
BMPWriter.h LibGfx: Move all image loaders and writers to a subdirectory 2023-03-21 22:39:25 +01:00
BooleanDecoder.cpp LibGfx+LibVideo: Make BooleanDecoder usable for both VP8 and VP9 2023-05-27 05:47:42 +02:00
BooleanDecoder.h LibGfx+LibVideo: Make BooleanDecoder usable for both VP8 and VP9 2023-05-27 05:47:42 +02:00
DDSLoader.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
DDSLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
GIFLoader.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
GIFLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
ICOLoader.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
ICOLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
ImageDecoder.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
ImageDecoder.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
JPEGLoader.cpp LibGfx/JPEG: Use Error to propagate errors 2023-06-02 20:07:27 +02:00
JPEGLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
PBMLoader.cpp LibGfx/PortableFormat: Propagate errors from read_image_data() 2023-03-24 10:56:58 +01:00
PBMLoader.h LibGfx/PortableFormat: Propagate errors from read_image_data() 2023-03-24 10:56:58 +01:00
PGMLoader.cpp LibGfx/PortableFormat: Use static_cast instead of C-style casts 2023-03-24 10:56:58 +01:00
PGMLoader.h LibGfx/PortableFormat: Propagate errors from read_image_data() 2023-03-24 10:56:58 +01:00
PNGLoader.cpp LibGfx: Fix partial loading of tall and interlaced PNG files 2023-06-06 19:55:51 +02:00
PNGLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
PNGShared.h LibGfx: Move all image loaders and writers to a subdirectory 2023-03-21 22:39:25 +01:00
PNGWriter.cpp LibGfx: Move all image loaders and writers to a subdirectory 2023-03-21 22:39:25 +01:00
PNGWriter.h LibGfx: Move all image loaders and writers to a subdirectory 2023-03-21 22:39:25 +01:00
PortableFormatWriter.cpp LibGfx/PortableFormat: Use FixedArray::unchecked_at 2023-05-09 11:18:46 +02:00
PortableFormatWriter.h LibGfx/PortableFormat+image: Make encode take a Stream 2023-05-09 11:18:46 +02:00
PortableImageLoaderCommon.h LibGfx/PortableFormat: Reject images with a maximum value of 0 2023-06-06 23:48:52 +02:00
PortableImageMapLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
PPMLoader.cpp LibGfx/PortableFormat: Use static_cast instead of C-style casts 2023-03-24 10:56:58 +01:00
PPMLoader.h LibGfx/PortableFormat: Propagate errors from read_image_data() 2023-03-24 10:56:58 +01:00
QOILoader.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
QOILoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
QOIWriter.cpp Everywhere: Remove unused DeprecatedString includes 2023-04-09 22:00:54 +02:00
QOIWriter.h LibGfx: Move all image loaders and writers to a subdirectory 2023-03-21 22:39:25 +01:00
TGALoader.cpp LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
TGALoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
WebPLoader.cpp WebP/Lossy+Alpha: Implement filtering_method for ALPH chunk 2023-06-07 08:08:52 +02:00
WebPLoader.h LibGfx+Fuzz: Convert ImageDecoder::initialize to ErrorOr 2023-05-12 09:40:24 +01:00
WebPLoaderLossless.cpp LibGfx/WebP: Move lossless decoder to its own file 2023-05-08 12:52:05 +02:00
WebPLoaderLossless.h LibGfx/WebP: Minor cosmetical changes in WebPLoaderLossless.h 2023-05-09 06:35:56 +02:00
WebPLoaderLossy.cpp WebP/Lossy: Allow negative values from segment adjustment too 2023-06-01 17:36:20 +02:00
WebPLoaderLossy.h WebP/Lossy: Implement macroblock coefficient decoding 2023-05-29 10:41:53 -06:00
WebPLoaderLossyTables.h WebP/Lossy: Add const annotations to functions in Tables.h 2023-06-01 16:23:46 +02:00