diff options
author | Kurt Korbatits <kurt.korbatits@nokia.com> | 2009-11-10 13:07:46 +1000 |
---|---|---|
committer | Kurt Korbatits <kurt.korbatits@nokia.com> | 2009-11-10 13:07:46 +1000 |
commit | 74d3a4bf9654c8bbe9139951cc5c9352015438a6 (patch) | |
tree | 63cc04b5546454fcf668125169c6793fcdbdf04c /src/multimedia/audio/qaudioformat.cpp | |
parent | 8df98549a4d84b5877e50318140c2041e17632fb (diff) | |
download | qt4-tools-74d3a4bf9654c8bbe9139951cc5c9352015438a6.tar.gz |
Changes to low-level audio API.
QAudioFormat::isNull() -> QAudioFormat::isValid() (inverse logic)
QAudio::SuspendState -> QAudio::SuspendedState
QAudio::StopState -> QAudio::StoppedState
QAudioDeviceInfo::deviceList() ->
QAudioDeviceInfo::availableDevices()
clock() -> elapsedUSecs()
totalTime() -> processedUSecs()
QIODevice* start(QIODevice*) -> void
start(QIODevice*), QIODevice*
start()
Reviewed-by:Justin McPherson
Diffstat (limited to 'src/multimedia/audio/qaudioformat.cpp')
-rw-r--r-- | src/multimedia/audio/qaudioformat.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/multimedia/audio/qaudioformat.cpp b/src/multimedia/audio/qaudioformat.cpp index b2bbe144e9..86fe85b7a7 100644 --- a/src/multimedia/audio/qaudioformat.cpp +++ b/src/multimedia/audio/qaudioformat.cpp @@ -38,7 +38,7 @@ ** $QT_END_LICENSE$ ** ****************************************************************************/ -#include <QDebug> + #include <QtMultimedia/qaudioformat.h> @@ -214,13 +214,16 @@ bool QAudioFormat::operator!=(const QAudioFormat& other) const } /*! - Returns true if all of the parameters are valid. + Returns true if any of the parameters are invalid. */ -bool QAudioFormat::isValid() const +bool QAudioFormat::isNull() const { - return d->frequency != -1 && d->channels != -1 && d->sampleSize != -1 && - d->sampleType != QAudioFormat::Unknown && !d->codec.isEmpty(); + return d->frequency == -1 && d->channels == -1 && + d->sampleSize == -1 && + d->byteOrder == QAudioFormat::Endian(QSysInfo::ByteOrder) && + d->sampleType == QAudioFormat::Unknown && + d->codec.isNull(); } /*! |