summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/phonon/mmf/videowidget.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/phonon/mmf/videowidget.cpp')
-rw-r--r--src/3rdparty/phonon/mmf/videowidget.cpp23
1 files changed, 19 insertions, 4 deletions
diff --git a/src/3rdparty/phonon/mmf/videowidget.cpp b/src/3rdparty/phonon/mmf/videowidget.cpp
index bc9acfd..4ed9979 100644
--- a/src/3rdparty/phonon/mmf/videowidget.cpp
+++ b/src/3rdparty/phonon/mmf/videowidget.cpp
@@ -18,10 +18,15 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
#include "mediaobject.h"
#include "utils.h"
-#include "videooutput.h"
#include "videowidget.h"
+#ifdef PHONON_MMF_VIDEO_SURFACES
+#include "videooutput_surface.h"
+#else
+#include "videooutput_dsa.h"
+#endif
+
QT_BEGIN_NAMESPACE
using namespace Phonon;
@@ -45,10 +50,13 @@ static const qreal DefaultSaturation = 1.0;
// Constructor / destructor
//-----------------------------------------------------------------------------
-MMF::VideoWidget::VideoWidget
- (AncestorMoveMonitor* ancestorMoveMonitor, QWidget* parent)
+MMF::VideoWidget::VideoWidget(QWidget *parent)
: MediaNode(parent)
- , m_videoOutput(new VideoOutput(ancestorMoveMonitor, parent))
+#ifdef PHONON_MMF_VIDEO_SURFACES
+ , m_videoOutput(new SurfaceVideoOutput(parent))
+#else
+ , m_videoOutput(new DsaVideoOutput(parent))
+#endif
, m_brightness(DefaultBrightness)
, m_contrast(DefaultContrast)
, m_hue(DefaultHue)
@@ -68,6 +76,13 @@ MMF::VideoWidget::~VideoWidget()
TRACE_EXIT_0();
}
+#ifndef PHONON_MMF_VIDEO_SURFACES
+void MMF::VideoWidget::setAncestorMoveMonitor(AncestorMoveMonitor *monitor)
+{
+ static_cast<DsaVideoOutput *>(m_videoOutput.data())->setAncestorMoveMonitor(monitor);
+}
+#endif
+
//-----------------------------------------------------------------------------
// VideoWidgetInterface