tomwalters@292: // Copyright 2010, Thomas Walters tomwalters@292: // tomwalters@292: // AIM-C: A C++ implementation of the Auditory Image Model tomwalters@292: // http://www.acousticscale.org/AIMC tomwalters@292: // tomwalters@318: // Licensed under the Apache License, Version 2.0 (the "License"); tomwalters@318: // you may not use this file except in compliance with the License. tomwalters@318: // You may obtain a copy of the License at tomwalters@292: // tomwalters@318: // http://www.apache.org/licenses/LICENSE-2.0 tomwalters@292: // tomwalters@318: // Unless required by applicable law or agreed to in writing, software tomwalters@318: // distributed under the License is distributed on an "AS IS" BASIS, tomwalters@318: // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. tomwalters@318: // See the License for the specific language governing permissions and tomwalters@318: // limitations under the License. tomwalters@292: tomwalters@292: /*! tomwalters@292: * \author Thomas Walters tomwalters@292: * \date created 2010/02/19 tomwalters@292: * \version \$Id$ tomwalters@292: */ tomwalters@292: tomwalters@292: #ifndef AIMC_MODULES_PROFILE_SLICE_H_ tomwalters@292: #define AIMC_MODULES_PROFILE_SLICE_H_ tomwalters@292: tomwalters@292: #include "Support/Module.h" tomwalters@292: tomwalters@292: namespace aimc { tomwalters@292: using std::vector; tomwalters@292: class ModuleScaler : public Module { tomwalters@292: public: tomwalters@292: explicit ModuleScaler(Parameters *pParam); tomwalters@292: virtual ~ModuleScaler(); tomwalters@292: tomwalters@292: /*! \brief Process a buffer tomwalters@292: */ tomwalters@292: virtual void Process(const SignalBank &input); tomwalters@292: tomwalters@292: private: tomwalters@292: /*! \brief Reset the internal state of the module tomwalters@292: */ tomwalters@292: virtual void ResetInternal(); tomwalters@292: tomwalters@292: /*! \brief Prepare the module tomwalters@292: * \param input Input signal tomwalters@292: * \param output true on success false on failure tomwalters@292: */ tomwalters@292: virtual bool InitializeInternal(const SignalBank &input); tomwalters@292: tomwalters@292: float sample_rate_; tomwalters@292: int buffer_length_; tomwalters@292: int channel_count_; tomwalters@292: }; tomwalters@292: } // namespace aimc tomwalters@292: tomwalters@292: #endif // AIMC_MODULES_PROFILE_SLICE_H_