Class MediaStats
Represents stats collected from the connection.
Inheritance
System.Object
MediaStats
Assembly: FM.LiveSwitch.dll
public class MediaStats : object
Properties
Gets the available outgoing bitrate.
Declaration
public long AvailableOutgoingBitrate { get; }
Property Value
| Type |
Description |
| System.Int64 |
|
Gets if the media track is detached.
Declaration
public bool Detached { get; }
Property Value
| Type |
Description |
| System.Boolean |
|
Gets the direction the media is being sent.
Declaration
public string Direction { get; }
Property Value
| Type |
Description |
| System.String |
|
Gets the height of the last encoded frame.
Declaration
public int FrameHeight { get; }
Property Value
| Type |
Description |
| System.Int32 |
|
Gets the number of encoded frames sent in the last second.
Declaration
public double FrameRate { get; }
Property Value
| Type |
Description |
| System.Double |
|
Gets the width of the last encoded frame.
Declaration
public int FrameWidth { get; }
Property Value
| Type |
Description |
| System.Int32 |
|
Declaration
public string MediaType { get; }
Property Value
| Type |
Description |
| System.String |
|
Gets if the media track is muted.
Declaration
public bool Muted { get; }
Property Value
| Type |
Description |
| System.Boolean |
|
Gets or sets the NACK count.
Declaration
public long NackCount { get; set; }
Property Value
| Type |
Description |
| System.Int64 |
|
Gets the total packets lost.
Declaration
public int PacketsLost { get; }
Property Value
| Type |
Description |
| System.Int32 |
|
Gets the percent of packets lost.
Declaration
public double PercentLost { get; }
Property Value
| Type |
Description |
| System.Double |
|
Gets or sets the PLI count.
Declaration
public long PliCount { get; set; }
Property Value
| Type |
Description |
| System.Int64 |
|
Gets the durations for which quality has been limited for bandwidth, cpu, none, other.
Declaration
public QualityLimitationDurations QualityLimitationDurations { get; }
Property Value
Gets the the reason for quality limitation.
Declaration
public string QualityLimitationReason { get; }
Property Value
| Type |
Description |
| System.String |
|
Gets the count of resolution changes due to quality limitation.
Declaration
public long QualityLimitationResolutionChanges { get; }
Property Value
| Type |
Description |
| System.Int64 |
|
Gets if the media track is stopped.
Declaration
public bool Stopped { get; }
Property Value
| Type |
Description |
| System.Boolean |
|
Gets the target bitrate of the encoder.
Declaration
public int TargetBitrate { get; }
Property Value
| Type |
Description |
| System.Int32 |
|
Gets the timestamp when these stats were generated.
Declaration
public DateTime Timestamp { get; }
Property Value
| Type |
Description |
| DateTime |
|
Methods
Create outbound audio stats.
Declaration
public static MediaStats CreateOutboundAudioStreamStats(MediaStreamStats audioStreamStats)
Parameters
Returns
Create outbound video stats.
Declaration
public static MediaStats CreateOutboundVideoStats(MediaStreamStats videoStreamStats)
Parameters
Returns
Derializes media stats from JSON.
Declaration
public static MediaStats FromJson(string mediaStatsJson)
Parameters
| Type |
Name |
Description |
| System.String |
mediaStatsJson |
The media stats JSON.
|
Returns
Declaration
Returns
| Type |
Description |
| System.String |
|
Serializes outbound video stats to JSON.
Declaration
public static string ToJson(MediaStats outboundVideoStats)
Parameters
| Type |
Name |
Description |
| MediaStats |
outboundVideoStats |
The outbound video stats.
|
Returns
| Type |
Description |
| System.String |
|