Velvet Star Monitor

Standout celebrity highlights with iconic style.

updates

ffmpeg command produces black image as output

Writer Emily Wong

OS details:

Output of cat /etc/os-release

0
Input #0, video4linux2,v4l2, from '/dev/video0':
Duration: N/A, start: 13555.753906, bitrate: 147456 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640x480, 147456 kb/s, 30 fps, 30 tbr, 1000k tbn, 1000k tbc
Stream mapping:
Stream #0:0 -> #0:0 (rawvideo (native) -> mjpeg (native))
Press [q] to stop, [?] for help [swscaler @ 0x55fd0eafa3e0] deprecated pixel format used, make sure you did set range correctly Output #0, image2, to 'test1.jpeg':
Metadata:
encoder : Lavf57.83.100
Stream #0:0: Video: mjpeg, yuvj422p(pc), 640x480, q=2-31, 200 kb/s, 30 fps, 30 tbn, 30 tbc
Metadata:
encoder : Lavc57.107.100 mjpeg
Side data:
cpb: bitrate max/min/avg: 0/0/200000 buffer size: 0 vbv_delay: -1
frame= 1 fps=0.0 q=1.6 Lsize=N/A time=00:00:00.03 bitrate=N/A speed=8.41x
video:3kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

Command I used :

ffmpeg -i /dev/video0 -vframes 1 test1.jpeg

It produces black jpeg image as output. Why? Please suggest ffmpeg command to get webcam image.

2 Reset to default

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy