Forums > MaxMSP

Pak object confusion

Mar 18 2012 | 12:58 pm

Hello everyone, I am watching on of the baz tutorials on youtube which tells you how to make a drum machine-ish patch based on probabilities. < - its here

In it (around 8 minutes in) he is using the second input of the pak object to determine the start point of the second slice of audio. When i try to do this it does not work. The second Int. box just triggers the first box when the numbers are moved. I am using my own audio but that shouldn’t make a difference.

Any help would be the best ever. Everything i have is exactly the same as in the tutorial, i really need to be able to trigger different points in the same audio file for this to work.


Mar 18 2012 | 1:11 pm

Hey Jack~,

The answer can be found in the difference between pack and pak. With pack, only a change in the left inlet causes the two numbers to be output, while a change in either causes the pair to be output with pak. The right inlet doesn’t change the start point, it merely causes the pair of numbers stored in the pak to be output. You still need to change the first inlet to change your start point.

Hope this helps.

Marc P.

Mar 18 2012 | 1:40 pm

Thanks very much for the reply dapinsker! that makes sense now. What doesn’t now make sense to me is that if i put the value of the right input over (numerically) the left, no sound is generated anymore when i change them. Surely the end point needs to come after the start point?

Mar 18 2012 | 1:42 pm

bah seems i don’t understand after reading your post again. How is the pak object told how long the sample is going to be then? what is the purpose of the right int. input? Sorry for being stupid

Mar 18 2012 | 1:55 pm

No worries – I’ve spent HOURS wracking my brain on similar issues…

The pak object is simply combining the two numbers. The first (left) inlet will be the starting point and the second (right) inlet is the ending point of the sample. The pak object is simply being used to send the numbers to the seek message. If the two values were sent to the seek message directly, the seek message would only be triggered when the starting point value changes.By using the pak object, both values are sent simultaneously allowing the message to be triggered regardless of which value is changed.

Mar 18 2012 | 2:07 pm

haha right im getting there, my patch is acting a little strangely but with your help im managing to get my head round it. I may be back to ask something else but in the mean time, thanks loads!

Mar 18 2012 | 6:21 pm

you can also try:

–using just one number as the start point, and running it through a [+] operator with a selectable amount (say 500) which will give you slices of exactly 500 milliseconds, starting at the start point. So you can then choose the length as well.

–experimenting with [waveform~] which is the coolest ever and lots more intuitive visually.

Viewing 7 posts - 1 through 7 (of 7 total)

Forums > MaxMSP