没有这样的元素“;v4l2src“;使用gstreamer-1.0,但存在于gstreamer-0.10[UBUNTU 16.04.2 LTS]

没有这样的元素“;v4l2src“;使用gstreamer-1.0,但存在于gstreamer-0.10[UBUNTU 16.04.2 LTS],ubuntu,anaconda,gstreamer,ubuntu-16.04,v4l2,Ubuntu,Anaconda,Gstreamer,Ubuntu 16.04,V4l2,我在gstreamer-1.0中使用v4l2src时遇到了问题,但在gstreamer-0.10中它似乎存在。我在网上搜索过,但这些建议似乎都没有什么不同。我在下面列出了一些结果。还有什么我可以试试的吗 更新:@alper kucukkomurler是正确的。我已经安装了anaconda并且哪个gst-inspect-1.0正在返回~/anaconda2/bin。从我的路径中移除蟒蛇确实解决了这个问题。然而,如果可能的话,我更喜欢一种让水蟒留在路径上的解决方案。有没有办法让这一切顺利进行?(我

我在gstreamer-1.0中使用v4l2src时遇到了问题,但在gstreamer-0.10中它似乎存在。我在网上搜索过,但这些建议似乎都没有什么不同。我在下面列出了一些结果。还有什么我可以试试的吗


更新:@alper kucukkomurler是正确的。我已经安装了anaconda并且
哪个gst-inspect-1.0
正在返回
~/anaconda2/bin
。从我的路径中移除蟒蛇确实解决了这个问题。然而,如果可能的话,我更喜欢一种让水蟒留在路径上的解决方案。有没有办法让这一切顺利进行?(我确实在anaconda中安装了gstreamer和gst插件基本包)


更新2:来自另一个论坛的提示

指向这个帖子

讨论GST_插件_路径。我实际上没有这样的环境变量。但这是一个额外的信息点


$sudo apt get install gstreamer1.0-plugins-good
正在阅读软件包列表。。。多恩
构建依赖树
正在读取状态信息。。。多恩
gstreamer1.0-plugins-good已经是最新版本(1.8.3-1ubuntu0.4)。
0要升级,0要新安装,0要删除,0不升级。
#(我也试过重新安装)
$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
黑名单文件:
总数:0个被列入黑名单的文件
$gst-inspect-0.10-b
黑名单文件:
总数:0个被列入黑名单的文件
$gst-launch-1.0 v4l2src
错误:无法构造管道:没有元素“v4l2src”。
$gst-launch-0.10 v4l2src
正在将管道设置为暂停。。。
管道是带电的,不需要预滚。。。
正在将管道设置为播放。。。
新时钟:GstSystemClock
错误:来自元素/GstPipeline:pipeline0/GstV4l2Src:v4l2src0:内部数据流错误。
其他调试信息:
gstbasesrc.c(2625):gst_base_src_loop():/GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
流式处理任务已暂停,原因未链接(-1)
2089256849 ns后执行结束。
正在将管道设置为暂停。。。
正在将管道设置为就绪。。。
正在将管道设置为空。。。
释放管道。。。
$gst-inspect-1.0 v4l2src
没有这样的元素或插件“v4l2src”
$gst-inspect-0.10 v4l2src
工厂详情:
长名称:视频(video4linux2)源
类别:源/视频
描述:从Video4Linux2设备读取帧
作者:Edgard Lima,Stefan Kost
职级:小学(256)
插件详细信息:
名称:video4linux2
描述:视频4 Linux的元素
文件名:/usr/lib/x86_64-linux-gnu/gstreamer-0.10/libgstvideo4linux2.so
版本:0.10.31
许可证:LGPL
源模块:gst插件好
来源发布日期:2012-02-20
二进制软件包:gstreamergoodplugins(Ubuntu)
来源URL:https://launchpad.net/distros/ubuntu/+来源/gst-plugins-good0.10
...
...
$uname-a
Linux MSA-BLADE-UBUNTU 4.11.3-041103-generic#201705251233 SMP周四5月25日16:34:52 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
$lsb_发行版-a
没有可用的LSB模块。
分发服务器ID:Ubuntu
说明:Ubuntu 16.04.2 LTS
发行日期:16.04
代号:xenial

您可能遇到与我相同的问题,我丢失了一个
。因此
文件位于动态共享库路径外的一个文件夹中。我可以按照中描述的步骤看到这一点。为了解决这个问题,我必须运行
export-LD\u-LIBRARY\u-PATH=/lib:/usr/lib:/usr/local/lib

您是否安装了像anaconda这样的软件包?当我安装anaconda时,我遇到了类似的问题,因为它安装了一组二进制文件,包括gst-launch-1.0和gst-inspect-1.0,并添加到路径中。是的,我知道,是的,你是对的,这就是问题所在。除了从我的路径中删除Anaconda(我不想这样做,因为我有很多依赖于此),有没有办法让它玩Anaconda?也许还可以问另一个问题,为什么你需要另一个发行版(Anaconda/Conda),而你已经有了Ubuntu/Apt发行版。有数百个包管理器彼此破坏(并且每个人都认为它是宇宙的中心)。@memo在我的情况下,我所做的是从
/bin/
中删除二进制文件
gst-launch-1.0
gst-inspect-1.0
,因为我的系统上安装了另一个版本的gstreamer。它似乎为我做到了这一点。@Velkan我与许多不同的项目合作,这些项目有许多不同的要求,有些是py2.7与py3.5,并且在不同版本的软件包中。整个事情都是一场噩梦,虽然并不完美,但康达是迄今为止最好的管理方式(特别是考虑到我使用spyder等)。
$ 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