[FFmpeg-user] Audio sync issues when transcoding Hauppauge HDPVR content

Scott Naef snaef1 at mail.brookdalecc.edu
Tue Jan 15 20:30:17 CET 2013

I am attempting to transcode recordings made with an HDPVR.  I am using 
Mythtv to do the capture.   I originally had trouble with playback in 
Myth but was able to use the environment variable 
FORCE_DTS_TIMESTAMPS=1  to get proper playback in Myth.   I am an 
absolute newbie when it comes to the finer details of the workings of 
these various media packages.   I have read several places that the 
HDPVR produces broken PTS timestamps.    However, if there is a workable 
solution to playback content in Myth, I am hoping there is a workable 
solution to do transcoding with FFMPEG.

I have tried several options in FFMPEG such as  -async 1 but nothing I 
try seems to work.  I always end  up with about 1.5 second delay in 
video from audio.    From what I understand DTS timestamps are used to 
decode content and offer a deterministic way to predict the number of 
frames to decode and PTS timestamps are used to show the correct frames 
in the correct order.   If this is true (long shot!) then I guess I need 
a way to mux the audio and video streams using DTS not PTS.   Is this 
way the Myth player does it?


ffmpeg version git-2013-01-05-7e5d4fa Copyright (c) 2000-2013 the FFmpeg 
   built on Jan  5 2013 17:29:28 with gcc 4.6 (Ubuntu/Linaro 4.6.3-1ubuntu5)
   configuration: --enable-gpl --enable-libass --enable-libfaac 
--enable-libfdk-aac --enable-libmp3lame --enable-libopencore-amrnb 
--enable-libopencore-amrwb --enable-librtmp --enable-libtheora 
--enable-libvorbis --enable-libvpx --enable-x11grab --enable-libx264 
--enable-nonfree --enable-version3
   libavutil      52. 13.100 / 52. 13.100
   libavcodec     54. 85.101 / 54. 85.101
   libavformat    54. 59.104 / 54. 59.104
   libavdevice    54.  3.102 / 54.  3.102
   libavfilter     3. 32.100 /  3. 32.100
   libswscale      2.  1.103 /  2.  1.103
   libswresample   0. 17.102 /  0. 17.102
   libpostproc    52.  2.100 / 52.  2.100

Any help would be greatly appreciated.  If needed I can grab a few 
seconds of a news clip (talking heads help to see this) and offer it up 

Thank you!
-Scott Naef

More information about the ffmpeg-user mailing list