Blitline can return and set various different types of metadata about images. Blitline can read/write EXIF as well as IPTC, and even return image file information such as filesize, density, etc.
You can even choose to get information about a file that Blitline hasn’t downloaded yet.
In essence, we can ‘peek’ at a url and get the image information about it without downloading and processing the entire file.
By default, files output by Blitline are optimized for size, so they will have all metadata (EXIF, IPTC, Color Profiles, etc.) stripped from them. (You can override this by setting “save_metadata” to true. *
You can have Blitline return information about an image by setting:
"get_exif" : true
So, for example:
Will return something like:
You can set EXIF/IPTC metadata by using set_exif in the “save” node:
This will export metadata INTO the output file.
While the above setting will read/export metadata, by default Blitline strips out metadata when saving a file. So, if you are interested in metadata, it is often desirable to add:
"save_metadata" : true
…to your JSON, otherwise outputted images won’t have any EXIF data except for any you might have explicitly set (as in the example above).
So a more comprehensive example would be:
‘PEEKING’ AT METADATA
Sometimes, you might want to know metadata information about a file without having to download and process the whole file. Blitline can “peek” at an image and get information about it without having to download the whole file.
This behaves like a regular job, but the JSON that is returned contains all the exif/iptc data in the original_metadata node. So the postback/poll for this job would return:
This is particularly helpful for PDF files, where their page count is unknown. Downloading or processing a 1000 page PDF file would be very costly just to get exif information about it.