I've what seems like a simple request, how can I make a bouncing ball appear (and then disappear) by pressing a key? I've been able to create the bouncing balls but they appear when Processing starts. I'd like to be able to trigger them via different keys (ball 1 with the '1' key, ball 2 with '2' etc.).
I'm quite the beginner when it comes to Processing, Pure Data & programming in general but I have big(ish) ideas & would love some help on how to achieve these.
My plan is to combine Processing and Pure Data to form a sort of instrument or interactive noise maker. Visually/Processing-wise I want to combine OpenProcessing.org's user, BlueThen's, amazing sketch called 'Fluids' (found here
http://openprocessing.org/visuals/?visualID=5974) with a sound engine made in Pure Data. My idea is to have the particles hit the boundry/wall of the box and trigger oscillators in Pure Data.
I have already edited the Processing sketch so that 'gravity' is on by default and that there are a lot less particles, thus making the sound engine easier to create, at least to begin with.
Anyway, my question/problem is this: I have very little understanding of how to get Processing to talk to Pure Data, especially how to tell it where the particles are. I need Pure Data to know when they hit the wall of the box they're in, so that Pure Data triggers the sound.
I realise it's a long shot but all help would be appreciated. thank you!