From 78a45b47dede5ddf35dfc53e965b486a79177b18 Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Wed, 19 Dec 2012 17:34:57 -0500 Subject: Cleanup and simplify latest DSP code incarnation. Some things can just be a bit simpler in handling the list of stages and some things, especially format change handling, can be simplified for each stage implementation. Format changes are sent through the configure() callback. Hide some internal details and variables from processing stages and let the core deal with it. Do some miscellaneous cleanup and keep things a bit better factored. Change-Id: I19dd8ce1d0b792ba914d426013088a49a52ecb7e --- lib/rbcodec/dsp/compressor.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'lib/rbcodec/dsp/compressor.c') diff --git a/lib/rbcodec/dsp/compressor.c b/lib/rbcodec/dsp/compressor.c index 22a60e4..bdcc37b 100644 --- a/lib/rbcodec/dsp/compressor.c +++ b/lib/rbcodec/dsp/compressor.c @@ -386,14 +386,16 @@ static intptr_t compressor_configure(struct dsp_proc_entry *this, case DSP_PROC_INIT: if (value != 0) break; /* Already enabled */ - this->process[0] = compressor_process; + + this->process = compressor_process; + /* Fall-through */ case DSP_RESET: case DSP_FLUSH: release_gain = UNITY; break; } - return 1; + return 0; (void)dsp; } -- cgit v1.1