I'm able to capture from my webcam using ffmpeg, but it's real color. But my webcam is advertised as having IR capability. How do I access this?
When I run ffmpeg -f v4l2 -list_formats all -i /dev/video0
I get this output:
Compressed: mjpeg : Motion-JPEG : 1280x720 640x360 640x480 848x480 960x540
Raw : yuyv422 : YUYV 4:2:2 : 160x120 320x180 320x240 424x240 640x360 640x480
The camera specs are given as video: 1280x720 at 30 fps, IR Video: 340x340 at 60 fps
Also, here is the output of v4l2-ctl --list-devices
:
Integrated_Webcam_HD: Integrate (usb-0000:00:14.0-11):
/dev/video0
/dev/video1
I thought maybe the Raw stream would contain the Infrared video stream, but when I run this:
ffplay -input_format yuyv422 -video_size 320x240 -i /dev/video0
The output looks identical to the 1280x720 output except smaller.
I also ran ffmpeg -f v4l2 -list_formats all -i /dev/video1
and got this output:
Raw : Unsupported : 00000032-0002-0010-8000-00aa003 : 640x360
But I don't seem to be able to play anything from this device, I get:
Cannot find a proper format for codec 'none' (id 0), pixel format 'none' (id -1)
Assertion *codec_id != AV_CODEC_ID_NONE failed at src/libavdevice/v4l2.c:811
How do I capture infrared video from the webcam?
0 Answers