Menu

#269 Convert creates SubfileType 0x2 instead of 0x1

v1.0_(example)
closed-fixed
None
5
2015-07-26
2014-06-11
Timothy Kim
No

As part of a project I am working on I am required to create tiled pyramidal TIFF files out of large images. In order to do this, I used GM's convert operation:

gm convert summer8x3.tif -define tiff:tile-geometry=256x256 -compress jpeg 'ptif:gm-pyr.tif'

The layers of the resulting TIFF were successfully created, but image viewers were only recognizing the topmost layer of the image.
After running some diagnostics on the image, it turns out that the subfile type tag was labeled as 0x2 (multi-page document).

I then ran the convert command through ImageMagick:

convert summer8x3.tif -define tiff:tile-geometry=256x256 -compress jpeg 'ptif:im-pyr.tif'

which successfully created a TIFF which had pyramided layers that were recognizable by image viewing software.
The Subfile type of the working image was 0x1 (reduced-resolution image).

I am no expert in image processing but I believe that GM's convert operation does not create a pyramidal image compatible with image viewing software because it specifies an incorrect subfile type.

This was also apparently a bug in ImageMagick as well but was fixed a while back :
https://github.com/openslide/openslide/issues/68

Discussion

  • Bob Friesenhahn

    Bob Friesenhahn - 2015-07-26
    • status: open --> closed-fixed
    • assigned_to: Bob Friesenhahn
     
  • Bob Friesenhahn

    Bob Friesenhahn - 2015-07-26

    It seems that this was working up until 2007. Now fixed by Mercurial changeset 14656:9cc8bb0d163b. Thanks for reporting the issue.

     

Log in to post a comment.

MongoDB Logo MongoDB