max_k — Local maximum (or minimum) value of an incoming asig signal
max_k outputs the local maximum (or minimum) value of the incoming asig signal, checked in the time interval between ktrig has become true twice.
asig - incoming (input) signal
ktrig - trigger signal
max_k outputs the local maximum (or minimum) value of the incoming asig signal, checked in the time interval between ktrig has become true twice. itype determinates the behaviour of max_k:
1 - absolute maximum (sign of negative values is changed to positive before evaluation)
2 - actual maximum
3 - actual minimum
4 - calculate average value of asig in the time interval
This opcode can be useful in several situations, for example to implement a vu-meter.