Class RemoteTrackPublication
- Namespace
- LiveKit.Rtc
- Assembly
- LivekitRtc.dll
Remote track publication.
public class RemoteTrackPublication : TrackPublication
- Inheritance
-
RemoteTrackPublication
- Inherited Members
Properties
IsSubscribed
Whether this publication is subscribed.
public bool IsSubscribed { get; }
Property Value
Participant
The remote participant that owns this publication.
public RemoteParticipant Participant { get; }
Property Value
Track
The remote track (null until subscribed).
public RemoteTrack? Track { get; }
Property Value
Methods
SetEnabled(bool)
Enables or disables the subscribed track without unsubscribing. While disabled the server stops sending its media, which saves bandwidth when the track is not needed for a while (for example a video that is not being rendered).
public void SetEnabled(bool enabled)
Parameters
enabledboolFalse to pause receiving, true to resume.
SetSubscribed(bool)
Sets whether the track should be subscribed.
public void SetSubscribed(bool subscribed)
Parameters
subscribedboolTrue to subscribe, false to unsubscribe.
SetVideoDimensions(uint, uint)
Tells the server the dimensions at which this video track is consumed, so it can pick the most appropriate simulcast layer.
public void SetVideoDimensions(uint width, uint height)
Parameters
SetVideoQuality(VideoQuality)
For simulcast video tracks, requests a specific layer from the server:
Low (q), Medium (h) or High (f).
public void SetVideoQuality(VideoQuality quality)
Parameters
qualityVideoQualityThe layer to receive.
Exceptions
- InvalidOperationException
The publication is not a video track, or it is not simulcasted (selecting a layer requires multiple layers).