author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Fri, 19 Feb 2010 23:40:16 +0200 | |
branch | RCL_3 |
changeset 4 | 3b1da2848fc7 |
parent 0 | 1918ee327afb |
permissions | -rw-r--r-- |
0 | 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 |
||
4
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
24 |
class CAudioEqualizer; |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
25 |
|
0 | 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: |
|
4
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
44 |
AudioEqualizer(QObject *parent, const QList<EffectParameter> ¶meters); |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
45 |
|
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
46 |
// Static interface required by EffectFactory |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
47 |
static const char* description(); |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
48 |
static bool getParameters(CMdaAudioOutputStream *stream, |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
49 |
QList<EffectParameter>& parameters); |
0 | 50 |
|
51 |
protected: |
|
4
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
52 |
// AbstractAudioEffect |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
53 |
virtual void createEffect(AudioPlayer::NativePlayer *player); |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
54 |
virtual int effectParameterChanged(const EffectParameter ¶m, |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
55 |
const QVariant &value); |
0 | 56 |
|
57 |
private: |
|
4
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
58 |
CAudioEqualizer *concreteEffect(); |
3b1da2848fc7
Revision: 201003
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
59 |
|
0 | 60 |
}; |
61 |
} |
|
62 |
} |
|
63 |
||
64 |
QT_END_NAMESPACE |
|
65 |
||
66 |
#endif |
|
67 |