SuperCollider CLASSES (extension)

PVInfo
ExtensionExtension

Return mag and freq data from a CSound pv

Description

#mag, freq = PVInfo.ar(pvbuffer, binNum, filePointer, mul, add )
#mag, freq = PVInfo.kr(pvbuffer, binNum, filePointer, mul, add )

Class Methods

*categories

*ar (pvbuffer, binNum: 0, filePointer: 0, mul: 1, add: 0)

Arguments:

pvbuffer

Default value is nil.

binNum

Default value is 0.

filePointer

Default value is 0.

mul
add

*kr (pvbuffer, binNum: 0, filePointer: 0, mul: 1, add: 0)

Arguments:

pvbuffer
binNum
filePointer
mul
add

Inherited class methods

Instance Methods

-init ( ... theInputs)

Inherited instance methods

Examples

s.boot;

// load a file and save it to a buffer
a = PVFile.new("Platform.resourceDir +/+ sounds/cl-c4.pv", s).loadToBuffer;

// what this example does
(
x = SynthDef(\helpPVSynth, {arg scale = 1;
    var src, filts, mag, freq, point;
    src = WhiteNoise.ar;
    point = MouseX.kr(0, 1);
    filts = Mix.fill(100, {arg i;
        #mag, freq = PVInfo.ar(a.buffer, i + 5, point);
        BPF.ar(src, freq, 0.001, mag);
        });
    Out.ar(0, Pan2.ar(filts * a.magScale * scale), 0.0);
}).play(s, [\scale, 2]);
)

x.free;