uvcvideorenderercontrol.cpp 564 Bytes
Newer Older
Thiago Santini's avatar
Thiago Santini committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
#include "uvcvideorenderercontrol.h"

QT_BEGIN_NAMESPACE

UVCVideoRendererControl::UVCVideoRendererControl(UVCCameraSession* session, QObject *parent)
    :QVideoRendererControl(parent),
    m_surface(NULL),
    m_session(session)
{
}

UVCVideoRendererControl::~UVCVideoRendererControl()
{
}

QAbstractVideoSurface* UVCVideoRendererControl::surface() const
{
    return m_surface;
}

void UVCVideoRendererControl::setSurface(QAbstractVideoSurface *surface)
{
    m_surface = surface;
    if(m_session)
        m_session->setSurface(m_surface);
}

QT_END_NAMESPACE