簡體   English   中英

ubuntu 上的 gstreamer RTSP - 警告:錯誤的管道:沒有元素“rtspsrc”

[英]gstreamer RTSP on ubuntu - WARNING: erroneous pipeline: no element "rtspsrc"

讓我自己處於某種狀態。 我一直在嘗試讓 opencv 使用 gstreamer,在最終設法從源代碼編譯並讓它接收 gstreamer 之后,它無法正常工作。

所以我已經進入命令行以確保它首先在那里工作,並且我已經嘗試了所有方法但 gstreamer 沒有選擇“rtspsrc”。

我在終端中運行以下。

gst-launch-1.0 rtspsrc location=rtsp://admin:[**mypassword**]@192.168.0.40/h264Preview_01_main ! decodebin ! videoconvert ! appsink max-buffers=1 drop=true")

但是我收到以下錯誤,有人知道為什么會這樣嗎?

WARNING: erroneous pipeline: no element "rtspsrc"

運行 ubuntu - gstreamer1.0

Rtspsrc 是 Gst-plugins-good 的一部分。 你確定你安裝了那些?

如果沒有,請嘗試使用以下方法安裝它:

apt install libgstreamer-plugins-good1.0-0 libgstreamer-plugins-good1.0-dev gstreamer1.0-plugins-good

檢查 GStreamer 是否可以找到該插件。 在終端中運行以下命令:

gst-inspect-1.0 rtspsrc

如果它返回各種詳細信息,它可以正確找到插件。 如果找不到,它將返回:

No such element or plugin 'rtspsrc'

(編輯)

正如 OP 所說,對他來說

which gst-launch-1.0

返回

/home/lewis/anaconda3/bin

所以顯然 GStreamer 是通過 Anaconda 安裝的,這意味着通過 Anaconda 安裝插件可能是最簡單的。 我對 Anaconda 沒有任何具體經驗,但它認為以下應該有效:

conda install -c conda-forge gst-plugins-good

如果還缺少其他元素,也可以安裝plugins-base/bad

問題是當使用 apt-get 插件安裝到 /usr/bin

which gst-launch-1.0

返回 /home/lewis/anaconda3/bin

我不確定該怎么做,但在 linux 頁面上提出了一個新問題。

https://unix.stackexchange.com/questions/575262/whereis-gstreamer-located-in-two-paths-causing-issues

請注意,盡管 RTSP 組件位於 Debian/Ubuntu 上的一組good的插件中,但它們已被分離到自己的包中:

sudo apt install gstreamer1.0-rtsp

暫無
暫無

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

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