12
Views
7
Comments
Take picture with geo location data
Application Type
Mobile

I am going to capture an image inside my App and my system would like to collect the geo location data geo data inside the image file.

I have tried to grant location permission in my Android device and use Camera plugin to take a photo, unluckily, the photo taken doesn't consist of the geo data. 

Is there any other solution to do so?

mvp_badge
MVP
Rank: #17

Hi Carlos,

This information is stored in the EXIF meta data in the image.

Maybe you can use on of the following Forge components to extract it:

Regards,

Daniel

mvp_badge
MVP
Rank: #17

Are you using the https://www.outsystems.com/forge/component-overview/1390/camera-plugin?OutSystems R&D Camera Plugin.

It uses the following Cordova Plugin: https://github.com/OutSystems/cordova-plugin-camera#4.0.3-OS5

If you search the github page there is something mentioned about CameraUsesGeolocation  but only for iOS, so on what type of device are you testing iOS or Android?

Inspecting the iOS code you need to write the photo as JPEG not PNG if you want to have EXIF meta data in the photo.

Regards,

Daniel

mvp_badge
MVP
Rank: #17

One more thing, if you don't get it working with the existing camera plugin, consider to create a plugin using this Cordova Plugin: https://github.com/remoorejr/cordova-plugin-camera-with-exif.

Maybe I give it a try this evening and try to make the plugin for you.