Trait gstreamer_rtp::prelude::RTPHeaderExtensionExt [−][src]
pub trait RTPHeaderExtensionExt: 'static {}Show methods
fn id(&self) -> u32; fn max_size(&self, input_meta: &Buffer) -> usize; fn sdp_caps_field_name(&self) -> GString; fn supported_flags(&self) -> RTPHeaderExtensionFlags; fn uri(&self) -> Option<GString>; fn set_attributes_from_caps(&self, caps: &Caps) -> bool; fn set_attributes_from_caps_simple_sdp(&self, caps: &Caps) -> bool; fn set_caps_from_attributes(&self, caps: &mut Caps) -> bool; fn set_caps_from_attributes_simple_sdp(&self, caps: &mut Caps) -> bool; fn set_id(&self, ext_id: u32); fn set_non_rtp_sink_caps(&self, caps: &Caps) -> bool; fn set_wants_update_non_rtp_src_caps(&self, state: bool); fn update_non_rtp_src_caps(&self, caps: &mut Caps) -> bool; fn wants_update_non_rtp_src_caps(&self) -> bool;
Expand description
Required methods
This is used to know how much data a certain header extension will need for both allocating the resulting data, and deciding how much payload data can be generated.
Implementations should return as accurate a value as is possible using the
information given in the input buffer
.
input_meta
Returns
the maximum size of the data written by this extension
fn sdp_caps_field_name(&self) -> GString
[src]
fn sdp_caps_field_name(&self) -> GString
[src]Returns
the gst::Structure
field name used in SDP-like gst::Caps
for this self
configuration
fn supported_flags(&self) -> RTPHeaderExtensionFlags
[src]
fn supported_flags(&self) -> RTPHeaderExtensionFlags
[src]Returns
the flags supported by this instance of self
fn set_attributes_from_caps(&self, caps: &Caps) -> bool
[src]
fn set_attributes_from_caps(&self, caps: &Caps) -> bool
[src]set_id()
must have been called with a valid
extension id that is contained in these caps.
The only current known caps format is based on the SDP standard as produced
by gst_sdp_media_attributes_to_caps()
.
caps
the gst::Caps
to configure this extension with
Returns
whether the caps
could be successfully set on self
.
fn set_attributes_from_caps_simple_sdp(&self, caps: &Caps) -> bool
[src]
fn set_attributes_from_caps_simple_sdp(&self, caps: &Caps) -> bool
[src]Helper implementation for GstRTPExtensionClass::set_attributes_from_caps that retrieves the configured extension id and checks that the corresponding field in the sdp caps is configured for this extension uri. Requires that the extension does not have any attributes or direction advertised in the caps.
caps
gst::Caps
to read attributes from
Returns
whether the attributes in the caps
could be set on self
successfully
fn set_caps_from_attributes(&self, caps: &mut Caps) -> bool
[src]
fn set_caps_from_attributes(&self, caps: &mut Caps) -> bool
[src]set_id()
must have been called with a valid
extension id that is contained in these caps.
The only current known caps format is based on the SDP standard as produced
by gst_sdp_media_attributes_to_caps()
.
caps
writable gst::Caps
to modify
Returns
whether the configured attributes on self
can successfully be set on
caps
fn set_caps_from_attributes_simple_sdp(&self, caps: &mut Caps) -> bool
[src]
fn set_caps_from_attributes_simple_sdp(&self, caps: &mut Caps) -> bool
[src]Helper implementation for GstRTPExtensionClass::set_caps_from_attributes
that sets the self
uri on caps with the specified extension id as required
for sdp gst::Caps
.
Requires that the extension does not have any attributes or direction
advertised in caps
.
caps
gst::Caps
to write fields into
Returns
whether the self
attributes could be set on caps
.
fn set_non_rtp_sink_caps(&self, caps: &Caps) -> bool
[src]
fn set_non_rtp_sink_caps(&self, caps: &Caps) -> bool
[src]fn set_wants_update_non_rtp_src_caps(&self, state: bool)
[src]
fn set_wants_update_non_rtp_src_caps(&self, state: bool)
[src]Call this function in a subclass from GstRTPHeaderExtensionClass::read
to
tell the depayloader whether the data just parsed from RTP packet require
updating its src (non-RTP) caps. If state
is TRUE, GstRTPBaseDepayload
will
eventually invoke update_non_rtp_src_caps()
to
have the caps update applied. Applying the update also flips the internal
“wants update” flag back to FALSE.
state
TRUE if caps update is needed
fn update_non_rtp_src_caps(&self, caps: &mut Caps) -> bool
[src]
fn update_non_rtp_src_caps(&self, caps: &mut Caps) -> bool
[src]fn wants_update_non_rtp_src_caps(&self) -> bool
[src]
fn wants_update_non_rtp_src_caps(&self) -> bool
[src]Call this function after gst_rtp_header_extension_read()
to check if
the depayloader’s src caps need updating with data received in the last RTP
packet.
Returns
Whether self
wants to update depayloader’s src caps.
Implementors
v1_20
only.