onVideoTrackAddQuality method

  1. @override
void onVideoTrackAddQuality(
  1. int videoTrackUid,
  2. String qualityId,
  3. int qualityUid,
  4. String? name,
  5. int bandwidth,
  6. String? codecs,
  7. int width,
  8. int height,
  9. double frameRate,
  10. double firstFrame,
)
override

Implementation

@override
void onVideoTrackAddQuality(int videoTrackUid, String qualityId, int qualityUid, String? name, int bandwidth, String? codecs, int width, int height, double frameRate, double firstFrame) {
  VideoTrack? videoTrack = _videoTracks.firstWhereOrNull((item) => item.uid == videoTrackUid);
  if (videoTrack == null) {
    return;
  }

  VideoQualityImpl videoQuality = VideoQualityImpl(qualityId, qualityUid, name, bandwidth, codecs, width, height, frameRate, firstFrame);
  videoTrack.qualities.add(videoQuality);
}