[FFmpeg-user] Cutting on video frame

Christian Ebert blacktrash at gmx.net
Thu Jul 7 20:03:08 EEST 2016


* Louis Letourneau on Thursday, July 07, 2016 at 12:38:26 -0400
> When cutting a video, even when transcoding, I often have a small delay
> between the video and audio.
> 
> When looking at the video with either vlc or ffplay, I see the first frame
> shown twice.(The first is probably a dup until it the real pts is hit).
> 
> I was wondering if there is a way to force cutting on video frame
> boundaries to avoid this.
> 
> Also when using -ss to cut exactly to the video frame closest to where I
> want to cut. I still often get audio packets and frames with negative pts.

You may be interested in this:
https://trac.ffmpeg.org/ticket/3859

Basically there's always some aac padding. I usually resort to
the atrim filter to butcher that off at the beginning, and
sometimes other nasty stuff.

> If It then convert this video from mp4 -> hls, the negative frames are now
> positive and my video frame is push forward again.

Yeah, the behavior of the hls or other segment muxers doesn't
make things easier.

-- 
  Was heißt hier Dogma, ich bin Underdogma!
[ What the hell do you mean dogma, I am underdogma. ]
free movies       --->>> http://www.blacktrash.org/underdogma
http://itunes.apple.com/podcast/underdogma-movies/id363423596


More information about the ffmpeg-user mailing list