KDEGames

audio/kgaudioscene.h
1 /***************************************************************************
2  * Copyright 2010 Stefan Majewsky <[email protected]> *
3  * *
4  * This program is free software; you can redistribute it and/or modify *
5  * it under the terms of the GNU Library General Public License *
6  * version 2 as published by the Free Software Foundation *
7  * *
8  * This program is distributed in the hope that it will be useful, *
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
11  * GNU Library General Public License for more details. *
12  * *
13  * You should have received a copy of the GNU Library General Public *
14  * License along with this program; if not, write to the *
15  * Free Software Foundation, Inc., *
16  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
17  ***************************************************************************/
18 
19 #ifndef KGAUDIOSCENE_H
20 #define KGAUDIOSCENE_H
21 
22 #include <QPointF>
23 
24 #include <libkdegames_export.h>
25 
43 namespace KgAudioScene
44 {
48  {
51  SupportsPositionalPlayback = 1 << 1,
52  };
53  Q_DECLARE_FLAGS(Capabilities, Capability)
54 
55 
56  KDEGAMES_EXPORT Capabilities capabilities();
57 
59  KDEGAMES_EXPORT QPointF listenerPos();
63  KDEGAMES_EXPORT void setListenerPos(const QPointF& pos);
65  KDEGAMES_EXPORT qreal volume();
69  KDEGAMES_EXPORT void setVolume(qreal volume);
70 
84  KDEGAMES_EXPORT bool hasError();
85 };
86 
87 Q_DECLARE_OPERATORS_FOR_FLAGS(KgAudioScene::Capabilities)
88 
89 #endif // KGAUDIOSCENE_H
KDEGAMES_EXPORT QPointF listenerPos()
KDEGAMES_EXPORT qreal volume()
Capability
This enumeration represents capabilities which may not be provided by every KgAudio backend...
KDEGAMES_EXPORT void setListenerPos(const QPointF &pos)
Sets the position of the listener.
KDEGAMES_EXPORT void setVolume(qreal volume)
Sets the master volume for sounds outputted by TagaroAudio.
This class exposes general properties of the audio playback context.
Playback starts as soon as KgSound::start is called.
KDEGAMES_EXPORT Capabilities capabilities()
KDEGAMES_EXPORT bool hasError()
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Thu Nov 26 2020 22:36:18 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.