forked from SerenityOS/serenity
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
LibGfx/JPEG2000: Support [8..16] bits per pixel
Do this by making decode_code_block() write to a float buffer, instead of an i16 buffer. Alternatively, we could make decode_code_block() stop after some number of bits since we only need 8 anyways and update a few places in JPEG2000.cpp that currently read bit_depth(), but this here seems perf-neutral (even slightly positive) and is simpler, so let's go with this for now. (16 bpp images are very rare, and I haven't seen images with more than 16 bpp, even though the spec allows up to 38 bpp.)
- Loading branch information
Showing
3 changed files
with
17 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters