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 & HelpIntegration › Transitioning automatically between sketches
Page Index Toggle Pages: 1
Transitioning automatically between sketches (Read 411 times)
Transitioning automatically between sketches
Sep 2nd, 2008, 12:38am
 
I wasn't sure where to post this, and in fact, it's not really even a Processing question!

I'm going to be taking part in an exhibition, which will include having some interactive (via infrared-sensitive webcams) Processing sketches projected one after the other onto a screen. Several different sketches will be included, all running on one computer and being projected by one projector. I'm trying to think of a way to automatically transition between the different Processing sketches, without people seeing the details of one program ending and another starting up. All I want them to see is that a new interaction has taken over from the previous one.

I've considered embedding Processing applets in web pages and using Javascript/HTML to advance to the next page, but there will be a delay (and the Processing icon will display) as the applet initialises on the new page. I thought of maybe exporting the sketches as applications, and using a batch file to start one .exe file, pause for however long the sketch is to run, then start the next .exe file, but that wasn't working for me either. Maybe I'm not familiar enough with batch files.

I suppose all of the different interactions could be put together into one Processing sketch and then I could just use a timer in the code to move from one section to the next, but I didn't want to risk depending on one sketch to handle everything. If the different interactions are complex, I'm not sure how well the computer I'll be using would handle this either.

Could anyone offer any suggestions for doing what I'm suggesting. I hope I've been clear in my description.

Now that I think about it again, I suppose any strategy will have a startup delay, so what I really need is a way for the Processing sketch to be up and running and then some way of tranferring focus (fading?) automatically from one running sketch to the new one, and exiting the first one.

Thanks in advance
Re: Transitioning automatically between sketches
Reply #1 - Sep 2nd, 2008, 4:17am
 
This really depends on how your exhibition sketches are written, and what control you have over them.

If the exhibition sketches are written in Eclipse SDK for example (full java mode) you could make them all extend some form of base Client class, then write an Exhibition processing app that cycles and transitions between them seamlessly.

That's the only way I can think of to cleanly do this.

One way around this whole problem for your transitions is to have two machines, each having the processing apps, then having a video mixer automatically swap between the two. This is a huge (and potentially expensive) hack.
Page Index Toggle Pages: 1