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 › Changing video capture size during runtime
Page Index Toggle Pages: 1
Changing video capture size during runtime (Read 824 times)
Changing video capture size during runtime
Aug 22nd, 2005, 9:26pm
 
I need to change the video size during runtime. When I set capture.width and capture.height parameters, video image gets weird and if I call Capture constructor during runtime
(camr = new Capture(this, cam, camWidth, camHeight, camFrameRate)Wink I get an error message (couldntGetRequiredComponent) and my applet crashes.

Is that impossible, or am I doing something wrong?
Re: Changing video capture size during runtime
Reply #1 - Aug 23rd, 2005, 12:28am
 
Do you need to change the actual amount of information being captured during runtime? Could you not to set it for maximum condition and then copy / scale it to a buffer as required?

The obvious being:

image(captureName, x, y, xsize, ysize);

I think trying to modify during runtime is a no no, could be wrong though!

But I'd guess that you'd need to somehow dispose of the current capture object before you could instantiate a new one at the very least, hence the error.
Page Index Toggle Pages: 1