2005-07-14 10:29:30 +00:00
|
|
|
/* GStreamer
|
|
|
|
* Copyright (C) <2005> Philippe Khalaf <burger@speedy.org>
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
* <2005> Wim Taymans <wim@fluendo.com>
|
|
|
|
*
|
|
|
|
* gstrtpbuffer.h: various helper functions to manipulate buffers
|
|
|
|
* with RTP payload.
|
2005-07-14 10:29:30 +00:00
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Library General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Library General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Library General Public
|
|
|
|
* License along with this library; if not, write to the
|
2012-11-03 23:05:09 +00:00
|
|
|
* Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
|
|
|
|
* Boston, MA 02110-1301, USA.
|
2005-07-14 10:29:30 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __GST_RTPBUFFER_H__
|
|
|
|
#define __GST_RTPBUFFER_H__
|
|
|
|
|
|
|
|
#include <gst/gst.h>
|
2007-10-01 13:22:14 +00:00
|
|
|
#include <gst/rtp/gstrtppayloads.h>
|
2005-07-14 10:29:30 +00:00
|
|
|
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
|
2006-08-18 16:43:26 +00:00
|
|
|
/**
|
|
|
|
* GST_RTP_VERSION:
|
|
|
|
*
|
|
|
|
* The supported RTP version 2.
|
|
|
|
*/
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
#define GST_RTP_VERSION 2
|
|
|
|
|
2011-03-27 11:55:15 +00:00
|
|
|
|
|
|
|
typedef struct _GstRTPBuffer GstRTPBuffer;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* GstRTPBuffer:
|
|
|
|
* @buffer: pointer to RTP buffer
|
2012-04-02 08:31:18 +00:00
|
|
|
* @state: internal state
|
2012-08-21 09:48:33 +00:00
|
|
|
* @data: array of data
|
|
|
|
* @size: array of size
|
2012-04-02 08:31:18 +00:00
|
|
|
* @map: array of #GstMapInfo
|
2011-03-27 11:55:15 +00:00
|
|
|
*
|
|
|
|
* Data structure that points to an RTP packet.
|
|
|
|
* The size of the structure is made public to allow stack allocations.
|
|
|
|
*/
|
|
|
|
struct _GstRTPBuffer
|
|
|
|
{
|
|
|
|
GstBuffer *buffer;
|
2012-04-02 08:31:18 +00:00
|
|
|
guint state;
|
2012-07-17 14:35:06 +00:00
|
|
|
gpointer data[4];
|
|
|
|
gsize size[4];
|
2012-04-02 08:31:18 +00:00
|
|
|
GstMapInfo map[4];
|
2011-03-27 11:55:15 +00:00
|
|
|
};
|
|
|
|
|
2012-08-21 09:48:33 +00:00
|
|
|
#define GST_RTP_BUFFER_INIT { NULL, 0, { NULL, NULL, NULL, NULL}, { 0, 0, 0, 0 }, \
|
2012-07-17 14:35:06 +00:00
|
|
|
{ GST_MAP_INFO_INIT, GST_MAP_INFO_INIT, GST_MAP_INFO_INIT, GST_MAP_INFO_INIT} }
|
2011-12-09 15:03:41 +00:00
|
|
|
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
/* creating buffers */
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_allocate_data (GstBuffer *buffer, guint payload_len,
|
2007-09-03 19:31:11 +00:00
|
|
|
guint8 pad_len, guint8 csrc_count);
|
2005-07-14 10:29:30 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
GstBuffer* gst_rtp_buffer_new_take_data (gpointer data, gsize len);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2017-11-17 12:07:22 +00:00
|
|
|
GstBuffer* gst_rtp_buffer_new_copy_data (gconstpointer data, gsize len);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
GstBuffer* gst_rtp_buffer_new_allocate (guint payload_len, guint8 pad_len, guint8 csrc_count);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
GstBuffer* gst_rtp_buffer_new_allocate_len (guint packet_len, guint8 pad_len, guint8 csrc_count);
|
2005-07-14 10:29:30 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
guint gst_rtp_buffer_calc_header_len (guint8 csrc_count);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
guint gst_rtp_buffer_calc_packet_len (guint payload_len, guint8 pad_len, guint8 csrc_count);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
guint gst_rtp_buffer_calc_payload_len (guint packet_len, guint8 pad_len, guint8 csrc_count);
|
2005-07-14 10:29:30 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_map (GstBuffer *buffer, GstMapFlags flags, GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2012-07-17 14:35:06 +00:00
|
|
|
void gst_rtp_buffer_unmap (GstRTPBuffer *rtp);
|
2011-03-27 11:55:15 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_packet_len (GstRTPBuffer *rtp, guint len);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint gst_rtp_buffer_get_packet_len (GstRTPBuffer *rtp);
|
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint gst_rtp_buffer_get_header_len (GstRTPBuffer *rtp);
|
2005-08-09 17:29:40 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint8 gst_rtp_buffer_get_version (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_version (GstRTPBuffer *rtp, guint8 version);
|
2005-07-14 10:29:30 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_get_padding (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_padding (GstRTPBuffer *rtp, gboolean padding);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_pad_to (GstRTPBuffer *rtp, guint len);
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_get_extension (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_extension (GstRTPBuffer *rtp, gboolean extension);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_get_extension_data (GstRTPBuffer *rtp, guint16 *bits,
|
2007-09-03 19:31:11 +00:00
|
|
|
gpointer *data, guint *wordlen);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2013-06-16 20:39:30 +00:00
|
|
|
GBytes* gst_rtp_buffer_get_extension_bytes (GstRTPBuffer *rtp, guint16 *bits);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_set_extension_data (GstRTPBuffer *rtp, guint16 bits, guint16 length);
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint32 gst_rtp_buffer_get_ssrc (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_ssrc (GstRTPBuffer *rtp, guint32 ssrc);
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint8 gst_rtp_buffer_get_csrc_count (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint32 gst_rtp_buffer_get_csrc (GstRTPBuffer *rtp, guint8 idx);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_csrc (GstRTPBuffer *rtp, guint8 idx, guint32 csrc);
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_get_marker (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_marker (GstRTPBuffer *rtp, gboolean marker);
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint8 gst_rtp_buffer_get_payload_type (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_payload_type (GstRTPBuffer *rtp, guint8 payload_type);
|
gst-libs/gst/rtp/gstbasertpdepayload.*: Fix for RTPBuffer changes.
Original commit message from CVS:
* gst-libs/gst/rtp/gstbasertpdepayload.c:
(gst_base_rtp_depayload_chain),
(gst_base_rtp_depayload_add_to_queue),
(gst_base_rtp_depayload_push),
(gst_base_rtp_depayload_queue_release):
* gst-libs/gst/rtp/gstbasertpdepayload.h:
Fix for RTPBuffer changes.
* gst-libs/gst/rtp/gstrtpbuffer.c: (gst_rtpbuffer_allocate_data),
(gst_rtpbuffer_new_take_data), (gst_rtpbuffer_new_copy_data),
(gst_rtpbuffer_new_allocate), (gst_rtpbuffer_new_allocate_len),
(gst_rtpbuffer_calc_header_len), (gst_rtpbuffer_calc_packet_len),
(gst_rtpbuffer_calc_payload_len), (gst_rtpbuffer_validate_data),
(gst_rtpbuffer_validate), (gst_rtpbuffer_set_packet_len),
(gst_rtpbuffer_get_packet_len), (gst_rtpbuffer_get_version),
(gst_rtpbuffer_set_version), (gst_rtpbuffer_get_padding),
(gst_rtpbuffer_set_padding), (gst_rtpbuffer_pad_to),
(gst_rtpbuffer_get_extension), (gst_rtpbuffer_set_extension),
(gst_rtpbuffer_get_ssrc), (gst_rtpbuffer_set_ssrc),
(gst_rtpbuffer_get_csrc_count), (gst_rtpbuffer_get_csrc),
(gst_rtpbuffer_set_csrc), (gst_rtpbuffer_get_marker),
(gst_rtpbuffer_set_marker), (gst_rtpbuffer_get_payload_type),
(gst_rtpbuffer_set_payload_type), (gst_rtpbuffer_get_seq),
(gst_rtpbuffer_set_seq), (gst_rtpbuffer_get_timestamp),
(gst_rtpbuffer_set_timestamp), (gst_rtpbuffer_get_payload_len),
(gst_rtpbuffer_get_payload):
* gst-libs/gst/rtp/gstrtpbuffer.h:
Don't subclass GstBuffer but add methods and helper functions
to construct and manipulate RTP packets in regular GstBuffers.
2005-08-18 10:23:54 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint16 gst_rtp_buffer_get_seq (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_seq (GstRTPBuffer *rtp, guint16 seq);
|
2007-09-03 19:31:11 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint32 gst_rtp_buffer_get_timestamp (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
void gst_rtp_buffer_set_timestamp (GstRTPBuffer *rtp, guint32 timestamp);
|
2005-07-14 10:29:30 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-11-11 18:21:09 +00:00
|
|
|
GstBuffer* gst_rtp_buffer_get_payload_buffer (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-11-11 18:21:09 +00:00
|
|
|
GstBuffer* gst_rtp_buffer_get_payload_subbuffer (GstRTPBuffer *rtp, guint offset, guint len);
|
2006-08-18 16:43:26 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
guint gst_rtp_buffer_get_payload_len (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gpointer gst_rtp_buffer_get_payload (GstRTPBuffer *rtp);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2013-06-16 20:39:30 +00:00
|
|
|
GBytes* gst_rtp_buffer_get_payload_bytes (GstRTPBuffer *rtp);
|
2005-07-14 10:29:30 +00:00
|
|
|
|
2007-03-29 10:17:52 +00:00
|
|
|
/* some helpers */
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
guint32 gst_rtp_buffer_default_clock_rate (guint8 payload_type);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
gint gst_rtp_buffer_compare_seqnum (guint16 seqnum1, guint16 seqnum2);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2007-09-03 19:31:11 +00:00
|
|
|
guint64 gst_rtp_buffer_ext_timestamp (guint64 *exttimestamp, guint32 timestamp);
|
2007-03-29 10:17:52 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_get_extension_onebyte_header (GstRTPBuffer *rtp,
|
|
|
|
guint8 id,
|
|
|
|
guint nth,
|
|
|
|
gpointer * data,
|
|
|
|
guint * size);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_get_extension_twobytes_header (GstRTPBuffer *rtp,
|
2010-08-19 20:26:18 +00:00
|
|
|
guint8 * appbits,
|
|
|
|
guint8 id,
|
|
|
|
guint nth,
|
|
|
|
gpointer * data,
|
|
|
|
guint * size);
|
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_add_extension_onebyte_header (GstRTPBuffer *rtp,
|
|
|
|
guint8 id,
|
2016-07-26 14:46:02 +00:00
|
|
|
gconstpointer data,
|
2011-03-27 11:55:15 +00:00
|
|
|
guint size);
|
2017-05-16 00:00:09 +00:00
|
|
|
|
2018-03-13 11:17:58 +00:00
|
|
|
GST_RTP_API
|
2011-03-27 11:55:15 +00:00
|
|
|
gboolean gst_rtp_buffer_add_extension_twobytes_header (GstRTPBuffer *rtp,
|
2010-08-20 21:13:06 +00:00
|
|
|
guint8 appbits,
|
|
|
|
guint8 id,
|
2016-07-26 14:46:02 +00:00
|
|
|
gconstpointer data,
|
2010-08-20 21:13:06 +00:00
|
|
|
guint size);
|
2010-08-22 21:22:21 +00:00
|
|
|
|
2016-09-01 07:57:33 +00:00
|
|
|
/**
|
|
|
|
* GstRTPBufferFlags:
|
|
|
|
* @GST_RTP_BUFFER_FLAG_RETRANSMISSION: The #GstBuffer was once wrapped
|
|
|
|
* in a retransmitted packet as specified by RFC 4588.
|
2017-11-17 01:05:33 +00:00
|
|
|
* @GST_RTP_BUFFER_FLAG_REDUNDANT: The packet represents redundant RTP packet.
|
|
|
|
* The flag is used in gstrtpstorage to be able to hold the packetback
|
|
|
|
* and use it only for recovery from packet loss.
|
|
|
|
* Since: 1.14
|
2016-09-01 07:57:33 +00:00
|
|
|
* @GST_RTP_BUFFER_FLAG_LAST: Offset to define more flags.
|
|
|
|
*
|
|
|
|
* Additional RTP buffer flags. These flags can potentially be used on any
|
|
|
|
* buffers carrying RTP packets.
|
|
|
|
*
|
|
|
|
* Note that these are only valid for #GstCaps of type: application/x-rtp (x-rtcp).
|
|
|
|
* They can conflict with other extended buffer flags.
|
|
|
|
*
|
|
|
|
* Since: 1.10
|
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
GST_RTP_BUFFER_FLAG_RETRANSMISSION = (GST_BUFFER_FLAG_LAST << 0),
|
2017-11-17 01:05:33 +00:00
|
|
|
GST_RTP_BUFFER_FLAG_REDUNDANT = (GST_BUFFER_FLAG_LAST << 1),
|
2016-09-01 07:57:33 +00:00
|
|
|
GST_RTP_BUFFER_FLAG_LAST = (GST_BUFFER_FLAG_LAST << 8)
|
|
|
|
} GstRTPBufferFlags;
|
|
|
|
|
2015-07-22 09:31:05 +00:00
|
|
|
/**
|
|
|
|
* GstRTPBufferMapFlags:
|
|
|
|
* @GST_RTP_BUFFER_MAP_FLAG_SKIP_PADDING: Skip mapping and validation of RTP
|
|
|
|
* padding and RTP pad count when present. Useful for buffers where
|
|
|
|
* the padding may be encrypted.
|
|
|
|
* @GST_RTP_BUFFER_MAP_FLAG_LAST: Offset to define more flags
|
|
|
|
*
|
|
|
|
* Additional mapping flags for gst_rtp_buffer_map().
|
|
|
|
*
|
2015-10-20 09:08:23 +00:00
|
|
|
* Since: 1.6.1
|
2015-07-22 09:31:05 +00:00
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
GST_RTP_BUFFER_MAP_FLAG_SKIP_PADDING = (GST_MAP_FLAG_LAST << 0),
|
|
|
|
GST_RTP_BUFFER_MAP_FLAG_LAST = (GST_MAP_FLAG_LAST << 8)
|
|
|
|
/* 8 more flags possible afterwards */
|
|
|
|
} GstRTPBufferMapFlags;
|
2010-08-22 23:44:38 +00:00
|
|
|
|
2005-07-14 10:29:30 +00:00
|
|
|
G_END_DECLS
|
|
|
|
|
|
|
|
#endif /* __GST_RTPBUFFER_H__ */
|
|
|
|
|