| Audio-Mad documentation | view source | Contained in the Audio-Mad distribution. |
Audio::Mad::Dither - Dithering routines for mad_fixed_t data
my $dither = new Audio::Mad::Dither (MAD_DITHER_S16_LE); my $s16le = $dither->dither($fixed_l, $fixed_r); $dither->init(MAD_DITHER_S24_BE); my $s24be = $dither->dither($fixed_l);
This module provides a means of dithering and converting streams of mad_fixed_t samples into a small variety of pcm sample streams. The underlying module converts the streams using the linear quantization method provided in the mad-0.14.2b distribution.
Creates a new Audio::Mad::Dither object, and returns a handle to it. You may provide an optional type parmater, corresponding to a MAD_DITHER constant, or accept the default of signed 16 bit little endian samples.
Reinitializes an Audio::Mad::Dither object into producing a different type of pcm stream.
Returns a formatted stream of pcm samples, dithered from the mad_fixed_t streams of samples: left, and optionally right (mono streams only have left channel). The data returned here is appropriate to be sent to at a /dev/dsp or similar device.
Mark McConnell <mischke@cpan.org>
| Audio-Mad documentation | view source | Contained in the Audio-Mad distribution. |