ffmpeg-python
ffmpeg-python copied to clipboard
It is possible use this library to stream a local camera?
It is possible use this library to stream a local camera ( like /dev/video ) in a web page ( using flask or another webserver ) ?
any help? a simple example of how to stream /dev/video0 in h264 through a web page would be perfect
@blademckain I would not recommend trying this with ffmpeg - the part of the library that used to do this has been removed.
I think you'll have a lot easier time using something like https://github.com/mpromonet/v4l2rtspserver to provide an RTSP feed of a webcam.
That said, if you need to do some processing in the middle, you might use ffmpeg V4L support to read from the input and then output as a V4L device. I haven't played with this, as I don't have a Linux machine with a webcam at the moment.
An input parameter for ffmpeg to capture from local web camera is: -i video=My_web_cam_name. This parameter works at least in Windows. An attempt to use: ffmpeg.input('video=My_web_cam_name') raises error video="Unity Video Capture": Invalid argument.
How to read the local web camera with ffmpeg-python in Windows?