IIIF / image-validator

Validator for the Image API
http://iiif.io/api/image/validator/
Apache License 2.0
35 stars 20 forks source link

Odd behaviour with the validator test image and certain JPEG 2000 codecs #30

Open acdha opened 9 years ago

acdha commented 9 years ago

We noticed severe image corruption decoding the validator test image (http://iiif.io/api/image/validator/67352ccc-d1b0-11e1-89ae-279075081939.jp2) at certain resolutions using the Aware codec. Attempting to decode it using OpenJPEG works but throws some validation errors:

cadams@ganymede:~/Downloads $ j2k_dump -i 67352ccc-d1b0-11e1-89ae-279075081939.jp2 
[WARNING] SOT marker inconsistency in tile 0: tile-part index greater (0) than number of tile-parts (0)
[WARNING] SOT marker inconsistency in tile 0: tile-part index greater (1) than number of tile-parts (0)
[WARNING] SOT marker inconsistency in tile 0: tile-part index greater (2) than number of tile-parts (0)
[WARNING] SOT marker inconsistency in tile 0: tile-part index greater (3) than number of tile-parts (0)

I think the answer for us is simply going to be using the PNG version but it might be worth seeing whether the stock JP2 can be updated in case anyone else runs into this.

Example URL: http://tile.loc.gov/image-services/iiif/service:project1:67352ccc-d1b0-11e1-89ae-279075081939/400,500,50,50/full/0/default.jpg

Example image:

example-corrupt-50x50

acdha commented 9 years ago

The example URL above no longer fails because the image has been switched to a TIFF (http://tile.loc.gov/service/project1/67352ccc-d1b0-11e1-89ae-279075081939.tif). The screenshot is accurate.