1

Using ffmpeg examples transcoding.c. (https://github.com/FFmpeg/FFmpeg/blob/release/4.1/doc/examples/transcoding.c)

This is read by ffprobe.exe (ffprobe.exe -i test.mp4 -show_packets)

[PACKET]
codec_type=video
stream_index=0
pts=162000
pts_time=1.800000
dts=162000
dts_time=1.800000
duration=18000
duration_time=0.200000
size=238317
pos=2285176
flags=__
[/PACKET]
[PACKET]
codec_type=video
stream_index=0
pts=180000
pts_time=2.000000
dts=180000
dts_time=2.000000
duration=18000
duration_time=0.200000
size=24111
pos=2523493
flags=_D

The ​last packet flags has AV_PKT_FLAG_DISCARD.

itisyang
  • 11
  • 1
  • Why are you using version 4.1 and not 4.4? [https://github.com/FFmpeg/FFmpeg/blob/release/4.4/doc/examples/transcoding.c](https://github.com/FFmpeg/FFmpeg/blob/release/4.4/doc/examples/transcoding.c) – Rotem Dec 29 '21 at 10:11
  • I tried that. It's the same thing – itisyang Dec 30 '21 at 01:04

1 Answers1

0

An MP4 file might have an edit list and the sample happens to have a composition time outside of the edit list.

So it depends on your video file.

micha137
  • 1,195
  • 8
  • 22