Problem Streaming Live Audio Using RTP and UDPSink

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

Problem Streaming Live Audio Using RTP and UDPSink

william.l.metcalf
I am trying to capture live audio from a capture card in a gstreamer
application, encode it into AAC format, and then send the audio over a
network using UDPSink and RTP.  My method of accomplishing this task
works almost perfectly, except that occasionally the audio will become
very jumpy for a few seconds and then return to normal, and then after a
few seconds it will get jumpy, etc.  I am not getting any errors when I
play the audio, so I am assuming that it must be some property I am not
setting correctly, or maybe there is an element I am missing which can
help solve the problem.  My pipelines are as follows:

Server Pipeline: appsrc max-bytes=8000 is-live=true typefind=true !
audioparse ! faac bitrate=320000 ! rtpmp4apay host=192.168.42.68 port=52222

Client Pipeline: udpsrc port=52222 !
"application/x-rtp,media=(string)audio,clock-rate=(int)44100,encoding-name=(string)MP4A-LATM,payload=(int)96"
! rtpmp4adepay !
"audio/mpeg,mpegversion=(int)4,channels=(int)2,rate=(int)44100" ! faad !
autoaudiosink

I am very close to having this work, so any help that anyone can provide
will be greatly appreciated!

William
_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Problem Streaming Live Audio Using RTP and UDPSink

Tiago Katcipis


On Mon, Jul 18, 2011 at 3:23 PM, William Metcalf <[hidden email]> wrote:
I am trying to capture live audio from a capture card in a gstreamer application, encode it into AAC format, and then send the audio over a network using UDPSink and RTP.  My method of accomplishing this task works almost perfectly, except that occasionally the audio will become very jumpy for a few seconds and then return to normal, and then after a few seconds it will get jumpy, etc.  I am not getting any errors when I play the audio, so I am assuming that it must be some property I am not setting correctly, or maybe there is an element I am missing which can help solve the problem.  My pipelines are as follows:

Server Pipeline: appsrc max-bytes=8000 is-live=true typefind=true ! audioparse ! faac bitrate=320000 ! rtpmp4apay host=192.168.42.68 port=52222

Client Pipeline: udpsrc port=52222 ! "application/x-rtp,media=(string)audio,clock-rate=(int)44100,encoding-name=(string)MP4A-LATM,payload=(int)96" ! rtpmp4adepay ! "audio/mpeg,mpegversion=(int)4,channels=(int)2,rate=(int)44100" ! faad ! autoaudiosink

I am very close to having this work, so any help that anyone can provide will be greatly appreciated!

Try:

udpsrc port=52222 ! "application/x-rtp,media=(stri
ng)audio,clock-rate=(int)44100,encoding-name=(string)MP4A-LATM,payload=(int)96" ! gstrtpjitterbuffer ! rtpmp4adepay ! "audio/mpeg,mpegversion=(int)4,channels=(int)2,rate=(int)44100" ! faad ! autoaudiosink

and consider using the whole gstrtpbin when dealing with RTP streams.

Hope this helps.

Best regards,
Katcipis

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


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