2

我正在尝试从 h264 解码视频并重新编码以通过 udp 传输到客户端:

在发射端:

gst-launch-1.0 -v filesrc location=/home/ubuntu/Videos/test.mp4 ! qtdemux name=demux ! h264parse ! omxh264dec ! nvvidconv ! omxh264enc ! rtph264pay ! udpsink host=127.0.0.1 port=5000

在接收方:

gst-launch-1.0 udpsrc port=5000 ! application/x-rtp,media=video,clock-rate=90000,encoding-name=H264 ! rtph264depay ! h264parse ! omxh264dec ! nveglglessink

我在本地进行测试,在 NVidia Tegra TK1 上进行测试,但没有显示任何内容,尽管没有引发错误。

有人看到要补充的吗?提前致谢。

4

1 回答 1

1

好的,我终于让它工作了,但是使用了其他网络协议:

仅用于在 Tegra TK1 本身上进行本地测试、发送和接收:

发送:

gst-launch-1.0 filesrc location=/home/ubuntu/Videos/test.mp4 ! qtdemux name=demux ! h264parse ! omxh264dec ! nvvidconv ! omxh264enc ! rtph264pay config-interval=1 pt=96 ! gdppay ! tcpserversink host=127.0.0.1 port=5000 

收到:

gst-launch-1.0 -v tcpclientsrc host=127.0.0.1 port=5000 ! gdpdepay ! rtph264depay ! h264parse ! omxh264dec ! nveglglessink sync=false

结果是不稳定的,但我不在乎这个阶段。我收到东西!!

在 Ubuntu PC 上接收:

gst-launch-1.0 -v tcpclientsrc host=<Tegra IP> port=5000 ! gdpdepay ! rtph264depay ! avdec_h264 ! videoconvert ! autovideosink sync=false
于 2015-03-20T17:07:45.533 回答