﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc	mlocked
11328	HD-PVR recordings can have a long initial sequence with no keyframes, confusing ffmpeg	mythwiki@…	jpoet	"I'm speculating a bit about the cause of the problem, but it seems likely to be due to a recording having a long time before the first keyframe is encountered.  The HD-PVR issues a keyframe every 3 or 4 seconds.  On some, but not all recordings, ffmpeg has difficulty reading the file.  This manifests itself in two ways:
- ffprobe returns nonsensical bitrates, causing it to believe that the recording is about 1/4 the true length, which leads to problems with scripts that use ffprobe to determine the total length of a recording
- ffmpeg decides that the file doesn't contain pts values, so it makes up its own.  However, when ffmpeg creates its own pts for output, it starts at a time of 1.0 seconds, rather than the 0.0 seconds that the HD-PVR produces in its pts values.  For scripts that need precise control over time, this leads to an uncertainty of 1 second in the position of frames.

I suspect these problems would go away if the HD-PVR recording loop discarded frames before the first keyframe.  I don't know if this is a practical solution, but it might be helpful to try."	Bug Report - General	closed	minor	0.27	MythTV - Recording	Master Head	low	fixed	hd-pvr, ffmpeg, scripts		0
