gstreamer-1.0 appsrc sample example

classic Classic list List threaded Threaded
14 messages Options
Reply | Threaded
Open this post in threaded view
|

gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
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.

Regards,
Biswajit

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_APPSRC.c (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
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
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
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 <[hidden email]> 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
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_APPSRC.c (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
On Di, 2016-05-10 at 14:17 +0530, Biswajit Panigrahi wrote:

> 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.
Your pipeline still has the 3 problems from the previous mail. Fix
those first and then report what exactly is happening again.

Without fixing those your pipeline will never go to PAUSED or PLAYING
and the callback will never be called. Even more, you should get
various assertions at runtime.

Also I looked another time now and there's two more problems:
4) You're creating and assigning pipeline twice, the first one is
   just overwritten and not useful, you can remove it.
   Same goes for the appsrc.
5) On the appsrc you have to set emit-signals to TRUE, otherwise
   the signals are never emitted but only the callbacks.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
Hi Sebastian,
Thanks for figuring out the issue.
I have modified the code completely.As of now instead of streaming over udp i am testing it with fakesink.
Now the Start Feed and Stop Feed Function get called once.

The Error Log:

**************************************start feeding******************************************8
inside read_data
inside read_data
inside read_data
*********************stop feeding*********************
ERROR from element mysource: Internal data flow error.
Debugging info: gstbasesrc.c(2865): gst_base_src_loop (): /GstPipeline:pipeline0/GstAppSrc:mysource:
streaming task paused, reason not-negotiated (-4)



Currently appsrc looks like:

gst_parse_launch("appsrc name=mysource ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! fakesink dump=1 ", NULL);

 caps = gst_caps_new_simple ("video/x-raw",
            "format",G_TYPE_STRING,"RGB",
            "bpp",G_TYPE_INT,24,
             "depth",G_TYPE_INT,24,
            "width", G_TYPE_INT, 640,
            "height", G_TYPE_INT, 480,
            "framerate", GST_TYPE_FRACTION, 30, 1,
             NULL);
 
     gst_app_src_set_caps(GST_APP_SRC(app->appsrc), caps);

Can you please check what could be the issue.I have attached the complete code .Please review it and figure out the root couse.

Regards,
Biswajit


On Wed, May 11, 2016 at 11:17 AM, Sebastian Dröge <[hidden email]> wrote:
On Di, 2016-05-10 at 14:17 +0530, Biswajit Panigrahi wrote:
> 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.

Your pipeline still has the 3 problems from the previous mail. Fix
those first and then report what exactly is happening again.

Without fixing those your pipeline will never go to PAUSED or PLAYING
and the callback will never be called. Even more, you should get
various assertions at runtime.

Also I looked another time now and there's two more problems:
4) You're creating and assigning pipeline twice, the first one is
   just overwritten and not useful, you can remove it.
   Same goes for the appsrc.
5) On the appsrc you have to set emit-signals to TRUE, otherwise
   the signals are never emitted but only the callbacks.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_Final.c (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
On Mi, 2016-05-11 at 13:31 +0530, Biswajit Panigrahi wrote:

> Hi Sebastian,
> Thanks for figuring out the issue.
> I have modified the code completely.As of now instead of streaming
> over udp i am testing it with fakesink.
> Now the Start Feed and Stop Feed Function get called once.
> [...]
> ERROR from element mysource: Internal data flow error.
> Debugging info: gstbasesrc.c(2865): gst_base_src_loop ():
> /GstPipeline:pipeline0/GstAppSrc:mysource:
> streaming task paused, reason not-negotiated (-4)
>
>
>
> Currently appsrc looks like:
>
> gst_parse_launch("appsrc name=mysource ! vpe num-input-buffers=8 ! 
> ducatimpeg4enc bitrate=4000 ! fakesink dump=1 ", NULL);
>
>  caps = gst_caps_new_simple ("video/x-raw",
>             "format",G_TYPE_STRING,"RGB",
>             "bpp",G_TYPE_INT,24,
>              "depth",G_TYPE_INT,24,
>             "width", G_TYPE_INT, 640,
>             "height", G_TYPE_INT, 480,
>             "framerate", GST_TYPE_FRACTION, 30, 1,
>              NULL);
vpe probably does not accept RGB input. Put a videoconvert after your
appsrc as mentioned in my previous mail (instead of the
ffmpegcolorspace you had there before and which does not exist).

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
Hi Sebastian,
Thank a lot for debugging .

Now both fakesink as well as filesink location=testSRC1.mpeg in appsrc works fine.
But while streaming over udp ,its getting failed.

app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! queue ! rtpmp4vpay config-interval= 10 pt=96 ! udpsink host=192.227.1.20 port=5000 ", NULL);

I am getting continuous message like :
(GST_Final:1639): GStreamer-CRITICAL **: gst_segment_to_running_time: assertion 'segment->format == format' failed

Any idea what could be the root couse for this.
I have attached the complete code also in  this mail.

Regards,
Biswajit



On Wed, May 11, 2016 at 1:53 PM, Sebastian Dröge <[hidden email]> wrote:
On Mi, 2016-05-11 at 13:31 +0530, Biswajit Panigrahi wrote:
> Hi Sebastian,
> Thanks for figuring out the issue.
> I have modified the code completely.As of now instead of streaming
> over udp i am testing it with fakesink.
> Now the Start Feed and Stop Feed Function get called once.
> [...]
> ERROR from element mysource: Internal data flow error.
> Debugging info: gstbasesrc.c(2865): gst_base_src_loop ():
> /GstPipeline:pipeline0/GstAppSrc:mysource:
> streaming task paused, reason not-negotiated (-4)
>
>
>
> Currently appsrc looks like:
>
> gst_parse_launch("appsrc name=mysource ! vpe num-input-buffers=8 ! 
> ducatimpeg4enc bitrate=4000 ! fakesink dump=1 ", NULL);
>
>  caps = gst_caps_new_simple ("video/x-raw",
>             "format",G_TYPE_STRING,"RGB",
>             "bpp",G_TYPE_INT,24,
>              "depth",G_TYPE_INT,24,
>             "width", G_TYPE_INT, 640,
>             "height", G_TYPE_INT, 480,
>             "framerate", GST_TYPE_FRACTION, 30, 1,
>              NULL);

vpe probably does not accept RGB input. Put a videoconvert after your
appsrc as mentioned in my previous mail (instead of the
ffmpegcolorspace you had there before and which does not exist).

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_Final.c (6K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
On Mi, 2016-05-11 at 15:03 +0530, Biswajit Panigrahi wrote:

> Hi Sebastian,
> Thank a lot for debugging .
>
> Now both fakesink as well as filesink location=testSRC1.mpeg in
> appsrc works fine.
> But while streaming over udp ,its getting failed.
>
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! queue !
> rtpmp4vpay config-interval= 10 pt=96 ! udpsink host=192.227.1.20
> port=5000 ", NULL);
>
> I am getting continuous message like :
> (GST_Final:1639): GStreamer-CRITICAL **: gst_segment_to_running_time:
> assertion 'segment->format == format' failed
>
> Any idea what could be the root couse for this.
> I have attached the complete code also in  this mail.
Your source (or the encoder) is not producing a segment in TIME format.
For your source there would be the "format" property on appsrc.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
Hi Sebastian,
After your suggestion, I have added below line:
g_object_set (app->appsrc, "format", GST_FORMAT_TIME, NULL);
After that the warning which was not coming but when i am trying to stream over udp and  playing the same in other machine like vlc test.sdp then it shows few messages like:

VLC media player 2.0.8 Twoflower (revision 2.0.8a-0-g68cf50b)
[0x88ec908] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface.
[0xb5104520] es demux error: cannot peek
[mpeg4 @ 0xb5121b20] hmm, seems the headers are not complete, trying to guess time_increment_bits
[mpeg4 @ 0xb5121b20] my guess is 5 bits ;)
[mpeg4 @ 0xb5121b20] looks like this file was encoded with (divx4/(old)xvid/opendivx) -> forcing low_delay flag

Content of test.sdp:
v=0
m=video 5000 RTP/AVP 96
c=IN IP4 192.227.1.20
a=rtpmap:96 MP4V-ES/90000

I have attached the complete code .Please let me know if any issue is there in the code.

Regards,
Biswajit



On Wed, May 11, 2016 at 3:45 PM, Sebastian Dröge <[hidden email]> wrote:
On Mi, 2016-05-11 at 15:03 +0530, Biswajit Panigrahi wrote:
> Hi Sebastian,
> Thank a lot for debugging .
>
> Now both fakesink as well as filesink location=testSRC1.mpeg in
> appsrc works fine.
> But while streaming over udp ,its getting failed.
>
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! queue !
> rtpmp4vpay config-interval= 10 pt=96 ! udpsink host=192.227.1.20
> port=5000 ", NULL);
>
> I am getting continuous message like :
> (GST_Final:1639): GStreamer-CRITICAL **: gst_segment_to_running_time:
> assertion 'segment->format == format' failed
>
> Any idea what could be the root couse for this.
> I have attached the complete code also in  this mail.

Your source (or the encoder) is not producing a segment in TIME format.
For your source there would be the "format" property on appsrc.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_Final.c (7K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
On Do, 2016-05-12 at 11:36 +0530, Biswajit Panigrahi wrote:

> Hi Sebastian,
> After your suggestion, I have added below line:
> g_object_set (app->appsrc, "format", GST_FORMAT_TIME, NULL);
> After that the warning which was not coming but when i am trying to
> stream over udp and  playing the same in other machine like vlc
> test.sdp then it shows few messages like:
>
> VLC media player 2.0.8 Twoflower (revision 2.0.8a-0-g68cf50b)
> [0x88ec908] main libvlc: Running vlc with the default interface. Use
> 'cvlc' to use vlc without interface.
> [0xb5104520] es demux error: cannot peek
> [mpeg4 @ 0xb5121b20] hmm, seems the headers are not complete, trying
> to guess time_increment_bits
> [mpeg4 @ 0xb5121b20] my guess is 5 bits ;)
> [mpeg4 @ 0xb5121b20] looks like this file was encoded with
> (divx4/(old)xvid/opendivx) -> forcing low_delay flag
>
> Content of test.sdp:
> v=0
> m=video 5000 RTP/AVP 96
> c=IN IP4 192.227.1.20
> a=rtpmap:96 MP4V-ES/90000
>
> I have attached the complete code .Please let me know if any issue is
> there in the code.
Try with a known-to-work MPEG-4 Part 2 encoder, e.g. avenc_mpeg4,
instead of the Ducati elements. Does that work?

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
Hi Sebastian,
Yes if i use filesink location in Pipeline like:
app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! filesink location=FinalSRC12.mpeg ", NULL);
Then I am able play the FinalSRC12.mpeg without any problem.

I have tried with avenc_mpeg4 also in pipeline like:
app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert ! vpe num-input-buffers=8 !  avenc_mpeg4 bitrate=4000 ! filesink location=FinalSRC12.mpeg ", NULL);

but when I started UDP streaming in vlc by executing vlc test.sdp then the vlc gives error like:
demux error:cannot peak
no data received in 10s,aborting

Complete code is attached..

Regards,
Biswajit
 


On Thu, May 12, 2016 at 11:52 AM, Sebastian Dröge <[hidden email]> wrote:
On Do, 2016-05-12 at 11:36 +0530, Biswajit Panigrahi wrote:
> Hi Sebastian,
> After your suggestion, I have added below line:
> g_object_set (app->appsrc, "format", GST_FORMAT_TIME, NULL);
> After that the warning which was not coming but when i am trying to
> stream over udp and  playing the same in other machine like vlc
> test.sdp then it shows few messages like:
>
> VLC media player 2.0.8 Twoflower (revision 2.0.8a-0-g68cf50b)
> [0x88ec908] main libvlc: Running vlc with the default interface. Use
> 'cvlc' to use vlc without interface.
> [0xb5104520] es demux error: cannot peek
> [mpeg4 @ 0xb5121b20] hmm, seems the headers are not complete, trying
> to guess time_increment_bits
> [mpeg4 @ 0xb5121b20] my guess is 5 bits ;)
> [mpeg4 @ 0xb5121b20] looks like this file was encoded with
> (divx4/(old)xvid/opendivx) -> forcing low_delay flag
>
> Content of test.sdp:
> v=0
> m=video 5000 RTP/AVP 96
> c=IN IP4 192.227.1.20
> a=rtpmap:96 MP4V-ES/90000
>
> I have attached the complete code .Please let me know if any issue is
> there in the code.

Try with a known-to-work MPEG-4 Part 2 encoder, e.g. avenc_mpeg4,
instead of the Ducati elements. Does that work?

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_Final.c (7K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
On Do, 2016-05-12 at 12:33 +0530, Biswajit Panigrahi wrote:

> Hi Sebastian,
> Yes if i use filesink location in Pipeline like:
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! filesink
> location=FinalSRC12.mpeg ", NULL); 
> Then I am able play the FinalSRC12.mpeg without any problem.
>
> I have tried with avenc_mpeg4 also in pipeline like:
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! vpe num-input-buffers=8 !  avenc_mpeg4 bitrate=4000 ! filesink
> location=FinalSRC12.mpeg ", NULL);
>
> but when I started UDP streaming in vlc by executing vlc test.sdp
> then the vlc gives error like:
> demux error:cannot peak
> no data received in 10s,aborting
Does it work with a GStreamer receiver? Also don't use the vpe element
(or what is it doing?) before avenc_mpeg4.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Biswajit Panigrahi
Hi Sebastian,

If I will not use vpe element and use the pipeline as below :

app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert ! avenc_mpeg4 ! rtpmp4vpay config-interval=true  pt=96 ! udpsink  host=192.227.1.20 port=5000", NULL);

Then it fails with the below error:

**************************************start feeding******************************************8
inside read_data
inside read_data
*********************stop feeding*********************
ERROR from element mysource: Internal data flow error.
Debugging info: gstbasesrc.c(2865): gst_base_src_loop (): /GstPipeline:pipeline0/GstAppSrc:mysource:
streaming task paused, reason not-linked (-1)

Regarding testing with gstreamer reciver, Can you guide me how to test with this instead of testing with vlc player
I have attached the test code with this mail.

Regards,
Biswajit

On Fri, May 13, 2016 at 1:52 PM, Sebastian Dröge <[hidden email]> wrote:
On Do, 2016-05-12 at 12:33 +0530, Biswajit Panigrahi wrote:
> Hi Sebastian,
> Yes if i use filesink location in Pipeline like:
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! vpe num-input-buffers=8 !  ducatimpeg4enc bitrate=4000 ! filesink
> location=FinalSRC12.mpeg ", NULL); 
> Then I am able play the FinalSRC12.mpeg without any problem.
>
> I have tried with avenc_mpeg4 also in pipeline like:
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! vpe num-input-buffers=8 !  avenc_mpeg4 bitrate=4000 ! filesink
> location=FinalSRC12.mpeg ", NULL);
>
> but when I started UDP streaming in vlc by executing vlc test.sdp
> then the vlc gives error like:
> demux error:cannot peak
> no data received in 10s,aborting

Does it work with a GStreamer receiver? Also don't use the vpe element
(or what is it doing?) before avenc_mpeg4.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

GST_Final.c (9K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gstreamer-1.0 appsrc sample example

Sebastian Dröge-3
On Mo, 2016-05-16 at 10:59 +0530, Biswajit Panigrahi wrote:

> Hi Sebastian,
>
> If I will not use vpe element and use the pipeline as below :
>
> app->pipeline = gst_parse_launch("appsrc name=mysource ! videoconvert
> ! avenc_mpeg4 ! rtpmp4vpay config-interval=true  pt=96 ! udpsink 
> host=192.227.1.20 port=5000", NULL);
>
> Then it fails with the below error:
>
> **************************************start
> feeding******************************************8
> inside read_data
> inside read_data
> *********************stop feeding*********************
> ERROR from element mysource: Internal data flow error.
> Debugging info: gstbasesrc.c(2865): gst_base_src_loop ():
> /GstPipeline:pipeline0/GstAppSrc:mysource:
> streaming task paused, reason not-linked (-1)
Your attached application works fine for me without any errors. This is
with GStreamer 1.8.1

Can you get a debug log?

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (968 bytes) Download Attachment