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 & HelpSound,  Music Libraries › ESS sound sample synchonisation problem
Page Index Toggle Pages: 1
ESS sound sample synchonisation problem (Read 708 times)
ESS sound sample synchonisation problem
Apr 27th, 2009, 12:24pm
 
Hey,
i´m playing a little with ess and i´m trying to synchronize a special event with the exact ending of a sound sample.

i have tried "if" clauses with things like ".cue" and ".size" but unfortunately the "cue" function generates rather unprecise values. so the if clause stays false...

i´m looking for a condition or function that fixes that problem.
something like:

if (soundfile.position==soundfile.length)
{
.....
}

thanks!




Re: ESS sound sample synchonisation problem
Reply #1 - Apr 29th, 2009, 11:11pm
 
have you tried the audioChannelDone() method? It is called whenever an AudioChannel finishes playing, so just put what you want to have happen within it.

http://www.tree-axis.com/Ess/AudioChannel/audioChannelDone.html

Page Index Toggle Pages: 1