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 › Creating graphics using motion detection
Page Index Toggle Pages: 1
Creating graphics using motion detection? (Read 2288 times)
Creating graphics using motion detection?
Dec 7th, 2006, 8:44pm
 
Just wondered if there was any way you can use blobDetection or JMyron to capture motion and translate the motion into graphics (not live feed). For example like what Robert Hodgin does with  ripples (http://www.flight404.com/vj/exhibit.html) but using blob detection to capture movement and create visuals instead of using Sonia to create visuals when sound is input.

For example, capturing your hand drawing invisible letters in the air then the letters actually being visualised on screen but showing no live feed, just the graphics.
Or in the case of Ripples, moving your hand fast to increase the size of the ripples.

Would be much appreciated if someone could point me in the right direction, I've been constantly searching and scratching my head trying to figure out if this can actually be achieved.
Re: Creating graphics using motion detection?
Reply #1 - Dec 7th, 2006, 9:14pm
 
If you don't know what you're doing I wouldn't worry about capturing individual objects, that's something of a fine art. Interpreting the visual data abstractly is much easier.

http://www.neilwallis.com/java/water.html

You could measure the difference between one video and the frame and the next and translate that into the ripples. The formula I think is:

1stFramePixel^2ndFramePixel = difference;

When you're ready to move on to hardier things you might try reacTIVision or the libraries. Try not to get fustrated though (I tried using two web-cams to do motion capture - a term of wasted work, but a lesson well learned).
Re: Creating graphics using motion detection?
Reply #2 - Dec 17th, 2006, 6:28pm
 
Thanks for that, I was hoping to use two cameras to detect movement but I can understand what you mean. Still having a little trouble as I'm not the most skilled coder in the world and I'm still quite new to processing.

Does anyone know if there any good examples of source code I could look at for a bit of help with this? I've searched my arse off but had no luck.
Re: Creating graphics using motion detection?
Reply #3 - May 22nd, 2007, 2:58am
 
I've been trying to get this water effect to follow the difference between frames instead of the mouse cursor, while maintaining the esthetic.  I haven't had much luck.  Does anyone have any tips for translating the mousetracking to motion tracking?  I'm... well, lost.  Thanks.

P.S.  I have some very bad code written, if anyone thinks that would help this topic, i'd post.
Re: Creating graphics using motion detection?
Reply #4 - May 22nd, 2007, 10:36am
 
Java ripple in Processing code

The ripple is caused by a height map. There is a fuction in the program loop that pushes against the height map where the mouse cursor is. Track down that function in the code above and you'll begin to understand how the ripple works.

All you have to do then is get the difference between frames on the web cam and use that instead as the data to push against the height map.
Page Index Toggle Pages: 1