Discussion:
[FFmpeg-user] Why are half the frames "duplicate" ?
sean darcy
2018-09-27 02:27:26 UTC
Permalink
I'm transcoding mpeg2 -> x264.

Stream #0:0[0x64]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002),
yuv420p(tv, progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions,
29.97 fps, 59.94 tbr, 90k tbn, 59.94 tbc

When I run ffmpeg:

ffmpeg -i in.mpg -map 0:0 -map 0:2 -c:v libx264 -tune film -preset slow
-crf 22 -c:a copy out.mp4

almost half the frames are dups:

frame=394550 fps=135 q=-1.0 Lsize= 2218652kB time=03:39:24.71
bitrate=1380.6kbits/s dup=175142 drop=0 speed=4.51x

Does this really mean that there were 175,142 frames with exact copies ?
So only ( 394,550 less 175,142 ) unique frames ?

The output looks fine. The input looks fine. What are these duplicated
frames? Is it an interlacing issue ? But the input is progressive.

Does it have to do with this warning:

[mp4 @ 0x921c80] track 1: codec frame size is not set
Output #0, mp4, to 'out.mp4':
Metadata:
encoder : Lavf58.18.103
Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p,
720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc
Metadata:
encoder : Lavc58.31.100 libx264

Puzzled.

_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "unsu
DopeLabs
2018-09-27 09:55:30 UTC
Permalink
input: 90k tbn, 59.94 tbc

output: 30k tbn, 29.97 tbc

try explicitly specifying the output frame rate

-c:v h264 -r 29.97
Post by sean darcy
I'm transcoding mpeg2 -> x264.
Stream #0:0[0x64]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002), yuv420p(tv, progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps, 59.94 tbr, 90k tbn, 59.94 tbc
ffmpeg -i in.mpg -map 0:0 -map 0:2 -c:v libx264 -tune film -preset slow -crf 22 -c:a copy out.mp4
frame=394550 fps=135 q=-1.0 Lsize= 2218652kB time=03:39:24.71 bitrate=1380.6kbits/s dup=175142 drop=0 speed=4.51x
Does this really mean that there were 175,142 frames with exact copies ? So only ( 394,550 less 175,142 ) unique frames ?
The output looks fine. The input looks fine. What are these duplicated frames? Is it an interlacing issue ? But the input is progressive.
encoder : Lavf58.18.103
Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc
encoder : Lavc58.31.100 libx264
Puzzled.
_______________________________________________
ffmpeg-user mailing list
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
To unsubscribe, visit link above, or email
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ff
sean darcy
2018-09-27 20:13:32 UTC
Permalink
Post by DopeLabs
input: 90k tbn, 59.94 tbc
output: 30k tbn, 29.97 tbc
try explicitly specifying the output frame rate
-c:v h264 -r 29.97
Post by sean darcy
I'm transcoding mpeg2 -> x264.
Stream #0:0[0x64]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002), yuv420p(tv, progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps, 59.94 tbr, 90k tbn, 59.94 tbc
ffmpeg -i in.mpg -map 0:0 -map 0:2 -c:v libx264 -tune film -preset slow -crf 22 -c:a copy out.mp4
frame=394550 fps=135 q=-1.0 Lsize= 2218652kB time=03:39:24.71 bitrate=1380.6kbits/s dup=175142 drop=0 speed=4.51x
Does this really mean that there were 175,142 frames with exact copies ? So only ( 394,550 less 175,142 ) unique frames ?
The output looks fine. The input looks fine. What are these duplicated frames? Is it an interlacing issue ? But the input is progressive.
encoder : Lavf58.18.103
Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc
encoder : Lavc58.31.100 libx264
Puzzled.
But isn't that what ffmpeg does anyway:

ffprobe out.mp4
.........
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'out.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf58.18.103
Duration: 00:21:40.97, start: 0.000000, bitrate: 1346 kb/s
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p,
720x480 [SAR 8:9 DAR 4:3], 944 kb/s, 29.97 fps, 29.97 tbr, 30k tbn,
59.94 tbc (default)
Metadata:
handler_name : VideoHandler

Does specifying the frame rate do anything but silence the dup warnings
? I mean, does ffmpeg do anything different when it's transcoding ?




_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-us
Carl Eugen Hoyos
2018-09-27 21:07:10 UTC
Permalink
Post by DopeLabs
input: 90k tbn, 59.94 tbc
output: 30k tbn, 29.97 tbc
try explicitly specifying the output frame rate
-c:v h264 -r 29.97
This is definitely not correct, "29.97" is not the right framerate
for any common use-case, the framerate for ntsc video is
"30000/1001".

Please remember not to top-post here, Carl Eugen
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "unsubscrib
Carl Eugen Hoyos
2018-09-27 21:11:36 UTC
Permalink
Post by sean darcy
I'm transcoding mpeg2 -> x264.
Stream #0:0[0x64]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002),
yuv420p(tv, progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions,
29.97 fps, 59.94 tbr, 90k tbn, 59.94 tbc
ffmpeg -i in.mpg -map 0:0 -map 0:2 -c:v libx264 -tune film -preset slow
-crf 22 -c:a copy out.mp4
Please (test current FFmpeg git head and) provide the command line
you used together with the complete, uncut console output.

If your input is progressive and variable frame rate and you want
mp4 output, then the duplicated frames are unavoidable as FFmpeg
is unable to write valid variable frame rate mp4 files.
(vfr mkv is supported)
If your input is mixed telecined and progressive, there are command
lines that help iirc.
If your input is only telecined or soft telecined, the output frame-rate
should be 24000/1001 (this is also true for the case above).
The idet filter can help you detect what your input's properties are,
visual inspection is even better, an alternative is to provide a sample.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "unsubscri
sean darcy
2018-09-28 18:58:45 UTC
Permalink
Post by Carl Eugen Hoyos
Post by sean darcy
I'm transcoding mpeg2 -> x264.
Stream #0:0[0x64]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002),
yuv420p(tv, progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions,
29.97 fps, 59.94 tbr, 90k tbn, 59.94 tbc
ffmpeg -i in.mpg -map 0:0 -map 0:2 -c:v libx264 -tune film -preset slow
-crf 22 -c:a copy out.mp4
Please (test current FFmpeg git head and) provide the command line
you used together with the complete, uncut console output.
If your input is progressive and variable frame rate and you want
mp4 output, then the duplicated frames are unavoidable as FFmpeg
is unable to write valid variable frame rate mp4 files.
(vfr mkv is supported)
If your input is mixed telecined and progressive, there are command
lines that help iirc.
If your input is only telecined or soft telecined, the output frame-rate
should be 24000/1001 (this is also true for the case above).
The idet filter can help you detect what your input's properties are,
visual inspection is even better, an alternative is to provide a sample.
Carl Eugen
_______________________________________________
Thanks for the help.

ffmpeg -i in.mpg -frames:v 2000 -map 0:0 -map 0:2 -c:v libx264 -tune
film -preset slow -crf 22 -an -f mp4 /dev/null
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 56. 19.101 / 56. 19.101
libavcodec 58. 31.101 / 58. 31.101
libavformat 58. 18.103 / 58. 18.103
libavdevice 58. 4.104 / 58. 4.104
libavfilter 7. 33.100 / 7. 33.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
libpostproc 55. 2.100 / 55. 2.100
[mpeg2video @ 0xe34a00] Invalid frame dimensions 0x0.
Last message repeated 10 times
Input #0, mpeg, from 'in.mpg':
Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:3[0x1bf]: Data: dvd_nav_packet
Stream #0:4[0x22]: Subtitle: dvd_subtitle
Stream #0:5[0x21]: Subtitle: dvd_subtitle
Stream #0:6[0x20]: Subtitle: dvd_subtitle
File '/dev/null' already exists. Overwrite ? [y/N] y
Stream mapping:
Stream #0:0 -> #0:0 (mpeg2video (native) -> h264 (libx264))
Press [q] to stop, [?] for help
[libx264 @ 0xe5b180] using SAR=8/9
[libx264 @ 0xe5b180] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
AVX FMA3 BMI2 AVX2
[libx264 @ 0xe5b180] profile High, level 3.0, 4:2:0, 8-bit
[libx264 @ 0xe5b180] 264 - core 157 - H.264/MPEG-4 AVC codec - Copyleft
2003-2018 - http://www.videolan.org/x264.html - options: cabac=1 ref=5
deblock=1:-1:-1 analyse=0x3:0x113 me=hex subme=8 psy=1 psy_rd=1.00:0.15
mixed_ref=1 me_range=16 chroma_me=1 trellis=2 8x8dct=1 cqm=0
deadzone=21,11 fast_pskip=1 chroma_qp_offset=-3 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=3 weightb=1 open_gop=0 weightp=2 keyint=250
keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=50 rc=crf
mbtree=1 crf=22.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40
aq=1:1.00
Output #0, mp4, to '/dev/null':
Metadata:
encoder : Lavf58.18.103
Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p,
720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc
Metadata:
encoder : Lavc58.31.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
frame= 2000 fps=132 q=-1.0 Lsize= 10708kB time=00:01:06.63
bitrate=1316.5kbits/s dup=401 drop=0 speed=4.39x
video:10684kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.229348%
[libx264 @ 0xe5b180] frame I:10 Avg QP:21.04 size: 33873
[libx264 @ 0xe5b180] frame P:593 Avg QP:23.63 size: 12243
[libx264 @ 0xe5b180] frame B:1397 Avg QP:25.67 size: 2391
[libx264 @ 0xe5b180] consecutive B-frames: 0.6% 18.5% 1.4% 79.6%
[libx264 @ 0xe5b180] mb I I16..4: 2.8% 90.7% 6.5%
[libx264 @ 0xe5b180] mb P I16..4: 0.5% 10.7% 0.7% P16..4: 47.9%
21.4% 10.1% 0.0% 0.0% skip: 8.7%
[libx264 @ 0xe5b180] mb B I16..4: 0.0% 0.5% 0.0% B16..8: 35.4%
5.2% 1.1% direct: 2.1% skip:55.6% L0:45.0% L1:42.4% BI:12.6%
[libx264 @ 0xe5b180] 8x8 transform intra:90.0% inter:76.7%
[libx264 @ 0xe5b180] direct mvs spatial:99.6% temporal:0.4%
[libx264 @ 0xe5b180] coded y,uvDC,uvAC intra: 88.7% 74.2% 28.5% inter:
17.7% 23.4% 1.0%
[libx264 @ 0xe5b180] i16 v,h,dc,p: 47% 12% 9% 32%
[libx264 @ 0xe5b180] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 19% 10% 13% 7% 10%
12% 10% 11% 10%
[libx264 @ 0xe5b180] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 17% 6% 3% 8% 15%
17% 13% 11% 9%
[libx264 @ 0xe5b180] i8c dc,h,v,p: 39% 24% 25% 12%
[libx264 @ 0xe5b180] Weighted P-Frames: Y:17.7% UV:13.0%
[libx264 @ 0xe5b180] ref P L0: 52.3% 18.7% 17.0% 6.0% 5.0% 1.0%
[libx264 @ 0xe5b180] ref B L0: 89.7% 7.1% 2.7% 0.6%
[libx264 @ 0xe5b180] ref B L1: 99.5% 0.5%
[libx264 @ 0xe5b180] kb/s:1311.43

Also, I used ffprobe:

ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347

This means there are at least some interlaced frames. Is yadif called for ?

And the frames have two different durations:

ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
pkt_duration_time
32399

ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
pkt_duration_time=0.033367
17227

ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
pkt_duration_time=0.050044
15172

which generally alternate.

_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "unsubscri
Carl Eugen Hoyos
2018-09-28 23:29:06 UTC
Permalink
Post by sean darcy
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).

Either use the idet filter or do a visual inspection.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "un
sean darcy
2018-09-29 20:46:45 UTC
Permalink
Post by Carl Eugen Hoyos
Post by sean darcy
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).
Either use the idet filter or do a visual inspection.
Carl Eugen
_______________________________________________
Never used idet filter before, so don't know how to make use of the info.

ffmpeg -vf idet -frames:v 5000 -an -f rawvideo -y /dev/null -i in.mpg
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 56. 19.101 / 56. 19.101
libavcodec 58. 31.101 / 58. 31.101
libavformat 58. 18.103 / 58. 18.103
libavdevice 58. 4.104 / 58. 4.104
libavfilter 7. 33.100 / 7. 33.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
libpostproc 55. 2.100 / 55. 2.100
[mpeg2video @ 0x1eef200] Invalid frame dimensions 0x0.
Last message repeated 10 times
Input #0, mpeg, from 'in.mpg':
Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:3[0x1bf]: Data: dvd_nav_packet
Stream #0:4[0x22]: Subtitle: dvd_subtitle
Stream #0:5[0x21]: Subtitle: dvd_subtitle
Stream #0:6[0x20]: Subtitle: dvd_subtitle
Stream mapping:
Stream #0:0 -> #0:0 (mpeg2video (native) -> rawvideo (native))
Press [q] to stop, [?] for help
Output #0, rawvideo, to '/dev/null':
Metadata:
encoder : Lavf58.18.103
Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 720x480
[SAR 8:9 DAR 4:3], q=2-31, 124291 kb/s, 29.97 fps, 29.97 tbn, 29.97 tbc
Metadata:
encoder : Lavc58.31.101 rawvideo
More than 1000 frames duplicated= 2191360kB time=00:02:24.44
bitrate=124280.6kbits/s dup=867 drop=0 speed=72.2x
frame= 5000 fps=2162 q=-0.0 Lsize= 2531250kB time=00:02:46.83
bitrate=124291.7kbits/s dup=1001 drop=0 speed=72.1x
video:2531250kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.000000%
[Parsed_idet_0 @ 0x21f7dc0] Repeated Fields: Neither: 4000 Top: 0
Bottom: 0
[Parsed_idet_0 @ 0x21f7dc0] Single frame detection: TFF: 0 BFF:
0 Progressive: 3894 Undetermined: 106
[Parsed_idet_0 @ 0x21f7dc0] Multi frame detection: TFF: 0 BFF: 0
Progressive: 4000 Undetermined: 0

As I read this, the idet filter only saw 4000 out of the 5000 frames, of
which 106 couldn't be classified. What about the 1001 duplicated frames ?

Again, thanks for the help.


_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with
Carl Eugen Hoyos
2018-09-29 21:15:58 UTC
Permalink
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).
Either use the idet filter or do a visual inspection.
Carl Eugen
_______________________________________________
Never used idet filter before, so don't know how to make use of the info.
ffmpeg -vf idet -frames:v 5000 -an -f rawvideo -y /dev/null -i in.mpg
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 56. 19.101 / 56. 19.101
libavcodec 58. 31.101 / 58. 31.101
libavformat 58. 18.103 / 58. 18.103
libavdevice 58. 4.104 / 58. 4.104
libavfilter 7. 33.100 / 7. 33.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
libpostproc 55. 2.100 / 55. 2.100
Last message repeated 10 times
Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:3[0x1bf]: Data: dvd_nav_packet
Stream #0:4[0x22]: Subtitle: dvd_subtitle
Stream #0:5[0x21]: Subtitle: dvd_subtitle
Stream #0:6[0x20]: Subtitle: dvd_subtitle
Stream #0:0 -> #0:0 (mpeg2video (native) -> rawvideo (native))
Press [q] to stop, [?] for help
encoder : Lavf58.18.103
Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 720x480
[SAR 8:9 DAR 4:3], q=2-31, 124291 kb/s, 29.97 fps, 29.97 tbn, 29.97 tbc
encoder : Lavc58.31.101 rawvideo
More than 1000 frames duplicated= 2191360kB time=00:02:24.44
bitrate=124280.6kbits/s dup=867 drop=0 speed=72.2x
frame= 5000 fps=2162 q=-0.0 Lsize= 2531250kB time=00:02:46.83
bitrate=124291.7kbits/s dup=1001 drop=0 speed=72.1x
video:2531250kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.000000%
Bottom: 0
0 Progressive: 3894 Undetermined: 106
Progressive: 4000 Undetermined: 0
As I read this, the idet filter only saw 4000 out of the 5000 frames, of
which 106 couldn't be classified. What about the 1001 duplicated frames ?
This indicates soft-telecine of progressive original.

Please test with output option "-r 24000/1001". If that
leads to (many) duplicated and dropped frames, there
are ways to work-around iirc.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-use
sean darcy
2018-09-30 14:45:24 UTC
Permalink
Post by Carl Eugen Hoyos
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).
Either use the idet filter or do a visual inspection.
Carl Eugen
_______________________________________________
Never used idet filter before, so don't know how to make use of the info.
ffmpeg -vf idet -frames:v 5000 -an -f rawvideo -y /dev/null -i in.mpg
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 56. 19.101 / 56. 19.101
libavcodec 58. 31.101 / 58. 31.101
libavformat 58. 18.103 / 58. 18.103
libavdevice 58. 4.104 / 58. 4.104
libavfilter 7. 33.100 / 7. 33.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
libpostproc 55. 2.100 / 55. 2.100
Last message repeated 10 times
Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:3[0x1bf]: Data: dvd_nav_packet
Stream #0:4[0x22]: Subtitle: dvd_subtitle
Stream #0:5[0x21]: Subtitle: dvd_subtitle
Stream #0:6[0x20]: Subtitle: dvd_subtitle
Stream #0:0 -> #0:0 (mpeg2video (native) -> rawvideo (native))
Press [q] to stop, [?] for help
encoder : Lavf58.18.103
Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 720x480
[SAR 8:9 DAR 4:3], q=2-31, 124291 kb/s, 29.97 fps, 29.97 tbn, 29.97 tbc
encoder : Lavc58.31.101 rawvideo
More than 1000 frames duplicated= 2191360kB time=00:02:24.44
bitrate=124280.6kbits/s dup=867 drop=0 speed=72.2x
frame= 5000 fps=2162 q=-0.0 Lsize= 2531250kB time=00:02:46.83
bitrate=124291.7kbits/s dup=1001 drop=0 speed=72.1x
video:2531250kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.000000%
Bottom: 0
0 Progressive: 3894 Undetermined: 106
Progressive: 4000 Undetermined: 0
As I read this, the idet filter only saw 4000 out of the 5000 frames, of
which 106 couldn't be classified. What about the 1001 duplicated frames ?
This indicates soft-telecine of progressive original.
Please test with output option "-r 24000/1001". If that
leads to (many) duplicated and dropped frames, there
are ways to work-around iirc.
Carl Eugen
You are the man !

Ran the entire clip at 24000/1001, only 11 duplicated frames.
What did you see in the idet output that told you that the progressive
original (24fps, correct ? ) had been telecined ?




_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ff
sean darcy
2018-09-30 15:21:36 UTC
Permalink
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
Post by Carl Eugen Hoyos
ffprobe -show_frames -select_streams v -i in.mpg  2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg  2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).
Either use the idet filter or do a visual inspection.
Carl Eugen
_______________________________________________
Never used idet filter before, so don't know how to make use of the info.
ffmpeg -vf idet -frames:v 5000 -an -f rawvideo -y /dev/null -i  in.mpg
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
    built with gcc 8 (GCC)
    configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
    libavutil      56. 19.101 / 56. 19.101
    libavcodec     58. 31.101 / 58. 31.101
    libavformat    58. 18.103 / 58. 18.103
    libavdevice    58.  4.104 / 58.  4.104
    libavfilter     7. 33.100 /  7. 33.100
    libswscale      5.  2.100 /  5.  2.100
    libswresample   3.  2.100 /  3.  2.100
    libpostproc    55.  2.100 / 55.  2.100
      Last message repeated 10 times
    Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
      Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
      Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
      Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
      Stream #0:3[0x1bf]: Data: dvd_nav_packet
      Stream #0:4[0x22]: Subtitle: dvd_subtitle
      Stream #0:5[0x21]: Subtitle: dvd_subtitle
      Stream #0:6[0x20]: Subtitle: dvd_subtitle
    Stream #0:0 -> #0:0 (mpeg2video (native) -> rawvideo (native))
Press [q] to stop, [?] for help
      encoder         : Lavf58.18.103
      Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 720x480
[SAR 8:9 DAR 4:3], q=2-31, 124291 kb/s, 29.97 fps, 29.97 tbn, 29.97 tbc
        encoder         : Lavc58.31.101 rawvideo
More than 1000 frames duplicated= 2191360kB time=00:02:24.44
bitrate=124280.6kbits/s dup=867 drop=0 speed=72.2x
frame= 5000 fps=2162 q=-0.0 Lsize= 2531250kB time=00:02:46.83
bitrate=124291.7kbits/s dup=1001 drop=0 speed=72.1x
video:2531250kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.000000%
Bottom:     0
0 Progressive:  3894 Undetermined:   106
Progressive:  4000 Undetermined:     0
As I read this, the idet filter only saw 4000 out of the 5000 frames, of
which 106 couldn't be classified. What about the 1001 duplicated frames ?
This indicates soft-telecine of progressive original.
Please test with output option "-r 24000/1001". If that
leads to (many) duplicated and dropped frames, there
are ways to work-around iirc.
Carl Eugen
You are the man !
Ran the entire clip at 24000/1001, only 11 duplicated frames.
What did you see in the idet output that told you that the progressive
original (~24fps, correct ? ) had been telecined ?
I've been googling soft telecine. Some have suggested using "-re" as the
frame rate. Why would 24000/1001 be preferred ?


_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmp
Carl Eugen Hoyos
2018-09-30 18:58:49 UTC
Permalink
Post by sean darcy
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).
Either use the idet filter or do a visual inspection.
Carl Eugen
_______________________________________________
Never used idet filter before, so don't know how to make use of the info.
ffmpeg -vf idet -frames:v 5000 -an -f rawvideo -y /dev/null -i in.mpg
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 56. 19.101 / 56. 19.101
libavcodec 58. 31.101 / 58. 31.101
libavformat 58. 18.103 / 58. 18.103
libavdevice 58. 4.104 / 58. 4.104
libavfilter 7. 33.100 / 7. 33.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
libpostproc 55. 2.100 / 55. 2.100
Last message repeated 10 times
Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:3[0x1bf]: Data: dvd_nav_packet
Stream #0:4[0x22]: Subtitle: dvd_subtitle
Stream #0:5[0x21]: Subtitle: dvd_subtitle
Stream #0:6[0x20]: Subtitle: dvd_subtitle
Stream #0:0 -> #0:0 (mpeg2video (native) -> rawvideo (native))
Press [q] to stop, [?] for help
encoder : Lavf58.18.103
Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 720x480
[SAR 8:9 DAR 4:3], q=2-31, 124291 kb/s, 29.97 fps, 29.97 tbn, 29.97 tbc
encoder : Lavc58.31.101 rawvideo
More than 1000 frames duplicated= 2191360kB time=00:02:24.44
bitrate=124280.6kbits/s dup=867 drop=0 speed=72.2x
frame= 5000 fps=2162 q=-0.0 Lsize= 2531250kB time=00:02:46.83
bitrate=124291.7kbits/s dup=1001 drop=0 speed=72.1x
video:2531250kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.000000%
Bottom: 0
0 Progressive: 3894 Undetermined: 106
Progressive: 4000 Undetermined: 0
As I read this, the idet filter only saw 4000 out of the 5000 frames, of
which 106 couldn't be classified. What about the 1001 duplicated frames ?
This indicates soft-telecine of progressive original.
Please test with output option "-r 24000/1001". If that
leads to (many) duplicated and dropped frames, there
are ways to work-around iirc.
Carl Eugen
You are the man !
Ran the entire clip at 24000/1001, only 11 duplicated frames.
This imo indicates that the command line is correct.
Post by sean darcy
Post by sean darcy
What did you see in the idet output that told you that the progressive
original (~24fps, correct ? ) had been telecined ?
I saw that it was not telecined (since all frames are progressive).
Therefore the only explanation that made sense was soft-telecine:
The actual framerate was always 24000/1001 but since old American
televisions required 30000/1001, the stream contains information
that frames have to be duplicated (what FFmpeg did originally).

Maybe unrelated:
Note that FFmpeg's mpeg-ps muxer is unable to add this information
to its output streams, MEncoder can do it.
Post by sean darcy
I've been googling soft telecine. Some have suggested using "-re"
as the frame rate. Why would 24000/1001 be preferred ?
That does not sound correct, "-re" allows FFmpeg to encode in
real-time (instead of faster), it should not change the output frame
rate. Does it?

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with
sean darcy
2018-10-02 01:26:02 UTC
Permalink
Post by Carl Eugen Hoyos
Post by sean darcy
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
Post by Carl Eugen Hoyos
Post by sean darcy
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=1
2052
ffprobe -show_frames -select_streams v -i in.mpg 2>&1 | grep -c
interlaced_frame=0
30347
This means there are at least some interlaced frames
No, unfortunately ffprobe cannot tell you (the information above
is mostly unrelated to the question if the content is interlaced,
telecined or progressive).
Either use the idet filter or do a visual inspection.
Carl Eugen
_______________________________________________
Never used idet filter before, so don't know how to make use of the info.
ffmpeg -vf idet -frames:v 5000 -an -f rawvideo -y /dev/null -i in.mpg
ffmpeg version git-snapshot-20180928-RPMFusion Copyright (c) 2000-2018
the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin
--datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg
--libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64
--optflags='-O2 -ffast-math -march=native -ftree-vectorize
-fomit-frame-pointer -pipe -fPIC' --enable-bzlib --disable-crystalhd
--enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls
--enable-ladspa --enable-libass --enable-libbluray --enable-libcdio
--enable-libfdk-aac --enable-nonfree --enable-indev=jack
--enable-libfreetype --enable-libfribidi --enable-libgsm
--enable-libmp3lame --enable-openal --enable-opencl --disable-libopencv
--enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse
--enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis
--enable-libv4l2 --enable-libvpx --enable-libwebp --enable-libx264
--enable-libx265 --enable-avfilter --enable-postproc --enable-pthreads
--disable-static --enable-shared --enable-gpl --enable-version3
--enable-nonfree --disable-debug --enable-stripping
--shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 56. 19.101 / 56. 19.101
libavcodec 58. 31.101 / 58. 31.101
libavformat 58. 18.103 / 58. 18.103
libavdevice 58. 4.104 / 58. 4.104
libavfilter 7. 33.100 / 7. 33.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
libpostproc 55. 2.100 / 55. 2.100
Last message repeated 10 times
Duration: 26:09:34.50, start: 1305.384367, bitrate: 91 kb/s
Stream #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv,
progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions, 29.97 fps,
59.94 tbr, 90k tbn, 59.94 tbc
Stream #0:1[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
Stream #0:3[0x1bf]: Data: dvd_nav_packet
Stream #0:4[0x22]: Subtitle: dvd_subtitle
Stream #0:5[0x21]: Subtitle: dvd_subtitle
Stream #0:6[0x20]: Subtitle: dvd_subtitle
Stream #0:0 -> #0:0 (mpeg2video (native) -> rawvideo (native))
Press [q] to stop, [?] for help
encoder : Lavf58.18.103
Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 720x480
[SAR 8:9 DAR 4:3], q=2-31, 124291 kb/s, 29.97 fps, 29.97 tbn, 29.97 tbc
encoder : Lavc58.31.101 rawvideo
More than 1000 frames duplicated= 2191360kB time=00:02:24.44
bitrate=124280.6kbits/s dup=867 drop=0 speed=72.2x
frame= 5000 fps=2162 q=-0.0 Lsize= 2531250kB time=00:02:46.83
bitrate=124291.7kbits/s dup=1001 drop=0 speed=72.1x
video:2531250kB audio:0kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.000000%
Bottom: 0
0 Progressive: 3894 Undetermined: 106
Progressive: 4000 Undetermined: 0
As I read this, the idet filter only saw 4000 out of the 5000 frames, of
which 106 couldn't be classified. What about the 1001 duplicated frames ?
This indicates soft-telecine of progressive original.
Please test with output option "-r 24000/1001". If that
leads to (many) duplicated and dropped frames, there
are ways to work-around iirc.
Carl Eugen
You are the man !
Ran the entire clip at 24000/1001, only 11 duplicated frames.
This imo indicates that the command line is correct.
Post by sean darcy
Post by sean darcy
What did you see in the idet output that told you that the progressive
original (~24fps, correct ? ) had been telecined ?
I saw that it was not telecined (since all frames are progressive).
The actual framerate was always 24000/1001 but since old American
televisions required 30000/1001, the stream contains information
that frames have to be duplicated (what FFmpeg did originally).
Note that FFmpeg's mpeg-ps muxer is unable to add this information
to its output streams, MEncoder can do it.
Thanks. Very helpful.
Post by Carl Eugen Hoyos
Post by sean darcy
I've been googling soft telecine. Some have suggested using "-re"
as the frame rate. Why would 24000/1001 be preferred ?
That does not sound correct, "-re" allows FFmpeg to encode in
real-time (instead of faster), it should not change the output frame
rate. Does it?
Carl Eugen
From 12 years ago:

https://lists.libav.org/pipermail/ffmpeg-user/2006-February/002349.html

make an decoding/encoding with
framerate " -re" (instead of "-r pal" or -r ntsc" or "-r 25" or "-r
30000:1001", ...) the "-re" parameter for framerate will just
decode/encode your input without forcing framerate (read your input at
its own framerate and write it "the same")
You'll will see (even if your input was a ntsc-film with pulldown)
that your output will be 24000:1001 too.

_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "uns
Moritz Barsnick
2018-10-02 08:28:17 UTC
Permalink
Post by sean darcy
Post by Carl Eugen Hoyos
That does not sound correct, "-re" allows FFmpeg to encode in
real-time (instead of faster), it should not change the output frame
rate. Does it?
https://lists.libav.org/pipermail/ffmpeg-user/2006-February/002349.html
make an decoding/encoding with
framerate " -re" (instead of "-r pal" or -r ntsc" or "-r 25" or "-r
30000:1001", ...) the "-re" parameter for framerate will just
decode/encode your input without forcing framerate (read your input at
its own framerate and write it "the same")
You'll will see (even if your input was a ntsc-film with pulldown)
that your output will be 24000:1001 too.
Ah, well, that was already incorrect 12 years ago. "-re" does not
change how ffmpeg maps the inputs frame (or field) rate to its output's
frame rate. It changes how fast the input is processed:

https://ffmpeg.org/ffmpeg.html#Advanced-options

"This option will slow down the reading of the input(s) to the native
frame rate of the input(s). It is useful for real-time output (e.g.
live streaming)."

Cheers,
Moritz
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject

Reuben Martin
2018-09-28 00:41:35 UTC
Permalink
Post by sean darcy
I'm transcoding mpeg2 -> x264.
Stream #0:0[0x64]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002),
yuv420p(tv, progressive), 720x480 [SAR 8:9 DAR 4:3], Closed Captions,
29.97 fps, 59.94 tbr, 90k tbn, 59.94 tbc
I doubt that is progressive. Or if it is it’s probably progressive with a
telecine flag set so that it’s played interlaced. When you see both 29.97 and
59.94, it’s probably interlaced. (frame-rate and field-rate)

-Reuben




_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.o
Continue reading on narkive:
Loading...