[FFmpeg-user] (mpeg2) how to set "audio delay relative to video" as 0 ?

Stefano Sabatini stefasab at gmail.com
Wed Sep 17 14:10:45 CEST 2014


On date Wednesday 2014-09-17 19:44:02 +0800, linxs wrote:
> Hi everybody,
> I transcode other video to mpg2 video as following command:
> ffmpeg -i <other video> -c:v mpeg2video -b:v 8000k -c:a mp2 -y 0.mpg
> 
> /****************************************************************************************************
> /****************************************************************************************************
> d:\>ffmpeg -i orig.mpg -c:v mpeg2video -c:a mp2 -y 0.mpg
> ffmpeg version N-63439-g96470ca Copyright (c) 2000-2014 the FFmpeg
> developers
[...]
> I use MediaInfo.exe to view the ouput mpg, and get the result:
> 
> /****************************************************************************************************
> /****************************************************************************************************
> General
> Complete name                            :
> D:\1.project\1.HDPlayer\audiolevel\FM_MIRROR\loop\0.mpg
> Format                                   : MPEG-PS
> File size                                : 1.70 MiB
> Duration                                 : 15s 24ms
> Overall bit rate mode                    : Variable
> Overall bit rate                         : 951 Kbps
> 
> Video
> ID                                       : 224 (0xE0)
> Format                                   : MPEG Video
> Format version                           : Version 2
> Format profile                           : Main at Main
> Format settings, BVOP                    : No
> Format settings, Matrix                  : Default
> Format settings, GOP                     : Variable
> Duration                                 : 14s 960ms
> Bit rate mode                            : Variable
> Bit rate                                 : 548 Kbps
> Width                                    : 720 pixels
> Height                                   : 576 pixels
> Display aspect ratio                     : 4:3
> Frame rate                               : 25.000 fps
> Standard                                 : PAL
> Color space                              : YUV
> Chroma subsampling                       : 4:2:0
> Bit depth                                : 8 bits
> Scan type                                : Progressive
> Compression mode                         : Lossy
> Bits/(Pixel*Frame)                       : 0.053
> Time code of first frame                 : 00:00:00:00
> Time code source                         : Group of pictures header
> Stream size                              : 1 001 KiB (57%)
> 
> Audio
> ID                                       : 192 (0xC0)
> Format                                   : MPEG Audio
> Format version                           : Version 1
> Format profile                           : Layer 2
> Duration                                 : 15s 24ms
> Bit rate mode                            : Constant
> Bit rate                                 : 384 Kbps
> Channel(s)                               : 2 channels
> Sampling rate                            : 48.0 KHz
> Compression mode                         : Lossy
> Delay relative to video                  : -10ms
> 
> >>>>>>>>>  !!!!!!! how to make this "delay relative to video" value to
> 0ms?

What values do you get with ffprobe? Did you try with the asetpts
filter? This will require audio transcoding though.


More information about the ffmpeg-user mailing list