ExifTool Forum

ExifTool => Developers => Topic started by: herb on February 05, 2019, 08:03:43 AM

Title: Question to -api Filter=
Post by: herb on February 05, 2019, 08:03:43 AM
Hello Phil,

I work with Exiftool 11.26 on a Win 7 system.

In order to get also multiline output I use a filter function -api Filter=ReplaceNL($_) that changes binary data like line-feed or carriage-return to printable characters "\n" and "\r" and it also escapes "\" with "\\".
(Many thanks again to you and also StarGeek to find this solution).

As far as I know this filter is applied to all tag-values.
My question is: Is it possible that such a filter is NOT applied to binary data like ThumbnailImage (and maybe some others), because using the filter e.g. the length of a thumbnail changes:
from -- Thumbnail Image: (Binary data 7077 bytes, use -b option to extract)
to     -- Thumbnail Image: (Binary data 7139 bytes, use -b option to extract)

Best regards
Herb
Title: Re: Question to -api Filter=
Post by: Phil Harvey on February 08, 2019, 01:07:06 PM
Hi Herb,

Currently the filter is applied to all print-converted values.  You can disable print conversion on individual tags by adding '#' to the tag name.  But this could be problematic if you are requesting all tags.

- Phil