gstreamer的音乐可视化错误

时间:2010-02-26 04:29:39

标签: c++ python linux audio gstreamer

嗨我正在尝试使用以下命令在gstreamer中显示音乐文件:

gst-launch filesrc location=file.mp3 ! decodebin ! audioconvert ! 
tee name=myT myT. ! queue ! autoaudiosink myT. ! queue ! goom ! 
colorspace ! autovideosink

但我收到此错误:“可能存在时间戳问题,或者此计算机速度太慢。”

Pipeline is PREROLLING ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstAudioSinkClock
WARNING: from element /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstDshowVideoSink:autovideosink0-actual-sink-dshowvideo: A lot of buffers are being dropped.
Additional debug info:
..\Source\gstreamer\libs\gst\base\gstbasesink.c(2572): gst_base_sink_is_too_late (): /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstDshowVideoSink:autovideosink0-actual-sink-dshowvideo:
There may be a timestamping problem, or this computer is too slow.
ERROR: from element /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0

假设这与线程有关,我尝试了以下命令:

gst-launch filesrc location=file.mp3 ! decodebin ! audioconvert ! tee name=myT 
{ ! queue ! autoaudiosink } { tee. ! queue ! goom ! colorspace ! autovideosink }

然后它给出了folloiwng链接错误:

** (gst-launch-0.10:5308): WARNING **: Trying to connect elements that don't share a common ancestor: tee and queue1
0:00:00.125000000  5308   003342F0 ERROR           GST_PIPELINE grammar.tab.c:656:gst_parse_perform_link: could not link tee to queue1
WARNING: erroneous pipeline: could not link tee to queue1

谁能说出错是什么意思?感谢

2 个答案:

答案 0 :(得分:1)

我无法给你一个确切的答案,因为我没有安装Windows。

对于调试,请使用第一个管道(在linux中工作)。使用参数-v和gst-launch并在autovideosink之前放置元素标识。这将打印通过元素标识的缓冲区信息,查找任何奇怪的内容。

您也可以尝试使用directdrawsink而不是autovideosink。我将做的另一项测试是使用audiotestsrc生成音频。

请记住,如果您发现错误,可以在gnome bugzilla中打开错误报告,以便GStreamer开发人员意识到存在问题。即便你自己修理它并发送补丁。

答案 1 :(得分:0)

对于There may be a timestamping problem, or this computer is too slow. 错误,请尝试使用sync=false

`gst-launch filesrc location=file.mp3 ! decodebin ! audioconvert ! tee name=myT myT. ! queue ! autoaudiosink myT. ! queue ! goom ! colorspace ! autovideosink sync=false`

或者您可能必须尝试在Tee的两个下沉端

`gst-launch filesrc location=file.mp3 ! decodebin ! audioconvert ! tee name=myT myT. ! queue ! autoaudiosink sync=false myT. ! queue ! goom ! colorspace ! autovideosink sync=false`

我还观察到,如果您将autovideosink替换为xvimagesinkximagesink,则时间戳问题显然似乎已得到解决。

相关问题