summaryrefslogtreecommitdiff
path: root/src/plugins/gstreamer/mediacapture
diff options
context:
space:
mode:
authorDmytro Poplavskiy <dmytro.poplavskiy@nokia.com>2012-01-31 10:08:49 +1000
committerQt by Nokia <qt-info@nokia.com>2012-02-01 08:10:20 +0100
commita22a0195f146e83174ee4eacffe33c161ab39e50 (patch)
treeecc72efc2790bce4238c8c1c9df223f54c0b3651 /src/plugins/gstreamer/mediacapture
parent9d3102efe29e294971b30aa2ce00be5cb7db5e05 (diff)
downloadqtmultimedia-a22a0195f146e83174ee4eacffe33c161ab39e50.tar.gz
Split QMediaRecorder::setEncodingSettings to separate setters.
It's easier to change only the necessary part of encoding settings. The settings are applied during the next event loop or before recording starts. Change-Id: Ia2b5c93826a302212aa7f79a0c75e4cbaaf1dd7a Reviewed-by: Ling Hu <ling.hu@nokia.com> Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
Diffstat (limited to 'src/plugins/gstreamer/mediacapture')
-rw-r--r--src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.cpp2
-rw-r--r--src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.h6
-rw-r--r--src/plugins/gstreamer/mediacapture/qgstreamerrecordercontrol.cpp6
3 files changed, 7 insertions, 7 deletions
diff --git a/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.cpp b/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.cpp
index 3e57cc786..12297bac5 100644
--- a/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.cpp
+++ b/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.cpp
@@ -101,7 +101,7 @@ QGstreamerMediaContainerControl::QGstreamerMediaContainerControl(QObject *parent
}
//if (!m_supportedContainers.isEmpty())
- // setContainerMimeType(m_supportedContainers[0]);
+ // setContainerFormat(m_supportedContainers[0]);
}
QSet<QString> QGstreamerMediaContainerControl::supportedStreamTypes(GstElementFactory *factory, GstPadDirection direction)
diff --git a/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.h b/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.h
index 68a0b0b56..75d7e8eb7 100644
--- a/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.h
+++ b/src/plugins/gstreamer/mediacapture/qgstreamermediacontainercontrol.h
@@ -59,12 +59,12 @@ public:
virtual ~QGstreamerMediaContainerControl() {};
virtual QStringList supportedContainers() const { return m_supportedContainers; }
- virtual QString containerMimeType() const { return m_format; }
- virtual void setContainerMimeType(const QString &formatMimeType) { m_format = formatMimeType; }
+ virtual QString containerFormat() const { return m_format; }
+ virtual void setContainerFormat(const QString &formatMimeType) { m_format = formatMimeType; }
virtual QString containerDescription(const QString &formatMimeType) const { return m_containerDescriptions.value(formatMimeType); }
- QByteArray formatElementName() const { return m_elementNames.value(containerMimeType()); }
+ QByteArray formatElementName() const { return m_elementNames.value(containerFormat()); }
QSet<QString> supportedStreamTypes(const QString &container) const;
diff --git a/src/plugins/gstreamer/mediacapture/qgstreamerrecordercontrol.cpp b/src/plugins/gstreamer/mediacapture/qgstreamerrecordercontrol.cpp
index 958551fb7..c9e8d454c 100644
--- a/src/plugins/gstreamer/mediacapture/qgstreamerrecordercontrol.cpp
+++ b/src/plugins/gstreamer/mediacapture/qgstreamerrecordercontrol.cpp
@@ -152,10 +152,10 @@ void QGstreamerRecorderControl::applySettings()
bool needVideo = m_session->captureMode() & QGstreamerCaptureSession::Video;
QStringList containerCandidates;
- if (mediaContainerControl->containerMimeType().isEmpty())
+ if (mediaContainerControl->containerFormat().isEmpty())
containerCandidates = mediaContainerControl->supportedContainers();
else
- containerCandidates << mediaContainerControl->containerMimeType();
+ containerCandidates << mediaContainerControl->containerFormat();
QStringList audioCandidates;
@@ -221,7 +221,7 @@ void QGstreamerRecorderControl::applySettings()
if (container.isEmpty()) {
emit error(QMediaRecorder::FormatError, tr("Not compatible codecs and container format."));
} else {
- mediaContainerControl->setContainerMimeType(container);
+ mediaContainerControl->setContainerFormat(container);
if (needAudio) {
QAudioEncoderSettings audioSettings = audioEncodeControl->audioSettings();