We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpVideo Capture,  Movie Playback,  Vision Libraries › displaying webcam image realtime with lager window
Page Index Toggle Pages: 1
displaying webcam image realtime with lager window (Read 728 times)
displaying webcam image realtime with lager window
Jan 25th, 2006, 6:54am
 
hi,this is my first posting and i think this is basic  question.

now i'm using video library reference page's video capture code to display webcam image realtime.and finally i want to display it on multimonitor.

when i use The size() function and set display window 200*200, displayed movie speed was smooth.but when i set display window 800*800 displayed movie became too slow and choppy without any image processing.

is there any way to improve displaying speed of webcam realtime with larger window size?

my system is P5v102, QT6 and WVdig1.0.1.
Re: displaying webcam image realtime with lager wi
Reply #1 - Jan 25th, 2006, 6:29pm
 
A faster computer. Wink

The problem is you're pumping 2 and a half megabytes of data each frame when you try to do 800x800 video.  And you're not using any hardware acceleration.  On top of that, unless you have a fancy camera, the actual resolution of the webcam is only 320x240, or maybe 640x480 if you're lucky (although many 640x480 webcams drop to a lower framerate at that resolution).

So what's happening is the computer is now scaling your 320x240 or 640x480 source to 800x800, which also takes a huge hit on the CPU, then you're transferring that 2.5MB image to the screen.  It all adds up.

What you might want to consider doing is setting your webcam to 320x240, then using opengl and image scaling to draw the image larger (it won't add any more detail, but if you have a good video card, you'll get scaling of that 320x240 image to pretty much any window size for "free").

Marcello
Re: displaying webcam image realtime with lager wi
Reply #2 - Jan 26th, 2006, 4:35pm
 
i could make it work well thanks to cello's advice.
thank you so much.
Page Index Toggle Pages: 1