public void UnmuteAudioIn() { System.Diagnostics.Debug.WriteLine("audio unmuted"); RTCMediaStream localStream = _peerConnection.LocalStreams[0]; localStream.AddAudioTrack(defaultAudioTrack); _peerConnection.RemoveStream(localStream); _peerConnection.AddStream(localStream); if (_isSpeakerEnabled) { EnableSpeaker(); } }
RTCMediaStream CreateLocalMediaStream() { RTCMediaStream localStream = _factory.MediaStreamWithLabel("ARDAMS"); RTCVideoTrack localVideoTrack = CreateLocalVideoTrack(); if (localVideoTrack != null) { localStream.AddVideoTrack(localVideoTrack); ARDAppClientDelegate.DidReceiveLocalVideoTrack(this, localVideoTrack); // [_delegate appClient:self didReceiveLocalVideoTrack:localVideoTrack]; } localStream.AddAudioTrack(_factory.AudioTrackWithID("ARDAMSa0")); if (_isSpeakerEnabled) { EnableSpeaker(); } return(localStream); }
public void AddTrack(IAudioTrack audioTrack) { _mediaStream.AddAudioTrack(audioTrack.ToNative <RTCAudioTrack>()); }