sound (version 1.4.5)

mirror: Mirror a Stereo Sample

Description

Interchange the left and the right channel of a stereo Sample object or a stereo wav file.

Usage

mirror(s)

Value

a Sample object, with the left and the right channel of s interchanged.

Arguments

s

a Sample object, or a string giving the name of a wav file.

Author

Author: tools:::Rd_package_author("sound")

Maintainer: tools:::Rd_package_maintainer("sound")

Details

If s is a mono sample, it will be returned as it is.

See Also

panorama for a command with more parameters, left and right for access to single channels of a sample.

Examples

Run this code
if (FALSE) {
s <- stereo(Sine(440,1),Sine(220,1))
play(s)  # higher tone is on the left
play(mirror(s))  # now higher tone is on the right
}

Run the code above in your browser using DataLab