[PD] threads with -rt

Frank Barknecht fbar at footils.org
Tue Oct 3 16:23:19 CEST 2006


Hallo,
padawan12 hat gesagt: // padawan12 wrote:

> Isn't the way to solve this problem to preallocate some space and
> have sndfiler read into that, then swap the pointer?

When I was in Graz recently Peter Plessas told me about a little trick
he got from Thomas Musil: You can preload the start of a long file
into a table in advance, play this with tabplay~ etc. and then
seemlessly switch over to [readsf~] on the go, but start
reasf~-playing with an offset matching the table-size. 

This idea is illustrated in attached abstraction "gigaplay~.pd"
(because GigaSampler uses a similar idea and even has a patent on it,
duh.)

It's good to be in Graz from time to time not only for things like
this. ;)

Ciao
-- 
 Frank Barknecht                 _ ______footils.org_ __goto10.org__
-------------- next part --------------
#N canvas 505 329 703 511 10;
#X obj 316 211 soundfiler;
#X obj 316 157 pack s s;
#X obj 367 122 symbol \$0-start;
#X obj 367 71 loadbang;
#X msg 380 95 bang;
#X obj 286 44 inlet;
#X obj 66 44 inlet;
#X obj 444 318 table \$0-start-l 44100;
#X obj 444 291 table \$0-start-r 44100;
#X obj 190 379 outlet~;
#X obj 220 343 outlet~;
#X obj 191 277 readsf~ 2;
#X obj 191 223 symbol;
#X obj 286 127 t a a;
#X msg 191 250 open \$1 44100;
#X obj 66 218 del 1000;
#X msg 66 245 1;
#X obj 302 291 tabplay~ \$0-start-r;
#X obj 302 318 tabplay~ \$0-start-l;
#X obj 66 115 t b b b;
#X obj 302 264 b;
#X obj 249 291 outlet;
#X text 389 156 no resize!;
#X obj 302 427 print tabplay!;
#X obj 66 427 print readsf;
#X obj 302 400 spigot;
#X obj 66 400 spigot;
#X obj 377 385 tgl 15 0 empty empty debug 17 7 0 10 -262144 -1 -1 0
1;
#X msg 316 184 read -nframes 44100 \$1 \$2-l \$2-r;
#X text 110 43 start;
#X text 335 43 filename;
#X connect 1 0 28 0;
#X connect 2 0 1 1;
#X connect 3 0 2 0;
#X connect 4 0 2 0;
#X connect 5 0 13 0;
#X connect 6 0 19 0;
#X connect 11 0 9 0;
#X connect 11 1 10 0;
#X connect 11 2 21 0;
#X connect 12 0 14 0;
#X connect 13 0 12 1;
#X connect 13 1 1 0;
#X connect 14 0 11 0;
#X connect 15 0 16 0;
#X connect 16 0 11 0;
#X connect 16 0 26 0;
#X connect 17 0 10 0;
#X connect 18 0 9 0;
#X connect 19 0 15 0;
#X connect 19 1 12 0;
#X connect 19 2 20 0;
#X connect 20 0 17 0;
#X connect 20 0 18 0;
#X connect 20 0 25 0;
#X connect 25 0 23 0;
#X connect 26 0 24 0;
#X connect 27 0 25 1;
#X connect 27 0 26 1;
#X connect 28 0 0 0;
-------------- next part --------------
#N canvas 401 209 450 300 10;
#X obj 161 138 dac~;
#X obj 218 82 openpanel;
#X msg 218 57 bang;
#X msg 160 82 bang;
#X obj 117 188 timer;
#X floatatom 117 211 5 0 0 0 - - -;
#X obj 218 137 spigot 1;
#X obj 218 159 del 0;
#X obj 269 112 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X obj 160 107 gigaplay~;
#X connect 1 0 9 1;
#X connect 2 0 1 0;
#X connect 3 0 4 0;
#X connect 3 0 9 0;
#X connect 4 0 5 0;
#X connect 6 0 7 0;
#X connect 7 0 4 0;
#X connect 7 0 9 0;
#X connect 8 0 6 1;
#X connect 9 0 0 0;
#X connect 9 1 0 1;
#X connect 9 2 4 1;
#X connect 9 2 6 0;


More information about the Pd-list mailing list