[Clam-devel] very basic processings examples / no time-domain audio gain in NE?

David García Garzón dgarcia at iua.upf.edu
Tue Nov 20 11:58:54 PST 2007


On Tuesday 20 November 2007 20:16:32 Hernán Ordiales wrote:
> On 11/19/07, David García Garzón <dgarcia at iua.upf.edu> wrote:
> [snip]
>
> > Maybe because this:
> >                 BaseProcessing()
> >
> >                         mInputAudio("Input Audio",this ),
> >                         mOutputAudio("Audio Output",this),
> >
> >                         mInputControl("Control", this)
> >                 {
> >                         Configure( mConfig );
> >                 }
> >
> > Should be:
> >
> >                 BaseProcessing(ProcessingConfig & config=Config())
> >
> >                         mInputAudio("Input Audio",this ),
> >                         mOutputAudio("Audio Output",this),
> >                          mInputControl("Control", this)
> >                 {
> >                         Configure( config );
> >                 }
> > Try it out.
>
> worked with:
>
> 		BaseProcessing(NullProcessingConfig config=Config())
>
> 			mInputAudio("Input Audio",this ),
> 			mOutputAudio("Audio Output",this),
>
> 			mInputControl("Control", this)
> 		{
> 			Configure( config );
> 		}
>

Sorry the generic code that should work everywhere with minimal modifications 
of the cut and paste is:
 		BaseProcessing(const Config & config=Config())

 			mInputAudio("Input Audio",this ),
 			mOutputAudio("Audio Output",this),

 			mInputControl("Control", this)
 		{
 			Configure( config );
 		}
check out the use of the Config alias and the reference to avoid copies. I 
also missed the 'const'.

David.





More information about the clam-devel mailing list