gstreamer-1.0 appsrc sample example
Biswajit Panigrahi
biswajit.p at mistralsolutions.com
Tue May 10 08:47:37 UTC 2016
Hi Sebastian,
Thanks a lot for your help.
Basically I would like to stream a mpeg4 encoded data over udp.
If i execute a pipline on the command prompt like :
gst-launch-1.0 -e videotestsrc ! "video/x-raw, format=(string)YUY2,
width=(int)640, height=(int)480, framerate=(fraction)30/1" ! vpe
num-input-buffers=8 ! queue ! ducatimpeg4enc bitrate=4000 ! queue !
mpeg4videoparse ! rtpmp4vpay config-interval= 10 pt=96 ! udpsink
host=192.168.43.2 port=5000
and Play the same in Vlc player on 192.168.43.2 by "vlc test.sdp "
then it works fine.
Contents of test.sdp:
v=0
m=video 5000 RTP/AVP 96
c=IN IP4 192.168.43.2
a=rtpmap:96 MP4V-ES/90000
I would like to do similar kind of test using appsrc where instead of using
videotestsrc like to stream our own data.
So for that we are filling the gstbuffer.I have tried both with and without
mpeg4videoparse but the result is same.
cb_need_data function is not getting called for not even once.
Since i am new to gstreamer can you please help me in figuring out the
issue.
I am attaching the modified code.
Regards,
Biswajit
On Tue, May 10, 2016 at 12:06 PM, Sebastian Dröge <sebastian at centricular.com
> wrote:
> On Fr, 2016-05-06 at 18:59 +0530, Biswajit Panigrahi wrote:
> > Hi ,
> > I am trying to test the streaming of mpeg4 encoded over udp.
> > Is there any appsrc pipline sample code is available which can solve
> > my problem.
> > I have searched in internet but i didn't get any working test code.
> > I have attached a code which i am reffering .But couldn't figure out
> > why its not working.
>
> What is your appsrc producing? Raw video or something else?
>
> I assume raw video, in which case there are various bugs in your
> pipeline (I didn't look at the surrounding code).
>
> 1) There is no ffmpegcolorspace element in 1.x, use videoconvert
> 2) Don't put a capsfilter after appsrc but instead set the caps
> property on appsrc accordingly
> 3) Don't put mpeg4videoparse after the appsrc. It can't parse raw
> video but is for parsing MPEG-4 Part 2 encoded video.
>
> Apart from that there might be more problems of course, but that's what
> I saw for now. Also try using an alternative h264 encoder (x264enc) if
> this still doesn't work, no idea how well the ducati elements are
> working these days and how well their error reporting is.
>
>
> In general, for your pipeline you should've seen gst_parse_launch()
> returning NULL. If you had used the GError parameter you would also get
> a more meaningful error, or if you set GST_DEBUG=3 in the environment
> you should also already get a few hints.
>
> --
> Sebastian Dröge, Centricular Ltd · http://www.centricular.com
>
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160510/2934738c/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: GST_APPSRC.c
Type: text/x-csrc
Size: 2515 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160510/2934738c/attachment-0001.c>
More information about the gstreamer-devel
mailing list