Skip to content

Commit

Permalink
cfFilterImageToRaster(): Add 16-bit-per-color output support
Browse files Browse the repository at this point in the history
If 16-bit-per-color output is requested by printer and job attributes, the output image always gets completely blank as this output color depth is simply not supported by cfFilterImageToRaster().

To fix this we derive the appropriate code simply from the 8-bit-per-color output code by sending each byte twice. This gives, independent of Endian, 16-bit numbers which have more or less the same percentage of the maximum value as the original 8-bit numbers have, giving the same image color impression as the original.

16-bit-per-color image input is not supported as the current library functions do not support it.

This way we do not gain better output image quality but we assure that any requested output color space and depth gives useful output.
  • Loading branch information
Harshit09-lang committed Apr 8, 2023
1 parent b6c7ace commit c83bead
Showing 1 changed file with 593 additions and 4 deletions.

0 comments on commit c83bead

Please sign in to comment.