Skip to main content

divide

divide(
@operand 1
@resamplingfiltersize 11
@resamplingmode 'sinc'
@resamplingpolicy 3
@envtimeunit 2
) -> llll

Generates an audio process operation for performing division on a buffer.


Arguments

  • @operand [int/float/llll]: Value to divide buffer by either as a single number, envelope, or buffer. (default: 1).
  • @resamplingfiltersize [int]: Resampling filter size. (default: 11).
  • @resamplingmode [symbol]: Resampling mode. (default: 'sinc').
    • 'sinc'
    • 'nearest neighbor'
    • 'sample and hold'
    • 'linear'
    • 'quad'
    • 'cubic'
  • @resamplingpolicy [int]: Resampling policy. (default: 3).
    • 0: Don't
    • 1: To lowest
    • 2: To highest
    • 3: To most common
    • 4: To max. current
  • @envtimeunit [int]: Envelope time unit. (default: 2).
    • 0: Milliseconds
    • 1: Samples
    • 2: Duration ratio
    • 3: Milliseconds difference
    • 4: Samples difference

Output

Divide operation [llll]


Usage

divide is meant to be used with the process function:

$buffer = importaudio('singing.wav'); ## input buffer
$op = divide([0 1 0] [1 10 -0.125]); ## processing operation
$buffer = $buffer.process($op); ## apply processing
$buffer.view('after divide process')