diff --git a/src/VideoStreaming/VideoStreaming.cc b/src/VideoStreaming/VideoStreaming.cc index 92bd7e87d9ee63c5f7006b1d87e1086aec7fe66e..4b45adbc5c6e5d8d521130f31a5cf496f2401313 100644 --- a/src/VideoStreaming/VideoStreaming.cc +++ b/src/VideoStreaming/VideoStreaming.cc @@ -42,16 +42,12 @@ #endif #if defined(QGC_GST_STREAMING) -#if defined(__macos__) -#ifdef QGC_INSTALL_RELEASE static void qgcputenv(const QString& key, const QString& root, const QString& path) { QString value = root + path; qputenv(key.toStdString().c_str(), QByteArray(value.toStdString().c_str())); } #endif -#endif -#endif void initializeVideoStreaming(int &argc, char* argv[]) { @@ -67,6 +63,9 @@ void initializeVideoStreaming(int &argc, char* argv[]) qgcputenv("GST_PLUGIN_PATH_1_0", currentDir, "/../Frameworks/GStreamer.framework/Versions/Current/lib/gstreamer-1.0"); qgcputenv("GST_PLUGIN_PATH", currentDir, "/../Frameworks/GStreamer.framework/Versions/Current/lib/gstreamer-1.0"); #endif + #elif defined(Q_OS_WIN) + QString currentDir = QCoreApplication::applicationDirPath(); + qgcputenv("GST_PLUGIN_PATH", currentDir, "/gstreamer-plugins"); #endif // Initialize GStreamer GError* error = NULL;