Struct medea_jason::media::constraints::LocalTracksConstraints
source · pub struct LocalTracksConstraints(_);
Expand description
Local media stream for injecting into new created PeerConnection
s.
Implementations§
source§impl LocalTracksConstraints
impl LocalTracksConstraints
sourcepub fn calculate_kinds_diff(
&self,
settings: &MediaStreamSettings
) -> LocalStreamUpdateCriteria
pub fn calculate_kinds_diff( &self, settings: &MediaStreamSettings ) -> LocalStreamUpdateCriteria
Returns LocalStreamUpdateCriteria
with MediaKind
and
MediaSourceKind
which are different in the provided
MediaStreamSettings
.
sourcepub fn constrain(&self, other: MediaStreamSettings)
pub fn constrain(&self, other: MediaStreamSettings)
Constrains the underlying MediaStreamSettings
with the given other
MediaStreamSettings
.
sourcepub fn inner(&self) -> MediaStreamSettings
pub fn inner(&self) -> MediaStreamSettings
Clones the underlying MediaStreamSettings
.
sourcepub fn set_media_state(
&self,
state: MediaState,
kind: MediaKind,
source_kind: Option<MediaSourceKind>
)
pub fn set_media_state( &self, state: MediaState, kind: MediaKind, source_kind: Option<MediaSourceKind> )
Changes the underlying MediaStreamSettings
basing on the provided
MediaState
.
sourcepub fn set_media_exchange_state_by_kinds(
&self,
state: Stable,
kinds: LocalStreamUpdateCriteria
)
pub fn set_media_exchange_state_by_kinds( &self, state: Stable, kinds: LocalStreamUpdateCriteria )
Enables/disables provided LocalStreamUpdateCriteria
based on
provided media_exchange_state
.
sourcepub fn enabled(&self, kind: MediaType) -> bool
pub fn enabled(&self, kind: MediaType) -> bool
Indicates whether provided MediaType
is enabled in the underlying
MediaStreamSettings
.
sourcepub fn muted(&self, kind: MediaType) -> bool
pub fn muted(&self, kind: MediaType) -> bool
Indicates whether provided MediaType
is muted in the underlying
MediaStreamSettings
.
sourcepub fn is_track_enabled_and_constrained(
&self,
kind: MediaKind,
source: Option<MediaSourceKind>
) -> bool
pub fn is_track_enabled_and_constrained( &self, kind: MediaKind, source: Option<MediaSourceKind> ) -> bool
Indicates whether the provided MediaKind
and MediaSourceKind
are
enabled and constrained in this LocalTracksConstraints
.
sourcepub fn is_track_enabled(
&self,
kind: MediaKind,
source: Option<MediaSourceKind>
) -> bool
pub fn is_track_enabled( &self, kind: MediaKind, source: Option<MediaSourceKind> ) -> bool
Indicates whether the provided MediaKind
and MediaSourceKind
are
enabled in this LocalTracksConstraints
.
Trait Implementations§
source§impl Clone for LocalTracksConstraints
impl Clone for LocalTracksConstraints
source§fn clone(&self) -> LocalTracksConstraints
fn clone(&self) -> LocalTracksConstraints
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more