GStreamer issue on TX2

Anyone know why the following command does not seem to work?
gst-launch-1.0 udpsrc port=[port_num] ! tee name=t ! queue ! filesink location=/some/path/test.mpg t. ! queue ! tsparse ! tsdemux ! h264parse ! omxh264dec ! nveglglessink -e

output:
Setting pipeline to PAUSED …
Pipeline is live and does not need PREROLL …
Got context from element ‘eglglessink0’: gst.egl.EGLDisplay=context, display=(GstEGLDisplay)NULL;
Setting pipeline to PLAYING …
New clock: GstSystemClock

It just stall here and does not do anything as far as I can tell. There is an empty test.mpg file created, but it does not get written to. I’ve written the gstreamer c code equivalent and it does the same exact thing.

I’ve tried these and they all work:

gst-launch-1.0 udpsrc port=[port_num] ! filesink location=/some/path/test.mpg

gst-launch-1.0 udpsrc port=[port_num] ! tsparse ! tsdemux ! queue ! h264parse ! omxh264dec ! nveglglessink -e

gst-launch-1.0 filesrc location=/some/path/test.mpg ! tee name=t ! queue ! filesink location=/some/path/t_test.mpg t. ! queue ! tsparse ! tsdemux ! h264parse ! omxh264dec ! nveglglessink -e
where the test.mpg is the same exact type of file being sent over udp.

gst-launch-1.0 udpsrc port=[port_num] ! tee name=t ! queue ! filesink location=/some/path/t_test.mpg t. ! queue ! fakesink
This one writes to the file.

Thanks!

Hi Bogan123,
On r28.1/TX2, we are able to run
[Server]

$ gst-launch-1.0 videotestsrc ! nvvidconv ! omxh264enc ! 'video/x-h264,stream-format=byte-stream' ! h264parse ! rtph264pay ! udpsink host=127.0.0.1 port=5000

[Client]

$ export DISPLAY=:0
$ gst-launch-1.0 udpsrc port=5000 ! 'application/x-rtp,encoding-name=H264,payload=96' ! tee name=t t. ! queue ! filesink location= test.mpg t. ! queue ! rtph264depay ! h264parse ! omxh264dec ! nveglglessink

Please check if it helps your case.
You may also go to gstreamer forum http://gstreamer-devel.966125.n4.nabble.com/

Thanks for replying. Unfortunately, I do not have access to the server side code. Do you think there are elements I can change in the current client side to make it work?

Not sure but you may try to configure ‘config-interval’ in h264parse element.

$ gst-inspect-1.0 h264parse
(...skip...)
Element Properties:
  name                : The name of the object
                        flags: readable, writable
                        String. Default: "h264parse0"
  parent              : The parent of the object
                        flags: readable, writable
                        Object of type "GstObject"
  disable-passthrough : Force processing (disables passthrough)
                        flags: readable, writable
                        Boolean. Default: false
  config-interval     : Send SPS and PPS Insertion Interval in seconds (sprop parameter sets will be multiplexed in the data stream when detected.) (0 = disabled)
                        flags: readable, writable
                        Unsigned Integer. Range: 0 - 3600 Default: 0

Solution:
"
That is because the queue before filesink is full, make it bigger and
it will work.

  1. udpsrc produce 1 buffer
  2. “queue ! filesink” received it and preroll
  3. “queue ! dec” will queue, but not produce anything yet
  4. “queue ! filesink”" stores data
    1. happens again

      N) “queue ! filesink” the queue is full, we are blocked on pre-roll.

Considering you don’t really care if you start writing to disk before
you have reached play, I’d just set async=FALSE on filesink, and safe a
some RAM.

Nicolas
"

Thanks for sharing the fix information.