[FFmpeg-trac] #9390(undetermined:new): Wrong FPS used for timecode computation mangles timecodes
FFmpeg
trac at avcodec.org
Sat Aug 28 00:53:26 EEST 2021
#9390: Wrong FPS used for timecode computation mangles timecodes
-------------------------------------+-------------------------------------
Reporter: Marcelo | Owner: (none)
Magnasco |
Type: defect | Status: new
Priority: normal | Component:
| undetermined
Version: unspecified | Resolution:
Keywords: timecode | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Old description:
> Summary of the bug:
> ffprobe reports the wrong timecode for footage generated by my GoPro 9
> Black cameras. The error is due to ffprobe/ffmpeg mangling the frame rate
> from 29.97 or 59.94 to 29/1 or 59/1.
>
> For example, footage with start timecode 10:59:47:14, 29.97fps, is
> reported by ffprobe as having start timecode 11:22:32:16, which is equal
> to (10:59:47:14)*30/29.
>
> How to reproduce:
> {{{
> % ffprobe GP001.MP4
> where GP001.MP4 is a 29.97fps clip from a GoPro, includes in its output a
> black-backgrounded line
> [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7ffb6b80ac00] Using non-standard frame rate
> 29/1
>
> The incorrect framerate 29 is used to convert the timecode from frames-
> since-midnight to HH:MM:SS:FF format.
>
> ffmpeg version 4.2.1-tessus
> built with Apple LLVM version 10.0.1 (clang-1001.0.46.4)
>
> }}}
> Patches should be submitted to the ffmpeg-devel mailing list and not this
> bug tracker.
New description:
Summary of the bug:
ffprobe reports the wrong timecode for footage generated by my GoPro 9
Black cameras. The error is due to ffprobe/ffmpeg mangling the frame rate
from 29.97 or 59.94 to 29/1 or 59/1.
For example, footage with start timecode 10:59:47:14, 29.97fps, is
reported by ffprobe as having start timecode 11:22:32:16, which is equal
to (10:59:47:14)*30/29.
How to reproduce:
{{{
% ffprobe GP001.MP4
where GP001.MP4 is a 29.97fps clip from a GoPro, includes in its output a
black-backgrounded line
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x7ffb6b80ac00] Using non-standard frame rate
29/1
The incorrect framerate 29 is used to convert the timecode from frames-
since-midnight to HH:MM:SS:FF format.
PLEASE SEE THE ATTACHED FILE AND NOTE
ffmpeg version 4.2.1-tessus
built with Apple LLVM version 10.0.1 (clang-1001.0.46.4)
}}}
Patches should be submitted to the ffmpeg-devel mailing list and not this
bug tracker.
--
Comment (by Marcelo Magnasco):
NOTE: the 2MB file size limit prevented me from attaching most of the
files in the set. I was only able to attach file C5GL010008.mp4 . I can
submit all five files in the testing set through a different channel of
your choice (i.e. dropbox link).
I made three clips (plus two LRV previews) with a GoPro Hero9 Black
camera, pointing at a timeslate running on my desktop. The camera's clock
is synced to my phone not to the slate so it's about one sec off from the
25fps timecode (which should be correct time of day).
GoPro cameras list all their FPSs as 60/120/240 but they are in fact NTSC
59.94... etc.
C5GX010007.MP4 1080p/240fps
C5GH010008.MP4 1080p/120fps
C5GL010008.mp4 480p/60fps preview of 008
C5GH010009.MP4 1080p/60fps
C5GL010009.mp4 480p/60fps preview of 009
Timecode of first frame in movie and timecode displayed on slate on first
frame nondrop/30, vs. timecode reported by ffprobe
@@@@@@@@@ |. 1st frame. | on slate. |.
ffprobe
C5GX010007.MP4 | 08:54:16:144 | 08:54:17:13 | 08:56:30:113
C5GH010008.MP4 | 08:55:05:017 | 08:55:05:27 | 08:59:34:81
C5GL010008.mp4 | 08:55:04:53 | 08:55:05:27 | 09:04:09:02
C5GH010009.MP4 | 08:55:50:00 | 08:55:51:04 | 09:04:54:54
C5GL010009.mp4 |08:55:50:00 | 08:55:51:04 | 09:04:54:54
Please note these are not small errors, ffprobe is off by many minutes,
the more the slower the sampling rate.
You can compute easily that in the case of the file attached, the timecode
reported by ffprobe, 09:04:09:02, equals (60/59)*08:55:04:53
--
Ticket URL: <https://trac.ffmpeg.org/ticket/9390#comment:2>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list