Change the behaviour of ViewArea to support the input of a PlaYUVerFrame

This commit is contained in:
jfmcarreira committed 2014-04-17 20:21:46 +01:00
1 parent cb12f3710f
commit 9e666117b2
5 files changed
+57 -23

No files matched your search

+7 -1
View File
@@ -37,7 +37,6 @@
#include "ViewArea.h"
#include "GridManager.h"
#include "PlaYUVerFrame.h"
#include "InputStream.h"
namespace plaYUVer
@@ -69,6 +68,13 @@ ViewArea::ViewArea( QWidget *parent ) :
m_pStream = NULL;
}
void ViewArea::setImage( PlaYUVerFrame* pcFrame )
{
pcFrame->FrametoRGB8();
QImage qimg = QImage( pcFrame->getQImageBuffer(), pcFrame->getWidth(), pcFrame->getHeight(), QImage::Format_RGB888 );
setImage( QPixmap::fromImage( qimg ) );
}
void ViewArea::setImage( const QPixmap &pixmap )
{
m_pixmap = pixmap;