<br>Hallo Frank :-), thanks for your reply<br><br>(i updated the subject since the discussion moved on..)<br><br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
While you could bang vsnapshot~ at samplerate and keep track of samples in a<br>
list or so, this is a waste of resources. Something like tabsend~ or tabwrite~<br>
probably is much better: Just write a number of samples into a table and then<br>
analyse that for peaks. There are some externals for that or do it manually.<br></blockquote></div><br clear="all">As I understand it (and hopefully i am not completely wrong..) you don't have to 'store' a list and 'then' read again it to find the max magnitude. It's as simple as the following:<br>
<br>(some signal)<br><b>I</b><br><b>I</b> [pd metro@samplerate]<br><b>I</b>/<br>[vsnapshot~ ]<br>|<br>[abs ]<br>|<br>[moses ]X[t f ]<br> |<br> [f ]<br><br>So in the last [f ] you have the max magnitude stored and you can bang it to the [vu ] inlet say at a fix rate (which is the simplest way, it just requires a [metro ] banging [f ] and resetting [moses ])<br>
<br>I don't understand how using an array to store samples and then analyse it is more efficient than that. It seems to me you have to read 2 times: one to write the array in the fist place and one more to analyse it.<br>
<br>a simple comparison:<br><br>read-analyse<br>vs.<br>read-write-read-analyse<br><br><br>Please correct me if i am missing something and post an example with the use of an array if you can.<br><br><br>alabala<br><br>-- <br>
ypatios<br>