rtpmpapay2
Payload an MPEG Audio Elementary Stream into RTP packets as per RFC 2038 and RFC 2250. Also see the IANA media-type page for MPA.
Aggregation Modes
The default aggregation mode is auto: If upstream is live, the payloader will send out all
audio frames immediately, even if they don't completely fill a packet, in order to minimise
latency. If upstream is not live, the payloader will by default aggregate audio frames until
it has completely filled an RTP packet as per the configured MTU size or the max-ptime
property if it is set (it is not set by default).
The aggregation mode can be controlled via the aggregate-mode property.
Example pipeline
gst-launch-1.0 audiotestsrc wave=ticks ! lamemp3enc ! mpegaudioparse ! rtpmpapay2 ! udpsink host=127.0.0.1 port=5004
This will encode an audio test signal to MP3 and then payload the encoded audio into RTP packets and send them out via UDP to localhost (IPv4) port 5004. You can use the rtpmpadepay2 or rtpmpadepay elements to depayload such a stream, and the mpg123audiodec or avdec_mp3 element to decode the depayloaded stream.
Hierarchy
GObject ╰──GInitiallyUnowned ╰──GstObject ╰──GstElement ╰──GstRtpBasePay2 ╰──rtpmpapay2
Factory details
Authors: – Tim-Philipp Müller
Classification: – Codec/Payloader/Network/RTP
Rank – primary
Plugin – rsrtp
Package – gst-plugin-rtp
Pad Templates
sink
audio/mpeg:
mpegversion: 1
parsed: true
src
application/x-rtp:
media: audio
encoding-name: MPA
clock-rate: 90000
application/x-rtp:
media: audio
payload: 14
clock-rate: 90000
Properties
aggregate-mode
“aggregate-mode” Rtp-mpeg-audio-pay-aggregate-mode *
Whether to send out audio frames immediately or aggregate them until a packet is full.
Flags : Read / Write
Default value : auto (-1)
max-ptime
“max-ptime” gint64
Maximum duration of the packet data in ns (-1 = unlimited up to MTU)
Flags : Read / Write
Default value : 18446744073709551615
Named constants
Rtp-mpeg-audio-pay-aggregate-mode
Members
auto (-1) – Automatic: zero-latency if upstream is live, otherwise aggregate frames until packet is full.
zero-latency (0) – Zero Latency: always send out frames right away, do not wait for more frames to fill a packet.
aggregate (1) – Aggregate: collect audio frames until we have a full packet or the max-ptime limit is hit (if set).
The results of the search are