gst-launch-1.0 videotestsrc pattern=ball ! "video/x-raw,weight=1920,height=1080" ! x264enc sps-id=0 byte-stream=true aud=false key-int-max=30 ! udpsink host=192.168.0.121 port=1200
使用以上指令可以推流h264,并且每个I帧都有SPS和PPS头,用ffmpeg解析时就没有问题了
gst-launch-1.0 videotestsrc pattern=ball ! "video/x-raw,weight=1920,height=1080" ! x264enc sps-id=0 byte-stream=true aud=false key-int-max=30 ! udpsink host=192.168.0.121 port=1200
使用以上指令可以推流h264,并且每个I帧都有SPS和PPS头,用ffmpeg解析时就没有问题了