[FFmpeg-trac] #8590(avfilter:new): 'telecine=pattern' error for p24, soft telecined sources
FFmpeg
trac at avcodec.org
Tue Mar 31 10:57:32 EEST 2020
#8590: 'telecine=pattern' error for p24, soft telecined sources
-------------------------------------+-------------------------------------
Reporter: markfilipak | Type: defect
Status: new | Priority: normal
Component: avfilter | Version:
| unspecified
Keywords: | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Scenario:
I transcode p24 sources to p60 targets via a 5-5-5-5 pull-down in order to
virtually eliminate the telecine judder associated with 2-3-2-3 pull-down.
This telecine strategy works wonderfully for progressive p24 sources (Blu-
ray) but fails for soft-telecined p24 sources (DVD).
Bug Summary:
ffmpeg -i IN.VOB -vf "telecine=pattern=5555,bwdif=mode=send_frame" OUT.MKV
where IN.VOB is any soft telecined, p24 MPEG-2 DVD source,
results in an OUT.MKV @ 75/1.001 FPS instead of @ 60/1.001 FPS, and also a
plethora of PTS errors.
It appears that the 'telecine' filter is disregarding the metadata [1]
that clearly shows soft-telecining and instead is honoring
'frame_rate_code' (which is bogus for soft-telecined streams) found in the
MPEG sequence header.
I suspect 'frame_rate_code' because this line:
ffmpeg -i IN.M2TS -vf "telecine=pattern=5555,bwdif=mode=send_frame"
OUT.MKV
works as expected and, to my knowledge, 'frame_rate_code' is the only
difference between a progressive p24 source (frame_rate_code=0001, i.e.,
24/1.001 FPS) and a soft-telecined p24 source (frame_rate_code=0100, i.e.,
30/1.001 FPS).
[1]
frames.frame.0.interlaced_frame=0
frames.frame.0.top_field_first=1
frames.frame.0.repeat_pict=0
frames.frame.1.interlaced_frame=0
frames.frame.1.top_field_first=1
frames.frame.1.repeat_pict=1
frames.frame.2.interlaced_frame=0
frames.frame.2.top_field_first=0
frames.frame.2.repeat_pict=0
frames.frame.3.interlaced_frame=0
frames.frame.3.top_field_first=0
frames.frame.3.repeat_pict=1
Problem Statement:
Except for the audio, the resulting OUT.MKV plays fast.
Repeatability:
Always for soft telecined sources.
Files Effected:
Any unencrypted VOB for a soft telecined movie.
ffmpeg -report -i IN.VOB -vf "telecine=pattern=5555,bwdif=mode=send_frame"
OUT.MKV
ffmpeg started on 2020-03-31 at 02:56:03
Report written to "ffmpeg-20200331-025603.log"
ffmpeg version N-94664-g0821bc4eee Copyright (c) 2000-2019 the FFmpeg
developers
built with gcc 9.1.1 (GCC) 20190807
configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-
fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-
libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame
--enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
--enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr
--enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack
--enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2
--enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-
libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa
--enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx
--enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-
nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt
libavutil 56. 33.100 / 56. 33.100
libavcodec 58. 55.101 / 58. 55.101
libavformat 58. 31.104 / 58. 31.104
libavdevice 58. 9.100 / 58. 9.100
libavfilter 7. 58.101 / 7. 58.101
libswscale 5. 6.100 / 5. 6.100
libswresample 3. 6.100 / 3. 6.100
libpostproc 55. 6.100 / 55. 6.100
Input #0, mpeg, from 'IN.VOB':
Duration: 00:22:07.55, start: 0.066633, bitrate: 6470 kb/s
Stream #0:0[0x1bf]: Data: dvd_nav_packet
Stream #0:1[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 32:27 DAR 16:9], 29.97 fps, 59.94 tbr, 90k tbn,
59.94 tbc
Stream #0:2[0x83]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
Stream #0:3[0x82]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
Stream #0:4[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
Stream #0:5[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
Stream mapping:
Stream #0:1 -> #0:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:2 -> #0:1 (ac3 (native) -> vorbis (libvorbis))
Press [q] to stop, [?] for help
[Parsed_telecine_0 @ 0000020fdbc1a800] Telecine pattern 5555 yields up to
3 frames per frame, pts advance factor: 8/20
[libx264 @ 0000020fdbdabc80] using SAR=32/27
[libx264 @ 0000020fdbdabc80] using cpu capabilities: MMX2 SSE2Fast SSSE3
SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 0000020fdbdabc80] profile High, level 3.1, 4:2:0, 8-bit
[libx264 @ 0000020fdbdabc80] 264 - core 158 r2984 3759fcb - H.264/MPEG-4
AVC codec - Copyleft 2003-2019 - http://www.videolan.org/x264.html -
options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7
psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1
8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=12
lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0
bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1
b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25
scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0
qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, matroska, to 'OUT.MKV':
Metadata:
encoder : Lavf58.31.104
Stream #0:0: Video: h264 (libx264) (H264 / 0x34363248),
yuv420p(progressive), 720x480 [SAR 32:27 DAR 16:9], q=-1--1, 74.93 fps, 1k
tbn, 74.93 tbc
Metadata:
encoder : Lavc58.55.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay:
18446744073709551615
Stream #0:1: Audio: vorbis (libvorbis) (oV[0][0] / 0x566F), 48000 Hz,
5.1(side), fltp
Metadata:
encoder : Lavc58.55.101 libvorbis
[mpeg @ 0000020fdb73a000] New subtitle stream 0:6 at pos:4487182 and
DTS:6.106s/s speed=2.35x
[mpeg @ 0000020fdb73a000] New subtitle stream 0:7 at pos:4489230 and
DTS:6.106s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:8 at pos:55965710 and
DTS:71.4713sspeed=1.25x
[mpeg @ 0000020fdb73a000] New subtitle stream 0:9 at pos:55967758 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:10 at pos:55969806 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:11 at pos:55971854 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:12 at pos:55982094 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:13 at pos:55984142 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:14 at pos:55986190 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:15 at pos:55988238 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:16 at pos:55990286 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:17 at pos:55992334 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:18 at pos:55994382 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:19 at pos:55996430 and
DTS:71.4713s
[mpeg @ 0000020fdb73a000] New subtitle stream 0:20 at pos:60086286 and
DTS:77.0102speed=1.23x
[mpeg @ 0000020fdb73a000] New subtitle stream 0:21 at pos:60088334 and
DTS:77.0102s
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp=
661.1kbits/s speed=1.12x
Last message repeated 10 times
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp=
669.3kbits/s speed=1.12x
Last message repeated 13 times
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp=
668.6kbits/s speed=1.13x
Last message repeated 9 times
:::::::::::::::::::::::::::::::::::::::::
:: ::
:: Repeated several thousand times ::
:: ::
:::::::::::::::::::::::::::::::::::::::::
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp=
785.3kbits/s speed=1.17x
Last message repeated 5 times
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp=
785.3kbits/s speed=1.17x
Last message repeated 7 times
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp=
785.3kbits/s speed=1.17x
Last message repeated 10 times
[mpeg2video @ 0000020fdbdad340] ac-tex damaged at 16 17
[mpeg2video @ 0000020fdbdad340] Warning MVs not available
[mpeg2video @ 0000020fdbdad340] concealing 585 DC, 585 AC, 585 MV errors
in B frame
IN.VOB: corrupt decoded frame in stream 1
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp
[ac3 @ 0000020fdbdac580] incomplete frame
IN.VOB: corrupt decoded frame in stream 2
[matroska @ 0000020fdbc22940] Starting new cluster due to timestamp
frame=79575 fps= 70 q=-1.0 Lsize= 127629kB time=00:22:07.54 bitrate=
787.6kbits/s speed=1.17x
video:88135kB audio:37691kB subtitle:0kB other streams:0kB global
headers:7kB muxing overhead: 1.433324%
[libx264 @ 0000020fdbdabc80] frame I:567 Avg QP:20.88 size: 18473
[libx264 @ 0000020fdbdabc80] frame P:24105 Avg QP:24.91 size: 2497
[libx264 @ 0000020fdbdabc80] frame B:54903 Avg QP:24.65 size: 357
[libx264 @ 0000020fdbdabc80] consecutive B-frames: 1.2% 19.5% 3.1% 76.2%
[libx264 @ 0000020fdbdabc80] mb I I16..4: 23.3% 62.6% 14.1%
[libx264 @ 0000020fdbdabc80] mb P I16..4: 0.6% 1.9% 0.3% P16..4:
19.9% 5.7% 3.4% 0.0% 0.0% skip:68.1%
[libx264 @ 0000020fdbdabc80] mb B I16..4: 0.0% 0.1% 0.0% B16..8:
14.8% 0.6% 0.1% direct: 0.2% skip:84.2% L0:40.3% L1:56.9% BI: 2.8%
[libx264 @ 0000020fdbdabc80] 8x8 transform intra:65.2% inter:76.0%
[libx264 @ 0000020fdbdabc80] coded y,uvDC,uvAC intra: 53.9% 51.2% 17.6%
inter: 3.3% 2.5% 0.1%
[libx264 @ 0000020fdbdabc80] i16 v,h,dc,p: 36% 36% 7% 20%
[libx264 @ 0000020fdbdabc80] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 17% 20%
5% 7% 9% 6% 8% 7%
[libx264 @ 0000020fdbdabc80] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 23% 23% 16%
5% 7% 9% 6% 6% 5%
[libx264 @ 0000020fdbdabc80] i8c dc,h,v,p: 58% 21% 17% 4%
[libx264 @ 0000020fdbdabc80] Weighted P-Frames: Y:1.7% UV:0.2%
[libx264 @ 0000020fdbdabc80] ref P L0: 63.4% 17.8% 11.3% 7.4% 0.1%
[libx264 @ 0000020fdbdabc80] ref B L0: 90.7% 6.4% 2.9%
[libx264 @ 0000020fdbdabc80] ref B L1: 97.9% 2.1%
[libx264 @ 0000020fdbdabc80] kb/s:679.80
--
Ticket URL: <https://trac.ffmpeg.org/ticket/8590>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list