Open tomkyle opened 7 years ago
When running with dcraw_emu, mogrify will complain:
mogrify: ASCII value for tag "ImageDescription" contains null byte in value; value incorrectly truncated during reading due to implementation limitations. `TIFFFetchNormalTag' @ warning/tiff.c/TIFFWarnings/925.
mogrify: ASCII value for tag "Make" contains null byte in value; value incorrectly truncated during reading due to implementation limitations. `TIFFFetchNormalTag' @ warning/tiff.c/TIFFWarnings/925.
mogrify: ASCII value for tag "Model" contains null byte in value; value incorrectly truncated during reading due to implementation limitations. `TIFFFetchNormalTag' @ warning/tiff.c/TIFFWarnings/925.
mogrify: ASCII value for tag "Software" contains null byte in value; value incorrectly truncated during reading due to implementation limitations. `TIFFFetchNormalTag' @ warning/tiff.c/TIFFWarnings/925.
mogrify: ASCII value for tag "Artist" contains null byte in value; value incorrectly truncated during reading due to implementation limitations. `TIFFFetchNormalTag' @ warning/tiff.c/TIFFWarnings/925.
It seems, setting the meta data entries to empty string can fix this:
exiftool -overwrite_original \
-mwg:Description="" \
-mwg:Creator="" \
-make="" \
-model="" \
-software="" \
"${output_tiff}" > /dev/null
Solution currently looks like this: try to copy missing meta data from existing tags
declare -a exiftool_fix_missing_metadata=(
"-mwg:Description="""
"-mwg:Creator="""
"-Artist<mwg:Creator"
"-Make<exif:Make"
"-Model<exif:model"
"-Software<exif:software"
)
exiftool -overwrite_original -quiet "${exiftool_fix_missing_metadata[@]}" "${output_tiff}"
Just saw it seems libraw's _dcrawemu command is about one third faster than dcraw. Should one try?