# GstRTPBuffer

The GstRTPBuffer helper functions makes it easy to parse and create regular GstBuffer objects that contain RTP payloads. These buffers are typically of 'application/x-rtp' GstCaps.

## GstRTPBuffer

Data structure that points to an RTP packet. The size of the structure is made public to allow stack allocations.

### Members

`buffer` (GstBuffer *) –

pointer to RTP buffer

`state` (guint) –

internal state

`data` (gpointer *) –

array of data

`size` (gsize *) –

array of size

`map` (GstMapInfo *) –

array of GstMapInfo

## GstRtp.RTPBuffer

Data structure that points to an RTP packet. The size of the structure is made public to allow stack allocations.

### Members

`buffer` (Gst.Buffer) –

pointer to RTP buffer

`state` (Number) –

internal state

`data` ([ Object ]) –

array of data

`size` ([ Number ]) –

array of size

`map` ([ Gst.MapInfo ]) –

array of Gst.MapInfo

## GstRtp.RTPBuffer

Data structure that points to an RTP packet. The size of the structure is made public to allow stack allocations.

### Members

`buffer` (Gst.Buffer) –

pointer to RTP buffer

`state` (int) –

internal state

`data` ([ object ]) –

array of data

`size` ([ int ]) –

array of size

`map` ([ Gst.MapInfo ]) –

array of Gst.MapInfo

### Methods

#### gst_rtp_buffer_add_extension_onebyte_header

    gboolean
    gst_rtp_buffer_add_extension_onebyte_header (GstRTPBuffer * rtp,
                                                 guint8 id,
                                                 gconstpointer data,
                                                 guint size)

Adds a RFC 5285 header extension with a one byte header to the end of the RTP header. If there is already a RFC 5285 header extension with a one byte header, the new extension will be appended. It will not work if there is already a header extension that does not follow the mechanism described in RFC 5285 or if there is a header extension with a two bytes header as described in RFC 5285. In that case, use gst_rtp_buffer_add_extension_twobytes_header

Parameters:

`rtp` –

the RTP packet

`id` –

The ID of the header extension (between 1 and 14).

`data` ( [array length=size][element-type guint8]) –

location for data

`size` –

the size of the data in bytes

Returns –

TRUE if header extension could be added

#### GstRtp.RTPBuffer.prototype.add_extension_onebyte_header

    function GstRtp.RTPBuffer.prototype.add_extension_onebyte_header(id: Number, data: [ Number ], size: Number): {
        // javascript wrapper for 'gst_rtp_buffer_add_extension_onebyte_header'
    }

Adds a RFC 5285 header extension with a one byte header to the end of the RTP header. If there is already a RFC 5285 header extension with a one byte header, the new extension will be appended. It will not work if there is already a header extension that does not follow the mechanism described in RFC 5285 or if there is a header extension with a two bytes header as described in RFC 5285. In that case, use GstRtp.RTPBuffer.prototype.add_extension_twobytes_header

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`id` (Number) –

The ID of the header extension (between 1 and 14).

`data` ([ Number ]) –

location for data

`size` (Number) –

the size of the data in bytes

Returns (Number) –

true if header extension could be added

#### GstRtp.RTPBuffer.add_extension_onebyte_header

    def GstRtp.RTPBuffer.add_extension_onebyte_header (self, id, data, size):
        #python wrapper for 'gst_rtp_buffer_add_extension_onebyte_header'

Adds a RFC 5285 header extension with a one byte header to the end of the RTP header. If there is already a RFC 5285 header extension with a one byte header, the new extension will be appended. It will not work if there is already a header extension that does not follow the mechanism described in RFC 5285 or if there is a header extension with a two bytes header as described in RFC 5285. In that case, use GstRtp.RTPBuffer.add_extension_twobytes_header

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`id` (int) –

The ID of the header extension (between 1 and 14).

`data` ([ int ]) –

location for data

`size` (int) –

the size of the data in bytes

Returns (bool) –

True if header extension could be added

#### gst_rtp_buffer_add_extension_twobytes_header

    gboolean
    gst_rtp_buffer_add_extension_twobytes_header (GstRTPBuffer * rtp,
                                                  guint8 appbits,
                                                  guint8 id,
                                                  gconstpointer data,
                                                  guint size)

Adds a RFC 5285 header extension with a two bytes header to the end of the RTP header. If there is already a RFC 5285 header extension with a two bytes header, the new extension will be appended. It will not work if there is already a header extension that does not follow the mechanism described in RFC 5285 or if there is a header extension with a one byte header as described in RFC 5285. In that case, use gst_rtp_buffer_add_extension_onebyte_header

Parameters:

`rtp` –

the RTP packet

`appbits` –

Application specific bits

`id` –

The ID of the header extension

`data` ( [array length=size][element-type guint8]) –

location for data

`size` –

the size of the data in bytes

Returns –

TRUE if header extension could be added

#### GstRtp.RTPBuffer.prototype.add_extension_twobytes_header

    function GstRtp.RTPBuffer.prototype.add_extension_twobytes_header(appbits: Number, id: Number, data: [ Number ], size: Number): {
        // javascript wrapper for 'gst_rtp_buffer_add_extension_twobytes_header'
    }

Adds a RFC 5285 header extension with a two bytes header to the end of the RTP header. If there is already a RFC 5285 header extension with a two bytes header, the new extension will be appended. It will not work if there is already a header extension that does not follow the mechanism described in RFC 5285 or if there is a header extension with a one byte header as described in RFC 5285. In that case, use GstRtp.RTPBuffer.prototype.add_extension_onebyte_header

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`appbits` (Number) –

Application specific bits

`id` (Number) –

The ID of the header extension

`data` ([ Number ]) –

location for data

`size` (Number) –

the size of the data in bytes

Returns (Number) –

true if header extension could be added

#### GstRtp.RTPBuffer.add_extension_twobytes_header

    def GstRtp.RTPBuffer.add_extension_twobytes_header (self, appbits, id, data, size):
        #python wrapper for 'gst_rtp_buffer_add_extension_twobytes_header'

Adds a RFC 5285 header extension with a two bytes header to the end of the RTP header. If there is already a RFC 5285 header extension with a two bytes header, the new extension will be appended. It will not work if there is already a header extension that does not follow the mechanism described in RFC 5285 or if there is a header extension with a one byte header as described in RFC 5285. In that case, use GstRtp.RTPBuffer.add_extension_onebyte_header

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`appbits` (int) –

Application specific bits

`id` (int) –

The ID of the header extension

`data` ([ int ]) –

location for data

`size` (int) –

the size of the data in bytes

Returns (bool) –

True if header extension could be added

#### gst_rtp_buffer_get_csrc

    guint32
    gst_rtp_buffer_get_csrc (GstRTPBuffer * rtp,
                             guint8 idx)

Get the CSRC at index idx in buffer.

Parameters:

`rtp` –

the RTP packet

`idx` –

the index of the CSRC to get

Returns –

the CSRC at index idx in host order.

#### GstRtp.RTPBuffer.prototype.get_csrc

    function GstRtp.RTPBuffer.prototype.get_csrc(idx: Number): {
        // javascript wrapper for 'gst_rtp_buffer_get_csrc'
    }

Get the CSRC at index idx in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`idx` (Number) –

the index of the CSRC to get

Returns (Number) –

the CSRC at index idx in host order.

#### GstRtp.RTPBuffer.get_csrc

    def GstRtp.RTPBuffer.get_csrc (self, idx):
        #python wrapper for 'gst_rtp_buffer_get_csrc'

Get the CSRC at index idx in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`idx` (int) –

the index of the CSRC to get

Returns (int) –

the CSRC at index idx in host order.

#### gst_rtp_buffer_get_csrc_count

    guint8
    gst_rtp_buffer_get_csrc_count (GstRTPBuffer * rtp)

Get the CSRC count of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

the CSRC count of buffer.

#### GstRtp.RTPBuffer.prototype.get_csrc_count

    function GstRtp.RTPBuffer.prototype.get_csrc_count(): {
        // javascript wrapper for 'gst_rtp_buffer_get_csrc_count'
    }

Get the CSRC count of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

the CSRC count of buffer.

#### GstRtp.RTPBuffer.get_csrc_count

    def GstRtp.RTPBuffer.get_csrc_count (self):
        #python wrapper for 'gst_rtp_buffer_get_csrc_count'

Get the CSRC count of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

the CSRC count of buffer.

#### gst_rtp_buffer_get_extension

    gboolean
    gst_rtp_buffer_get_extension (GstRTPBuffer * rtp)

Check if the extension bit is set on the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

TRUE if buffer has the extension bit set.

#### GstRtp.RTPBuffer.prototype.get_extension

    function GstRtp.RTPBuffer.prototype.get_extension(): {
        // javascript wrapper for 'gst_rtp_buffer_get_extension'
    }

Check if the extension bit is set on the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

TRUE if buffer has the extension bit set.

#### GstRtp.RTPBuffer.get_extension

    def GstRtp.RTPBuffer.get_extension (self):
        #python wrapper for 'gst_rtp_buffer_get_extension'

Check if the extension bit is set on the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (bool) –

TRUE if buffer has the extension bit set.

#### gst_rtp_buffer_get_extension_bytes

    GBytes *
    gst_rtp_buffer_get_extension_bytes (GstRTPBuffer * rtp,
                                        guint16 * bits)

Similar to gst_rtp_buffer_get_extension_data, but more suitable for language bindings usage. bits will contain the extension 16 bits of custom data and the extension data (not including the extension header) is placed in a new GBytes structure.

If rtp did not contain an extension, this function will return NULL, with bits unchanged. If there is an extension header but no extension data then an empty GBytes will be returned.

Parameters:

`rtp` –

the RTP packet

`bits` ( [out]) –

location for header bits

Returns ( [transfer: full][nullable]) –

A new GBytes if an extension header was present and NULL otherwise.

Since : 1.2

#### GstRtp.RTPBuffer.prototype.get_extension_bytes

    function GstRtp.RTPBuffer.prototype.get_extension_bytes(): {
        // javascript wrapper for 'gst_rtp_buffer_get_extension_bytes'
    }

Similar to gst_rtp_buffer_get_extension_data, but more suitable for language bindings usage. bits will contain the extension 16 bits of custom data and the extension data (not including the extension header) is placed in a new GBytes (not introspectable) structure.

If rtp did not contain an extension, this function will return null, with bits unchanged. If there is an extension header but no extension data then an empty GBytes (not introspectable) will be returned.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns a tuple made of:

(GBytes (not introspectable) ) –

A new GBytes (not introspectable) if an extension header was present and null otherwise.

`bits` (Number ) –

A new GBytes (not introspectable) if an extension header was present and null otherwise.

Since : 1.2

#### GstRtp.RTPBuffer.get_extension_bytes

    def GstRtp.RTPBuffer.get_extension_bytes (self):
        #python wrapper for 'gst_rtp_buffer_get_extension_bytes'

Similar to gst_rtp_buffer_get_extension_data, but more suitable for language bindings usage. bits will contain the extension 16 bits of custom data and the extension data (not including the extension header) is placed in a new GBytes (not introspectable) structure.

If rtp did not contain an extension, this function will return None, with bits unchanged. If there is an extension header but no extension data then an empty GBytes (not introspectable) will be returned.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns a tuple made of:

(GBytes (not introspectable) ) –

A new GBytes (not introspectable) if an extension header was present and None otherwise.

`bits` (int ) –

A new GBytes (not introspectable) if an extension header was present and None otherwise.

Since : 1.2

#### gst_rtp_buffer_get_extension_data

    gboolean
    gst_rtp_buffer_get_extension_data (GstRTPBuffer * rtp,
                                       guint16 * bits,
                                       gpointer * data,
                                       guint * wordlen)

Get the extension data. bits will contain the extension 16 bits of custom data. data will point to the data in the extension and wordlen will contain the length of data in 32 bits words.

If buffer did not contain an extension, this function will return FALSE with bits, data and wordlen unchanged.

Parameters:

`rtp` –

the RTP packet

`bits` ( [optional][out]) –

location for result bits

`data` ( [optional][out][array][element-type guint8][transfer: none]) –

location for data

`wordlen` ( [optional][out]) –

location for length of data in 32 bits words

Returns –

TRUE if buffer had the extension bit set.

#### gst_rtp_buffer_get_extension_onebyte_header

    gboolean
    gst_rtp_buffer_get_extension_onebyte_header (GstRTPBuffer * rtp,
                                                 guint8 id,
                                                 guint nth,
                                                 gpointer * data,
                                                 guint * size)

Parses RFC 5285 style header extensions with a one byte header. It will return the nth extension with the requested id.

Parameters:

`rtp` –

the RTP packet

`id` –

The ID of the header extension to be read (between 1 and 14).

`nth` –

Read the nth extension packet with the requested ID

`data` –

(optional) (out) (array length=size) (element-type guint8) (transfer none): location for data

`size` ( [optional][out]) –

the size of the data in bytes

Returns –

TRUE if buffer had the requested header extension

#### GstRtp.RTPBuffer.prototype.get_extension_onebyte_header

    function GstRtp.RTPBuffer.prototype.get_extension_onebyte_header(id: Number, nth: Number): {
        // javascript wrapper for 'gst_rtp_buffer_get_extension_onebyte_header'
    }

Parses RFC 5285 style header extensions with a one byte header. It will return the nth extension with the requested id.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`id` (Number) –

The ID of the header extension to be read (between 1 and 14).

`nth` (Number) –

Read the nth extension packet with the requested ID

Returns a tuple made of:

(Number ) –

TRUE if buffer had the requested header extension

`data` ([ Number ] ) –

TRUE if buffer had the requested header extension

`size` (Number ) –

TRUE if buffer had the requested header extension

#### GstRtp.RTPBuffer.get_extension_onebyte_header

    def GstRtp.RTPBuffer.get_extension_onebyte_header (self, id, nth):
        #python wrapper for 'gst_rtp_buffer_get_extension_onebyte_header'

Parses RFC 5285 style header extensions with a one byte header. It will return the nth extension with the requested id.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`id` (int) –

The ID of the header extension to be read (between 1 and 14).

`nth` (int) –

Read the nth extension packet with the requested ID

Returns a tuple made of:

(bool ) –

TRUE if buffer had the requested header extension

`data` ([ int ] ) –

TRUE if buffer had the requested header extension

`size` (int ) –

TRUE if buffer had the requested header extension

#### gst_rtp_buffer_get_extension_twobytes_header

    gboolean
    gst_rtp_buffer_get_extension_twobytes_header (GstRTPBuffer * rtp,
                                                  guint8 * appbits,
                                                  guint8 id,
                                                  guint nth,
                                                  gpointer * data,
                                                  guint * size)

Parses RFC 5285 style header extensions with a two bytes header. It will return the nth extension with the requested id.

Parameters:

`rtp` –

the RTP packet

`appbits` ( [optional][out]) –

Application specific bits

`id` –

The ID of the header extension to be read (between 1 and 14).

`nth` –

Read the nth extension packet with the requested ID

`data` –

(optional) (out) (array length=size) (element-type guint8) (transfer none): location for data

`size` ( [optional][out]) –

the size of the data in bytes

Returns –

TRUE if buffer had the requested header extension

#### GstRtp.RTPBuffer.prototype.get_extension_twobytes_header

    function GstRtp.RTPBuffer.prototype.get_extension_twobytes_header(id: Number, nth: Number): {
        // javascript wrapper for 'gst_rtp_buffer_get_extension_twobytes_header'
    }

Parses RFC 5285 style header extensions with a two bytes header. It will return the nth extension with the requested id.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`id` (Number) –

The ID of the header extension to be read (between 1 and 14).

`nth` (Number) –

Read the nth extension packet with the requested ID

Returns a tuple made of:

(Number ) –

TRUE if buffer had the requested header extension

`appbits` (Number ) –

TRUE if buffer had the requested header extension

`data` ([ Number ] ) –

TRUE if buffer had the requested header extension

`size` (Number ) –

TRUE if buffer had the requested header extension

#### GstRtp.RTPBuffer.get_extension_twobytes_header

    def GstRtp.RTPBuffer.get_extension_twobytes_header (self, id, nth):
        #python wrapper for 'gst_rtp_buffer_get_extension_twobytes_header'

Parses RFC 5285 style header extensions with a two bytes header. It will return the nth extension with the requested id.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`id` (int) –

The ID of the header extension to be read (between 1 and 14).

`nth` (int) –

Read the nth extension packet with the requested ID

Returns a tuple made of:

(bool ) –

TRUE if buffer had the requested header extension

`appbits` (int ) –

TRUE if buffer had the requested header extension

`data` ([ int ] ) –

TRUE if buffer had the requested header extension

`size` (int ) –

TRUE if buffer had the requested header extension

#### gst_rtp_buffer_get_header_len

    guint
    gst_rtp_buffer_get_header_len (GstRTPBuffer * rtp)

Return the total length of the header in buffer. This include the length of the fixed header, the CSRC list and the extension header.

Parameters:

`rtp` –

the RTP packet

Returns –

The total length of the header in buffer.

#### GstRtp.RTPBuffer.prototype.get_header_len

    function GstRtp.RTPBuffer.prototype.get_header_len(): {
        // javascript wrapper for 'gst_rtp_buffer_get_header_len'
    }

Return the total length of the header in buffer. This include the length of the fixed header, the CSRC list and the extension header.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The total length of the header in buffer.

#### GstRtp.RTPBuffer.get_header_len

    def GstRtp.RTPBuffer.get_header_len (self):
        #python wrapper for 'gst_rtp_buffer_get_header_len'

Return the total length of the header in buffer. This include the length of the fixed header, the CSRC list and the extension header.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The total length of the header in buffer.

#### gst_rtp_buffer_get_marker

    gboolean
    gst_rtp_buffer_get_marker (GstRTPBuffer * rtp)

Check if the marker bit is set on the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

TRUE if buffer has the marker bit set.

#### GstRtp.RTPBuffer.prototype.get_marker

    function GstRtp.RTPBuffer.prototype.get_marker(): {
        // javascript wrapper for 'gst_rtp_buffer_get_marker'
    }

Check if the marker bit is set on the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

TRUE if buffer has the marker bit set.

#### GstRtp.RTPBuffer.get_marker

    def GstRtp.RTPBuffer.get_marker (self):
        #python wrapper for 'gst_rtp_buffer_get_marker'

Check if the marker bit is set on the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (bool) –

TRUE if buffer has the marker bit set.

#### gst_rtp_buffer_get_packet_len

    guint
    gst_rtp_buffer_get_packet_len (GstRTPBuffer * rtp)

Return the total length of the packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

The total length of the packet in buffer.

#### GstRtp.RTPBuffer.prototype.get_packet_len

    function GstRtp.RTPBuffer.prototype.get_packet_len(): {
        // javascript wrapper for 'gst_rtp_buffer_get_packet_len'
    }

Return the total length of the packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The total length of the packet in buffer.

#### GstRtp.RTPBuffer.get_packet_len

    def GstRtp.RTPBuffer.get_packet_len (self):
        #python wrapper for 'gst_rtp_buffer_get_packet_len'

Return the total length of the packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The total length of the packet in buffer.

#### gst_rtp_buffer_get_padding

    gboolean
    gst_rtp_buffer_get_padding (GstRTPBuffer * rtp)

Check if the padding bit is set on the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

TRUE if buffer has the padding bit set.

#### GstRtp.RTPBuffer.prototype.get_padding

    function GstRtp.RTPBuffer.prototype.get_padding(): {
        // javascript wrapper for 'gst_rtp_buffer_get_padding'
    }

Check if the padding bit is set on the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

TRUE if buffer has the padding bit set.

#### GstRtp.RTPBuffer.get_padding

    def GstRtp.RTPBuffer.get_padding (self):
        #python wrapper for 'gst_rtp_buffer_get_padding'

Check if the padding bit is set on the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (bool) –

TRUE if buffer has the padding bit set.

#### gst_rtp_buffer_get_payload

    gpointer
    gst_rtp_buffer_get_payload (GstRTPBuffer * rtp)

Get a pointer to the payload data in buffer. This pointer is valid as long as a reference to buffer is held.

Parameters:

`rtp` –

the RTP packet

Returns ( [array][element-type guint8][transfer: none][nullable]) –

A pointer to the payload data in buffer.

#### gst_rtp_buffer_get_payload_buffer

    GstBuffer *
    gst_rtp_buffer_get_payload_buffer (GstRTPBuffer * rtp)

Create a buffer of the payload of the RTP packet in buffer. This function will internally create a subbuffer of buffer so that a memcpy can be avoided.

Parameters:

`rtp` –

the RTP packet

Returns ( [transfer: full]) –

A new buffer with the data of the payload.

#### GstRtp.RTPBuffer.prototype.get_payload_buffer

    function GstRtp.RTPBuffer.prototype.get_payload_buffer(): {
        // javascript wrapper for 'gst_rtp_buffer_get_payload_buffer'
    }

Create a buffer of the payload of the RTP packet in buffer. This function will internally create a subbuffer of buffer so that a memcpy can be avoided.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Gst.Buffer) –

A new buffer with the data of the payload.

#### GstRtp.RTPBuffer.get_payload_buffer

    def GstRtp.RTPBuffer.get_payload_buffer (self):
        #python wrapper for 'gst_rtp_buffer_get_payload_buffer'

Create a buffer of the payload of the RTP packet in buffer. This function will internally create a subbuffer of buffer so that a memcpy can be avoided.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Gst.Buffer) –

A new buffer with the data of the payload.

#### gst_rtp_buffer_get_payload_bytes

    GBytes *
    gst_rtp_buffer_get_payload_bytes (GstRTPBuffer * rtp)

Similar to gst_rtp_buffer_get_payload, but more suitable for language bindings usage. The return value is a pointer to a GBytes structure containing the payload data in rtp.

Parameters:

`rtp` –

the RTP packet

Returns ( [transfer: full][nullable]) –

A new GBytes containing the payload data in rtp.

Since : 1.2

#### GstRtp.RTPBuffer.prototype.get_payload_bytes

    function GstRtp.RTPBuffer.prototype.get_payload_bytes(): {
        // javascript wrapper for 'gst_rtp_buffer_get_payload_bytes'
    }

Similar to gst_rtp_buffer_get_payload, but more suitable for language bindings usage. The return value is a pointer to a GBytes (not introspectable) structure containing the payload data in rtp.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (GBytes (not introspectable)) –

A new GBytes (not introspectable) containing the payload data in rtp.

Since : 1.2

#### GstRtp.RTPBuffer.get_payload_bytes

    def GstRtp.RTPBuffer.get_payload_bytes (self):
        #python wrapper for 'gst_rtp_buffer_get_payload_bytes'

Similar to gst_rtp_buffer_get_payload, but more suitable for language bindings usage. The return value is a pointer to a GBytes (not introspectable) structure containing the payload data in rtp.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (GBytes (not introspectable)) –

A new GBytes (not introspectable) containing the payload data in rtp.

Since : 1.2

#### gst_rtp_buffer_get_payload_len

    guint
    gst_rtp_buffer_get_payload_len (GstRTPBuffer * rtp)

Get the length of the payload of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

The length of the payload in buffer.

#### GstRtp.RTPBuffer.prototype.get_payload_len

    function GstRtp.RTPBuffer.prototype.get_payload_len(): {
        // javascript wrapper for 'gst_rtp_buffer_get_payload_len'
    }

Get the length of the payload of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The length of the payload in buffer.

#### GstRtp.RTPBuffer.get_payload_len

    def GstRtp.RTPBuffer.get_payload_len (self):
        #python wrapper for 'gst_rtp_buffer_get_payload_len'

Get the length of the payload of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The length of the payload in buffer.

#### gst_rtp_buffer_get_payload_subbuffer

    GstBuffer *
    gst_rtp_buffer_get_payload_subbuffer (GstRTPBuffer * rtp,
                                          guint offset,
                                          guint len)

Create a subbuffer of the payload of the RTP packet in buffer. offset bytes are skipped in the payload and the subbuffer will be of size len. If len is -1 the total payload starting from offset is subbuffered.

Parameters:

`rtp` –

the RTP packet

`offset` –

the offset in the payload

`len` –

the length in the payload

Returns ( [transfer: full]) –

A new buffer with the specified data of the payload.

#### GstRtp.RTPBuffer.prototype.get_payload_subbuffer

    function GstRtp.RTPBuffer.prototype.get_payload_subbuffer(offset: Number, len: Number): {
        // javascript wrapper for 'gst_rtp_buffer_get_payload_subbuffer'
    }

Create a subbuffer of the payload of the RTP packet in buffer. offset bytes are skipped in the payload and the subbuffer will be of size len. If len is -1 the total payload starting from offset is subbuffered.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`offset` (Number) –

the offset in the payload

`len` (Number) –

the length in the payload

Returns (Gst.Buffer) –

A new buffer with the specified data of the payload.

#### GstRtp.RTPBuffer.get_payload_subbuffer

    def GstRtp.RTPBuffer.get_payload_subbuffer (self, offset, len):
        #python wrapper for 'gst_rtp_buffer_get_payload_subbuffer'

Create a subbuffer of the payload of the RTP packet in buffer. offset bytes are skipped in the payload and the subbuffer will be of size len. If len is -1 the total payload starting from offset is subbuffered.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`offset` (int) –

the offset in the payload

`len` (int) –

the length in the payload

Returns (Gst.Buffer) –

A new buffer with the specified data of the payload.

#### gst_rtp_buffer_get_payload_type

    guint8
    gst_rtp_buffer_get_payload_type (GstRTPBuffer * rtp)

Get the payload type of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

The payload type.

#### GstRtp.RTPBuffer.prototype.get_payload_type

    function GstRtp.RTPBuffer.prototype.get_payload_type(): {
        // javascript wrapper for 'gst_rtp_buffer_get_payload_type'
    }

Get the payload type of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The payload type.

#### GstRtp.RTPBuffer.get_payload_type

    def GstRtp.RTPBuffer.get_payload_type (self):
        #python wrapper for 'gst_rtp_buffer_get_payload_type'

Get the payload type of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The payload type.

#### gst_rtp_buffer_get_seq

    guint16
    gst_rtp_buffer_get_seq (GstRTPBuffer * rtp)

Get the sequence number of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

The sequence number in host order.

#### GstRtp.RTPBuffer.prototype.get_seq

    function GstRtp.RTPBuffer.prototype.get_seq(): {
        // javascript wrapper for 'gst_rtp_buffer_get_seq'
    }

Get the sequence number of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The sequence number in host order.

#### GstRtp.RTPBuffer.get_seq

    def GstRtp.RTPBuffer.get_seq (self):
        #python wrapper for 'gst_rtp_buffer_get_seq'

Get the sequence number of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The sequence number in host order.

#### gst_rtp_buffer_get_ssrc

    guint32
    gst_rtp_buffer_get_ssrc (GstRTPBuffer * rtp)

Get the SSRC of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

the SSRC of buffer in host order.

#### GstRtp.RTPBuffer.prototype.get_ssrc

    function GstRtp.RTPBuffer.prototype.get_ssrc(): {
        // javascript wrapper for 'gst_rtp_buffer_get_ssrc'
    }

Get the SSRC of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

the SSRC of buffer in host order.

#### GstRtp.RTPBuffer.get_ssrc

    def GstRtp.RTPBuffer.get_ssrc (self):
        #python wrapper for 'gst_rtp_buffer_get_ssrc'

Get the SSRC of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

the SSRC of buffer in host order.

#### gst_rtp_buffer_get_timestamp

    guint32
    gst_rtp_buffer_get_timestamp (GstRTPBuffer * rtp)

Get the timestamp of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

The timestamp in host order.

#### GstRtp.RTPBuffer.prototype.get_timestamp

    function GstRtp.RTPBuffer.prototype.get_timestamp(): {
        // javascript wrapper for 'gst_rtp_buffer_get_timestamp'
    }

Get the timestamp of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The timestamp in host order.

#### GstRtp.RTPBuffer.get_timestamp

    def GstRtp.RTPBuffer.get_timestamp (self):
        #python wrapper for 'gst_rtp_buffer_get_timestamp'

Get the timestamp of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The timestamp in host order.

#### gst_rtp_buffer_get_version

    guint8
    gst_rtp_buffer_get_version (GstRTPBuffer * rtp)

Get the version number of the RTP packet in buffer.

Parameters:

`rtp` –

the RTP packet

Returns –

The version of buffer.

#### GstRtp.RTPBuffer.prototype.get_version

    function GstRtp.RTPBuffer.prototype.get_version(): {
        // javascript wrapper for 'gst_rtp_buffer_get_version'
    }

Get the version number of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (Number) –

The version of buffer.

#### GstRtp.RTPBuffer.get_version

    def GstRtp.RTPBuffer.get_version (self):
        #python wrapper for 'gst_rtp_buffer_get_version'

Get the version number of the RTP packet in buffer.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Returns (int) –

The version of buffer.

#### gst_rtp_buffer_pad_to

    gst_rtp_buffer_pad_to (GstRTPBuffer * rtp,
                           guint len)

Set the amount of padding in the RTP packet in buffer to len. If len is 0, the padding is removed.

NOTE: This function does not work correctly.

Parameters:

`rtp` –

the RTP packet

`len` –

the new amount of padding

#### GstRtp.RTPBuffer.prototype.pad_to

    function GstRtp.RTPBuffer.prototype.pad_to(len: Number): {
        // javascript wrapper for 'gst_rtp_buffer_pad_to'
    }

Set the amount of padding in the RTP packet in buffer to len. If len is 0, the padding is removed.

NOTE: This function does not work correctly.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`len` (Number) –

the new amount of padding

#### GstRtp.RTPBuffer.pad_to

    def GstRtp.RTPBuffer.pad_to (self, len):
        #python wrapper for 'gst_rtp_buffer_pad_to'

Set the amount of padding in the RTP packet in buffer to len. If len is 0, the padding is removed.

NOTE: This function does not work correctly.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`len` (int) –

the new amount of padding

#### gst_rtp_buffer_remove_extension_data

    gst_rtp_buffer_remove_extension_data (GstRTPBuffer * rtp)

Unsets the extension bit of the RTP buffer and removes the extension header and data.

If the RTP buffer has no header extension data, the action has no effect. The RTP buffer must be mapped READWRITE only once and the underlying GstBuffer must be writable.

Parameters:

`rtp` –

the RTP packet

Since : 1.20

#### GstRtp.RTPBuffer.prototype.remove_extension_data

    function GstRtp.RTPBuffer.prototype.remove_extension_data(): {
        // javascript wrapper for 'gst_rtp_buffer_remove_extension_data'
    }

Unsets the extension bit of the RTP buffer and removes the extension header and data.

If the RTP buffer has no header extension data, the action has no effect. The RTP buffer must be mapped READWRITE only once and the underlying GstBuffer must be writable.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Since : 1.20

#### GstRtp.RTPBuffer.remove_extension_data

    def GstRtp.RTPBuffer.remove_extension_data (self):
        #python wrapper for 'gst_rtp_buffer_remove_extension_data'

Unsets the extension bit of the RTP buffer and removes the extension header and data.

If the RTP buffer has no header extension data, the action has no effect. The RTP buffer must be mapped READWRITE only once and the underlying GstBuffer must be writable.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

Since : 1.20

#### gst_rtp_buffer_set_csrc

    gst_rtp_buffer_set_csrc (GstRTPBuffer * rtp,
                             guint8 idx,
                             guint32 csrc)

Modify the CSRC at index idx in buffer to csrc.

Parameters:

`rtp` –

the RTP packet

`idx` –

the CSRC index to set

`csrc` –

the CSRC in host order to set at idx

#### GstRtp.RTPBuffer.prototype.set_csrc

    function GstRtp.RTPBuffer.prototype.set_csrc(idx: Number, csrc: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_csrc'
    }

Modify the CSRC at index idx in buffer to csrc.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`idx` (Number) –

the CSRC index to set

`csrc` (Number) –

the CSRC in host order to set at idx

#### GstRtp.RTPBuffer.set_csrc

    def GstRtp.RTPBuffer.set_csrc (self, idx, csrc):
        #python wrapper for 'gst_rtp_buffer_set_csrc'

Modify the CSRC at index idx in buffer to csrc.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`idx` (int) –

the CSRC index to set

`csrc` (int) –

the CSRC in host order to set at idx

#### gst_rtp_buffer_set_extension

    gst_rtp_buffer_set_extension (GstRTPBuffer * rtp,
                                  gboolean extension)

Set the extension bit on the RTP packet in buffer to extension.

Parameters:

`rtp` –

the RTP packet

`extension` –

the new extension

#### GstRtp.RTPBuffer.prototype.set_extension

    function GstRtp.RTPBuffer.prototype.set_extension(extension: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_extension'
    }

Set the extension bit on the RTP packet in buffer to extension.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`extension` (Number) –

the new extension

#### GstRtp.RTPBuffer.set_extension

    def GstRtp.RTPBuffer.set_extension (self, extension):
        #python wrapper for 'gst_rtp_buffer_set_extension'

Set the extension bit on the RTP packet in buffer to extension.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`extension` (bool) –

the new extension

#### gst_rtp_buffer_set_extension_data

    gboolean
    gst_rtp_buffer_set_extension_data (GstRTPBuffer * rtp,
                                       guint16 bits,
                                       guint16 length)

Set the extension bit of the rtp buffer and fill in the bits and length of the extension header. If the existing extension data is not large enough, it will be made larger.

Will also shorten the extension data from 1.20.

Parameters:

`rtp` –

the RTP packet

`bits` –

the bits specific for the extension

`length` –

the length that counts the number of 32-bit words in the extension, excluding the extension header ( therefore zero is a valid length)

Returns –

True if done.

#### GstRtp.RTPBuffer.prototype.set_extension_data

    function GstRtp.RTPBuffer.prototype.set_extension_data(bits: Number, length: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_extension_data'
    }

Set the extension bit of the rtp buffer and fill in the bits and length of the extension header. If the existing extension data is not large enough, it will be made larger.

Will also shorten the extension data from 1.20.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`bits` (Number) –

the bits specific for the extension

`length` (Number) –

the length that counts the number of 32-bit words in the extension, excluding the extension header ( therefore zero is a valid length)

Returns (Number) –

True if done.

#### GstRtp.RTPBuffer.set_extension_data

    def GstRtp.RTPBuffer.set_extension_data (self, bits, length):
        #python wrapper for 'gst_rtp_buffer_set_extension_data'

Set the extension bit of the rtp buffer and fill in the bits and length of the extension header. If the existing extension data is not large enough, it will be made larger.

Will also shorten the extension data from 1.20.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`bits` (int) –

the bits specific for the extension

`length` (int) –

the length that counts the number of 32-bit words in the extension, excluding the extension header ( therefore zero is a valid length)

Returns (bool) –

True if done.

#### gst_rtp_buffer_set_marker

    gst_rtp_buffer_set_marker (GstRTPBuffer * rtp,
                               gboolean marker)

Set the marker bit on the RTP packet in buffer to marker.

Parameters:

`rtp` –

the RTP packet

`marker` –

the new marker

#### GstRtp.RTPBuffer.prototype.set_marker

    function GstRtp.RTPBuffer.prototype.set_marker(marker: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_marker'
    }

Set the marker bit on the RTP packet in buffer to marker.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`marker` (Number) –

the new marker

#### GstRtp.RTPBuffer.set_marker

    def GstRtp.RTPBuffer.set_marker (self, marker):
        #python wrapper for 'gst_rtp_buffer_set_marker'

Set the marker bit on the RTP packet in buffer to marker.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`marker` (bool) –

the new marker

#### gst_rtp_buffer_set_packet_len

    gst_rtp_buffer_set_packet_len (GstRTPBuffer * rtp,
                                   guint len)

Set the total rtp size to len. The data in the buffer will be made larger if needed. Any padding will be removed from the packet.

Parameters:

`rtp` –

the RTP packet

`len` –

the new packet length

#### GstRtp.RTPBuffer.prototype.set_packet_len

    function GstRtp.RTPBuffer.prototype.set_packet_len(len: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_packet_len'
    }

Set the total rtp size to len. The data in the buffer will be made larger if needed. Any padding will be removed from the packet.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`len` (Number) –

the new packet length

#### GstRtp.RTPBuffer.set_packet_len

    def GstRtp.RTPBuffer.set_packet_len (self, len):
        #python wrapper for 'gst_rtp_buffer_set_packet_len'

Set the total rtp size to len. The data in the buffer will be made larger if needed. Any padding will be removed from the packet.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`len` (int) –

the new packet length

#### gst_rtp_buffer_set_padding

    gst_rtp_buffer_set_padding (GstRTPBuffer * rtp,
                                gboolean padding)

Set the padding bit on the RTP packet in buffer to padding.

Parameters:

`rtp` –

the buffer

`padding` –

the new padding

#### GstRtp.RTPBuffer.prototype.set_padding

    function GstRtp.RTPBuffer.prototype.set_padding(padding: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_padding'
    }

Set the padding bit on the RTP packet in buffer to padding.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the buffer

`padding` (Number) –

the new padding

#### GstRtp.RTPBuffer.set_padding

    def GstRtp.RTPBuffer.set_padding (self, padding):
        #python wrapper for 'gst_rtp_buffer_set_padding'

Set the padding bit on the RTP packet in buffer to padding.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the buffer

`padding` (bool) –

the new padding

#### gst_rtp_buffer_set_payload_type

    gst_rtp_buffer_set_payload_type (GstRTPBuffer * rtp,
                                     guint8 payload_type)

Set the payload type of the RTP packet in buffer to payload_type.

Parameters:

`rtp` –

the RTP packet

`payload_type` –

the new type

#### GstRtp.RTPBuffer.prototype.set_payload_type

    function GstRtp.RTPBuffer.prototype.set_payload_type(payload_type: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_payload_type'
    }

Set the payload type of the RTP packet in buffer to payload_type.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`payload_type` (Number) –

the new type

#### GstRtp.RTPBuffer.set_payload_type

    def GstRtp.RTPBuffer.set_payload_type (self, payload_type):
        #python wrapper for 'gst_rtp_buffer_set_payload_type'

Set the payload type of the RTP packet in buffer to payload_type.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`payload_type` (int) –

the new type

#### gst_rtp_buffer_set_seq

    gst_rtp_buffer_set_seq (GstRTPBuffer * rtp,
                            guint16 seq)

Set the sequence number of the RTP packet in buffer to seq.

Parameters:

`rtp` –

the RTP packet

`seq` –

the new sequence number

#### GstRtp.RTPBuffer.prototype.set_seq

    function GstRtp.RTPBuffer.prototype.set_seq(seq: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_seq'
    }

Set the sequence number of the RTP packet in buffer to seq.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`seq` (Number) –

the new sequence number

#### GstRtp.RTPBuffer.set_seq

    def GstRtp.RTPBuffer.set_seq (self, seq):
        #python wrapper for 'gst_rtp_buffer_set_seq'

Set the sequence number of the RTP packet in buffer to seq.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`seq` (int) –

the new sequence number

#### gst_rtp_buffer_set_ssrc

    gst_rtp_buffer_set_ssrc (GstRTPBuffer * rtp,
                             guint32 ssrc)

Set the SSRC on the RTP packet in buffer to ssrc.

Parameters:

`rtp` –

the RTP packet

`ssrc` –

the new SSRC

#### GstRtp.RTPBuffer.prototype.set_ssrc

    function GstRtp.RTPBuffer.prototype.set_ssrc(ssrc: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_ssrc'
    }

Set the SSRC on the RTP packet in buffer to ssrc.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`ssrc` (Number) –

the new SSRC

#### GstRtp.RTPBuffer.set_ssrc

    def GstRtp.RTPBuffer.set_ssrc (self, ssrc):
        #python wrapper for 'gst_rtp_buffer_set_ssrc'

Set the SSRC on the RTP packet in buffer to ssrc.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`ssrc` (int) –

the new SSRC

#### gst_rtp_buffer_set_timestamp

    gst_rtp_buffer_set_timestamp (GstRTPBuffer * rtp,
                                  guint32 timestamp)

Set the timestamp of the RTP packet in buffer to timestamp.

Parameters:

`rtp` –

the RTP packet

`timestamp` –

the new timestamp

#### GstRtp.RTPBuffer.prototype.set_timestamp

    function GstRtp.RTPBuffer.prototype.set_timestamp(timestamp: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_timestamp'
    }

Set the timestamp of the RTP packet in buffer to timestamp.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`timestamp` (Number) –

the new timestamp

#### GstRtp.RTPBuffer.set_timestamp

    def GstRtp.RTPBuffer.set_timestamp (self, timestamp):
        #python wrapper for 'gst_rtp_buffer_set_timestamp'

Set the timestamp of the RTP packet in buffer to timestamp.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`timestamp` (int) –

the new timestamp

#### gst_rtp_buffer_set_version

    gst_rtp_buffer_set_version (GstRTPBuffer * rtp,
                                guint8 version)

Set the version of the RTP packet in buffer to version.

Parameters:

`rtp` –

the RTP packet

`version` –

the new version

#### GstRtp.RTPBuffer.prototype.set_version

    function GstRtp.RTPBuffer.prototype.set_version(version: Number): {
        // javascript wrapper for 'gst_rtp_buffer_set_version'
    }

Set the version of the RTP packet in buffer to version.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`version` (Number) –

the new version

#### GstRtp.RTPBuffer.set_version

    def GstRtp.RTPBuffer.set_version (self, version):
        #python wrapper for 'gst_rtp_buffer_set_version'

Set the version of the RTP packet in buffer to version.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

the RTP packet

`version` (int) –

the new version

#### gst_rtp_buffer_unmap

    gst_rtp_buffer_unmap (GstRTPBuffer * rtp)

Unmap rtp previously mapped with gst_rtp_buffer_map.

Parameters:

`rtp` –

a GstRTPBuffer

#### GstRtp.RTPBuffer.prototype.unmap

    function GstRtp.RTPBuffer.prototype.unmap(): {
        // javascript wrapper for 'gst_rtp_buffer_unmap'
    }

Unmap rtp previously mapped with GstRtp.RTPBuffer.prototype.map.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

a GstRtp.RTPBuffer

#### GstRtp.RTPBuffer.unmap

    def GstRtp.RTPBuffer.unmap (self):
        #python wrapper for 'gst_rtp_buffer_unmap'

Unmap rtp previously mapped with GstRtp.RTPBuffer.map.

Parameters:

`rtp` (GstRtp.RTPBuffer) –

a GstRtp.RTPBuffer

### Functions

#### gst_rtp_buffer_allocate_data

    gst_rtp_buffer_allocate_data (GstBuffer * buffer,
                                  guint payload_len,
                                  guint8 pad_len,
                                  guint8 csrc_count)

Allocate enough data in buffer to hold an RTP packet with csrc_count CSRCs, a payload length of payload_len and padding of pad_len. buffer must be writable and all previous memory in buffer will be freed. If pad_len is >0, the padding bit will be set. All other RTP header fields will be set to 0/FALSE.

Parameters:

`buffer` –

a GstBuffer

`payload_len` –

the length of the payload

`pad_len` –

the amount of padding

`csrc_count` –

the number of CSRC entries

#### GstRtp.RTPBuffer.prototype.allocate_data

    function GstRtp.RTPBuffer.prototype.allocate_data(buffer: Gst.Buffer, payload_len: Number, pad_len: Number, csrc_count: Number): {
        // javascript wrapper for 'gst_rtp_buffer_allocate_data'
    }

Allocate enough data in buffer to hold an RTP packet with csrc_count CSRCs, a payload length of payload_len and padding of pad_len. buffer must be writable and all previous memory in buffer will be freed. If pad_len is >0, the padding bit will be set. All other RTP header fields will be set to 0/FALSE.

Parameters:

`buffer` (Gst.Buffer) –

a Gst.Buffer

`payload_len` (Number) –

the length of the payload

`pad_len` (Number) –

the amount of padding

`csrc_count` (Number) –

the number of CSRC entries

#### GstRtp.RTPBuffer.allocate_data

    def GstRtp.RTPBuffer.allocate_data (buffer, payload_len, pad_len, csrc_count):
        #python wrapper for 'gst_rtp_buffer_allocate_data'

Allocate enough data in buffer to hold an RTP packet with csrc_count CSRCs, a payload length of payload_len and padding of pad_len. buffer must be writable and all previous memory in buffer will be freed. If pad_len is >0, the padding bit will be set. All other RTP header fields will be set to 0/FALSE.

Parameters:

`buffer` (Gst.Buffer) –

a Gst.Buffer

`payload_len` (int) –

the length of the payload

`pad_len` (int) –

the amount of padding

`csrc_count` (int) –

the number of CSRC entries

#### gst_rtp_buffer_calc_header_len

    guint
    gst_rtp_buffer_calc_header_len (guint8 csrc_count)

Calculate the header length of an RTP packet with csrc_count CSRC entries. An RTP packet can have at most 15 CSRC entries.

Parameters:

`csrc_count` –

the number of CSRC entries

Returns –

The length of an RTP header with csrc_count CSRC entries.

#### GstRtp.RTPBuffer.prototype.calc_header_len

    function GstRtp.RTPBuffer.prototype.calc_header_len(csrc_count: Number): {
        // javascript wrapper for 'gst_rtp_buffer_calc_header_len'
    }

Calculate the header length of an RTP packet with csrc_count CSRC entries. An RTP packet can have at most 15 CSRC entries.

Parameters:

`csrc_count` (Number) –

the number of CSRC entries

Returns (Number) –

The length of an RTP header with csrc_count CSRC entries.

#### GstRtp.RTPBuffer.calc_header_len

    def GstRtp.RTPBuffer.calc_header_len (csrc_count):
        #python wrapper for 'gst_rtp_buffer_calc_header_len'

Calculate the header length of an RTP packet with csrc_count CSRC entries. An RTP packet can have at most 15 CSRC entries.

Parameters:

`csrc_count` (int) –

the number of CSRC entries

Returns (int) –

The length of an RTP header with csrc_count CSRC entries.

#### gst_rtp_buffer_calc_packet_len

    guint
    gst_rtp_buffer_calc_packet_len (guint payload_len,
                                    guint8 pad_len,
                                    guint8 csrc_count)

Calculate the total length of an RTP packet with a payload size of payload_len, a padding of pad_len and a csrc_count CSRC entries.

Parameters:

`payload_len` –

the length of the payload

`pad_len` –

the amount of padding

`csrc_count` –

the number of CSRC entries

Returns –

The total length of an RTP header with given parameters.

#### GstRtp.RTPBuffer.prototype.calc_packet_len

    function GstRtp.RTPBuffer.prototype.calc_packet_len(payload_len: Number, pad_len: Number, csrc_count: Number): {
        // javascript wrapper for 'gst_rtp_buffer_calc_packet_len'
    }

Calculate the total length of an RTP packet with a payload size of payload_len, a padding of pad_len and a csrc_count CSRC entries.

Parameters:

`payload_len` (Number) –

the length of the payload

`pad_len` (Number) –

the amount of padding

`csrc_count` (Number) –

the number of CSRC entries

Returns (Number) –

The total length of an RTP header with given parameters.

#### GstRtp.RTPBuffer.calc_packet_len

    def GstRtp.RTPBuffer.calc_packet_len (payload_len, pad_len, csrc_count):
        #python wrapper for 'gst_rtp_buffer_calc_packet_len'

Calculate the total length of an RTP packet with a payload size of payload_len, a padding of pad_len and a csrc_count CSRC entries.

Parameters:

`payload_len` (int) –

the length of the payload

`pad_len` (int) –

the amount of padding

`csrc_count` (int) –

the number of CSRC entries

Returns (int) –

The total length of an RTP header with given parameters.

#### gst_rtp_buffer_calc_payload_len

    guint
    gst_rtp_buffer_calc_payload_len (guint packet_len,
                                     guint8 pad_len,
                                     guint8 csrc_count)

Calculate the length of the payload of an RTP packet with size packet_len, a padding of pad_len and a csrc_count CSRC entries.

Parameters:

`packet_len` –

the length of the total RTP packet

`pad_len` –

the amount of padding

`csrc_count` –

the number of CSRC entries

Returns –

The length of the payload of an RTP packet with given parameters.

#### GstRtp.RTPBuffer.prototype.calc_payload_len

    function GstRtp.RTPBuffer.prototype.calc_payload_len(packet_len: Number, pad_len: Number, csrc_count: Number): {
        // javascript wrapper for 'gst_rtp_buffer_calc_payload_len'
    }

Calculate the length of the payload of an RTP packet with size packet_len, a padding of pad_len and a csrc_count CSRC entries.

Parameters:

`packet_len` (Number) –

the length of the total RTP packet

`pad_len` (Number) –

the amount of padding

`csrc_count` (Number) –

the number of CSRC entries

Returns (Number) –

The length of the payload of an RTP packet with given parameters.

#### GstRtp.RTPBuffer.calc_payload_len

    def GstRtp.RTPBuffer.calc_payload_len (packet_len, pad_len, csrc_count):
        #python wrapper for 'gst_rtp_buffer_calc_payload_len'

Calculate the length of the payload of an RTP packet with size packet_len, a padding of pad_len and a csrc_count CSRC entries.

Parameters:

`packet_len` (int) –

the length of the total RTP packet

`pad_len` (int) –

the amount of padding

`csrc_count` (int) –

the number of CSRC entries

Returns (int) –

The length of the payload of an RTP packet with given parameters.

#### gst_rtp_buffer_compare_seqnum

    gint
    gst_rtp_buffer_compare_seqnum (guint16 seqnum1,
                                   guint16 seqnum2)

Compare two sequence numbers, taking care of wraparounds. This function returns the difference between seqnum1 and seqnum2.

Parameters:

`seqnum1` –

a sequence number

`seqnum2` –

a sequence number

Returns –

a negative value if seqnum1 is bigger than seqnum2, 0 if they are equal or a positive value if seqnum1 is smaller than segnum2.

#### GstRtp.RTPBuffer.prototype.compare_seqnum

    function GstRtp.RTPBuffer.prototype.compare_seqnum(seqnum1: Number, seqnum2: Number): {
        // javascript wrapper for 'gst_rtp_buffer_compare_seqnum'
    }

Compare two sequence numbers, taking care of wraparounds. This function returns the difference between seqnum1 and seqnum2.

Parameters:

`seqnum1` (Number) –

a sequence number

`seqnum2` (Number) –

a sequence number

Returns (Number) –

a negative value if seqnum1 is bigger than seqnum2, 0 if they are equal or a positive value if seqnum1 is smaller than segnum2.

#### GstRtp.RTPBuffer.compare_seqnum

    def GstRtp.RTPBuffer.compare_seqnum (seqnum1, seqnum2):
        #python wrapper for 'gst_rtp_buffer_compare_seqnum'

Compare two sequence numbers, taking care of wraparounds. This function returns the difference between seqnum1 and seqnum2.

Parameters:

`seqnum1` (int) –

a sequence number

`seqnum2` (int) –

a sequence number

Returns (int) –

a negative value if seqnum1 is bigger than seqnum2, 0 if they are equal or a positive value if seqnum1 is smaller than segnum2.

#### gst_rtp_buffer_default_clock_rate

    guint32
    gst_rtp_buffer_default_clock_rate (guint8 payload_type)

Get the default clock-rate for the static payload type payload_type.

Parameters:

`payload_type` –

the static payload type

Returns –

the default clock rate or -1 if the payload type is not static or the clock-rate is undefined.

#### GstRtp.RTPBuffer.prototype.default_clock_rate

    function GstRtp.RTPBuffer.prototype.default_clock_rate(payload_type: Number): {
        // javascript wrapper for 'gst_rtp_buffer_default_clock_rate'
    }

Get the default clock-rate for the static payload type payload_type.

Parameters:

`payload_type` (Number) –

the static payload type

Returns (Number) –

the default clock rate or -1 if the payload type is not static or the clock-rate is undefined.

#### GstRtp.RTPBuffer.default_clock_rate

    def GstRtp.RTPBuffer.default_clock_rate (payload_type):
        #python wrapper for 'gst_rtp_buffer_default_clock_rate'

Get the default clock-rate for the static payload type payload_type.

Parameters:

`payload_type` (int) –

the static payload type

Returns (int) –

the default clock rate or -1 if the payload type is not static or the clock-rate is undefined.

#### gst_rtp_buffer_ext_timestamp

    guint64
    gst_rtp_buffer_ext_timestamp (guint64 * exttimestamp,
                                  guint32 timestamp)

Update the exttimestamp field with the extended timestamp of timestamp For the first call of the method, exttimestamp should point to a location with a value of -1.

This function is able to handle both forward and backward timestamps taking into account:

- timestamp wraparound making sure that the returned value is properly increased.
- timestamp unwraparound making sure that the returned value is properly decreased.

Parameters:

`exttimestamp` ( [inout]) –

a previous extended timestamp

`timestamp` –

a new timestamp

Returns –

The extended timestamp of timestamp or 0 if the result can't go anywhere backwards.

#### GstRtp.RTPBuffer.prototype.ext_timestamp

    function GstRtp.RTPBuffer.prototype.ext_timestamp(exttimestamp: Number, timestamp: Number): {
        // javascript wrapper for 'gst_rtp_buffer_ext_timestamp'
    }

Update the exttimestamp field with the extended timestamp of timestamp For the first call of the method, exttimestamp should point to a location with a value of -1.

This function is able to handle both forward and backward timestamps taking into account:

- timestamp wraparound making sure that the returned value is properly increased.
- timestamp unwraparound making sure that the returned value is properly decreased.

Parameters:

`exttimestamp` (Number) –

a previous extended timestamp

`timestamp` (Number) –

a new timestamp

Returns a tuple made of:

(Number ) –

The extended timestamp of timestamp or 0 if the result can't go anywhere backwards.

`exttimestamp` (Number ) –

The extended timestamp of timestamp or 0 if the result can't go anywhere backwards.

#### GstRtp.RTPBuffer.ext_timestamp

    def GstRtp.RTPBuffer.ext_timestamp (exttimestamp, timestamp):
        #python wrapper for 'gst_rtp_buffer_ext_timestamp'

Update the exttimestamp field with the extended timestamp of timestamp For the first call of the method, exttimestamp should point to a location with a value of -1.

This function is able to handle both forward and backward timestamps taking into account:

- timestamp wraparound making sure that the returned value is properly increased.
- timestamp unwraparound making sure that the returned value is properly decreased.

Parameters:

`exttimestamp` (int) –

a previous extended timestamp

`timestamp` (int) –

a new timestamp

Returns a tuple made of:

(int ) –

The extended timestamp of timestamp or 0 if the result can't go anywhere backwards.

`exttimestamp` (int ) –

The extended timestamp of timestamp or 0 if the result can't go anywhere backwards.

#### gst_rtp_buffer_get_extension_onebyte_header_from_bytes

    gboolean
    gst_rtp_buffer_get_extension_onebyte_header_from_bytes (GBytes * bytes,
                                                            guint16 bit_pattern,
                                                            guint8 id,
                                                            guint nth,
                                                            gpointer * data,
                                                            guint * size)

Similar to gst_rtp_buffer_get_extension_onebyte_header, but working on the GBytes you get from gst_rtp_buffer_get_extension_bytes. Parses RFC 5285 style header extensions with a one byte header. It will return the nth extension with the requested id.

Parameters:

`bytes` –

GBytes

`bit_pattern` –

The bit-pattern. Anything but 0xBEDE is rejected.

`id` –

The ID of the header extension to be read (between 1 and 14).

`nth` –

Read the nth extension packet with the requested ID

`data` –

(out) (array length=size) (element-type guint8) (transfer none): location for data

`size` ( [out]) –

the size of the data in bytes

Returns –

TRUE if bytes had the requested header extension

Since : 1.18

#### GstRtp.RTPBuffer.prototype.get_extension_onebyte_header_from_bytes

    function GstRtp.RTPBuffer.prototype.get_extension_onebyte_header_from_bytes(bytes: GBytes (not introspectable), bit_pattern: Number, id: Number, nth: Number): {
        // javascript wrapper for 'gst_rtp_buffer_get_extension_onebyte_header_from_bytes'
    }

Similar to gst_rtp_buffer_get_extension_onebyte_header, but working on the GBytes (not introspectable) you get from gst_rtp_buffer_get_extension_bytes. Parses RFC 5285 style header extensions with a one byte header. It will return the nth extension with the requested id.

Parameters:

`bytes` (GBytes (not introspectable)) –

GBytes (not introspectable)

`bit_pattern` (Number) –

The bit-pattern. Anything but 0xBEDE is rejected.

`id` (Number) –

The ID of the header extension to be read (between 1 and 14).

`nth` (Number) –

Read the nth extension packet with the requested ID

Returns a tuple made of:

(Number ) –

TRUE if bytes had the requested header extension

`data` ([ Number ] ) –

TRUE if bytes had the requested header extension

`size` (Number ) –

TRUE if bytes had the requested header extension

Since : 1.18

#### GstRtp.RTPBuffer.get_extension_onebyte_header_from_bytes

    def GstRtp.RTPBuffer.get_extension_onebyte_header_from_bytes (bytes, bit_pattern, id, nth):
        #python wrapper for 'gst_rtp_buffer_get_extension_onebyte_header_from_bytes'

Similar to gst_rtp_buffer_get_extension_onebyte_header, but working on the GBytes (not introspectable) you get from gst_rtp_buffer_get_extension_bytes. Parses RFC 5285 style header extensions with a one byte header. It will return the nth extension with the requested id.

Parameters:

`bytes` (GBytes (not introspectable)) –

GBytes (not introspectable)

`bit_pattern` (int) –

The bit-pattern. Anything but 0xBEDE is rejected.

`id` (int) –

The ID of the header extension to be read (between 1 and 14).

`nth` (int) –

Read the nth extension packet with the requested ID

Returns a tuple made of:

(bool ) –

TRUE if bytes had the requested header extension

`data` ([ int ] ) –

TRUE if bytes had the requested header extension

`size` (int ) –

TRUE if bytes had the requested header extension

Since : 1.18

#### gst_rtp_buffer_map

    gboolean
    gst_rtp_buffer_map (GstBuffer * buffer,
                        GstMapFlags flags,
                        GstRTPBuffer * rtp)

Map the contents of buffer into rtp.

Parameters:

`buffer` –

a GstBuffer

`flags` –

GstMapFlags

`rtp` ( [out]) –

a GstRTPBuffer

Returns –

TRUE if buffer could be mapped.

#### GstRtp.RTPBuffer.prototype.map

    function GstRtp.RTPBuffer.prototype.map(buffer: Gst.Buffer, flags: Gst.MapFlags): {
        // javascript wrapper for 'gst_rtp_buffer_map'
    }

Map the contents of buffer into rtp.

Parameters:

`buffer` (Gst.Buffer) –

a Gst.Buffer

`flags` (Gst.MapFlags) –

Gst.MapFlags

Returns a tuple made of:

(Number ) –

true if buffer could be mapped.

`rtp` (GstRtp.RTPBuffer ) –

true if buffer could be mapped.

#### GstRtp.RTPBuffer.map

    def GstRtp.RTPBuffer.map (buffer, flags):
        #python wrapper for 'gst_rtp_buffer_map'

Map the contents of buffer into rtp.

Parameters:

`buffer` (Gst.Buffer) –

a Gst.Buffer

`flags` (Gst.MapFlags) –

Gst.MapFlags

Returns a tuple made of:

(bool ) –

True if buffer could be mapped.

`rtp` (GstRtp.RTPBuffer ) –

True if buffer could be mapped.

#### gst_rtp_buffer_new_allocate

    GstBuffer *
    gst_rtp_buffer_new_allocate (guint payload_len,
                                 guint8 pad_len,
                                 guint8 csrc_count)

Allocate a new GstBuffer with enough data to hold an RTP packet with csrc_count CSRCs, a payload length of payload_len and padding of pad_len. All other RTP header fields will be set to 0/FALSE.

Parameters:

`payload_len` –

the length of the payload

`pad_len` –

the amount of padding

`csrc_count` –

the number of CSRC entries

Returns ( [transfer: full]) –

A newly allocated buffer that can hold an RTP packet with given parameters.

#### GstRtp.RTPBuffer.prototype.new_allocate

    function GstRtp.RTPBuffer.prototype.new_allocate(payload_len: Number, pad_len: Number, csrc_count: Number): {
        // javascript wrapper for 'gst_rtp_buffer_new_allocate'
    }

Allocate a new Gst.Buffer with enough data to hold an RTP packet with csrc_count CSRCs, a payload length of payload_len and padding of pad_len. All other RTP header fields will be set to 0/FALSE.

Parameters:

`payload_len` (Number) –

the length of the payload

`pad_len` (Number) –

the amount of padding

`csrc_count` (Number) –

the number of CSRC entries

Returns (Gst.Buffer) –

A newly allocated buffer that can hold an RTP packet with given parameters.

#### GstRtp.RTPBuffer.new_allocate

    def GstRtp.RTPBuffer.new_allocate (payload_len, pad_len, csrc_count):
        #python wrapper for 'gst_rtp_buffer_new_allocate'

Allocate a new Gst.Buffer with enough data to hold an RTP packet with csrc_count CSRCs, a payload length of payload_len and padding of pad_len. All other RTP header fields will be set to 0/FALSE.

Parameters:

`payload_len` (int) –

the length of the payload

`pad_len` (int) –

the amount of padding

`csrc_count` (int) –

the number of CSRC entries

Returns (Gst.Buffer) –

A newly allocated buffer that can hold an RTP packet with given parameters.

#### gst_rtp_buffer_new_allocate_len

    GstBuffer *
    gst_rtp_buffer_new_allocate_len (guint packet_len,
                                     guint8 pad_len,
                                     guint8 csrc_count)

Create a new GstBuffer that can hold an RTP packet that is exactly packet_len long. The length of the payload depends on pad_len and csrc_count and can be calculated with gst_rtp_buffer_calc_payload_len. All RTP header fields will be set to 0/FALSE.

Parameters:

`packet_len` –

the total length of the packet

`pad_len` –

the amount of padding

`csrc_count` –

the number of CSRC entries

Returns ( [transfer: full]) –

A newly allocated buffer that can hold an RTP packet of packet_len.

#### GstRtp.RTPBuffer.prototype.new_allocate_len

    function GstRtp.RTPBuffer.prototype.new_allocate_len(packet_len: Number, pad_len: Number, csrc_count: Number): {
        // javascript wrapper for 'gst_rtp_buffer_new_allocate_len'
    }

Create a new Gst.Buffer that can hold an RTP packet that is exactly packet_len long. The length of the payload depends on pad_len and csrc_count and can be calculated with GstRtp.RTPBuffer.prototype.calc_payload_len. All RTP header fields will be set to 0/FALSE.

Parameters:

`packet_len` (Number) –

the total length of the packet

`pad_len` (Number) –

the amount of padding

`csrc_count` (Number) –

the number of CSRC entries

Returns (Gst.Buffer) –

A newly allocated buffer that can hold an RTP packet of packet_len.

#### GstRtp.RTPBuffer.new_allocate_len

    def GstRtp.RTPBuffer.new_allocate_len (packet_len, pad_len, csrc_count):
        #python wrapper for 'gst_rtp_buffer_new_allocate_len'

Create a new Gst.Buffer that can hold an RTP packet that is exactly packet_len long. The length of the payload depends on pad_len and csrc_count and can be calculated with GstRtp.RTPBuffer.calc_payload_len. All RTP header fields will be set to 0/FALSE.

Parameters:

`packet_len` (int) –

the total length of the packet

`pad_len` (int) –

the amount of padding

`csrc_count` (int) –

the number of CSRC entries

Returns (Gst.Buffer) –

A newly allocated buffer that can hold an RTP packet of packet_len.

#### gst_rtp_buffer_new_copy_data

    GstBuffer *
    gst_rtp_buffer_new_copy_data (gconstpointer data,
                                  gsize len)

Create a new buffer and set the data to a copy of len bytes of data and the size to len. The data will be freed when the buffer is freed.

Parameters:

`data` ( [array length=len][element-type guint8]) –

data for the new buffer

`len` –

the length of data

Returns ( [transfer: full]) –

A newly allocated buffer with a copy of data and of size len.

#### GstRtp.RTPBuffer.prototype.new_copy_data

    function GstRtp.RTPBuffer.prototype.new_copy_data(data: [ Number ], len: Number): {
        // javascript wrapper for 'gst_rtp_buffer_new_copy_data'
    }

Create a new buffer and set the data to a copy of len bytes of data and the size to len. The data will be freed when the buffer is freed.

Parameters:

`data` ([ Number ]) –

data for the new buffer

`len` (Number) –

the length of data

Returns (Gst.Buffer) –

A newly allocated buffer with a copy of data and of size len.

#### GstRtp.RTPBuffer.new_copy_data

    def GstRtp.RTPBuffer.new_copy_data (data, len):
        #python wrapper for 'gst_rtp_buffer_new_copy_data'

Create a new buffer and set the data to a copy of len bytes of data and the size to len. The data will be freed when the buffer is freed.

Parameters:

`data` ([ int ]) –

data for the new buffer

`len` (int) –

the length of data

Returns (Gst.Buffer) –

A newly allocated buffer with a copy of data and of size len.

#### gst_rtp_buffer_new_take_data

    GstBuffer *
    gst_rtp_buffer_new_take_data (gpointer data,
                                  gsize len)

Create a new buffer and set the data and size of the buffer to data and len respectively. data will be freed when the buffer is unreffed, so this function transfers ownership of data to the new buffer.

Parameters:

`data` –

(array length=len) (transfer full) (element-type guint8): data for the new buffer

`len` –

the length of data

Returns ( [transfer: full]) –

A newly allocated buffer with data and of size len.

#### GstRtp.RTPBuffer.prototype.new_take_data

    function GstRtp.RTPBuffer.prototype.new_take_data(data: [ Number ], len: Number): {
        // javascript wrapper for 'gst_rtp_buffer_new_take_data'
    }

Create a new buffer and set the data and size of the buffer to data and len respectively. data will be freed when the buffer is unreffed, so this function transfers ownership of data to the new buffer.

Parameters:

`data` ([ Number ]) –

(array length=len) (transfer full) (element-type guint8): data for the new buffer

`len` (Number) –

the length of data

Returns (Gst.Buffer) –

A newly allocated buffer with data and of size len.

#### GstRtp.RTPBuffer.new_take_data

    def GstRtp.RTPBuffer.new_take_data (data, len):
        #python wrapper for 'gst_rtp_buffer_new_take_data'

Create a new buffer and set the data and size of the buffer to data and len respectively. data will be freed when the buffer is unreffed, so this function transfers ownership of data to the new buffer.

Parameters:

`data` ([ int ]) –

(array length=len) (transfer full) (element-type guint8): data for the new buffer

`len` (int) –

the length of data

Returns (Gst.Buffer) –

A newly allocated buffer with data and of size len.

## Enumerations

### GstRTPBufferFlags

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.

##### Members

`GST_RTP_BUFFER_FLAG_RETRANSMISSION` (1048576) –

The GstBuffer was once wrapped in a retransmitted packet as specified by RFC 4588.

`GST_RTP_BUFFER_FLAG_REDUNDANT` (2097152) –

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

`GST_RTP_BUFFER_FLAG_LAST` (268435456) –

Offset to define more flags.

Since : 1.10

### GstRtp.RTPBufferFlags

Additional RTP buffer flags. These flags can potentially be used on any buffers carrying RTP packets.

Note that these are only valid for Gst.Caps of type: application/x-rtp (x-rtcp). They can conflict with other extended buffer flags.

##### Members

`GstRtp.RTPBufferFlags.RETRANSMISSION` (1048576) –

The Gst.Buffer was once wrapped in a retransmitted packet as specified by RFC 4588.

`GstRtp.RTPBufferFlags.REDUNDANT` (2097152) –

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

`GstRtp.RTPBufferFlags.LAST` (268435456) –

Offset to define more flags.

Since : 1.10

### GstRtp.RTPBufferFlags

Additional RTP buffer flags. These flags can potentially be used on any buffers carrying RTP packets.

Note that these are only valid for Gst.Caps of type: application/x-rtp (x-rtcp). They can conflict with other extended buffer flags.

##### Members

`GstRtp.RTPBufferFlags.RETRANSMISSION` (1048576) –

The Gst.Buffer was once wrapped in a retransmitted packet as specified by RFC 4588.

`GstRtp.RTPBufferFlags.REDUNDANT` (2097152) –

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

`GstRtp.RTPBufferFlags.LAST` (268435456) –

Offset to define more flags.

Since : 1.10

### GstRTPBufferMapFlags

Additional mapping flags for gst_rtp_buffer_map.

##### Members

`GST_RTP_BUFFER_MAP_FLAG_SKIP_PADDING` (65536) –

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` (16777216) –

Offset to define more flags

Since : 1.6.1

### GstRtp.RTPBufferMapFlags

Additional mapping flags for GstRtp.RTPBuffer.prototype.map.

##### Members

`GstRtp.RTPBufferMapFlags.SKIP_PADDING` (65536) –

Skip mapping and validation of RTP padding and RTP pad count when present. Useful for buffers where the padding may be encrypted.

`GstRtp.RTPBufferMapFlags.LAST` (16777216) –

Offset to define more flags

Since : 1.6.1

### GstRtp.RTPBufferMapFlags

Additional mapping flags for GstRtp.RTPBuffer.map.

##### Members

`GstRtp.RTPBufferMapFlags.SKIP_PADDING` (65536) –

Skip mapping and validation of RTP padding and RTP pad count when present. Useful for buffers where the padding may be encrypted.

`GstRtp.RTPBufferMapFlags.LAST` (16777216) –

Offset to define more flags

Since : 1.6.1

## Constants

### GST_RTP_BUFFER_INIT

    #define GST_RTP_BUFFER_INIT { NULL, 0, { NULL, NULL, NULL, NULL}, { 0, 0, 0, 0 }, \
      { GST_MAP_INFO_INIT, GST_MAP_INFO_INIT, GST_MAP_INFO_INIT, GST_MAP_INFO_INIT} }

### GST_RTP_VERSION

    #define GST_RTP_VERSION 2

The supported RTP version 2.

### GstRtp.RTP_VERSION

The supported RTP version 2.

### GstRtp.RTP_VERSION

The supported RTP version 2.

The results of the search are