gst-launch-1.0 videotestsrc ! autovideosink(对我不起作用!)

gst-launch-1.0 videotestsrc ! autovideosink (does not work for me!)

我正在使用 Ubuntu 18.04.3 LTS,我按照 https://gstreamer.freedesktop.org/documentation/installing/on-linux.html?gi-language=c 上列出的指南安装 gstreamer。

我认为我的安装有问题,因为我没有看到此管道的任何测试源:

u2@u2:~$ gst-launch-1.0 videotestsrc ! autovideosink

Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
Got context from element 'autovideosink0-actual-sink-vaapi': gst.vaapi.Display=context, gst.vaapi.Display=(GstVaapiDisplay)"\(GstVaapiDisplayDRM\)\ vaapidisplaydrm2";
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

我希望至少能够看到视频测试源。

遇到了与您相同的问题:autovideosink 可以播放视频,但无法在 window 中显示。尝试:

gst-launch-1.0 videotestsrc ! ximagesink

此外,glimagesink 也适用于我们。

希望了解更多的水槽元素

*要播放本地 .mp4 视频,请使用:

gst-launch-1.0 playbin uri=file:///home/path/to/your/video.mp4 video-sink="ximagesink"

**要使 autovideosink 正常工作,请尝试:

sudo apt-get remove gstreamer1.0-vaapi

说实话,初级以上的装备挡了我们一会,这么简单的问题我们都很难解决:)

希望对各位gstreamer新手有所帮助!