[Csnd] Creating a loop shuffler with pvsbuffer
| Date | 2011-04-09 14:21 |
| From | Ed Costello |
| Subject | [Csnd] Creating a loop shuffler with pvsbuffer |
| Hi list, I'm trying to make a loop shuffler for live reordering of loops, I'm running into problems using the pvsbufread opcode, I think its probably the approach I am taking though. My instrument reads through a table for the starting position of the buffer, the table is like [1/8] [2/8] [7/8].......... for 8 divisions in the loop, then I use a shedkwhen to trigger the instrument that reads from the pvs buffer, the position from where it reads from is altered by changing the starting phase of a phasor. This is my code here, it uses Joachim Heintz's FileToPvsBuf udo ....
instr 1 turnon 2 k_PatternClock phasor 1 gk_ReadPatternTable table k_PatternClock * 8, 20 schedkwhen gk_ReadPatternTable, 0, 1, 3, 0, 1/8 printk2 gk_ReadPatternTable endin instr 2 ifftsize = 1024 ioverlap = ifftsize /2 iwinsize = ifftsize iwinshape = 1 gibuffer, gilen, k0 FileToPvsBuf "loop.wav", ifftsize, ioverlap, iwinsize, iwinshape turnoff endin instr 3 kphasor phasor 1, i(gk_ReadPatternTable) fread pvsbufread kphasor * gilen, gibuffer aout pvsynth fread out aout
endin
My problem is that the playback is really stuttered, I though it was a problem with the timings I'm using for the triggers, but I have adjusted them many times and I still can't get smooth playback from the buffer, is there a better approach to making such an instrument? Ed |
| Date | 2011-04-11 13:56 |
| From | peiman khosravi |
| Subject | Re: [Csnd] Creating a loop shuffler with pvsbuffer |
On 09/04/2011 14:21, Ed Costello wrote:
>
> instr 1
>
> turnon 2
>
> k_PatternClock phasor 1
>
> gk_ReadPatternTable table k_PatternClock * 8, 20
>
> schedkwhen gk_ReadPatternTable, 0, 1, 3, 0, 1/8
>
> printk2 gk_ReadPatternTable
>
> endin
>
> instr 2
>
> ifftsize = 1024
>
> ioverlap = ifftsize /2
>
> iwinsize = ifftsize
>
> iwinshape = 1
>
> gibuffer, gilen, k0 FileToPvsBuf "loop.wav", ifftsize, ioverlap,
> iwinsize, iwinshape
>
> turnoff
>
> endin
>
> instr 3
>
> kphasor phasor 1, i(gk_ReadPatternTable)
>
> fread pvsbufread kphasor * gilen, gibuffer
>
> aout pvsynth fread
>
> out aout
>
> endin
>
Hello,
I am happy to test your example but can you send a full csd please?
Best,
Peiman
Send bugs reports to the Sourceforge bug tracker
https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"
|