public async Task RequestSdpAnswer(SdpAnswerRequestArgs args)
        {
            var  answer = _peer.GetSdpAnswer(args);
            bool useInsetableStreams = args.RemotePeerSupportsInsertableStreams;

            _peer.ExtractTimestampFromFrame = useInsetableStreams;

            await _connection.SendSdpAnswer(new SdpAnswerResponseArgs
            {
                ConnectionId         = _peer.ConnectionId,
                SdpAnswer            = answer.sdp,
                UseInsertableStreams = useInsetableStreams
            });
        }
示例#2
0
        public Task RequestSdpAnswer(SdpAnswerRequestArgs args)
        {
            connectionId = args.ConnectionId;

            webRtcClient.ReceiveOffer(args.ConnectionId, new SessionDescription(SessionDescription.SdpType.Offer, args.SdpOffer), (sdpAnswer, error) =>
            {
                virtualStudioConnection.SendSdpAnswer(new SdpAnswerResponseArgs
                {
                    ConnectionId         = args.ConnectionId,
                    SdpAnswer            = sdpAnswer.Description,
                    UseInsertableStreams = false
                });
            });
            return(Task.CompletedTask);
        }