Exemple #1
0
        internal static MediaStatsEvent FromNative(
            ADLMediaStatsEvent mediaStatsEvnt)
        {
            MediaStatsEvent result = new MediaStatsEvent();

            result._scopeId      = mediaStatsEvnt.scopeId.body;
            result._mediaType    = MediaType.FromString(mediaStatsEvnt.mediaType.body);
            result._remoteUserId = mediaStatsEvnt.remoteUserId;
            result._stats        = new MediaStats(mediaStatsEvnt.stats);
            return(result);
        }
Exemple #2
0
 private void on_media_stats_callback_t(IntPtr opaque,
                                        ref ADLMediaStatsEvent e)
 {
     try
     {
         Console.Error.WriteLine("Media stats: " + e.stats.bitRate);
         if (_listener != null)
         {
             _listener.onMediaStats(
                 MediaStatsEvent.FromNative(e));
         }
     }
     catch (Exception)
     {
     }
 }
 private void on_media_stats_callback_t(IntPtr opaque,
     ref ADLMediaStatsEvent e)
 {
     try
     {
         Console.Error.WriteLine("Media stats: " + e.stats.bitRate);
         if (_listener != null)
             _listener.onMediaStats(
                 MediaStatsEvent.FromNative(e));
     }
     catch (Exception )
     {
     }
 }
 internal static MediaStatsEvent FromNative(
     ADLMediaStatsEvent mediaStatsEvnt)
 {
     MediaStatsEvent result = new MediaStatsEvent();
     result._scopeId = mediaStatsEvnt.scopeId.body;
     result._mediaType = MediaType.FromString(mediaStatsEvnt.mediaType.body);
     result._remoteUserId = mediaStatsEvnt.remoteUserId;
     result._stats = new MediaStats(mediaStatsEvnt.stats);
     return result;
 }