Page 1 of 1

Convert TIF w/annotations to JPG

Posted: 2010-01-19T11:06:18-07:00
by kblair
I have a very large group of images that have been annotated by the Wang/Kodak (imgedit.ocx) formerly distributed with Windows. I need to convert these to jpeg files and retain the annotations. When I run convert, I get a series of warnings which I have read elseware I can ignore. However, the created jpg file does not have the annotations that were in the original.

convert 4.tif 4.jpg
convert: 4.tif: unknown field with tag 32932 (0x80a4) encountered. `TIFFReadDirectory'.
convert: 4.tif: unknown field with tag 32934 (0x80a6) encountered. `TIFFReadDirectory'.
convert: incorrect count for field "Tag 32934" (0, expecting 1); tag ignored. `4.tif'.

so, is there a way to convert these and retain the annotations?

Thanks,

Kent

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-03T13:24:03-07:00
by rvanderpoel
Hi Kent,

It's been a few years now but I was wondering whether you ever got anything working as I now need to do a similar thing, extract annotations from TIFF files or burn them into the image.

Thanks
Rob

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-03T13:28:40-07:00
by fmw42
You might be able to extract the text using EXIFTOOL and then use Imagemagick to write the text onto the image and convert to JPG

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-03T13:30:38-07:00
by rvanderpoel
Thanks, I'll look into it. Hadn't considered going the EXIF route

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-03T14:09:03-07:00
by rvanderpoel
So far I have managed to get it to extract the tag but, unfortunately, it only extracts it as binary data. I can see the text in there but no idea how to get other data such as font details and positioning.

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-03T14:19:51-07:00
by snibgo
If you post a sample, someone may take a look.

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-08T17:18:30-07:00
by rvanderpoel
Thanks for the suggestion, snibgo.

I'm new to this forum so not sure whether this will work.

Here is a link to the TIFF. I've had to redact quite a bit. TIFF with annotations

Here's a link to a screen shot of the image with the annotations in a supported viewer. The annotations are highlighted in yellow. Screenshot showing annotations

From what I've been able to find out the annotations are in an Eastman/eiStream format.

If someone can take a look that would be greatly appreciated.

Thanks
Rob

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-08T18:19:14-07:00
by snibgo
You've probably figured that ...

Code: Select all

exiftool -b -IFD0:WangAnnotation x.tiff >x.txt
... dumps the binary. This seems to be text data, readable as numbers between 0 and 255. I suppose "Bottom Left" would be here as "66 111 116 116 111 109 32 76 101 102 116".

It would take more work (and examples) to work out what the other numbers mean.

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-10T21:47:31-07:00
by rvanderpoel
That's pretty much where I got to. I was hoping that ImageMagick might have some capability to read this stuff and then burn it back in as part of the image but doesn't sound like it and I'll need to look into other options.

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-10T22:18:49-07:00
by snibgo
IM does not contain code that will read these annotations. http://web.archive.org/web/200503091413 ... nospec.htm might be the specification for the data.

I see that the format was already considered old and dead in 2006.

Re: Convert TIF w/annotations to JPG

Posted: 2015-11-11T20:30:20-07:00
by rvanderpoel
Looks like I'll have to build my own utility to get them out and then I can use IM to burn them in. Many thanks for looking into this for me.

Cheers
Rob