1

我在 Win 7 x64 上的 Gstreamer OSS Build 0.10.7 中使用以下管道(简化):

udpsrc ! application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264,        payload=(int)96 !
gstrtpjitterbuffer latency=200 ! rtph264depay ! tee name=h264Tee 

h264Tee. ! queue ! h264parse ! mux. 

matroskamux name=mux ! filesink location=rec.mkv sync=false // same for avimux/mp4/qt

h264Tee. ! queue ! ffdec_h264 ! tee name=videoTee 

//.videoTee ! queue ! dx9videosink
//.videoTee ! queue ! appsink

//udpsrc ! queue ! directsoundsink

audiotestsrc ! mux. //only for testing, should be connected to udpsrc

该管道通过 Gstreamer-Sharp 启动。这是管道的控制台输出:

WARN default xoverlay.c:354:gst_x_overlay_set_xwindow_id:<videoSink> Using deprecated gst_x_overlay_set_xwindow_id()
ERROR d3dvideosink d3dvideosink.c:2204:gst_d3dvideosink_release_swap_chain: Direct3D device has not been initialized
WARN bin gstbin.c:2378:gst_bin_do_latency_func:<pipeline0> failed to query latency
WARN matroskamux matroska-mux.c:970:gst_matroska_mux_video_pad_setcaps:<mux> pad video_0 refused caps 05370C40

只要我不使用复用器,视频和音频都可以正常播放。当在管道中包含多路复用器时,视频立即冻结并且听不到声音。什么是错的,为什么混音器拒绝盖帽?

4

1 回答 1

0

好的,我自己解决了:上面的视频上限不包含播放不需要的 sprop-parameter-sets。但是,对于编码,它们是必需的,因为流的各种属性都在这些属性中进行了编码:

udpsrc ! 
application/x-rtp, media=(string)video, clock-rate=(int)90000, 
encoding-name=(string)H264, 
sprop-parameter-sets= (string)\"Z0LADdkBQfsBEAAAAwAQAAADAyjxQqSA\\,aMuMTIA\\=\", 
payload=(int)96, 
ssrc (uint)2332354585, 
clock-base=(uint)1158355497, 
seqnum-base=(uint)10049 !
gstrtpjitterbuffer latency=200 ! rtph264depay ! tee name=h264Tee 

...
于 2012-11-22T00:02:28.230 回答