Hi Mike,
I was curious myself to see if this could be done, however after reading thru the code, the riff tool appears to do little more than play a file. I did find an old post in the archives under a search of the group tool called "searching for a particular measure". Here is part of it:
>Is there any
>way to seek to a particular measure in the Group tool using another tool?
>I'm trying for a tool that will act as a tape transport more or less for
>Group, telling it to start & stop playing, and rewinding and
>fastforwarding to a particular measure. And also one that only plays
>particular tracks, etc..
There's nothing built in for seeking, but bang() and stop() are
standard methods for playing and stopping in the Group and Riff
tools. There's no method for simply setting the audition area
of the Group tool, but this is what it would look like:
method setaudition(tm1,tm2) {
$.audition = ["start"=tm1,"end"=tm2]
}
For playing particular tracks, you'd want a method like
the existing setsolo(), but it is only capable of soloing
tracks that are currently displayed, so it might be better
to create a more direct method (perhaps bangtrack(n))
that would just play a given track.
You can use the Bang tool as an example of a tool that
lets you graphically "connect" to another tool and
invoke methods on it.
...Tim...
I had tried to do something similar with the kboom(old) by enabling the step button in the 1st page of code, then setting the # of steps to the length of the pattern. If you stop playback just before you want to
start again, then you can use the step button to jog forward to the desired position. The problem was I could not get the bang tool to start at the step position, instead of the beginning of the pattern.
Thanks, Hank