簡體   English   中英

Qt 上的 GStreamer 用於 iOS

[英]GStreamer on Qt for iOS

我正在嘗試開發一個 iOS 應用程序(iPad 應該是主要目標)來控制連接到同一網絡的設備(Linux 嵌入式)。

基本上它是一個遠程桌面應用程序。

應用程序必須是多平台的,因此它已構建在多平台框架內。 通過使用QtQt Creator開發應用程序來滿足此要求。

應用程序應播放從 Linux 設備通過網絡傳輸的 stream 視頻 stream。 我為此使用GStreamer I already downloaded and succesfully installed the iOS package from the official site ( https://gstreamer.freedesktop.org/documentation/installing/for-ios-development.html?gi-language=c. ).

到目前為止,我已經設法正確鏈接庫並在模擬器中成功運行項目,但是當我嘗試創建 GStreamer 元素時,它在運行時失敗。

這是我的.pro

#iOS
INCLUDEPATH += /Users/user/Library/Developer/GStreamer/iPhone.sdk/GStreamer.framework/Headers
LIBS += -F /Users/user/Library/Developer/GStreamer/iPhone.sdk -framework GStreamer

LIBS += -L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib -liconv

QMAKE_IOS_DEPLOYMENT_TARGET = 12.0

#Universal target (iPhone and iPad)
QMAKE_APPLE_TARGETED_DEVICE_FAMILY = 1,2

QMAKE_APPLE_DEVICE_ARCHS = arm64
QMAKE_APPLE_SIMULATOR_ARCHS = x86_64

這是應用程序失敗的地方:

data.pipeline = gst_pipeline_new ("pipeline");
qDebug() << "pipeline" << data.pipeline;

data.udpsrc = gst_element_factory_make("udpsrc", NULL);
data.rtph264depay = gst_element_factory_make("rtph264depay", NULL);
data.avdec_h264 = gst_element_factory_make("avdec_h264", NULL);
data.videoconvert = gst_element_factory_make("videoconvert", NULL);
data.videoflip = gst_element_factory_make ("videoflip", NULL);

qDebug() << "udpsrc" << data.udpsrc;
qDebug() << "rtph264depay" << data.rtph264depay;
qDebug() << "avdec_h264" << data.avdec_h264;
qDebug() << "videoconvert" << data.videoconvert;
qDebug() << "videoflip" << data.videoflip;

所有對 gst_element_factory_make 的調用都返回 null。

附加信息

  • Qt 5.15.2
  • Xcode 12.5
  • 在大蘇爾開發

有任何想法嗎?

謝謝

問題是插件(udpsrc、rtph264depay、avdec_h264 等屬於)必須靜態鏈接。 https://forum.qt.io/topic/126746/gstreamer-on-ios中解釋的解決方案

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM