.TH "aflibAudioConstantSrc" 3 "16 Jan 2007" "Open Source Audio Library Project" \" -*- nroff -*- .ad l .nh .SH NAME aflibAudioConstantSrc \- Inserts a constant audio source in a chain for test purposes. .PP .SH SYNOPSIS .br .PP \fC#include \fP .PP Inherits \fBaflibAudio\fP. .PP .SS "Public Types" .in +1c .ti -1c .RI "enum \fBwaveform_type\fP { \fBWAVEFORM_DCLEVEL\fP, \fBWAVEFORM_TRIANGLE\fP, \fBWAVEFORM_SQUAREWAVE\fP, \fBWAVEFORM_SINEWAVE\fP }" .br .in -1c .SS "Public Member Functions" .in +1c .ti -1c .RI "\fBaflibAudioConstantSrc\fP (\fBaflibAudio\fP &audio)" .br .RI "\fIConstructor - defaults to a DC level fullscale signal. \fP" .ti -1c .RI "\fBaflibAudioConstantSrc\fP ()" .br .RI "\fIConstructor - defaults to a DC level fullscale signal. \fP" .ti -1c .RI "\fB~aflibAudioConstantSrc\fP ()" .br .RI "\fIDestructor. \fP" .ti -1c .RI "void \fBsetWaveformType\fP (aflibAudioConstantSrc::waveform_type wave, double max_amp, double min_amp, int frequency)" .br .RI "\fI.IP "\(bu" 2 Sets the type of waveform to be output. .PP \fP" .ti -1c .RI "aflibStatus \fBcompute_segment\fP (list< \fBaflibData\fP * > &data, long long position=-1)" .br .RI "\fIWork function, must be implemented by derived class. \fP" .ti -1c .RI "const char * \fBgetName\fP () const " .br .RI "\fIReturns the name of the derived class. \fP" .in -1c .SH "Detailed Description" .PP Inserts a constant audio source in a chain for test purposes. This class allows one to insert a test signal anywhere in an audio chain. It is mainly used for debugging other audio objects that work on audio data. When it is inserted in a chain it takes on the characteristics of everything before it in the chain. For instance a parent that is outputting a 22050 sample rate mono signal will cause this object to throw away the data from the parent and instead insert a test signal that is 22050 mono. .PP One can select a DC level, triangle wave, square wave, or sine wave. One can also adjust the frequency and amplitude. .PP .SH "Member Function Documentation" .PP .SS "void aflibAudioConstantSrc::setWaveformType (aflibAudioConstantSrc::waveform_type wave, double max_amp, double min_amp, int frequency)" .PP .IP "\(bu" 2 Sets the type of waveform to be output. .PP .PP Allow the user to select the waveform type, amplitude, and frequency. The amplitude will be the peak amplitude of the signal specified in percent. Both a max and min are required. For full scale one would use 100.0 for max and -100.0 for min. For the waveform DC level only max is used and min must be less than or equal to max. The frequency must be in Hz. .SH "Author" .PP Generated automatically by Doxygen for Open Source Audio Library Project from the source code.