@Jakki if you post the whole patch we could be of more help, all you posted was a counter. But it probably has to do with the position you're reading the sound file from changing discontinuously.
Yes, that might be true!
Here is a patch that shows how I do it currently. The sample "sound.wav" is recorded in 122 bpm, so in the pd-patch all the calculations are "hard-coded" with 122.
Let me know if something is unclear.
All the best, Jakki
Here is the sound-file. It must be in the same folder as the pd-patch, as I am not using [openpanel] in the patch:
i am putting together an 8-track-sample-player using the soundfiler-phasor~-tabread4~-approach for each track.
I experienced that i need some kind of sync-mechanism in order to keep the eight samples in sync while they are playing. So I gave the following a try:
I set the position of phasor~ using its right inlet with every whole beat (1,2,3,4) of my bpm-metronome. The current position is calculated in dependency of the current sample's length.
It works, but every time I set a new position to phasor~ I hear a popping noise in my speakers. So my approach is probably completely senseless, but I thought I ask you. Maybe you have a solution to my problem or an idea for another approach.
Attached, you find a pseudo-patch which symbolises what I am doing. Think of the print-object as the phasor~ object.
Thank you, Jakki
I am running a sample-player-patch in pd-extended 0.43.4 on a Raspberry Pi 2.
With [loadbang] I load round about 20 wav-samples from disk with [read] and [soundfiler]. When I do this in the pd-gui-environment, everything works okay. But when I load the patch via the command line like so:
"sudo pd-extended -nogui -open myPatch.pd"
I get the following message:
"sys_startgui: cannot allocate memory"
When I run the patch in pd-vanilla 0.46.2 - also on the Raspi 2- the same error occurs.