Main Menu

Dashcam GPS

Started by epech, June 02, 2021, 09:24:00 PM

Previous topic - Next topic

epech

Hello,

I have a Kingslim D4 dashcamera, how can I get the GPS data from the video using Exiftoo?
I tried using Dashcam viewer and it didn't recognize any GPS data.
There is is a cryptic software called "GXPlayer" and that one is able to display the GPS data.

This is the output of running Exiftool on a video:


ExifTool Version Number         : 12.26
File Name                       : 2021_05_31_162035_00.MP4
Directory                       : .
File Size                       : 400 MiB
File Modification Date/Time     : 2021:05:31 16:23:34-04:00
File Access Date/Time           : 2021:06:02 21:17:12-04:00
File Creation Date/Time         : 2021:06:02 18:14:40-04:00
File Permissions                : -rw-rw-rw-
File Type                       : MP4
File Type Extension             : mp4
MIME Type                       : video/mp4
Major Brand                     : MP4 v2 [ISO 14496-14]
Minor Version                   : 0.0.0
Compatible Brands               : mp42, isom
Media Data Size                 : 417989222
Media Data Offset               : 40
Movie Header Version            : 0
Create Date                     : 2021:05:31 16:20:35
Modify Date                     : 2021:05:31 16:20:35
Time Scale                      : 120000
Duration                        : 0:02:57
Preferred Rate                  : 1
Preferred Volume                : 100.00%
Preview Time                    : 0 s
Preview Duration                : 0 s
Poster Time                     : 0 s
Selection Time                  : 0 s
Selection Duration              : 0 s
Current Time                    : 0 s
Next Track ID                   : 4
Track Header Version            : 0
Track Create Date               : 2021:05:31 16:20:35
Track Modify Date               : 2021:05:31 16:20:35
Track ID                        : 1
Track Duration                  : 0:02:57
Track Layer                     : 0
Track Volume                    : 100.00%
Image Width                     : 3840
Image Height                    : 2160
Graphics Mode                   : srcCopy
Op Color                        : 0 0 0
Compressor ID                   : avc1
Source Image Width              : 3840
Source Image Height             : 2160
X Resolution                    : 72
Y Resolution                    : 72
Compressor Name                 : .
Bit Depth                       : 24
Video Frame Rate                : 30
Balance                         : 0
Audio Format                    : mp4a
Audio Channels                  : 1
Audio Bits Per Sample           : 16
Audio Sample Rate               : 48000
Matrix Structure                : 1 0 0 0 1 0 0 0 1
Media Header Version            : 0
Media Create Date               : 2021:05:31 16:20:35
Media Modify Date               : 2021:05:31 16:20:35
Media Time Scale                : 120000
Media Duration                  : 9.00 s
Handler Class                   : Data Handler
Handler Type                    : NRT Metadata
Handler Description             : Hisilicon MetaData
Gen Media Version               : 0
Gen Flags                       : 0 0 0
Gen Graphics Mode               : srcCopy
Gen Op Color                    : 0 0 0
Gen Balance                     : 0
Meta Format                     : gpmd
Warning                         : [minor] The ExtractEmbedded option may find more tags in the media data
Thumbnail Image                 : (Binary data 33101 bytes, use -b option to extract)
Image Size                      : 3840x2160
Megapixels                      : 8.3
Avg Bitrate                     : 18.9 Mbps
Rotation                        : 0

StarGeek

To see if exiftool can find the data in the file, try
exiftool -ee -gps* 2021_05_31_162035_00.MP4

Make sure you're using an up to date version of exiftool.

It's quite possible that exiftool cannot read the GPS data. Even though exiftool can extract GPS information from over 40+ different ways that it can be embedded, every cam seems to do things differently.  If you don't get any output from the above command, a short sample video that includes movement could help the chances of getting it decoded.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Phil Harvey

Quote from: StarGeek on June 03, 2021, 12:07:10 AM
exiftool can extract GPS information from over 40+ different ways that it can be embedded

(currently 51 different formats, mentioned here)

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

epech

Hi,

Thank you for the quick response.
I ran the suggested command and I do not see any output.

exiftool -ee -gps* 2021_05_31_162035_00.MP4

I will record a file and share it later today.

StarGeek

Quote from: Phil Harvey on June 03, 2021, 06:59:54 AM
(currently 51 different formats, mentioned here)

Ah, good.  I was searching through posts trying to find the count.  Now I know where to look.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

epech

I took a couple of videos (one with H.264 and another with H.265). I uploaded them to Google Drive, I shared them with Phil Harvey (66 at gmail).
Is there anyone else I should share them with?

StarGeek

That is fine.  Phil is the one who needs to see them.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Phil Harvey

I got the videos.  The GPS is stored in a format this may be a bit tricky to figure out.  What are the approximate coordinates where the video was shot?  (you can email them to me if you don't want to post here)

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

epech

Hi Phil,

Thank you for taking the time to check them out. I emailed you the information.

I'm a SW Engineer so I could try to help decode them if you can point me in the right direction. 
How do you visualize the data?
Is the GPS typically encoded on every frame? Is it at the start/end of the frame?
Does it matter if the encoding is H264 or H265?

Thanks again!

Quote from: Phil Harvey on June 03, 2021, 01:39:07 PM
I got the videos.  The GPS is stored in a format this may be a bit tricky to figure out.  What are the approximate coordinates where the video was shot?  (you can email them to me if you don't want to post here)

- Phil

sisco21

Hello,

First great job Phil Harvey.

Did you decode the format for this dash cam?, i've got the same issue.

I've extract GPS coordinates, the path look good but points are not positioned at the good place.

Indeed, points are in SPAIN and i leave in France.

Best regards,

François


Phil Harvey

I haven't had any luck with this yet.  I'm hoping someone else can figure out how to decode this because I've already spent more time working on this than I wanted.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Phil Harvey

I've finally figured this out, and ExifTool 13.07 will be able to extract GPS from this video.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).