udpsink/udpsrc vs. pipeline, filesrc vs. appsrc

George and Candy Koharchik t1mbre at tx.rr.com
Thu Aug 30 00:37:38 UTC 2018


Hi Folks,

 

   I'm unclear on concepts, I'm trying to stream video from appsrc  as h264
over udp.

 

   I based my appsrc code on basic-tutorial-8 at
https://gstreamer.freedesktop.org/documentation/tutorials/basic/short-cuttin
g-the-pipeline.html

 

   In gst-launch syntax, I got code for this to work:

 

   appsrc ! rawvideoparse ! videoconvert ! nvh264enc ! avdec_h264 !
videoconvert ! autovideosink      (one pipeline so all on the same host.)

 

  (Sorry for typos, I don't have it in front of me.)

 

   To put my appsrc in push mode, I set "is-live" to TRUE,  "stream-type" to
GT_APP_STREAM_TYPE_STREAM,  and set need-data, and enough-data  like appsrc
in basic-tutorial-8.

  Since my appsrc produces just pixels, I'm feeding that into rawvideoparse
with  use-sink-caps= FALSE, and setting width, height, and format (y42b) in
rawvideoparse.

 

  This works. I thought I'd insert the udp link and be done:

 

  so I put the first part of this one on host. I coded the pipeline
equivalent of:

 

appsrc ! rawvideoparse ! videoconvert ! nvh264enc ! udpsink "host=otherhost"
port= 5000  (with all the same settings above)

 

  on the other host I used a gst-launch script:

 

gst-launch-1.0  -vm udpsrc port=5000 ! video/x-h264,
stream-format=byte-stream, alignment=au, width=1280, height=1024,
framerate=30 ! avdec_h264 ! viideoconvert ! autovideosink

 

. and it didn't work. (I can see the "start feeding"," stop feeding" prints
on the input side that makes me think that part's working. On the receiving
side there's no window.) 

 

  So I thought I had something wrong with the network part: but when I put
in filesrc instead of appsrc on the input host, it does work. The video
window appears on the output host if I use filesrc on the input host.

 

In the output host messages, the filesrc case has a message from
avdec_h264-0:src with a property notify caps message.  That's missing in the
appsrc case.

 

So:

 

1)      What's different between filesrc and appsrc that udp works with
filesrc, but not appsrc?

2)      What's missing in udpsink/udpsrc that appsrc works in pipeline, but
not over udp?

3)      How do I get the equivalent of gst-launch's "-v" and "-m" in code?

 

Thanks,

 

blueshirt

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20180829/8c2b9d0a/attachment.html>


More information about the gstreamer-devel mailing list