MixedReality-WebRTC MixedReality-WebRTC
Search Results for

    Show / Hide Table of Contents

    Class VideoTrackSource

    Video source for WebRTC video tracks.

    The video source is not bound to any peer connection, and can therefore be shared by multiple video tracks from different peer connections. This is especially useful to share local video capture devices (microphones) amongst multiple peer connections when building a multi-peer experience with a mesh topology (one connection per pair of peers).

    The user owns the video track source, and is in charge of keeping it alive until after all tracks using it are destroyed, and then dispose of it. The behavior of disposing of the track source while a track is still using it is undefined. The Tracks property contains the list of tracks currently using the source.

    Inheritance
    Object
    VideoTrackSource
    DeviceVideoTrackSource
    ExternalVideoTrackSource
    Implements
    IVideoSource
    IDisposable
    Namespace: Microsoft.MixedReality.WebRTC
    Assembly: Microsoft.MixedReality.WebRTC.dll
    Syntax
    public abstract class VideoTrackSource : object, IVideoSource

    Properties

    | Improve this Doc View Source

    Enabled

    Enabled status of the source. True until the object is disposed.

    Declaration
    public bool Enabled { get; }
    Property Value
    Type Description
    Boolean
    | Improve this Doc View Source

    FrameEncoding

    Video encoding indicating the kind of frames the source is producing.

    Declaration
    public abstract VideoEncoding FrameEncoding { get; }
    Property Value
    Type Description
    VideoEncoding
    | Improve this Doc View Source

    Name

    A name for the video track source, used for logging and debugging.

    Declaration
    public string Name { get; set; }
    Property Value
    Type Description
    String
    | Improve this Doc View Source

    Tracks

    List of local video tracks this source is providing raw video frames to.

    Declaration
    public IReadOnlyList<LocalVideoTrack> Tracks { get; }
    Property Value
    Type Description
    IReadOnlyList<LocalVideoTrack>

    Methods

    | Improve this Doc View Source

    Dispose()

    Declaration
    public virtual void Dispose()
    | Improve this Doc View Source

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    String

    Events

    | Improve this Doc View Source

    Argb32VideoFrameReady

    Event that occurs when a new video frame is available from the source, either because the source produced it locally (VideoTrackSource, LocalVideoTrack) or because it received it from the remote peer (RemoteVideoTrack).

    Declaration
    public event Argb32VideoFrameDelegate Argb32VideoFrameReady
    Event Type
    Type Description
    Argb32VideoFrameDelegate
    Remarks

    The event delivers to the handlers an ARGB32-encoded video frame.

    This event is invoked on the WebRTC worker thread. Handlers can be added/removed safely while the event is invoked, but access to any resource used by its handlers must be synchronized manually. Note that a handler might be invoked (at most once) after it has been removed from the event.

    | Improve this Doc View Source

    I420AVideoFrameReady

    Event that occurs when a new video frame is available from the source, either because the source produced it locally (VideoTrackSource, LocalVideoTrack) or because it received it from the remote peer (RemoteVideoTrack).

    Declaration
    public event I420AVideoFrameDelegate I420AVideoFrameReady
    Event Type
    Type Description
    I420AVideoFrameDelegate
    Remarks

    The event delivers to the handlers an I420-encoded video frame.

    This event is invoked on the WebRTC worker thread. Handlers can be added/removed safely while the event is invoked, but access to any resource used by its handlers must be synchronized manually. Note that a handler might be invoked (at most once) after it has been removed from the event.

    Implements

    IVideoSource
    IDisposable

    See Also

    DeviceVideoTrackSource
    ExternalVideoTrackSource
    LocalVideoTrack
    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX