Bug 1064882: Receive RTCP SR's on recvonly streams for A/V sync r=jesup

This commit is contained in:
Oscar Patino 2014-09-11 09:25:47 -04:00
parent 411a228105
commit 9cf140bc68
3 changed files with 14 additions and 24 deletions

View File

@ -762,21 +762,15 @@ WebrtcAudioConduit::ReceivedRTCPPacket(const void *data, int len)
{
CSFLogDebug(logTag, "%s : channel %d",__FUNCTION__, mChannel);
if(mEngineTransmitting)
if(mPtrVoENetwork->ReceivedRTCPPacket(mChannel, data, len) == -1)
{
if(mPtrVoENetwork->ReceivedRTCPPacket(mChannel, data, len) == -1)
int error = mPtrVoEBase->LastError();
CSFLogError(logTag, "%s RTCP Processing Error %d", __FUNCTION__, error);
if(error == VE_RTP_RTCP_MODULE_ERROR)
{
int error = mPtrVoEBase->LastError();
CSFLogError(logTag, "%s RTCP Processing Error %d", __FUNCTION__, error);
if(error == VE_RTP_RTCP_MODULE_ERROR)
{
return kMediaConduitRTPRTCPModuleError;
}
return kMediaConduitUnknownError;
return kMediaConduitRTPRTCPModuleError;
}
} else {
CSFLogError(logTag, "Error: %s when not receiving", __FUNCTION__);
return kMediaConduitSessionNotInited;
return kMediaConduitUnknownError;
}
return kMediaConduitNoError;
}

View File

@ -1138,21 +1138,15 @@ WebrtcVideoConduit::ReceivedRTCPPacket(const void *data, int len)
CSFLogDebug(logTag, " %s Channel %d, Len %d ", __FUNCTION__, mChannel, len);
//Media Engine should be receiving already
if(mEngineTransmitting)
if(mPtrViENetwork->ReceivedRTCPPacket(mChannel,data,len) == -1)
{
if(mPtrViENetwork->ReceivedRTCPPacket(mChannel,data,len) == -1)
int error = mPtrViEBase->LastError();
CSFLogError(logTag, "%s RTP Processing Failed %d", __FUNCTION__, error);
if(error >= kViERtpRtcpInvalidChannelId && error <= kViERtpRtcpRtcpDisabled)
{
int error = mPtrViEBase->LastError();
CSFLogError(logTag, "%s RTP Processing Failed %d", __FUNCTION__, error);
if(error >= kViERtpRtcpInvalidChannelId && error <= kViERtpRtcpRtcpDisabled)
{
return kMediaConduitRTPProcessingFailed;
}
return kMediaConduitRTPRTCPModuleError;
return kMediaConduitRTPProcessingFailed;
}
} else {
CSFLogError(logTag, "Error: %s when not receiving", __FUNCTION__);
return kMediaConduitSessionNotInited;
return kMediaConduitRTPRTCPModuleError;
}
return kMediaConduitNoError;
}

2
media/webrtc/trunk/webrtc/video_engine/vie_channel.cc Normal file → Executable file
View File

@ -1684,6 +1684,7 @@ int32_t ViEChannel::StartReceive() {
return -1;
}
vie_receiver_.StartReceive();
vie_receiver_.StartRTCPReceive(); // For receiving RTCP SR in one-way connections
return 0;
}
@ -1692,6 +1693,7 @@ int32_t ViEChannel::StopReceive() {
__FUNCTION__);
vie_receiver_.StopReceive();
vie_receiver_.StopRTCPReceive();
StopDecodeThread();
vcm_.ResetDecoder();
return 0;