summaryrefslogtreecommitdiffstats
path: root/src/multimedia/audio/qaudioformat.cpp
diff options
context:
space:
mode:
authorMithra Pattison <mithra.pattison@nokia.com>2012-07-10 13:26:48 +1000
committerQt by Nokia <qt-info@nokia.com>2012-07-10 08:26:04 +0200
commit53fdcca36650970568f14b81814eb627cbabea43 (patch)
treea216aeb092d0ce10a0e5a7d163b23e704fddabd4 /src/multimedia/audio/qaudioformat.cpp
parent952bd004bec78c6ae43253dc42d897c42c9f90cd (diff)
Delete obsolete class methods and update related code
Delete obsolete methods from QAudioFormat and QAudioDeviceInfo and update code that relied on the obsolete methods. Change-Id: I007e36375a45399b1d5a289341bc5d5a05dc68cc Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
Diffstat (limited to 'src/multimedia/audio/qaudioformat.cpp')
-rw-r--r--src/multimedia/audio/qaudioformat.cpp56
1 files changed, 8 insertions, 48 deletions
diff --git a/src/multimedia/audio/qaudioformat.cpp b/src/multimedia/audio/qaudioformat.cpp
index a1ece4fcd..c91620b37 100644
--- a/src/multimedia/audio/qaudioformat.cpp
+++ b/src/multimedia/audio/qaudioformat.cpp
@@ -64,7 +64,7 @@ class QAudioFormatPrivate : public QSharedData
public:
QAudioFormatPrivate()
{
- frequency = -1;
+ sampleRate = -1;
channels = -1;
sampleSize = -1;
byteOrder = QAudioFormat::Endian(QSysInfo::ByteOrder);
@@ -76,7 +76,7 @@ public:
codec(other.codec),
byteOrder(other.byteOrder),
sampleType(other.sampleType),
- frequency(other.frequency),
+ sampleRate(other.sampleRate),
channels(other.channels),
sampleSize(other.sampleSize)
{
@@ -87,7 +87,7 @@ public:
codec = other.codec;
byteOrder = other.byteOrder;
sampleType = other.sampleType;
- frequency = other.frequency;
+ sampleRate = other.sampleRate;
channels = other.channels;
sampleSize = other.sampleSize;
@@ -97,7 +97,7 @@ public:
QString codec;
QAudioFormat::Endian byteOrder;
QAudioFormat::SampleType sampleType;
- int frequency;
+ int sampleRate;
int channels;
int sampleSize;
};
@@ -206,7 +206,7 @@ QAudioFormat& QAudioFormat::operator=(const QAudioFormat &other)
*/
bool QAudioFormat::operator==(const QAudioFormat &other) const
{
- return d->frequency == other.d->frequency &&
+ return d->sampleRate == other.d->sampleRate &&
d->channels == other.d->channels &&
d->sampleSize == other.d->sampleSize &&
d->byteOrder == other.d->byteOrder &&
@@ -230,7 +230,7 @@ bool QAudioFormat::operator!=(const QAudioFormat& other) const
*/
bool QAudioFormat::isValid() const
{
- return d->frequency != -1 && d->channels != -1 && d->sampleSize != -1 &&
+ return d->sampleRate != -1 && d->channels != -1 && d->sampleSize != -1 &&
d->sampleType != QAudioFormat::Unknown && !d->codec.isEmpty();
}
@@ -240,17 +240,7 @@ bool QAudioFormat::isValid() const
*/
void QAudioFormat::setSampleRate(int samplerate)
{
- d->frequency = samplerate;
-}
-
-/*!
- \obsolete
-
- Use setSampleRate() instead.
-*/
-void QAudioFormat::setFrequency(int frequency)
-{
- d->frequency = frequency;
+ d->sampleRate = samplerate;
}
/*!
@@ -259,17 +249,7 @@ void QAudioFormat::setFrequency(int frequency)
*/
int QAudioFormat::sampleRate() const
{
- return d->frequency;
-}
-
-/*!
- \obsolete
-
- Use sampleRate() instead.
-*/
-int QAudioFormat::frequency() const
-{
- return d->frequency;
+ return d->sampleRate;
}
/*!
@@ -282,16 +262,6 @@ void QAudioFormat::setChannelCount(int channels)
}
/*!
- \obsolete
-
- Use setChannelCount() instead.
-*/
-void QAudioFormat::setChannels(int channels)
-{
- d->channels = channels;
-}
-
-/*!
Returns the current channel count value.
*/
@@ -301,16 +271,6 @@ int QAudioFormat::channelCount() const
}
/*!
- \obsolete
-
- Use channelCount() instead.
-*/
-int QAudioFormat::channels() const
-{
- return d->channels;
-}
-
-/*!
Sets the sample size to the \a sampleSize specified, in bits.
This is typically 8 or 16, but some systems may support higher sample sizes.