Oh that's a delight

This commit is contained in:
Reid 'arrdem' McKenzie 2021-09-07 01:00:37 -06:00
parent 714d11da01
commit 80e908e7f9

View file

@ -592,6 +592,11 @@ def img_info(p: Path) -> ImgInfo:
# 944404
subsec = int(get_tag("EXIF SubSecTime") or get_tag("EXIF SubSecTimeOriginal") or get_tag("EXIF SubSecTimeDigitized") or "0")
# GoPro burst format is G%f.JPG or something close to it
if subsec == 0 and (m := re.match("g.*(\d{6}).jpe?g", p.name.lower())):
subsec = int(m.group(1))
date = date.replace(microsecond=subsec)
return ImgInfo(