Gstreamer media backend cleanup.

Moved controls specific bus/sync messages handling from
player/camera/capture session to corresponding controls.

Reviewed-by: Michael Goddard
Change-Id: Ieb67976ed335b0ef1cde87dc60e8ad8da3409526
Reviewed-on: http://codereview.qt.nokia.com/2535
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
This commit is contained in:
Dmytro Poplavskiy
2011-08-02 14:33:38 +10:00
committed by Qt by Nokia
parent 6eac3bd648
commit e70ebfd2ed
20 changed files with 211 additions and 165 deletions

View File

@@ -115,14 +115,23 @@ void QGstreamerVideoWindow::setWinId(WId id)
emit readyChanged(false);
}
void QGstreamerVideoWindow::precessNewStream()
bool QGstreamerVideoWindow::processSyncMessage(const QGstreamerMessage &message)
{
if (m_videoSink && GST_IS_X_OVERLAY(m_videoSink)) {
GstMessage* gm = message.rawMessage();
if ((GST_MESSAGE_TYPE(gm) == GST_MESSAGE_ELEMENT) &&
gst_structure_has_name(gm->structure, "prepare-xwindow-id") &&
m_videoSink && GST_IS_X_OVERLAY(m_videoSink)) {
gst_x_overlay_set_xwindow_id(GST_X_OVERLAY(m_videoSink), m_windowId);
GstPad *pad = gst_element_get_static_pad(m_videoSink,"sink");
m_bufferProbeId = gst_pad_add_buffer_probe(pad, G_CALLBACK(padBufferProbe), this);
return true;
}
return false;
}
QRect QGstreamerVideoWindow::displayRect() const