[FFmpeg-trac] #7221(ffmpeg:new): V4l2 fails when attempting a second capture
FFmpeg
trac at avcodec.org
Sat May 19 22:23:42 EEST 2018
#7221: V4l2 fails when attempting a second capture
----------------------------------+---------------------------------------
Reporter: andrelcm | Type: defect
Status: new | Priority: normal
Component: ffmpeg | Version: unspecified
Keywords: | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
----------------------------------+---------------------------------------
I am trying to capture video using this card: https://www.ebay.com/itm
/1080P-60FPS-USB-3-0-HD-HDMI-Video-Capture-Card-Box-for-Windows-Mac-
Linux-/263257786337?hash=item3d4b6307e1
The kernel driver is uvcvideo. The first capture is ok, everything works
fine, but the second attempt fails with this information: Dequeued v4l2
buffer contains corrupted data (0 bytes). Then, only audio is captured.
Using VLC, I can watch video from it no matter how many times I reopen the
program.
I can successfully capture video again if I reload the module with the
command bellow:
{{{
sudo modprobe -v -r uvcvideo && sudo modprobe -v uvcvideo
}}}
Or if I reser the card with this:
{{{
echo 0 > /sys/bus/usb/devices/4-3/authorized
echo 1 > /sys/bus/usb/devices/4-3/authorized
}}}
Here the output of ffmpeg:
{{{
ffmpeg version N-91127-g411f7141a3 Copyright (c) 2000-2018 the FFmpeg
developers
built with gcc 7 (Ubuntu 7.3.0-16ubuntu3)
configuration: --enable-nonfree --disable-shared --enable-nvenc
--enable-cuda --enable-cuvid --enable-pthreads --extra-
cflags=-I/usr/local/cuda-9.0/include --extra-
ldflags=-L/usr/local/cuda-9.0/lib64
libavutil 56. 18.102 / 56. 18.102
libavcodec 58. 19.102 / 58. 19.102
libavformat 58. 15.100 / 58. 15.100
libavdevice 58. 4.100 / 58. 4.100
libavfilter 7. 24.100 / 7. 24.100
libswscale 5. 2.100 / 5. 2.100
libswresample 3. 2.100 / 3. 2.100
Guessed Channel Layout for Input Stream #0.0 : stereo
Input #0, alsa, from 'hw:2,0':
Duration: N/A, start: 1526757005.217295, bitrate: 1536 kb/s
Stream #0:0: Audio: pcm_s16le, 48000 Hz, stereo, s16, 1536 kb/s
[video4linux2,v4l2 @ 0x5646abe4c400] Dequeued v4l2 buffer contains
corrupted data (0 bytes).
Input #1, video4linux2,v4l2, from '/dev/video0':
Duration: N/A, start: 0.000000, bitrate: 995328 kb/s
Stream #1:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 1920x1080,
995328 kb/s, 30 fps, 30 tbr, 1000k tbn, 1000k tbc
Stream mapping:
Stream #1:0 -> #0:0 (rawvideo (native) -> h264 (h264_nvenc))
Stream #0:0 -> #0:1 (pcm_s16le (native) -> aac (native))
Press [q] to stop, [?] for help
[video4linux2,v4l2 @ 0x5646abe4c400] Dequeued v4l2 buffer contains
corrupted data (0 bytes).
Last message repeated 30 times
Output #0, mpegts, to '/tmp/out.ts':
Metadata:
encoder : Lavf58.15.100
Stream #0:0: Video: h264 (h264_nvenc) (High 4:4:4 Predictive),
yuv444p(progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=19-50, 8000 kb/s, 30
fps, 90k tbn, 30 tbc
Metadata:
encoder : Lavc58.19.102 h264_nvenc
Side data:
cpb: bitrate max/min/avg: 12000000/0/8000000 buffer size: 16000000
vbv_delay: -1
Stream #0:1: Audio: aac (LC), 48000 Hz, stereo, fltp, 128 kb/s
Metadata:
encoder : Lavc58.19.102 aac
frame= 3 fps=0.0 q=21.0 size= 10kB time=00:18:06.70 bitrate=
0.1kbits/
frame= 3 fps=3.0 q=21.0 size= 19kB time=00:18:06.70 bitrate=
0.1kbits/
frame= 3 fps=2.0 q=21.0 size= 28kB time=00:18:06.70 bitrate=
0.2kbits/
frame= 3 fps=2.0 q=21.0 Lsize= 182kB time=00:18:06.76 bitrate=
1.4kbits/s speed= 709x
}}}
--
Ticket URL: <https://trac.ffmpeg.org/ticket/7221>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list