I found that in linux you can use video4linux2 and ffmpeg to read the data from /dev/video0 and grab the video from webcam. ffmpeg output the data to a video file, which has a limited length. My question is:
Can I pipe the the video stream both to remote viewer and to a local program so that I can keep processing the stream data in real time?
Thanks.
ffmpeg -f v4l2 -i /dev/video0