RemoveTrack(MediaStreamTrack track) |
void |
Removes the MediaStreamTrack given as argument. If the track is not part of the MediaStream object, nothing happens. |
AddTrack(MediaStreamTrack track) |
void |
Stores a copy of the MediaStreamTrack given as argument. If the track has already been added to the MediaStream object, nothing happens. |
Clone() |
MediaStream |
Returns a clone of the MediaStream object. The clone will, however, have a unique value for id. |
GetTrackById(string id) |
MediaStreamTrack? |
Returns the track whose ID corresponds to the one given in parameters, trackid. If no parameter is given, or if no track with that ID does exist, it returns null. If several tracks have the same ID, it returns the first one. |
GetTracksLength() |
int |
Returns the total number of tracks |
GetTracks() |
Array<MediaStreamTrack> |
Returns a list of all MediaStreamTrack objects stored in the MediaStream object, regardless of the value of the kind attribute. The order is not defined, and may not only vary from one browser to another, but also from one call to another. |
GetVideoTracks() |
Array<MediaStreamTrack> |
Returns a list of the MediaStreamTrack objects stored in the MediaStream object that have their kind attribute set to "video". The order is not defined, and may not only vary from one browser to another, but also from one call to another. |
GetAudioTracks() |
Array<MediaStreamTrack> |
Returns a list of the MediaStreamTrack objects stored in the MediaStream object that have their kind attribute set to audio. The order is not defined, and may not only vary from one browser to another, but also from one call to another. |
GetFirstVideoTrack() |
MediaStreamTrack? |
Returns the first video track or null |
GetFirstVideoTrackSettings() |
MediaTrackSettings? |
Returns the first video track settings |
GetFirstAudioTrackSettings() |
MediaTrackSettings? |
Returns the first audio track settings |
GetFirstAudioTrack() |
MediaStreamTrack? |
Returns the first audio track or null |
StopAllTracks() |
void |
Calls stop on all tracks |
RemoveAllTracks(bool stopTracks) |
void |
Removes all tracks and optionally stops them first (default) If true, stop() will be called on the track before removing |
RemoveAllVideoTracks(bool stopTracks) |
void |
Removes all video tracks and optionally stops them first (default) If true, stop() will be called on the track before removing |
RemoveAllAudioTracks(bool stopTracks) |
void |
Removes all audio tracks and optionally stops them first (default) If true, stop() will be called on the track before removing |