[FFmpeg-user] ts to HLS: yadif doesn't work
Zsolt
zsocam at gmail.com
Mon Jul 11 13:55:42 EEST 2016
Hello Guys,
I'd like to convert some ts files to HLS.
It works fine, the only problem is that the yadif command doesn't work.
Could you check my command?
/usr/local/ffmpeg/program/ffmpeg -i /usr/local/ffmpeg/progress/$INPUTFILE \
\
-c:v libx264 -vf "yadif=0:-1:1" -r 25 -profile:v main -level 3.1 \
-b:v "$BIT1"k -bufsize "$BIT1"k -vf scale=$RES1 -g 250 -keyint_min 250
-sc_threshold 0 \
-c:a libfdk_aac -b:a $AUD1 \
-hls_segment_filename
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT1"k/segment_"$BIT1"k_%04d.ts \
-hls_time 10 -hls_list_size 0 -hls_key_info_file file.keyinfo \
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT1"k/index_"$BIT1"k.m3u8 \
\
-c:v libx264 -vf "yadif=0:-1:1" -r 25 -profile:v main -level 3.1 \
-b:v "$BIT2"k -bufsize "$BIT2"k -vf scale=$RES2 -g 250 -keyint_min 250
-sc_threshold 0 \
-c:a libfdk_aac -b:a $AUD1 \
-hls_segment_filename
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT2"k/segment_"$BIT2"k_%04d.ts \
-hls_time 10 -hls_list_size 0 -hls_key_info_file file.keyinfo \
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT2"k/index_"$BIT2"k.m3u8 \
\
-c:v libx264 -vf "yadif=0:-1:1" -r 25 -profile:v main -level 3.1 \
-b:v "$BIT3"k -bufsize "$BIT3"k -vf scale=$RES3 -g 250 -keyint_min 250
-sc_threshold 0 \
-c:a libfdk_aac -b:a $AUD1 \
-hls_segment_filename
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT3"k/segment_"$BIT3"k_%04d.ts \
-hls_time 10 -hls_list_size 0 -hls_key_info_file file.keyinfo \
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT3"k/index_"$BIT3"k.m3u8 \
\
-c:v libx264 -vf "yadif=0:-1:1" -r 25 -profile:v main -level 3.1 \
-b:v "$BIT4"k -bufsize "$BIT4"k -vf scale=$RES4 -g 250 -keyint_min 250
-sc_threshold 0 \
-c:a libfdk_aac -b:a $AUD1 \
-hls_segment_filename
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT4"k/segment_"$BIT4"k_%04d.ts \
-hls_time 10 -hls_list_size 0 -hls_key_info_file file.keyinfo \
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT4"k/index_"$BIT4"k.m3u8 \
\
-c:v libx264 -vf "yadif=0:-1:1" -r 25 -profile:v main -level 3.1 \
-b:v "$BIT5"k -bufsize "$BIT5"k -vf scale=$RES5 -g 250 -keyint_min 250
-sc_threshold 0 \
-c:a libfdk_aac -b:a $AUD1 \
-hls_segment_filename
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT5"k/segment_"$BIT5"k_%04d.ts \
-hls_time 10 -hls_list_size 0 -hls_key_info_file file.keyinfo \
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT5"k/index_"$BIT5"k.m3u8 \
\
-c:v libx264 -vf "yadif=0:-1:1" -r 25 -profile:v main -level 3.1 \
-b:v "$BIT6"k -bufsize "$BIT6"k -vf scale=$RES6 -g 250 -keyint_min 250
-sc_threshold 0 \
-c:a libfdk_aac -b:a $AUD1 \
-hls_segment_filename
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT6"k/segment_"$BIT6"k_%04d.ts \
-hls_time 10 -hls_list_size 0 -hls_key_info_file file.keyinfo \
/usr/local/ffmpeg/output/$INPUTNAME/"$BIT6"k/index_"$BIT6"k.m3u8
Output:
ffmpeg version N-80872-g1a75145 Copyright (c) 2000-2016 the FFmpeg
developers
built with gcc 4.9.2 (Debian 4.9.2-10)
configuration: --prefix=/root/ffmpeg_build --pkg-config-flags=--static
--extra-cflags=-I/root/ffmpeg_build/include
--extra-ldflags=-L/root/ffmpeg_build/lib --bindir=/root/bin --enable-gpl
--enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libx264
--enable-nonfree
libavutil 55. 27.100 / 55. 27.100
libavcodec 57. 48.101 / 57. 48.101
libavformat 57. 40.101 / 57. 40.101
libavdevice 57. 0.102 / 57. 0.102
libavfilter 6. 47.100 / 6. 47.100
libswscale 4. 1.100 / 4. 1.100
libswresample 2. 1.100 / 2. 1.100
libpostproc 54. 0.100 / 54. 0.100
Input #0, mpegts, from '/usr/local/ffmpeg/progress/teszt12-A0737.ts':
Duration: 00:00:25.78, start: 0.541756, bitrate: 3808 kb/s
Program 1
Stream #0:0[0x1e1]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002),
yuv420p(tv), 720x576 [SAR 64:45 DAR 16:9], 3200 kb/s, 25 fps, 25 tbr, 90k
tbn, 50 tbc
Stream #0:1[0x1eb](hun): Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz,
stereo, s16p, 192 kb/s
[libx264 @ 0x29149a0] VBV maxrate unspecified, assuming CBR
[libx264 @ 0x29149a0] using SAR=1/1
[libx264 @ 0x29149a0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x29149a0] profile Main, level 3.1
[libx264 @ 0x291a5c0] VBV maxrate unspecified, assuming CBR
[libx264 @ 0x291a5c0] using SAR=1/1
[libx264 @ 0x291a5c0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x291a5c0] profile Main, level 3.1
[libx264 @ 0x291f0e0] VBV maxrate unspecified, assuming CBR
[libx264 @ 0x291f0e0] using SAR=1/1
[libx264 @ 0x291f0e0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x291f0e0] profile Main, level 3.1
[libx264 @ 0x2923ba0] VBV maxrate unspecified, assuming CBR
[libx264 @ 0x2923ba0] using SAR=1/1
[libx264 @ 0x2923ba0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x2923ba0] profile Main, level 3.1
[libx264 @ 0x2928540] VBV maxrate unspecified, assuming CBR
[libx264 @ 0x2928540] using SAR=1/1
[libx264 @ 0x2928540] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x2928540] profile Main, level 3.1
[libx264 @ 0x292cdc0] VBV maxrate unspecified, assuming CBR
[libx264 @ 0x292cdc0] using SAR=1/1
[libx264 @ 0x292cdc0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x292cdc0] profile Main, level 3.1
[hls @ 0x28edd40] Using AVStream.codec to pass codec parameters to muxers
is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
[hls @ 0x29189c0] Using AVStream.codec to pass codec parameters to muxers
is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
[hls @ 0x291d4e0] Using AVStream.codec to pass codec parameters to muxers
is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
[hls @ 0x2921ee0] Using AVStream.codec to pass codec parameters to muxers
is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
[hls @ 0x2926940] Using AVStream.codec to pass codec parameters to muxers
is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
[hls @ 0x292b100] Using AVStream.codec to pass codec parameters to muxers
is deprecated, use AVStream.codecpar instead.
Last message repeated 1 times
Output #0, hls, to
'/usr/local/ffmpeg/output/teszt12-A0737/500k/index_500k.m3u8':
Metadata:
encoder : Lavf57.40.101
Stream #0:0: Video: h264 (libx264), yuv420p, 384x216 [SAR 1:1 DAR
16:9], q=-1--1, 500 kb/s, 25 fps, 90k tbn, 25 tbc
Metadata:
encoder : Lavc57.48.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/500000 buffer size: 500000 vbv_delay: -1
Stream #0:1(hun): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16, 128
kb/s
Metadata:
encoder : Lavc57.48.101 libfdk_aac
Output #1, hls, to
'/usr/local/ffmpeg/output/teszt12-A0737/800k/index_800k.m3u8':
Metadata:
encoder : Lavf57.40.101
Stream #1:0: Video: h264 (libx264), yuv420p, 480x270 [SAR 1:1 DAR
16:9], q=-1--1, 800 kb/s, 25 fps, 90k tbn, 25 tbc
Metadata:
encoder : Lavc57.48.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/800000 buffer size: 800000 vbv_delay: -1
Stream #1:1(hun): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16, 128
kb/s
Metadata:
encoder : Lavc57.48.101 libfdk_aac
Output #2, hls, to
'/usr/local/ffmpeg/output/teszt12-A0737/1200k/index_1200k.m3u8':
Metadata:
encoder : Lavf57.40.101
Stream #2:0: Video: h264 (libx264), yuv420p, 640x360 [SAR 1:1 DAR
16:9], q=-1--1, 1200 kb/s, 25 fps, 90k tbn, 25 tbc
Metadata:
encoder : Lavc57.48.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/1200000 buffer size: 1200000 vbv_delay:
-1
Stream #2:1(hun): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16, 128
kb/s
Metadata:
encoder : Lavc57.48.101 libfdk_aac
Output #3, hls, to
'/usr/local/ffmpeg/output/teszt12-A0737/1500k/index_1500k.m3u8':
Metadata:
encoder : Lavf57.40.101
Stream #3:0: Video: h264 (libx264), yuv420p, 640x360 [SAR 1:1 DAR
16:9], q=-1--1, 1500 kb/s, 25 fps, 90k tbn, 25 tbc
Metadata:
encoder : Lavc57.48.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/1500000 buffer size: 1500000 vbv_delay:
-1
Stream #3:1(hun): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16, 128
kb/s
Metadata:
encoder : Lavc57.48.101 libfdk_aac
Output #4, hls, to
'/usr/local/ffmpeg/output/teszt12-A0737/2000k/index_2000k.m3u8':
Metadata:
encoder : Lavf57.40.101
Stream #4:0: Video: h264 (libx264), yuv420p, 1024x576 [SAR 1:1 DAR
16:9], q=-1--1, 2000 kb/s, 25 fps, 90k tbn, 25 tbc
Metadata:
encoder : Lavc57.48.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/2000000 buffer size: 2000000 vbv_delay:
-1
Stream #4:1(hun): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16, 128
kb/s
Metadata:
encoder : Lavc57.48.101 libfdk_aac
Output #5, hls, to
'/usr/local/ffmpeg/output/teszt12-A0737/2500k/index_2500k.m3u8':
Metadata:
encoder : Lavf57.40.101
Stream #5:0: Video: h264 (libx264), yuv420p, 1280x720 [SAR 1:1 DAR
16:9], q=-1--1, 2500 kb/s, 25 fps, 90k tbn, 25 tbc
Metadata:
encoder : Lavc57.48.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/2500000 buffer size: 2500000 vbv_delay:
-1
Stream #5:1(hun): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16, 128
kb/s
Metadata:
encoder : Lavc57.48.101 libfdk_aac
Stream mapping:
Stream #0:0 -> #0:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (mp2 (native) -> aac (libfdk_aac))
Stream #0:0 -> #1:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:1 -> #1:1 (mp2 (native) -> aac (libfdk_aac))
Stream #0:0 -> #2:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:1 -> #2:1 (mp2 (native) -> aac (libfdk_aac))
Stream #0:0 -> #3:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:1 -> #3:1 (mp2 (native) -> aac (libfdk_aac))
Stream #0:0 -> #4:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:1 -> #4:1 (mp2 (native) -> aac (libfdk_aac))
Stream #0:0 -> #5:0 (mpeg2video (native) -> h264 (libx264))
Stream #0:1 -> #5:1 (mp2 (native) -> aac (libfdk_aac))
Press [q] to stop, [?] for help
frame= 17 fps=0.0 q=0.0 q=0.0 q=0.0 q=0.0 q=0.0 q=0.0 size=N/A
time=00:00:00.29 bitrate=N/A speed=0.581x
frame= 32 fps= 31 q=0.0 q=0.0 q=0.0 q=0.0 q=0.0 q=0.0 size=N/A
time=00:00:00.83 bitrate=N/A speed=0.807x
[...]
frame= 580 fps= 19 q=27.0 q=27.0 q=28.0 q=26.0 q=31.0 q=32.0 size=N/A
time=00:00:22.74 bitrate=N/A speed=0.762x
frame= 595 fps= 20 q=28.0 q=27.0 q=28.0 q=26.0 q=31.0 q=32.0 size=N/A
time=00:00:23.23 bitrate=N/A speed=0.765x
frame= 606 fps= 20 q=28.0 q=27.0 q=28.0 q=27.0 q=32.0 q=32.0 size=N/A
time=00:00:23.82 bitrate=N/A speed=0.772x
frame= 619 fps= 20 q=27.0 q=27.0 q=28.0 q=26.0 q=30.0 q=32.0 size=N/A
time=00:00:24.34 bitrate=N/A speed=0.776x
frame= 632 fps= 20 q=26.0 q=25.0 q=27.0 q=25.0 q=28.0 q=29.0 size=N/A
time=00:00:24.81 bitrate=N/A speed=0.778x
frame= 641 fps= 20 q=28.0 q=27.0 q=28.0 q=26.0 q=31.0 q=32.0 size=N/A
time=00:00:25.70 bitrate=N/A speed=0.793x
frame= 644 fps= 18 q=-1.0 Lq=-1.0 q=-1.0 q=-1.0 q=-1.0 q=-1.0 size=N/A
time=00:00:25.79 bitrate=N/A speed=0.714x
video:21450kB audio:2423kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: unknown
[libx264 @ 0x29149a0] frame I:3 Avg QP:23.04 size: 6160
[...]
[libx264 @ 0x292cdc0] ref B L1: 98.7% 1.3%
[libx264 @ 0x292cdc0] kb/s:1996.25
Cheers,
Zsolt
More information about the ffmpeg-user
mailing list