summaryrefslogtreecommitdiffstats
path: root/src/multimedia/audio
diff options
context:
space:
mode:
authorJonas Rabbe <jonas.rabbe@nokia.com>2012-04-03 15:55:55 +1000
committerQt by Nokia <qt-info@nokia.com>2012-04-05 03:54:02 +0200
commitc532850fd1f55b563930ad6e178e30cf560ee532 (patch)
tree818e0cb5a8fe04193101ba72c15a38243b0e0157 /src/multimedia/audio
parente908790a6a8b6cc779e5ec24ec94f6caf00d354e (diff)
Updated a lot of minor fixes to the docs and removed warnings from qdoc
Change-Id: Ib7fd75fb93c038f9e8fa9d71b6ad01fb27b97622 Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
Diffstat (limited to 'src/multimedia/audio')
-rw-r--r--src/multimedia/audio/qaudiobuffer.cpp5
-rw-r--r--src/multimedia/audio/qaudioprobe.cpp8
-rw-r--r--src/multimedia/audio/qaudiosystemplugin.cpp5
-rw-r--r--src/multimedia/audio/qsound.cpp6
-rw-r--r--src/multimedia/audio/qsoundeffect.cpp81
5 files changed, 73 insertions, 32 deletions
diff --git a/src/multimedia/audio/qaudiobuffer.cpp b/src/multimedia/audio/qaudiobuffer.cpp
index b8287f235..7161e44d4 100644
--- a/src/multimedia/audio/qaudiobuffer.cpp
+++ b/src/multimedia/audio/qaudiobuffer.cpp
@@ -194,13 +194,10 @@ QAudioBufferPrivate *QAudioBufferPrivate::clone()
/*!
\class QAudioBuffer
- \brief A class that represents a collection of audio samples.
\inmodule QtMultimedia
\ingroup multimedia
\ingroup multimedia_audio
-
- The QAudioBuffer class represents a collection of audio samples,
- with a specific format and sample rate.
+ \brief The QAudioBuffer class represents a collection of audio samples with a specific format and sample rate.
*/
// ^ Mostly useful with probe or decoder
diff --git a/src/multimedia/audio/qaudioprobe.cpp b/src/multimedia/audio/qaudioprobe.cpp
index d23b0d10e..6dd7d7258 100644
--- a/src/multimedia/audio/qaudioprobe.cpp
+++ b/src/multimedia/audio/qaudioprobe.cpp
@@ -79,7 +79,7 @@ public:
};
/*!
- Creates a new QAudioProbe class. After setting the
+ Creates a new QAudioProbe class with a \a parent. After setting the
source to monitor with \l setSource(), the \l audioBufferProbed()
signal will be emitted when audio buffers are flowing in the
source media object.
@@ -157,8 +157,8 @@ bool QAudioProbe::setSource(QMediaObject *source)
Returns true on success.
- If \a source is zero, this probe will be deactivated
- and this function will return true.
+ If there is no mediaObject associated with \a mediaRecorder, or if it is
+ zero, this probe will be deactivated and this function wil return true.
If the media recorder instance does not support monitoring
audio, this function will return false.
@@ -194,7 +194,7 @@ bool QAudioProbe::isActive() const
/*!
\fn QAudioProbe::audioBufferProbed(const QAudioBuffer &buffer)
- This signal should be emitted when an audio buffer is processed in the
+ This signal should be emitted when an audio \a buffer is processed in the
media service.
*/
diff --git a/src/multimedia/audio/qaudiosystemplugin.cpp b/src/multimedia/audio/qaudiosystemplugin.cpp
index b99d5654f..a6457f031 100644
--- a/src/multimedia/audio/qaudiosystemplugin.cpp
+++ b/src/multimedia/audio/qaudiosystemplugin.cpp
@@ -106,11 +106,6 @@ QAudioSystemPlugin::~QAudioSystemPlugin()
{}
/*!
- \fn QStringList QAudioSystemPlugin::keys() const
- Returns the list of device identifiers this plugin supports.
-*/
-
-/*!
\fn QList<QByteArray> QAudioSystemPlugin::availableDevices(QAudio::Mode mode) const
Returns a list of available audio devices for \a mode
*/
diff --git a/src/multimedia/audio/qsound.cpp b/src/multimedia/audio/qsound.cpp
index dc07c08b4..d9f93dcee 100644
--- a/src/multimedia/audio/qsound.cpp
+++ b/src/multimedia/audio/qsound.cpp
@@ -80,6 +80,12 @@
\sa QSoundEffect
*/
+/*!
+ \enum QSound::Loop
+
+ \value Infinite Can be used as a parameter to \l setLoops() to loop infinitely.
+*/
+
/*!
Plays the sound stored in the file specified by the given \a filename.
diff --git a/src/multimedia/audio/qsoundeffect.cpp b/src/multimedia/audio/qsoundeffect.cpp
index 6ebbdc8bf..ffaeb3418 100644
--- a/src/multimedia/audio/qsoundeffect.cpp
+++ b/src/multimedia/audio/qsoundeffect.cpp
@@ -55,6 +55,7 @@ QT_BEGIN_NAMESPACE
\inmodule QtMultimedia
\ingroup multimedia_qml
+ \ingroup multimedia_audio_qml
\inqmlmodule QtMultimedia 5
This element is part of the \b{QtMultimedia 5.0} module.
@@ -75,6 +76,22 @@ QT_BEGIN_NAMESPACE
*/
/*!
+ \enum QSoundEffect::Loop
+
+ \value Infinite Used as a parameter to \l loops for infinite looping
+*/
+
+/*!
+ \enum QSoundEffect::Status
+
+ \value Null No source has been set or the source is null.
+ \value Loading The soundeffect is trying to load the source.
+ \value Ready The source is loaded and ready for play.
+ \value Error An error occurred during operation, such as failure of loading the source.
+
+*/
+
+/*!
\qmlproperty url QtMultimedia5::SoundEffect::source
\property QSoundEffect::source
@@ -113,20 +130,23 @@ QT_BEGIN_NAMESPACE
/*!
\qmlproperty bool QtMultimedia5::SoundEffect::playing
- \property QSoundEffect::source
+ \property QSoundEffect::playing
This property indicates if the soundeffect is playing or not.
*/
/*!
- \qmlproperty int QtMultimedia5::SoundEffect::status
+ \qmlproperty enumeration QtMultimedia5::SoundEffect::status
This property indicates the following status of the soundeffect.
- Null: no source has been set or is null.
- Loading: the soundeffect is trying to load the source.
- Ready: the source is loaded and ready for play.
- Error: some error happened during operation, such as failure of loading the source.
+ \table
+ \header \li Value \li Description
+ \row \li SoundEffect.Null \li No source has been set or the source is null.
+ \row \li SoundEffect.Loading \li The soundeffect is trying to load the source.
+ \row \li SoundEffect.Ready \li The source is loaded and ready for play.
+ \row \li SoundEffect.Error \li An error occurred during operation, such as failure of loading the source.
+ \endtable
*/
/*!
@@ -208,6 +228,11 @@ QSoundEffect::~QSoundEffect()
d->release();
}
+/*!
+ \fn QSoundEffect::supportedMimeTypes()
+
+ Returns a list of the supported mime types for this sound effect.
+*/
QStringList QSoundEffect::supportedMimeTypes()
{
return QSoundEffectPrivate::supportedMimeTypes();
@@ -233,6 +258,18 @@ int QSoundEffect::loopCount() const
return d->loopCount();
}
+/*!
+ \qmlproperty int QtMultimedia5::SoundEffect::loopsRemaining
+
+ This property contains the number of loops remaining before the sound effect
+ stops by itself, or SoundEffect.Infinite if that's what has been set in \l loops.
+*/
+/*!
+ \property QSoundEffect::loopsRemaining
+
+ This property contains the number of loops remaining before the sound effect
+ stops by itself, or QSoundEffect::Infinite if that's what has been set in \l loops.
+*/
int QSoundEffect::loopsRemaining() const
{
return d->loopsRemaining();
@@ -284,20 +321,32 @@ void QSoundEffect::setMuted(bool muted)
d->setMuted(muted);
}
+/*!
+ \qmlmethod bool QtMultimedia5::SoundEffect::isLoaded()
+ \fn QSoundEffect::isLoaded() const
+
+ Returns whether the sound effect has finished loading the \l source.
+*/
bool QSoundEffect::isLoaded() const
{
return d->isLoaded();
}
/*!
- \qmlmethod QtMultimedia5::SoundEffect::play()
+ \qmlmethod QtMultimedia5::SoundEffect::play()
- Start playback of the sound effect, looping the effect for the number of
- times as specified in the loops property.
+ Start playback of the sound effect, looping the effect for the number of
+ times as specified in the loops property.
- This is the default method for SoundEffect.
+ This is the default method for SoundEffect.
- \snippet doc/src/snippets/multimedia-snippets/soundeffect.qml play sound on click
+ \snippet doc/src/snippets/multimedia-snippets/soundeffect.qml play sound on click
+*/
+/*!
+ \fn QSoundEffect::play()
+
+ Start playback of the sound effect, looping the effect for the number of
+ times as specified in the loops property.
*/
void QSoundEffect::play()
{
@@ -310,14 +359,6 @@ bool QSoundEffect::isPlaying() const
}
/*!
- \enum QSoundEffect::Status
- \value Null This sound effect does not have a source set.
- \value Loading The source is being loaded
- \value Ready The source has been loaded, and can be played.
- \value Error An error occurred while loading the source or during playback.
-*/
-
-/*!
Returns the current status of this sound effect.
*/
QSoundEffect::Status QSoundEffect::status() const
@@ -328,8 +369,10 @@ QSoundEffect::Status QSoundEffect::status() const
/*!
\qmlmethod QtMultimedia5::SoundEffect::stop()
+ \fn QSoundEffect::stop()
Stop current playback.
+
Note that if the backend is PulseAudio, due to the limitation of the underlying API,
tis stop will only prevent next looping but will not be able to stop current playback immediately.