Go gstreamer网络摄像头vp9enc滞后

Go gstreamer网络摄像头vp9enc滞后,go,webrtc,gstreamer,Go,Webrtc,Gstreamer,我已经用websocket信令服务器和带有pion的webrtc部分构建了一个litte go webrtc项目 但是使用gstreamer创建vp8或vp9流失败->高延迟 这是管道 gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-raw,width=320,framerate=10/1 ! videoconvert ! vp9enc ! decodebin ! autovideosink 但是视频非常滞后,gst打印出了一些错误 Se

我已经用websocket信令服务器和带有pion的webrtc部分构建了一个litte go webrtc项目

但是使用gstreamer创建vp8或vp9流失败->高延迟

这是管道

gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-raw,width=320,framerate=10/1 ! videoconvert ! vp9enc ! decodebin ! autovideosink
但是视频非常滞后,gst打印出了一些错误

Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Redistribute latency...
WARNING: from element /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstXvImageSink:autovideosink0-actual-sink-xvimage: A lot of buffers are being dropped.
Additional debug info:
../gstreamer/libs/gst/base/gstbasesink.c(3003): gst_base_sink_is_too_late (): /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstXvImageSink:autovideosink0-actual-sink-xvimage:
There may be a timestamping problem, or this computer is too slow.
ERROR: from element /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstXvImageSink:autovideosink0-actual-sink-xvimage: Output window was closed
Additional debug info:
../gst-plugins-base/sys/xvimage/xvimagesink.c(554): gst_xv_image_sink_handle_xevents (): /GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstXvImageSink:autovideosink0-actual-sink-xvimage
Execution ended after 0:00:13.282962300
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

我的电脑是一台16G内存的i5。。。一定还有别的东西

我不知道
vp9enc
的等价物,但请查看这些设置以了解更多信息


默认情况下,大多数编码器不会以实时速度运行,因此您必须设置一些选项。如果你找到正确的vp9选项,公关将是伟大的

我已经看到了这个属性,我正在使用这个gst包装器。我以为vp9不需要它们。但是,使用具有书面属性的vp8enc管道不会改变任何东西。您的权利是,vp8管道是正常的。几个小时前,我在尝试vp8时遇到了另一个问题。vp9使用vp8属性更好,但如果存在
error resilience=partitions
,则会失败,但文档中提到itreported抱歉,我不确定,这似乎是一个VPx/GStreamer错误。现在只使用VP8可能更容易,我听说有些人为了实时而避免使用VP9,因为它的CPU成本更高。是的,我现在正在使用VP8,它运行得很好。使用带有srflx的webrtc时遇到一些问题,而不是主机(在我的局域网内),但这是另一个主题