jimp-dev/jimp

16 bit tiff does not convert properly

Open

#806 建立於 2019年10月19日

在 GitHub 查看
 (3 留言) (1 反應) (0 負責人)JavaScript (13,218 star) (785 fork)batch import
bughelp wanted

描述

Expected Behavior

one to one conversion from 16 bit tiff to (presumably) 8 bit jpg

Current Behavior

Images that look like this:

image

this is supposed to be an X-Rite color passport, a piece of equipment for color calibration, on a poorly lit but supposedly white background:

image

Failure Information (for bugs)

It seems like the 16 bit tiff data is getting processed as 8 bit data, I don't know if it's throwing away the top byte in each two-byte pair, or whether it's pretending a single 16 bit value is actually two consecutive single byte values, but it's definitely very wrong.

Steps to Reproduce

  1. Generate a 16 bit TIFF image in any random image editor (photoshop, gimp, what have you)
  2. Make Jimp convert it to jpeg (either with write or getBuffer etc)

Context

This might be an example of #664

  • Jimp Version: 0.8.5
  • Operating System: Win10 x64
  • Node version: 12

貢獻者指南