Skip to main content

pong

pong(
@low -1
@high 1
@mode 0
) -> llll

Generates an audio process operation for applying range limiting to a buffer.


Arguments

  • @low [int/float/llll]: low limit value, as either a single number, envelope, or buffer. (default: -1).
  • @high [int/float/llll]: high limit value, as either a single number, envelope, or buffer. (default: 1).
  • @mode [int]: range limiting mode. (default: 0).
    • 0: fold
    • 1: wrap
    • 2: clip

Output

pong operation [llll]


Usage

pong is meant to be used with the process function:

$buffer = importaudio('singing.wav'); ## input buffer
$op = pong(@low -0.125 @high 0.133); ## processing operation
$buffer = $buffer.process($op); ## apply processing
$buffer.inspect('after pong process')