Commit b2fe913c authored by Andrew Voznytsa's avatar Andrew Voznytsa

Implement GLVideoItem stub for no-gstreamer builds

parent bb763854
......@@ -331,13 +331,6 @@ contains (DEFINES, QGC_DISABLE_PAIRING) {
DEFINES += QGC_ENABLE_PAIRING
}
#
# Add qmlglsink (libs/gst-plugins-good/ext/qt)
#
include(qmlglsink.pri)
#
# External library configuration
#
......
#include "GLVideoItemStub.h"
GLVideoItemStub::GLVideoItemStub()
{
// setFlag(QQuickItem::ItemHasContents, true);
}
GLVideoItemStub::~GLVideoItemStub()
{
}
//QSGNode*
//GLVideoItemStub::updatePaintNode(QSGNode* oldNode, UpdatePaintNodeData* updatePaintNodeData)
//{
// return oldNode;
//}
#pragma once
#include <QtQuick/QQuickItem>
class GLVideoItemStub : public QQuickItem
{
Q_OBJECT
public:
GLVideoItemStub();
~GLVideoItemStub();
protected:
// QSGNode* updatePaintNode(QSGNode* oldNode, UpdatePaintNodeData* updatePaintNodeData);
private:
};
......@@ -25,6 +25,8 @@
#if defined(__ios__)
#include "gst_ios_init.h"
#endif
#else
#include "GLVideoItemStub.h"
#endif
#include "VideoStreaming.h"
......@@ -183,9 +185,10 @@ void initializeVideoStreaming(int &argc, char* argv[], char* logpath, char* debu
qCritical() << "unable to find qmlglsink - you need to build it yourself and add to GST_PLUGIN_PATH";
}
#else
Q_UNUSED(argc);
Q_UNUSED(argv);
Q_UNUSED(logpath);
Q_UNUSED(debuglevel);
qmlRegisterType<GLVideoItemStub> ("org.freedesktop.gstreamer.GLVideoItem", 1, 0, "GstGLVideoItem");
Q_UNUSED(argc)
Q_UNUSED(argv)
Q_UNUSED(logpath)
Q_UNUSED(debuglevel)
#endif
}
......@@ -17,5 +17,3 @@
#pragma once
extern void initializeVideoStreaming (int &argc, char *argv[], char* filename, char* debuglevel);
......@@ -126,6 +126,7 @@ VideoEnabled {
$$PWD/iOS
}
include($$PWD/../../qmlglsink.pri)
} else {
LinuxBuild|MacBuild|iOSBuild|WindowsBuild|AndroidBuild {
message("Skipping support for video streaming (GStreamer libraries not installed)")
......@@ -133,5 +134,10 @@ VideoEnabled {
} else {
message("Skipping support for video streaming (Unsupported platform)")
}
}
SOURCES += \
$$PWD/GLVideoItemStub.cc
HEADERS += \
$$PWD/GLVideoItemStub.h
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment