NAME

REVMIX - instrument that plays input file in reverse


SYNOPSIS

REVMIX(outskip, inskip, indur, ampmult [, inchan, stereoloc ])

Function table 1 gives amplitude curve.


DESCRIPTION

REVMIX plays the input file backward for the specified duration (indur), starting at the input start time (inskip). If you specify a duration that would result in an attempt to read before the start of the input file, REVMIX will shorten the note to prevent this.

Note that you can't use this instrument with a real-time input (microphone or aux bus), only with input from a sound file. (That's because the input start time of an instrument taking real-time input must be zero, but this instrument reads backward from its inskip.)

REVMIX uses the curve provided in function table 1 to scale the amplitudes of the input source. Use setline, setexp, or makegen to create function table 1. If this table has not been created, no amplitude scaling (other than that given by ampmult) will occur.

The output of REVMIX can be either mono or stereo.


PFIELDS

p0 (outskip) output start time
p1 (inskip) input start time
p2 (indur) input duration
p3 (ampmult) amplitude multiplier
p4 (inchan) input channel [optional, default is 0]
p5 (stereoloc) percent (from 0 to 1) of input signal to place in left output channel [optional, default is 0.5 if output is stereo]


EXAMPLES

   rtinput("a_stereo_sound")
   REVMIX(outskip=0, inskip=5, dur=3, amp=1, inchan=1, loc=.25)

This plays the right channel of the stereo input file in reverse, starting at a point 5 seconds from the beginning of the file and continuing for 3 seconds. It pans the sound midway between center and hard right.


SEE ALSO

setline, setexp, makegen


AUTHOR

Ivica ``Ico'' Bukvic <ico@fuse.net>

(with John Gibson <johgibso@indiana.edu>)