http://www.perlmonks.org?node_id=1011891


in reply to Re: Use perl to extract GPS coordinates from a cell phone image.
in thread Use perl to extract GPS coordinates from a cell phone image.

Hello tobyink,

++ for a great response. I have tried using your sample script and everything works great, except I have yet to see GPS data results. I reread the CPAN docs for 'Image::ExifTool' and it references a config file and was wondering if you had defined a config file?

I'm using a LG LS670 phone camera with GPS on, as well as checking some apple camera pictures that show GPS info. (Friend sent pictures to me, so I hope the pictures actually have the GPS info embedded).

Any ideas appreciated.

Thank you...Ed

"Well done is better than well said." - Benjamin Franklin

  • Comment on Re^2: Use perl to extract GPS coordinates from a cell phone image.

Replies are listed 'Best First'.
Re^3: Use perl to extract GPS coordinates from a cell phone image.
by tobyink (Canon) on Jan 06, 2013 at 19:48 UTC

    Works out of the box for me. (HTC Explorer phone, Android 2.3.)

    You could try throwing $metadata at Data::Dumper to see what's inside...

    use Data::Dumper; print Dumper ImageInfo "MyImage.jpeg";
    perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'

      tobyink,

      Thanks for the suggestion (which I tried), but neither picture had any GPS info. I'm running Android 2.3, so I'm going to assume that the camera's aren't set up correctly.

      Thanks...Ed

      "Well done is better than well said." - Benjamin Franklin

        As you say, perhaps the configuration is defaulting to not embedding GPS data. Which is sensible enough. IIRC there was a bug existing since at least 2.3 in which GPS data could be corrupted. 2.3 is fairly old, it may be worth while investigating the possability of running a third party ROM on your phone. I've used Cyanogenmod (or derivatives) for years on 2 different handsets.

        Update: example of the bug