[PD] [soundfile_info] made with vanilla

oliver oliver at klingt.org
Thu May 24 16:59:31 CEST 2018

On 2018-05-24 16:43, Joe White wrote:
> Hey Oliver,
> I will admit to not fully digesting your patch, but from skim reading
> it I'm assuming it loops over the sample data by incrementing the
> -skip argument until you reach the end of the file.

well, more like see-sawing between a possible maximum of samples and 0,
and then find the last valid point "in the middle"

For my purposes
> memory usage isn't really an issue, so I'd imagine it would be far
> quicker to just load the whole sample into the table.

depends on the length of the file. if it's a 30 minute file,
this will freeze PD and probably lock the memory too. my approach tries 
to overcome that.
and also is of course much faster than waiting for a long file to get 
loaded into RAM just to know its length.

> What would be nice is if [soundfiler] additionally read the data chunk
> size property in the wav header for the number of samples. I imagine
> that's why [soundfile_info] was created in the first place.

yes, that would be the nicest solution !

as alex pointed out, this is already a pull request. so, probably 
available in PD 0.49 ...


until that, it's either [soundfile_info] or a workaround, like i 



More information about the Pd-list mailing list