2008/6/5 Jonathan Siemasko <
zombiecontrol@gmail.com>:
Hello ChucK people,
Been following the list for a while now but this is my first
post. I am trying to create a Random Chuck Beat slicer. Basically
input any loops, set the rate and set the number of slices to use and
it will automatically create random breakbeats from it. The problem
is when I set the playback rate to anything other then half, single,
double, etc. slices stop lining up properly.
While I realise you are after knowing what's wrong with your code -and I'd like to help- I don't quite have the time for debugging this at the moment. BUT. I just remembered I have a beatslicer lying around that I impulsively made because I had a few hours to kill a while back. I'm not really that into breaks anymore so I doubt I'll ever get back to it and it's somewhat crude here&there but it has plenty of comments as I send it to a friend to play with already.
It works by taking a wave file which it assumes already loops properly. It tries to detect volume peaks and attempts to base slices on those (not on exact fractions of the length, this is more Jazz then House). It tries not to get fooled by random volume modulations and also discards very short slices.