1
/*  This file is part of the KDE project.
2
3
Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
4
5
This library is free software: you can redistribute it and/or modify
6
it under the terms of the GNU Lesser General Public License as published by
7
the Free Software Foundation, either version 2.1 or 3 of the License.
8
9
This library is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
GNU Lesser General Public License for more details.
13
14
You should have received a copy of the GNU Lesser General Public License
15
along with this library.  If not, see <http://www.gnu.org/licenses/>.
16
17
*/
18
19
#ifndef PHONON_MMF_AUDIOEQUALIZER_H
20
#define PHONON_MMF_AUDIOEQUALIZER_H
21
22
#include "abstractaudioeffect.h"
23
24
class CAudioEqualizer;
25
26
QT_BEGIN_NAMESPACE
27
28
namespace Phonon
29
{
30
namespace MMF
31
{
32
/**
33
 * @short A classic equalizer.
34
 *
35
 * The equalizer has a number of bands, and each band has a frequency, and a
36
 * volume. With Phonon's API, this is modeled such that each band is one
37
 * Phonon::EffectParameter, where Phonon::EffectParameter::id() is the band
38
 * number, and the setting is the volume level.
39
 */
40
class AudioEqualizer : public AbstractAudioEffect
41
{
42
    Q_OBJECT
43
public:
44
    AudioEqualizer(QObject *parent, const QList<EffectParameter> &parameters);
45
46
    // Static interface required by EffectFactory
47
    static const char* description();
48
    static bool getParameters(CMdaAudioOutputStream *stream,
49
        QList<EffectParameter>& parameters);
50
51
protected:
52
    // AbstractAudioEffect
53
    virtual void createEffect(AudioPlayer::NativePlayer *player);
54
    virtual int effectParameterChanged(const EffectParameter &param,
55
                                       const QVariant &value);
56
57
private:
58
    CAudioEqualizer *concreteEffect();
59
60
};
61
}
62
}
63
64
QT_END_NAMESPACE
65
66
#endif