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.
Page Index Toggle Pages: 1
FYI CaptureEvent() and draw() (Read 530 times)
FYI CaptureEvent() and draw()
Jan 18th, 2010, 2:18am
 
This is explained in more complex terms at "Problems with Video" section of the video library docs, but:

I was writing a script that kept on getting unpredictable errors of this type that I couldn't always reproduce:
Disabling captureEvent() for USB Video Class Video because of an error.

I was using captureEvent() obviously, and after two days of trying to find the problem I just copied everything from captureEvent() and pasted it into draw() and wrapped it all in an if(myCapture.available()) and suddenly everything worked.

Maybe this will save you some time.
Page Index Toggle Pages: 1