mpulse
Generates a set of impulses.
The impulses have amplitude kamp separated by kintvl seconds (or samples if kintvl is negative). The first impulse is generated after a delay of ioffset seconds.
Syntax
Initialization
ioffset (optional, default=0) -- the delay before the first impulse. If it is negative, the value is taken as the number of samples, otherwise it is in seconds. Default is zero.
Performance
kamp -- amplitude of the impulses generated
kintvl -- Interval of time in seconds (or samples if kintvl is negative) to the next pulse.
After the initial delay, an impulse of kamp amplitude is generated as a single sample. Immediately after generating the impulse, the time of the next one is determined from the value of kintvl at that precise moment. This means that any changes in kintvl between impulses are discarded. If kintvl is zero, there is an infinite wait to the next impulse. If kintvl is negative, the interval is counted in number of samples rather than seconds.
Examples
Here is an example of the mpulse opcode. It uses the file mpulse.csd.
Another example of how to use mpulse can be found here: mode
See Also
Credits
Written by John ffitch.
New in version 4.08