I want to copy the contents of one array to another as fast as
possible. Basically, I'll load a sound file into an array, and fill a
big buffer by concating that soundfile to the big buffer until its full.
Any ideas?
.hc
If you are not part of the solution, you are part of the problem.
Gee, I forgot to document this one, sorry.
a turned-off switch~ can be used to single-step the DSP in a window by sinding it a bang message. So you can "switch~ 2048" in a window, connect a tabplay~ to a tabwrite~ inside it, start them, then send the switch~ N/2048 bangs to copy N samples from one table to another.
don't tell anyone that was my idea :)
M
On Wed, Nov 11, 2009 at 08:36:28PM -0500, Hans-Christoph Steiner wrote:
I want to copy the contents of one array to another as fast as
possible. Basically, I'll load a sound file into an array, and fill a
big buffer by concating that soundfile to the big buffer until its full.Any ideas?
.hc
If you are not part of the solution, you are part of the problem.
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
On Wed, Nov 11, 2009 at 7:46 PM, Miller Puckette mpuckett@imusic1.ucsd.edu wrote:
Gee, I forgot to document this one, sorry.
a turned-off switch~ can be used to single-step the DSP in a window by sinding it a bang message. So you can "switch~ 2048" in a window, connect a tabplay~ to a tabwrite~ inside it, start them, then send the switch~ N/2048 bangs to copy N samples from one table to another.
don't tell anyone that was my idea :)
M
I used to use a [bang~]->toggle->[switch~] construction to try to have one execution and then switch off. Thanks for the tip! I guess I won't need that one anymore.
Chuck
Hallo, Charles Henry hat gesagt: // Charles Henry wrote:
On Wed, Nov 11, 2009 at 7:46 PM, Miller Puckette mpuckett@imusic1.ucsd.edu wrote:
Gee, I forgot to document this one, sorry.
a turned-off switch~ can be used to single-step the DSP in a window by sinding it a bang message. Â So you can "switch~ 2048" in a window, connect a tabplay~ to a tabwrite~ inside it, start them, then send the switch~ N/2048 bangs to copy N samples from one table to another.
I used to use a [bang~]->toggle->[switch~] construction to try to have one execution and then switch off. Thanks for the tip! I guess I won't need that one anymore.
I've been using this a lot recently as well, but I don't think, Miller's undocumented suggestion can replace this in all cases. One advantage of the bang~->switch~ approach is - I believe - that it gets rid of many function calls: You just let the CPU compute a set of, say 64 samples with basically one function call per object. But if you send 64 bangs instead, I think, the object get activated 64 time so you have 64 function calls which should be slower.
Is my reasoning correct?
Frank
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
I've been using this a lot recently as well, but I don't think, Miller's undocumented suggestion can replace this in all cases. One advantage of the bang~->switch~ approach is - I believe - that it gets rid of many function
I meant to write "[bang~]->[0(->[switch~]" here.
Frank
Just putting in my 2cents, but I've been using the bonus feature of being able to write an array's contents to a text file with a message and then read it back out to a different array with another message.
This is probably ok for my usage, since I have a project where I need to store *lots* of arrays in text files anway, but it's certainly a really easy solution in terms of code.
-Stephen
On Thu, Nov 12, 2009 at 5:37 PM, Frank Barknecht fbar@footils.org wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
I've been using this a lot recently as well, but I don't think, Miller's undocumented suggestion can replace this in all cases. One advantage of
the
bang~->switch~ approach is - I believe - that it gets rid of many
function
I meant to write "[bang~]->[0(->[switch~]" here.
Ciao
Frank
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
I should have also added that I'm only using this functionality for relatively small arrays (500 values), and haven't tried using it for arrays which may be holding longish audio samples.
-Stephen
On Thu, Nov 12, 2009 at 11:56 PM, Stephen Lucas s9lucas@gmail.com wrote:
Just putting in my 2cents, but I've been using the bonus feature of being able to write an array's contents to a text file with a message and then read it back out to a different array with another message.
This is probably ok for my usage, since I have a project where I need to store *lots* of arrays in text files anway, but it's certainly a really easy solution in terms of code.
-Stephen
On Thu, Nov 12, 2009 at 5:37 PM, Frank Barknecht fbar@footils.orgwrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
I've been using this a lot recently as well, but I don't think, Miller's undocumented suggestion can replace this in all cases. One advantage of
the
bang~->switch~ approach is - I believe - that it gets rid of many
function
I meant to write "[bang~]->[0(->[switch~]" here.
Ciao
Frank
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Stephen Lucas wrote:
I should have also added that I'm only using this functionality for relatively small arrays (500 values), and haven't tried using it for arrays which may be holding longish audio samples.
-Stephen
On Thu, Nov 12, 2009 at 11:56 PM, Stephen Lucas <s9lucas@gmail.com mailto:s9lucas@gmail.com> wrote:
Just putting in my 2cents, but I've been using the bonus feature of being able to write an array's contents to a text file with a message and then read it back out to a different array with another message.
you could use soundfiler too using this approach. but it also has to allocate memory twice... i used this approach to exchange relatively big arrays (more than 50,000 values) between two instances of pd, using /dev/shm (or any ramdrive) which worked fine.
cheers, Martin
2009/11/11 Hans-Christoph Steiner hans@at.or.at
I want to copy the contents of one array to another as fast as possible. Basically, I'll load a sound file into an array, and fill a big buffer by concating that soundfile to the big buffer until its full.
Any ideas?
.hc
Just a curiosity: Should [tab_copy] at "iem_tab" lib work for this?
;;;
I'm sure that in zmoelnig's (?) VASP there's something to do this. but I
can't look at it myself now.
I want to copy the contents of one array to another as fast as
possible. Basically, I'll load a sound file into an array, and fill a
big buffer by concating that soundfile to the big buffer until its full.Any ideas?
.hc
If you are not part of the solution, you are part of the problem.
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management ->
http://lists.puredata.info/listinfo/pd-list
João Pais wrote:
definitely not mine. it's günther rabl's toolset, ported to Pd by thomas grrrill.
hey, all of us are austrians; no nationalism intended.
tut mir Leid, war zu faul, um herauszusuchen. nächstes Mal mache ich es wieder falsch, aber nicht mit deinem Namen.
i was flattered anyhow :-)
fgmasfrt IOhannes