[英]no such element “v4l2src” using gstreamer-1.0, but exists in gstreamer-0.10 [UBUNTU 16.04.2 LTS]
I'm having trouble with v4l2src in gstreamer-1.0, but it appears to be there in gstreamer-0.10.我在 gstreamer-1.0 中遇到了 v4l2src 问题,但它似乎在 gstreamer-0.10 中。 I've searched around online but none of the suggestions seems to make any difference.我在网上搜索过,但没有任何建议似乎有任何区别。 I've included a bunch of results below.我在下面列出了一堆结果。 Is there anything else I can try?还有什么我可以尝试的吗?
Update: @alper-kucukkomurler is correct.更新:@alper-kucukkomurler 是正确的。 I have anaconda installed and which gst-inspect-1.0
is returning ~/anaconda2/bin
.我已经安装了 anaconda 并且which gst-inspect-1.0
正在返回~/anaconda2/bin
。 Removing anaconda from my path does resolve the issue.从我的路径中删除 anaconda 确实解决了这个问题。 However, I'd prefer a solution which keeps anaconda in the path if possible.但是,如果可能的话,我更喜欢一种将 anaconda 保留在路径中的解决方案。 Is there a way to make this work?有没有办法使这项工作? (I do have gstreamer and gst-plugins-base packages installed in anaconda). (我确实在 anaconda 中安装了 gstreamer 和 gst-plugins-base 软件包)。
Update2: A tip came from another forum https://forum.openframeworks.cc/t/error-ofgstutils-error-getting-device-data-no-element-v4l2src/26908/6更新 2:来自另一个论坛的提示https://forum.openframeworks.cc/t/error-ofgstutils-error-getting-device-data-no-element-v4l2src/26908/6
pointing to this post GStreamer plugin search path?指向这篇文章GStreamer 插件搜索路径?
discussing GST_PLUGIN_PATH.讨论 GST_PLUGIN_PATH。 I actually don't have such an env variable.我实际上没有这样的环境变量。 But it is an additional point of info.但这是一个额外的信息点。
$ sudo apt-get install gstreamer1.0-plugins-good
Reading package lists... Done
Building dependency tree
Reading state information... Done
gstreamer1.0-plugins-good is already the newest version (1.8.3-1ubuntu0.4).
0 to upgrade, 0 to newly install, 0 to remove and 0 not to upgrade.
# (I've tried --reinstall too)
$ locate libgstvideo4linux2.so
/usr/lib/x86_64-linux-gnu/gstreamer-0.10/libgstvideo4linux2.so
/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstvideo4linux2.so
$ gst-inspect-1.0 -b
Blacklisted files:
Total count: 0 blacklisted files
$ gst-inspect-0.10 -b
Blacklisted files:
Total count: 0 blacklisted files
$ gst-launch-1.0 v4l2src
ERROR: pipeline could not be constructed: no element "v4l2src".
$ gst-launch-0.10 v4l2src
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Internal data flow error.
Additional debug info:
gstbasesrc.c(2625): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
streaming task paused, reason not-linked (-1)
Execution ended after 2089256849 ns.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...
$ gst-inspect-1.0 v4l2src
No such element or plugin 'v4l2src'
$ gst-inspect-0.10 v4l2src
Factory Details:
Long name: Video (video4linux2) Source
Class: Source/Video
Description: Reads frames from a Video4Linux2 device
Author(s): Edgard Lima <edgard.lima@indt.org.br>, Stefan Kost <ensonic@users.sf.net>
Rank: primary (256)
Plugin Details:
Name: video4linux2
Description: elements for Video 4 Linux
Filename: /usr/lib/x86_64-linux-gnu/gstreamer-0.10/libgstvideo4linux2.so
Version: 0.10.31
License: LGPL
Source module: gst-plugins-good
Source release date: 2012-02-20
Binary package: GStreamer Good Plugins (Ubuntu)
Origin URL: https://launchpad.net/distros/ubuntu/+source/gst-plugins-good0.10
...
...
$ uname -a
Linux MSA-BLADE-UBUNTU 4.11.3-041103-generic #201705251233 SMP Thu May 25 16:34:52 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.2 LTS
Release: 16.04
Codename: xenial
You may have the same problem as I did, I was missing one .so
file which was on one folder out of my dynamic shared libraries path.您可能遇到了和我一样的问题,我丢失了一个.so
文件,该文件位于我的动态共享库路径之外的一个文件夹中。 I could see that by following the steps in described here .按照此处描述的步骤,我可以看到这一点。 To solve that I had to run export LD_LIBRARY_PATH=/lib:/usr/lib:/usr/local/lib
为了解决这个问题,我必须运行export LD_LIBRARY_PATH=/lib:/usr/lib:/usr/local/lib
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.