Explicitly include a boost "windows" folder even on linux
[supercollider.git] / HelpSource / Classes / BufFrames.schelp
blobf8ea6c18d1721cbec99a7fd9aab2f67b551c1ab0
1 class:: BufFrames
2 summary:: Current number of frames allocated in the buffer.
3 related:: Classes/BufChannels, Classes/BufDur, Classes/BufRateScale, Classes/BufSampleRate, Classes/BufSamples
4 categories::  UGens>Buffer>Info
6 Description::
7 Get the current number of allocated frames.
9 classmethods::
11 method::kr, ir
13 argument::bufnum
14 Buffer index.
16 returns:: the current number of allocated frames.
18 discussion::
19 warning::
20 The  code::.ir::  method is not the safest choice.
21 Since a buffer can be reallocated at any time, using
22 code::.ir::  will not track the changes.
25 Examples::
27 code::
29 b = Buffer.read(s, Platform.resourceDir +/+ "sounds/a11wlk01.wav");
31 // indexing with a phasor
32 { BufRd.ar(1, b, Phasor.ar(0, BufRateScale.kr(b), 0, BufFrames.kr(b))) }.play;
34 // indexing by hand
35 { BufRd.ar(1, b, K2A.ar(MouseX.kr(0, BufFrames.kr(b)))) }.play;
37 b.free