mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-08 00:59:48 +00:00
rtpamrdepay: fix unnecessary sub-buffer creation
We create a sub-buffer just to copy over its metas and then throw it away immediately, just use the original input buffer directly.
This commit is contained in:
parent
a8b8643977
commit
c75f94c8f5
1 changed files with 1 additions and 4 deletions
|
@ -306,7 +306,6 @@ gst_rtp_amr_depay_process (GstRTPBaseDepayload * depayload, GstRTPBuffer * rtp)
|
|||
gint i, num_packets, num_nonempty_packets;
|
||||
gint amr_len;
|
||||
gint ILL, ILP;
|
||||
GstBuffer *buf;
|
||||
|
||||
payload_len = gst_rtp_buffer_get_payload_len (rtp);
|
||||
|
||||
|
@ -428,10 +427,8 @@ gst_rtp_amr_depay_process (GstRTPBaseDepayload * depayload, GstRTPBuffer * rtp)
|
|||
GST_DEBUG_OBJECT (depayload, "pushing buffer of size %" G_GSIZE_FORMAT,
|
||||
gst_buffer_get_size (outbuf));
|
||||
|
||||
buf = gst_rtp_buffer_get_payload_buffer (rtp);
|
||||
gst_rtp_copy_meta (GST_ELEMENT_CAST (rtpamrdepay), outbuf, buf,
|
||||
gst_rtp_copy_meta (GST_ELEMENT_CAST (rtpamrdepay), outbuf, rtp->buffer,
|
||||
g_quark_from_static_string (GST_META_TAG_AUDIO_STR));
|
||||
gst_buffer_unref (buf);
|
||||
}
|
||||
|
||||
return outbuf;
|
||||
|
|
Loading…
Reference in a new issue