Ability to load geolocation from metadata
When uploading a video from gallery, it would be nice to check metadata to see if there's location info, and load this by default.
Hello @KyleKun I would really like this, can you give me some guidelines into how to start tackling this?
Also, it seems old OSD videos of mine (2023) had location metadata, but recent ones don't. How that was possible before?
Hey @arcstur , we are adding location metadata in the code already if geotagging is enabled, here's the relevant code snippet for searching:
String locationMetadata = '';
if (isGeotaggingEnabled) {
final latitude = Utils.locationPositionToString(widget.userPosition?.latitude);
final longitude = Utils.locationPositionToString(widget.userPosition?.longitude);
final localeName = widget.userLocation?.replaceAll('"', '\\"');
locationMetadata = ' -metadata location="$latitude$longitude/$localeName"';
}
But if we add the video from gallery, we will likely need to implement the checking with ffprobe so we can grab its value, similar to how we check streams:
await executeFFprobe('-v quiet -print_format json -show_format -show_streams "$currentVideo"')
Would it be possible to add the location metadata without geotagging text? I usually keep geotagging off because I don't like to add another text in the video, but I would like the metadata.
Would it be possible to add the location metadata without geotagging text? I usually keep geotagging off because I don't like to add another text in the video, but I would like the metadata.
Yes, we can make an option in settings for this no problem