mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-27 21:21:50 +03:00
a2d8de180c
Each secondary partition has an independent BooleanDecoder. Their bitstreams interleave per macroblock row, that is the first macroblock row is read from the first decoder, the second from the second, ..., until it wraps around again. All partitions share a single prediction state though: The second macroblock row (which reads coefficients off the second decoder) is predicted using the result of decoding the frist macroblock row (which reads coefficients off the first decoder). So if I understand things right, in theory the coefficient reading could be parallelized, but prediction can't be. (IDCT can also be parallelized, but that's true with just a single partition too.) I created the test image by running examples/cwebp -low_memory -partitions 3 -o foo.webp \ ~/src/serenity/Tests/LibGfx/test-inputs/4.webp using a cwebp hacked up as described in #19149. Since creating multi-partition lossy webps requires hacking up `cwebp`, they're likely very rare in practice. (But maybe other programs using the libwebp API create them.) Fixes #19149. With this, webp lossy support is complete (*) :^) And with that, webp support is complete: Lossless, lossy, lossy with alpha, animated lossless, animated lossy, animated lossy with alpha all work. (*: Loop filtering isn't implemented yet, which has a minor visual effect on the output. But it's only visible when carefully comparing a webp decoded without loop filtering to the same decoded with it. But it's technically a part of the spec that's still missing. The upsampling of UV in the YUV->RGB code is also low-quality. This produces somewhat visible banding in practice in some images (e.g. in the fire breather's face in 5.webp), so we should probably improve that at some point. Our JPG decoder has the same issue.) |
||
---|---|---|
.. | ||
AK | ||
Kernel | ||
LibAudio | ||
LibC | ||
LibCompress | ||
LibCore | ||
LibCpp | ||
LibCrypto | ||
LibEDID | ||
LibELF | ||
LibGfx | ||
LibGL | ||
LibIMAP | ||
LibJS | ||
LibLocale | ||
LibMarkdown | ||
LibPDF | ||
LibRegex | ||
LibSQL | ||
LibTest | ||
LibTextCodec | ||
LibThreading | ||
LibTimeZone | ||
LibTLS | ||
LibTTF | ||
LibUnicode | ||
LibVideo | ||
LibWasm | ||
LibWeb | ||
LibXML | ||
Spreadsheet | ||
UserspaceEmulator | ||
Utilities | ||
CMakeLists.txt |