I have confirmed that it is indeed possible to grab AND convert frames at 640x480 and 30 fps with the BBB and Logitech C920 operating in MJPEG mode. My solution was to basically install libjpeg-turbo from source with NEON enabled and then building and installing OpenCV from source, using libjpeg-turbo as the JPEG codec. I also built OpenCV with NEON enabled.
Here is sample output with every frame being processed. The 'top' utility shows about 50% CPU and only about 2% memory usage. Before executing the code, I set the CPU to operate at constant 1Ghz using "sudo cpufreq-set -g performance" so that there isn't a "slow start" while the BBB starts grabbing frames at 300 Mhz before it finally kicks into 1Ghz under load. time ./framegrabber -f mjpeg -H 480 -W 640 -c 1000 -I 30 -o Startup took 0.000000 seconds Captured 1000 frames and Processed 1000 in 13.940000 seconds Shutdown took 0.010000 seconds real 0m33.760s user 0m11.566s sys 0m2.518s I ended up using distcc to do a distributed cross-build of OpenCV on my PC, but still had problems with running out of space trying to store all of the source and object files on the 2GB eMMC on the BBB. I ended up having to mount an ext2 formatted filesystem using a USB thumb drive hooked up to the BBB and building OpenCV from there. I probably ended up doing a lot of extraneous things that had little to no effect but I do have a working process for those who need to get 30 fps. I need to go back and clean up some notes I took and then I plan to post a step-by-step guide for anybody else who wants to replicate what I did. Thanks, -Mike On Sat, Sep 21, 2013 at 4:48 PM, Matthew Witherwax <[email protected]>wrote: > Jon, > > I hope you find it useful. I would appreciate any feedback you have to > give. > > Best of luck, > Matthew > > > On Sat, Sep 21, 2013 at 4:54 AM, <[email protected]> wrote: > >> Matthew, >> >> Thanks! That may be really useful for me. Am messing around with a PTZ >> camera at the moment, and lag in the video stream has been a bit of a >> problem so far.. >> >> Regards, >> Jon >> >> >> On Friday, 20 September 2013 14:01:23 UTC+1, Matthew Witherwax wrote: >>> >>> William, >>> >>> I have posted my streaming code and writeup here >>> http://blog.lemoneerlabs.com/**post/bbb-mjpeg-streaming<http://blog.lemoneerlabs.com/post/bbb-mjpeg-streaming> >>> >>> >>> -- >> For more options, visit http://beagleboard.org/discuss >> --- >> You received this message because you are subscribed to a topic in the >> Google Groups "BeagleBoard" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/beagleboard/G5Xs2JuwD_4/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> [email protected]. >> For more options, visit https://groups.google.com/groups/opt_out. >> > > -- > For more options, visit http://beagleboard.org/discuss > --- > You received this message because you are subscribed to a topic in the > Google Groups "BeagleBoard" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/beagleboard/G5Xs2JuwD_4/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
