kingdompopla.blogg.se

Streaming video capture
Streaming video capture











  1. Streaming video capture 720p#
  2. Streaming video capture 1080p#
  3. Streaming video capture software#

This transcoding was taxing the power of the processor and the bandwidth for storage and memory. The camera was outputting a raw video feed that the Pi was then turning into mpeg4, which is more common. The biggest issue I was having on the Pi was limited power being dedicated to trying to transcode my incoming video stream to something I felt was more usable. My eventual ‘eureka’ moment came late on a Thursday night fueled by caffeine and good music. Make sure to use the ‘make -j4’ command to fully utilize the Pi’s four cores or you will be waiting quite a bit longer. If you do choose to compile locally, it won’t take hours, but it is enough time to go and get a cup of coffee and have a chat with someone. Compiling ffmpeg on the Raspberry Pi has typically been discouraged since compiling code can take a lot of work, but from my experience and when you take into account the four core processor of the Raspberry Pi 3, it is certainly reasonable to compile ffmpeg locally with many options. I began recompiling ffmpeg with different codecs for audio and video to test. I picked ‘dive deeper’ because I like the challenge and I thought the Pi would be able to do more. I was disappointed in my little workhorse Pi but was not ready to give up completely.Īt this point, I could choose to move to a different computer with extra power or dive deeper. Moving to WVGA format (which is 854x480), I finally got the consistent 30 frames per second I was looking for, but the video quality left a lot to be desired, and for image recognition, the more pixels the better.

Streaming video capture 720p#

I scaled back to 720p and saw some improvement to 14 frames per second, but this was still not worthwhile. When I went and looked at the results, I was getting about 6.6 frames per second, resulting in choppy and unusable video for streaming our lab or doing 3D object creation.

Streaming video capture 1080p#

Using ffmpeg to capture video from the USB webcam to an AVI file had poor results – the Raspberry Pi would hit about 50% cpu usage and had no hope of capturing 1080p video at a reasonable 30 frames per second.

Streaming video capture software#

While the Raspberry Pi comes with some software built in for capturing video like Streamer, I chose to go down a different path and work to utilize FFmpeg, which has a wide community following and a lot of options for different encoders, giving me flexibility and a ton of examples to get started from. Initially, I was just researching everything I could regarding video capture and settled on trying to work with a USB webcam I had on hand, the Logitech C920, as well as trying to implement the NoIR Pi Camera that we had used in our Fridge Defender project. If I could get this little single board computer to perform these tasks it would really free up more powerful machines, plus it would be a cool demo, but I was wondering if the board really had the horsepower to pull it off. These are both fun projects, and since we had a bunch of Raspberry Pi 3’s on hand, I decided to use one and see if I could make it capture a bunch of video feeds or turn it into an effective streaming device so I didn’t have to kidnap our video guy’s more powerful laptop. Embedded System Development Boards and Kits













Streaming video capture