Closed hep-canoy closed 9 months ago
I am just curious why tiff derived from pdf lacks these important metadata.
Can't really offer much help without evaluating source files, but I would guess this behavior comes down to the nuances of tagging. Possible some EXIF data needs to be re-keyed as TIFF standard tagging. See this chart.
However Wand & ImageMagick doesn't really edit metatags. You can use Image.profile
to dump & load raw data streams. A possible solution might be as simple as reading a PDF, export EXIF / XMP, modify payload, import EXIF / XMP, and write file.
Just to give an update, it's the problem with metadata format mapping, not with wand. The Standard Metadata Format does not able to detect the metadata we need which is the HorizontalReoslution, in which we solved it by adding another layer to that that will use TIFF Native Image Metadata Format if it cannot find the metadata using the Standard Metadata Format.
I am using Wand on my microservice called File Converter. On pdf to tiff converter, the tiff created does not contain HorizontalPixelSize (and other metadata) which is needed by another application which is a tiff viewer.
Upon checking the metadata when converting tiff to tiff (adjusting dpi) these are the metadata present
When doing pdf to tiff, these are the only metadata present
We need HorizontalPixelSize metadata since we store the resolution of the tiff file in our database.
I am just curious why tiff derived from pdf lacks these important metadata.