pvsgain
Scale the amplitude of a pv stream.
Syntax
Performance
fsig -- output pv stream
fsigin -- input pv stream in amplitude-frequency or amplitude-phase format
kgain -- amplitude multiplier. This argument is required. A value of 1 leaves the magnitudes unchanged; 0 sets them to zero. Frequencies or phases remain unchanged.
For frame-based input, gain changes take effect on the next new input frame. The output holds its values between frames. For sliding input, the current gain applies to each active sample in the control block.
You can restart the source with the same analysis settings while pvsgain keeps running. If you change the FFT size, hop size, window, or data format, reinitialize pvsgain too.
Warning
It is unsafe to use the same f-variable for both input and output of pvs opcodes. Using the same one might lead to undefined behavior on some opcodes. Use a different one on the left and right sides of the opcode.
Examples
Here is an example of the use of the pvsgain opcode. It uses the file pvsgain.csd.
See also
Tools for Real-time Spectral Processing (pvs opcodes)
Credits
Author: Victor Lazzarini
2011
New plugin in version 5
2011