bigflood / dartexif

Dart package to decode Exif data from tiff, jpeg and heic files
https://pub.dev/packages/exif
MIT License
30 stars 29 forks source link

there is no any gps information #9

Closed winsonet closed 3 years ago

winsonet commented 4 years ago

I try to get the GPS information from the image but it seems can't find anythings, what's the key should I take for get the lat/lng info?

thanks!

dekoding commented 4 years ago

Same here, and it seems to be specific to iOS. I get GPS information fine on Android:

Information on the iOS simulator:

[log] Image Orientation (Short): Horizontal (normal)
[log] Image ExifOffset (Long): 38
[log] EXIF ExifImageWidth (Long): 4032
[log] EXIF ExifImageLength (Long): 3024

Information on Android for the same image:

[log] Image DateTime (ASCII): 2017:08:21 09:33:37
[log] GPS GPSDOP (Ratio): 19
[log] GPS GPSVersionID (Byte): [2, 2, 0, 0]
[log] GPS GPSDate (ASCII): 2017:08:21
[log] GPS GPSAltitudeRef (Byte): 0
[log] GPS GPSLongitudeRef (ASCII): W
[log] GPS GPSLongitude (Ratio): [122, 16, 4403/100]
[log] GPS GPSProcessingMethod (Undefined): [65, 83, 67, 73, 73, 0, 0, 0, 102, 117, 115, 101, 100]
[log] GPS GPSLatitudeRef (ASCII): N
[log] GPS GPSTimeStamp (Ratio): [16, 33, 37]
[log] GPS GPSAltitude (Ratio): 1065
[log] GPS GPSLatitude (Ratio): [44, 36, 367/20]
[log] Image GPSInfo (Long): 19881
[log] Image Model (ASCII): Pixel XL
[log] Image ImageWidth (Short): 4048
[log] Image ResolutionUnit (Short): Pixels/Inch
[log] Image YCbCrPositioning (Short): Centered
[log] Image ImageLength (Short): 3036
[log] Image YResolution (Ratio): 72
[log] Image Orientation (Short): Horizontal (normal)
[log] Image Software (ASCII): HDR+ 1.0.163413028z
[log] Image ExifOffset (Long): 242
[log] Image XResolution (Ratio): 72
[log] Image Make (ASCII): Google
[log] Thumbnail ImageWidth (Short): 253
[log] Thumbnail ResolutionUnit (Short): Pixels/Inch
[log] Thumbnail ImageLength (Short): 189
[log] Thumbnail YResolution (Ratio): 72
[log] Thumbnail Orientation (Short): Horizontal (normal)
[log] Thumbnail JPEGInterchangeFormatLength (Long): 11254
[log] Thumbnail JPEGInterchangeFormat (Long): 20261
[log] Thumbnail Compression (Short): JPEG (old-style)
[log] Thumbnail XResolution (Ratio): 72
[log] EXIF ColorSpace (Short): sRGB
[log] EXIF FNumber (Ratio): 2
[log] EXIF DateTimeDigitized (ASCII): 2017:08:21 09:33:37
[log] EXIF SubjectDistanceRange (Short): 1
[log] EXIF FocalLength (Ratio): 467/100
[log] EXIF ApertureValue (Ratio): 2
[log] EXIF ExposureMode (Short): Auto Exposure
[log] EXIF SubSecTimeDigitized (ASCII): 257156
[log] EXIF ExifImageLength (Short): 3036
[log] EXIF CustomRendered (Short): Custom
[log] EXIF MaxApertureValue (Ratio): 2
[log] EXIF SceneCaptureType (Short): Standard
[log] EXIF SceneType (Undefined): Directly Photographed
[log] EXIF SubSecTimeOriginal (ASCII): 257156
[log] EXIF Saturation (Short): Normal
[log] EXIF ExposureProgram (Short): Program Normal
[log] EXIF Sharpness (Short): Normal
[log] EXIF WhiteBalance (Short): Auto
[log] EXIF ExifImageWidth (Short): 4048
[log] EXIF ShutterSpeedValue (Signed Ratio): 232/25
[log] EXIF SubSecTime (ASCII): 257156
[log] EXIF MeteringMode (Short): CenterWeightedAverage
[log] EXIF DateTimeOriginal (ASCII): 2017:08:21 09:33:37
[log] EXIF ComponentsConfiguration (Undefined): YCbCr
[log] EXIF SubjectDistance (Ratio): 673/1000
[log] EXIF ExifVersion (Undefined): 0220
[log] EXIF Flash (Short): Flash did not fire, compulsory flash mode
[log] EXIF Contrast (Short): Normal
[log] Interoperability InteroperabilityIndex (ASCII): R98
[log] Interoperability InteroperabilityVersion (Undefined): [48, 49, 48, 48]
[log] EXIF InteroperabilityOffset (Long): 19851
[log] EXIF ExposureBiasValue (Signed Ratio): 0
[log] EXIF BrightnessValue (Signed Ratio): 182/25
[log] EXIF ISOSpeedRatings (Short): 50
[log] EXIF FlashPixVersion (Undefined): 0100
[log] EXIF SensingMethod (Short): One-chip color area
[log] EXIF MakerNote (Undefined): [72, 68, 82, 80, 2, 239, 100, 53, 109, 94, 112, 30, 44, 234, 227, 76, 87, 100, 168, 80, ... ]
[log] EXIF ExposureTime (Ratio): 403/250000
[log] JPEGThumbnail (Proprietary):
pooja96km commented 3 years ago

Has anyone found the solution?

ludoo0d0a commented 3 years ago

Same here, GPSlatitude and GPSLongitude are marked as [0,0,0,0]

I tried with these samples : https://github.com/ianare/exif-samples/tree/master/jpg/gps

ludoo0d0a commented 3 years ago

I investigated, retried, read doc, compared with other exif parser and it's ok now for these images. May be I mixed images with no gps data in my tests, not clear...

You can close this issue for me. thanks

ludoo0d0a commented 3 years ago

FYI: I found again the issue around GPS with 0 values. it was only on an emulator with Android S. only data relevant to gps section were nullified. (strange behavior) Tested with another one with Android R : it is ok unit tests are ok.

bigflood commented 3 years ago

@ludoo0d0a thanks