stopAudioStream function

void stopAudioStream(
  1. MediaStream stream
)

Implementation

void stopAudioStream(MediaStream stream) {
  print('STOP AUDIO');
  List<MediaStreamTrack> audTracks = stream.getAudioTracks();
  for (var track in audTracks) {
    track.enabled = false;
  }
}