[solved]SRT streaming error

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

[solved]SRT streaming error

longkas
This post was updated on .
Hello,
I have built SRT and did a test but I got "payload size error" when I tried
to play the stream using VLC player

1) on server:
# gst-launch-1.0 -v videotestsrc ! srtsink uri=srt://:9988 mode=2
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps =
video/x-raw, format=(string)I420, width=(int)320, height=(int)240,
framerate=(fraction)30/1, multiview-mode=(string)mono,
pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstSRTSink:srtsink0.GstPad:sink: caps = video/x-raw,
format=(string)I420, width=(int)320, height=(int)240,
framerate=(fraction)30/1, multiview-mode=(string)mono,
pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
06:00:08 PM.697653/videotestsrc0:s*E:SRT.cc: LiveCC: payload size: 115200
exceeds maximum allowed 1316
06:00:08 PM.947806/videotestsrc0:s*E:SRT.cc: LiveCC: payload size: 115200
exceeds maximum allowed 1316

2) on client:
#vlc srt://:9988?pkt_size=1316



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
gstreamer-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

longkas
I have found the solution by searching here:

gst-launch-1.0 -v videotestsrc ! x264enc ! mpegtsmux alignment=7  ! srtsink
uri=srt://:9988 mode=2



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

Nicolas Dufresne-5
In reply to this post by longkas


Le sam. 28 déc. 2019 06 h 15, longkas <[hidden email]> a écrit :
Hello,
I have built SRT and did a test but I got "payload size error" when I tried
to play the stream using VLC player

1) on server:
# gst-launch-1.0 -v videotestsrc ! srtsink uri=srt://:9988 mode=2

SRT protocol expect packets of size around 1300 bytes. Also, it's not really meant to be used without a container.

Most users will send a transport streams (mpegtsmux) to the element, and use the alignment to control the size (alignment being a number of TS packet, so N * 188 bytes). On top of which, you may need to pick a compression method. Unfortunately, you have to know these things to use GStreamer, but we can help here.

Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps =
video/x-raw, format=(string)I420, width=(int)320, height=(int)240,
framerate=(fraction)30/1, multiview-mode=(string)mono,
pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstSRTSink:srtsink0.GstPad:sink: caps = video/x-raw,
format=(string)I420, width=(int)320, height=(int)240,
framerate=(fraction)30/1, multiview-mode=(string)mono,
pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
06:00:08 PM.697653/videotestsrc0:s*E:SRT.cc: LiveCC: payload size: 115200
exceeds maximum allowed 1316
06:00:08 PM.947806/videotestsrc0:s*E:SRT.cc: LiveCC: payload size: 115200
exceeds maximum allowed 1316

2) on client:
#vlc srt://:9988?pkt_size=1316



--
Sent from: http://gstreamer-devel.966125.n4.nabble.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
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

jahnmansour
Nicolas Dufresne-5 wrote
> Most users will send a transport streams (mpegtsmux) to the element, and
> use the alignment to control the size (alignment being a number of TS
> packet, so N * 188 bytes). On top of which, you may need to pick a
> compression method. Unfortunately, you have to know these things to use
> GStreamer, but we can help here.

Hello,
Do you know what is the right container to use if I want to stream jpeg
motion video and I get the same error as above,
since the mpegtsmux doesn't accept image/jpeg format?

best wishes
Jahn




--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

Samuel Hurst
On 05/08/2020 12:42, jahn wrote:

> Nicolas Dufresne-5 wrote
>> Most users will send a transport streams (mpegtsmux) to the element, and
>> use the alignment to control the size (alignment being a number of TS
>> packet, so N * 188 bytes). On top of which, you may need to pick a
>> compression method. Unfortunately, you have to know these things to use
>> GStreamer, but we can help here.
>
> Hello,
> Do you know what is the right container to use if I want to stream jpeg
> motion video and I get the same error as above,
> since the mpegtsmux doesn't accept image/jpeg format?
Hi,

As far as I'm aware, the only format which SRT supports is MPEG-TS, as
it's the only stream encapsulation format that they list in their I-D
[1] and in the SRT specification. You can do MJPEG over RTP though.

Best Regards,
Sam

[1]:
https://tools.ietf.org/html/draft-sharabayko-mops-srt-00#section-3.2.1.2


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

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

Re: SRT streaming error

Olivier Crête-3
On Thu, 2020-08-06 at 09:17 +0100, Samuel Hurst wrote:
On 05/08/2020 12:42, jahn wrote:
Nicolas Dufresne-5 wrote
Most users will send a transport streams (mpegtsmux) to the element, and
use the alignment to control the size (alignment being a number of TS
packet, so N * 188 bytes). On top of which, you may need to pick a
compression method. Unfortunately, you have to know these things to use
GStreamer, but we can help here.

Hello, 
Do you know what is the right container to use if I want to stream jpeg
motion video and I get the same error as above, 
since the mpegtsmux doesn't accept image/jpeg format?

Hi,

As far as I'm aware, the only format which SRT supports is MPEG-TS, as
it's the only stream encapsulation format that they list in their I-D
[1] and in the SRT specification. You can do MJPEG over RTP though.

This isn't really true. Although SRT was very much design with MPEG_TS in mind, it can really carry anything. It guarantees in order delivery and preserves packet boundaries, but it guarantee that all packets will be delivered. You can for example send RTP through it.

Olivier


Best Regards,
Sam

[1]:
https://tools.ietf.org/html/draft-sharabayko-mops-srt-00#section-3.2.1.2


_______________________________________________
gstreamer-devel mailing list
[hidden email]

https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

-- 
Olivier Crête


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

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

Re: SRT streaming error

Olivier Crête-3
On Thu, 2020-08-06 at 10:44 -0400, Olivier Crête wrote:
On Thu, 2020-08-06 at 09:17 +0100, Samuel Hurst wrote:
On 05/08/2020 12:42, jahn wrote:
Nicolas Dufresne-5 wrote
Most users will send a transport streams (mpegtsmux) to the element, and
use the alignment to control the size (alignment being a number of TS
packet, so N * 188 bytes). On top of which, you may need to pick a
compression method. Unfortunately, you have to know these things to use
GStreamer, but we can help here.

Hello, 
Do you know what is the right container to use if I want to stream jpeg
motion video and I get the same error as above, 
since the mpegtsmux doesn't accept image/jpeg format?

Hi,

As far as I'm aware, the only format which SRT supports is MPEG-TS, as
it's the only stream encapsulation format that they list in their I-D
[1] and in the SRT specification. You can do MJPEG over RTP though.

This isn't really true. Although SRT was very much design with MPEG_TS in mind, it can really carry anything. It guarantees in order delivery and preserves packet boundaries, but it guarantee that all packets will be delivered. You can for example send RTP through it.

Sorry, it was "but it does NOT guarantee that all packets will be delivered"

Olivier


Olivier


Best Regards,
Sam

[1]:
https://tools.ietf.org/html/draft-sharabayko-mops-srt-00#section-3.2.1.2


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

-- 

Olivier Crête

_______________________________________________
gstreamer-devel mailing list
[hidden email]

https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

-- 
Olivier Crête


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

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

Re: SRT streaming error

jahnmansour
In reply to this post by Olivier Crête-3
I tried sending motion jpeg in with SRT using Gstreamer 1.17 and it worked.
Apparently the SRT developers fixed the issue but this fixing isn't
considered in GStreamer 1.16 which is the default on Ubuntu 20.04 . The case
now is . My pipeline works fine on GStreamer 1.17 and crashes on GStreamer
1.16 . Does anybody know, what can i do?
Ps. I tried using rtpjpegpay and it didn't work

Best regards
Jahn



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

jahnmansour
jahn wrote
> I tried sending motion jpeg in with SRT using Gstreamer 1.17 and it
> worked.

 I used avimux in this case. But using it with GStreamer 1.16 raises the
error of packets size



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

evaluat0r
In reply to this post by jahnmansour
jahn wrote

> I tried sending motion jpeg in with SRT using Gstreamer 1.17 and it
> worked.
> Apparently the SRT developers fixed the issue but this fixing isn't
> considered in GStreamer 1.16 which is the default on Ubuntu 20.04 . The
> case
> now is . My pipeline works fine on GStreamer 1.17 and crashes on GStreamer
> 1.16 . Does anybody know, what can i do?
> Ps. I tried using rtpjpegpay and it didn't work
>
> Best regards
> Jahn
>
>
>
> --
> Sent from: http://gstreamer-devel.966125.n4.nabble.com/
> _______________________________________________
> gstreamer-devel mailing list

> gstreamer-devel@.freedesktop

> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

Just pull down the sources for your distro and apply the upstream patch,
rebuild, and install the patched libraries.



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

jahnmansour
evaluat0r wrote
> Just pull down the sources for your distro and apply the upstream patch,
> rebuild, and install the patched libraries.

Sorry, I'm not so experienced.
Can you provide more explanation/link/tutorial on how to do that?

Best reagrds
Jahn



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
z
Reply | Threaded
Open this post in threaded view
|

Re: SRT streaming error

z
In reply to this post by evaluat0r
Can you tell me how to achieve it?thanks!



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel