reading sample length in buffer~

Oct 12, 2008 at 11:51pm

reading sample length in buffer~

how can i display the length (in ms) of a loaded sample into buffer~?

like this:

read
|
[buffer~ sample1 10000]

i wan’t to know and to have displayed what the sample length of the loaded sample is.

#40304
Oct 12, 2008 at 11:59pm

Look at [info~ sample1]

#142441
Oct 13, 2008 at 12:34pm

now i get the sample length set in buffer. in this case 10000 ms.
the sample loaded is shorter, i wan’t that length. wich is variable offcourse because of different samples.

#142442
Oct 13, 2008 at 12:47pm

if i don’t specify a length in buffer~ i getthe actual length of the loaded sample so that’s solved but the problem is that if i change sample info doesn’t change. it only outputs info of the first loaded sample.

#142443
Oct 13, 2008 at 1:08pm

hi,

use the “replace” message, not “read”.

cheers

g

2008/10/13 wit

>
> if i don’t specify a length in buffer~ i getthe actual length of the loaded
> sample so that’s solved but the problem is that if i change sample info
> doesn’t change. it only outputs info of the first loaded sample.
>

#142444
Oct 13, 2008 at 1:33pm

If you use the message “read 0 -1″ to load a file into [buffer~] it resizes itself automatically, which you will be able to see in [info~]. Have a look in the [buffer~] reference file to see why.

lh

#142445
Oct 13, 2008 at 2:10pm

thanks, didn’t think about that. replace did the job.

#142446

You must be logged in to reply to this topic.