[FFmpeg-user] Is FFV1 able to encode interlaced video?
MrNice
wxcvbn2006 at iol.ie
Sun Aug 9 17:09:09 CEST 2015
On 09/08/15 15:54, Paul B Mahol wrote:
> Dana 9. 8. 2015. 15:31 osoba "MrNice" <wxcvbn2006 at iol.ie> napisala je:
>>
>> Hi
>>
>> From an interlaced input (video tape) is it possible to capture
>> interlaced video file encoded with FFV1 (using -flags +ilme+ildct)?
>>
>> I can't find an answer after long search.
>> All my captures seem to be converted to progressive.
>
> With what command?
>
>>
>> Thanks
>> _______________________________________________
>> ffmpeg-user mailing list
>> ffmpeg-user at ffmpeg.org
>> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
I use the following command.
I am not sure if the output file is interlaced because mediainfo says
nothing about that for FFV1 encoder.
./ffmpeg -debug 1 -f pulse -ar 44100 -ac 2 -channel_layout stereo
-thread_queue_size 512 -i alsa_input.pci-0000_00_14.2.analog-stereo -f
v4l2 -ts mono2abs -channel 1 -video_size 720x576 -pix_fmt yuyv422
-thread_queue_size 512 -i /dev/video0 -c:v ffv1 -level 3 -flags
+ilme+ildct -aspect 4:3 -pix_fmt yuv422p -c:a pcm_s16le
/Store3/Test/t_`date +%Y%m%d_%H%M`.mkv -aspect 4:3 -f sdl "Dazzle output"
ffmpeg version N-74246-ga0044be Copyright (c) 2000-2015 the FFmpeg
developers
built with gcc 5.1.1 (GCC) 20150618 (Red Hat 5.1.1-4)
configuration: --enable-libpulse --enable-gpl --enable-libx264
libavutil 54. 30.100 / 54. 30.100
libavcodec 56. 56.101 / 56. 56.101
libavformat 56. 40.101 / 56. 40.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 32.100 / 5. 32.100
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.101 / 1. 2.101
libpostproc 53. 3.100 / 53. 3.100
matched as AVOption 'debug' with argument '1'.
Reading option '-f' ... matched as option 'f' (force format) with
argument 'pulse'.
Reading option '-ar' ... matched as option 'ar' (set audio sampling rate
(in Hz)) with argument '44100'.
Reading option '-ac' ... matched as option 'ac' (set number of audio
channels) with argument '2'.
Reading option '-channel_layout' ... matched as option 'channel_layout'
(set channel layout) with argument 'stereo'.
Reading option '-thread_queue_size' ... matched as option
'thread_queue_size' (set the maximum number of queued packets from the
demuxer) with argument '512'.
Reading option '-i' ... matched as input file with argument
'alsa_input.pci-0000_00_14.2.analog-stereo'.
Reading option '-f' ... matched as option 'f' (force format) with
argument 'v4l2'.
Reading option '-ts' ... matched as AVOption 'ts' with argument 'mono2abs'.
Reading option '-channel' ... matched as AVOption 'channel' with
argument '1'.
Reading option '-video_size' ... matched as AVOption 'video_size' with
argument '720x576'.
Reading option '-pix_fmt' ... matched as option 'pix_fmt' (set pixel
format) with argument 'yuyv422'.
Reading option '-thread_queue_size' ... matched as option
'thread_queue_size' (set the maximum number of queued packets from the
demuxer) with argument '512'.
Reading option '-i' ... matched as input file with argument '/dev/video0'.
Reading option '-c:v' ... matched as option 'c' (codec name) with
argument 'ffv1'.
Reading option '-level' ... matched as AVOption 'level' with argument '3'.
Reading option '-flags' ... matched as AVOption 'flags' with argument
'+ilme+ildct'.
Reading option '-aspect' ... matched as option 'aspect' (set aspect
ratio (4:3, 16:9 or 1.3333, 1.7777)) with argument '4:3'.
Reading option '-pix_fmt' ... matched as option 'pix_fmt' (set pixel
format) with argument 'yuv422p'.
Reading option '-c:a' ... matched as option 'c' (codec name) with
argument 'pcm_s16le'.
Reading option '/Store3/Test/t_20150809_1557.mkv' ... matched as output
file.
Reading option '-aspect' ... matched as option 'aspect' (set aspect
ratio (4:3, 16:9 or 1.3333, 1.7777)) with argument '4:3'.
Reading option '-f' ... matched as option 'f' (force format) with
argument 'sdl'.
Reading option 'Dazzle output' ... matched as output file.
Finished splitting the commandline.
Parsing a group of options: global .
Successfully parsed a group of options.
Parsing a group of options: input file
alsa_input.pci-0000_00_14.2.analog-stereo.
Applying option f (force format) with argument pulse.
Applying option ar (set audio sampling rate (in Hz)) with argument 44100.
Applying option ac (set number of audio channels) with argument 2.
Applying option channel_layout (set channel layout) with argument stereo.
Applying option thread_queue_size (set the maximum number of queued
packets from the demuxer) with argument 512.
Successfully parsed a group of options.
Opening an input file: alsa_input.pci-0000_00_14.2.analog-stereo.
[pulse @ 0x23c3be0] All info found
Input #0, pulse, from 'alsa_input.pci-0000_00_14.2.analog-stereo':
Duration: N/A, start: 1439132278.249945, bitrate: 1411 kb/s
Stream #0:0, 1, 1/1000000: Audio: pcm_s16le, 44100 Hz, stereo, s16,
1411 kb/s
Successfully opened the file.
Parsing a group of options: input file /dev/video0.
Applying option f (force format) with argument v4l2.
Applying option pix_fmt (set pixel format) with argument yuyv422.
Applying option thread_queue_size (set the maximum number of queued
packets from the demuxer) with argument 512.
Successfully parsed a group of options.
Opening an input file: /dev/video0.
[video4linux2,v4l2 @ 0x23dcd80] fd:6 capabilities:85220001
[video4linux2,v4l2 @ 0x23dcd80] Selecting input_channel: 1
[video4linux2,v4l2 @ 0x23dcd80] Current input_channel: 1, input_name:
S-Video, input_std: ffffff
[video4linux2,v4l2 @ 0x23dcd80] The V4L2 driver is using the interlaced mode
[video4linux2,v4l2 @ 0x23dcd80] Current standard: PAL, id: ff,
frameperiod: 1/25
[video4linux2,v4l2 @ 0x23dcd80] Detected monotonic timestamps, converting
[video4linux2,v4l2 @ 0x23dcd80] All info found
Input #1, video4linux2,v4l2, from '/dev/video0':
Duration: N/A, start: 1439132279.417242, bitrate: 165888 kb/s
Stream #1:0, 1, 1/1000000: Video: rawvideo, 1 reference frame (YUY2
/ 0x32595559), yuyv422, 720x576, 1/1000000, 165888 kb/s, 25 fps, 25 tbr,
1000k tbn, 1000k tbc
Successfully opened the file.
Parsing a group of options: output file /Store3/Test/t_20150809_1557.mkv.
Applying option c:v (codec name) with argument ffv1.
Applying option aspect (set aspect ratio (4:3, 16:9 or 1.3333, 1.7777))
with argument 4:3.
Applying option pix_fmt (set pixel format) with argument yuv422p.
Applying option c:a (codec name) with argument pcm_s16le.
Successfully parsed a group of options.
Opening an output file: /Store3/Test/t_20150809_1557.mkv.
Successfully opened the file.
Parsing a group of options: output file Dazzle output.
Applying option aspect (set aspect ratio (4:3, 16:9 or 1.3333, 1.7777))
with argument 4:3.
Applying option f (force format) with argument sdl.
Successfully parsed a group of options.
Opening an output file: Dazzle output.
Successfully opened the file.
detected 8 logical cores
[graph 0 input from stream 1:0 @ 0x23b0220] Setting 'video_size' to
value '720x576'
[graph 0 input from stream 1:0 @ 0x23b0220] Setting 'pix_fmt' to value '1'
[graph 0 input from stream 1:0 @ 0x23b0220] Setting 'time_base' to value
'1/1000000'
[graph 0 input from stream 1:0 @ 0x23b0220] Setting 'pixel_aspect' to
value '0/1'
[graph 0 input from stream 1:0 @ 0x23b0220] Setting 'sws_param' to value
'flags=2'
[graph 0 input from stream 1:0 @ 0x23b0220] Setting 'frame_rate' to
value '25/1'
[graph 0 input from stream 1:0 @ 0x23b0220] w:720 h:576 pixfmt:yuyv422
tb:1/1000000 fr:25/1 sar:0/1 sws_param:flags=2
[format @ 0x23a5580] compat: called with args=[yuv422p]
[format @ 0x23a5580] Setting 'pix_fmts' to value 'yuv422p'
[auto-inserted scaler 0 @ 0x23a58e0] Setting 'flags' to value '0x4'
[auto-inserted scaler 0 @ 0x23a58e0] w:iw h:ih flags:'0x4' interl:0
[format @ 0x23a5580] auto-inserting filter 'auto-inserted scaler 0'
between the filter 'Parsed_null_0' and the filter 'format'
[AVFilterGraph @ 0x239ba40] query_formats: 4 queried, 2 merged, 1
already done, 0 delayed
[auto-inserted scaler 0 @ 0x23a58e0] w:720 h:576 fmt:yuyv422 sar:0/1 ->
w:720 h:576 fmt:yuv422p sar:0/1 flags:0x4
[graph 1 input from stream 0:0 @ 0x23b2a20] Setting 'time_base' to value
'1/44100'
[graph 1 input from stream 0:0 @ 0x23b2a20] Setting 'sample_rate' to
value '44100'
[graph 1 input from stream 0:0 @ 0x23b2a20] Setting 'sample_fmt' to
value 's16'
[graph 1 input from stream 0:0 @ 0x23b2a20] Setting 'channel_layout' to
value '0x3'
[graph 1 input from stream 0:0 @ 0x23b2a20] tb:1/44100 samplefmt:s16
samplerate:44100 chlayout:0x3
[audio format for output stream 0:1 @ 0x2396520] Setting 'sample_fmts'
to value 's16'
[AVFilterGraph @ 0x239bc60] query_formats: 4 queried, 9 merged, 0
already done, 0 delayed
[graph 2 input from stream 1:0 @ 0x2397560] Setting 'video_size' to
value '720x576'
[graph 2 input from stream 1:0 @ 0x2397560] Setting 'pix_fmt' to value '1'
[graph 2 input from stream 1:0 @ 0x2397560] Setting 'time_base' to value
'1/1000000'
[graph 2 input from stream 1:0 @ 0x2397560] Setting 'pixel_aspect' to
value '0/1'
[graph 2 input from stream 1:0 @ 0x2397560] Setting 'sws_param' to value
'flags=2'
[graph 2 input from stream 1:0 @ 0x2397560] Setting 'frame_rate' to
value '25/1'
[graph 2 input from stream 1:0 @ 0x2397560] w:720 h:576 pixfmt:yuyv422
tb:1/1000000 fr:25/1 sar:0/1 sws_param:flags=2
[AVFilterGraph @ 0x2398ca0] query_formats: 3 queried, 2 merged, 0
already done, 0 delayed
[sdl @ 0x23f3980] w:720 h:576 fmt:yuyv422 -> w:720 h:540
Output #0, matroska, to '/Store3/Test/t_20150809_1557.mkv':
Metadata:
encoder : Lavf56.40.101
Stream #0:0, 0, 1/1000: Video: ffv1, 1 reference frame (FFV1 /
0x31564646), yuv422p, 720x576 [SAR 16:15 DAR 4:3], 1/25, q=2-31, 200
kb/s, 25 fps, 1k tbn, 25 tbc
Metadata:
encoder : Lavc56.56.101 ffv1
Stream #0:1, 0, 1/1000: Audio: pcm_s16le ([1][0][0][0] / 0x0001),
44100 Hz, stereo, s16, 1411 kb/s
Metadata:
encoder : Lavc56.56.101 pcm_s16le
Output #1, sdl, to 'Dazzle output':
Metadata:
encoder : Lavf56.40.101
Stream #1:0, 0, 1/25: Video: rawvideo, 1 reference frame (YUY2 /
0x32595559), yuyv422, 720x576 [SAR 16:15 DAR 4:3], 1/25, q=2-31, 200
kb/s, 25 fps, 25 tbn, 25 tbc
Metadata:
encoder : Lavc56.56.101 rawvideo
Stream mapping:
Stream #1:0 -> #0:0 (rawvideo (native) -> ffv1 (native))
Stream #0:0 -> #0:1 (pcm_s16le (native) -> pcm_s16le (native))
Stream #1:0 -> #1:0 (rawvideo (native) -> rawvideo (native))
Press [q] to stop, [?] for help
Cliping frame in rate conversion by 0.000008
[matroska @ 0x23de880] Writing block at offset 829, size 131672, pts 0,
dts 0, duration 40, keyframe 1
[matroska @ 0x23de880] Writing block at offset 132509, size 65472, pts
0, dts 0, duration 371, keyframe 1
[matroska @ 0x23de880] Writing block at offset 197989, size 133198, pts
40, dts 40, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000069
[matroska @ 0x23de880] Writing block at offset 331195, size 135909, pts
80, dts 80, duration 40, keyframe 0
[matroska @ 0x23de880] Writing block at offset 467112, size 136589, pts
120, dts 120, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000313
[matroska @ 0x23de880] Writing block at offset 603709, size 137930, pts
160, dts 160, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000389
[matroska @ 0x23de880] Writing block at offset 741647, size 137107, pts
200, dts 200, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000542
[matroska @ 0x23de880] Writing block at offset 878762, size 136794, pts
240, dts 240, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000237
[matroska @ 0x23de880] Writing block at offset 1015564, size 136679, pts
280, dts 280, duration 40, keyframe 0
[matroska @ 0x23de880] Writing block at offset 1152251, size 135640, pts
320, dts 320, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001015
[matroska @ 0x23de880] Writing block at offset 1287899, size 136043, pts
360, dts 360, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001091
[matroska @ 0x23de880] Writing block at offset 1423950, size 46468, pts
371, dts 371, duration 263, keyframe 1
[matroska @ 0x23de880] Writing block at offset 1470426, size 134836, pts
400, dts 400, duration 40, keyframe 0
[matroska @ 0x23de880] Writing block at offset 1605270, size 136652, pts
440, dts 440, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000893
[matroska @ 0x23de880] Starting new cluster at offset 1741930 bytes, pts
480dts 480
[matroska @ 0x23de880] Writing block at offset 1741946, size 137090, pts
480, dts 480, duration 40, keyframe 1
Cliping frame in rate conversion by 0.001472
[matroska @ 0x23de880] Writing block at offset 1879044, size 134607, pts
520, dts 520, duration 40, keyframe 0
[matroska @ 0x23de880] Writing block at offset 2013659, size 134527, pts
560, dts 560, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001839098kB time=00:00:01.00
bitrate=17100.1kbits/s
[matroska @ 0x23de880] Writing block at offset 2148194, size 133442, pts
600, dts 600, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001793
[matroska @ 0x23de880] Writing block at offset 2281644, size 65472, pts
634, dts 634, duration 371, keyframe 1
[matroska @ 0x23de880] Writing block at offset 2347124, size 134538, pts
640, dts 640, duration 40, keyframe 0
Cliping frame in rate conversion by 0.002037
[matroska @ 0x23de880] Writing block at offset 2481670, size 133848, pts
680, dts 680, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001915
[matroska @ 0x23de880] Writing block at offset 2615526, size 134192, pts
720, dts 720, duration 40, keyframe 0
Cliping frame in rate conversion by 0.000313
[matroska @ 0x23de880] Writing block at offset 2749726, size 133302, pts
760, dts 760, duration 40, keyframe 0
Cliping frame in rate conversion by 0.002388
[matroska @ 0x23de880] Writing block at offset 2883036, size 132872, pts
800, dts 800, duration 40, keyframe 0
Cliping frame in rate conversion by 0.002693
[matroska @ 0x23de880] Writing block at offset 3015916, size 134320, pts
840, dts 840, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001320
[matroska @ 0x23de880] Writing block at offset 3150244, size 133214, pts
880, dts 880, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001167
[matroska @ 0x23de880] Writing block at offset 3283466, size 132882, pts
920, dts 920, duration 40, keyframe 0
Cliping frame in rate conversion by 0.003014
[matroska @ 0x23de880] Starting new cluster at offset 3416356 bytes, pts
960dts 960
[matroska @ 0x23de880] Writing block at offset 3416372, size 134532, pts
960, dts 960, duration 40, keyframe 1
Cliping frame in rate conversion by 0.000847
[matroska @ 0x23de880] Writing block at offset 3550912, size 134423, pts
1000, dts 1000, duration 40, keyframe 0
Cliping frame in rate conversion by 0.003044
[matroska @ 0x23de880] Writing block at offset 3685343, size 41540, pts
1005, dts 1005, duration 235, keyframe 1
[matroska @ 0x23de880] Writing block at offset 3726891, size 133873, pts
1040, dts 1040, duration 40, keyframe 0
Cliping frame in rate conversion by 0.003349
[matroska @ 0x23de880] Writing block at offset 3860772, size 135127, pts
1080, dts 1080, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001549902kB time=00:00:01.61
bitrate=19830.8kbits/s
[matroska @ 0x23de880] Writing block at offset 3995907, size 134884, pts
1120, dts 1120, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001747
[matroska @ 0x23de880] Writing block at offset 4130799, size 135281, pts
1160, dts 1160, duration 40, keyframe 0
Cliping frame in rate conversion by 0.003822
[matroska @ 0x23de880] Writing block at offset 4266088, size 135642, pts
1200, dts 1200, duration 40, keyframe 0
Cliping frame in rate conversion by 0.001747
[matroska @ 0x23de880] Writing block at offset 4401738, size 135418, pts
1240, dts 1240, duration 40, keyframe 0
Cliping frame in rate conversion by 0.004112
av_interleaved_write_frame(): Input/output error
No more output streams to write to, finishing.
[matroska @ 0x23de880] Writing block at offset 4537164, size 65472, pts
1241, dts 1241, duration 371, keyframe 1
[matroska @ 0x23de880] Writing block at offset 4602644, size 134772, pts
1280, dts 1280, duration 40, keyframe 0
[matroska @ 0x23de880] end duration = 1612
frame= 33 fps= 17 q=-0.0 Lq=-0.0 size= 4626kB time=00:00:01.61
bitrate=23511.1kbits/s
video:31077kB audio:278kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: unknown
Input file #0 (alsa_input.pci-0000_00_14.2.analog-stereo):
Input stream #0:0 (audio): 5 packets read (284424 bytes); 5 frames
decoded (71106 samples);
Total: 5 packets (284424 bytes) demuxed
Input file #1 (/dev/video0):
Input stream #1:0 (video): 33 packets read (27371520 bytes); 33 frames
decoded;
Total: 33 packets (27371520 bytes) demuxed
Output file #0 (/Store3/Test/t_20150809_1557.mkv):
Output stream #0:0 (video): 33 frames encoded; 33 packets muxed
(4451835 bytes);
Output stream #0:1 (audio): 5 frames encoded (71106 samples); 5
packets muxed (284424 bytes);
Total: 38 packets (4736259 bytes) muxed
Output file #1 (Dazzle output):
Output stream #1:0 (video): 33 frames encoded; 33 packets muxed
(27371520 bytes);
Total: 33 packets (27371520 bytes) muxed
38 frames successfully decoded, 0 decoding errors
[AVIOContext @ 0x23eb660] Statistics: 36 seeks, 199 writeouts
Conversion failed!
More information about the ffmpeg-user
mailing list