tomwalters@284: // Copyright 2010, Thomas Walters tomwalters@284: // tomwalters@284: // AIM-C: A C++ implementation of the Auditory Image Model tomwalters@284: // http://www.acousticscale.org/AIMC tomwalters@284: // 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@284: // tomwalters@318: // http://www.apache.org/licenses/LICENSE-2.0 tomwalters@284: // 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@284: tomwalters@284: /*! tomwalters@284: * \author Thomas Walters tomwalters@284: * \date created 2010/02/19 tomwalters@284: * \version \$Id$ tomwalters@284: */ tomwalters@284: tomwalters@292: #ifndef AIMC_MODULES_PROFILE_SCALER_H_ tomwalters@292: #define AIMC_MODULES_PROFILE_SCALER_H_ tomwalters@284: tomwalters@284: #include "Support/Module.h" tomwalters@284: tomwalters@284: namespace aimc { tomwalters@284: using std::vector; tomwalters@284: class ModuleSlice : public Module { tomwalters@284: public: tomwalters@284: explicit ModuleSlice(Parameters *pParam); tomwalters@284: virtual ~ModuleSlice(); tomwalters@284: tomwalters@284: /*! \brief Process a buffer tomwalters@284: */ tomwalters@284: virtual void Process(const SignalBank &input); tomwalters@284: tomwalters@284: private: tomwalters@284: /*! \brief Reset the internal state of the module tomwalters@284: */ tomwalters@284: virtual void ResetInternal(); tomwalters@284: tomwalters@284: /*! \brief Prepare the module tomwalters@284: * \param input Input signal tomwalters@284: * \param output true on success false on failure tomwalters@284: */ tomwalters@284: virtual bool InitializeInternal(const SignalBank &input); tomwalters@284: tomwalters@284: float sample_rate_; tomwalters@284: int buffer_length_; tomwalters@284: int channel_count_; tomwalters@284: tomwalters@284: bool temporal_profile_; tomwalters@284: bool take_all_; tomwalters@284: int lower_limit_; tomwalters@284: int upper_limit_; tomwalters@284: bool normalize_slice_; tomwalters@284: int slice_length_; tomwalters@284: }; tomwalters@284: } // namespace aimc tomwalters@284: tomwalters@292: #endif // AIMC_MODULES_PROFILE_SCALER_H_