See the App Inventor Extensions document about how to use an App Inventor Extension.
For questions about this extension or bug reports please start a new thread in the
App Inventor community. Thank you.
For feature requests please contact me by email.
To be a sponsor of a new method already is possible starting from only 10 USD! With your contribution you will help the complete App Inventor community. Thank you.
Jan 9th, 2016: Version 1 of the Metadata Extension released for App Inventor version ai2extensions6 and Companion version 235.cdk2.
Aug 11th, 2016: Version 1a: avoid DX execution failed error: build each extension separately
This extension reads the metadata of an image file. The extension uses the Metadata Extractor library from Drew Noakes. Thank you Drew!
For supported file formats see here.
Required permissions: android.permission.READ_EXTERNAL_STORAGE, android.permission.WRITE_EXTERNAL_STORAGE
Get metadata from image file
Prefix the imageFileName with / (i.e. relative path) for an image file on the SD card.
For instance /myImage.jpg will get the metadata of file mnt/sdcard/myImage.jpg. To get the metadata of an image file uploaded as
asset packaged with an application (also works for the Companion) start
the imageFileName with // (two slashes). If imageFileName starts with file:/// you can specify a complete path to the file.
The metadata result is provided as nested list. The metadata is structured into different directories (see the highlighted directory values in the example png file).
Inside each directory there are different tags and their values. You can get the value of a specific tag using the lookup in pairs block (see also below).
In case you are not familiar with working with lists, this is a good opportunity to learn more about that...
Example Image by Tom Hall, found on Flickr. Thank you Tom!
Example Image by jch2103 found in the photools.com forum (unfortunately not available anymore) to demonstrate geolocation data. Thank you jch2103!
Developing and maintaining snippets, tutorials and extensions for App Inventor takes a lot of time.
I hope it saved some of your time. If yes, then you might consider to donate a small amount!
or donate some mBTC to Address:
1Jd8kXLHu2Vkuhi15TWHiQm4uE9AGPYxi8
Thank you! Taifun
Download TaifunMetadata extension (aix file)
Download Metadata Test (aia file)
Back to top of page ...
This work by Pura Vida Apps
is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License
with attribution (name=Pura Vida Apps and link to the source site) required.