Playback speeds using count~ and index~


    Jul 19 2006 | 9:42 pm
    I know that you can use sfplay~ to determine the speeds that a file could get played, but I'm trying to use count~ going into an index~ and they are getting thier start and end points from a wavform display. A bang hits a message box that contains the minpoint for count to start at. I'm trying to find out if there is a way for counter~ or index~ to have a way to control the speed that the file plays back at. I hope that had some semblance of clarity to it :P Thanks for any help.
    Jhay

    • Jul 20 2006 | 6:41 am
      count~ | *~ 0.5 | index~
      this would play it in half speed ?, but you'll need to do a little work on the end point...
      something like this :
      end point in samples | | speed | | | [!/ 1.] | | [*~ 1.] | how high count should count~
      ----------
      but why not use play~ or groove~, much easier ?
    • Jul 20 2006 | 8:13 am
      i have a patch based on that idea, the advantage being you can use a master phasor~ to control all kinds of stuff
      you need to use the +=~ object if you are going to vary the playback speed, otherwise you will get jumps in the play position as you very the play speed (pitch)
      another problem you may encounter is when you get very big numbers out of +=~ you might get bad audio quality from play~, in which case the hr.play~ and other hr objects will sort it out
    • Jul 20 2006 | 11:28 am
      Jhaysonn wrote: > I'm trying to find out if there is a way for counter~ or index~ to > have a way to control the speed that the file plays back at.
      Just use a [*~] to change the speed...
      [*~ 1.] is original speed, [*~ 0.5] is half speed...
      (Math is usually way simpler than one might think it is...)
      Stefan
      -- Stefan Tiedje------------x------- --_____-----------|-------------- --(_|_ ----|-----|-----()------- -- _|_)----|-----()-------------- ----------()--------www.ccmix.com
    • Jul 20 2006 | 12:21 pm
      that wont work unless the pitch is a constant, because you get discontinuity in the audio when you change pitch. you got to use an accumulator
    • Jul 20 2006 | 2:56 pm
      thank you very much bin, that worked perfectly! Thanks for the help guys, really appreciate it