Set correct codec info before sending frame to VCM.
Review URL: http://webrtc-codereview.appspot.com/240003 git-svn-id: http://webrtc.googlecode.com/svn/trunk@780 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
81f25f9ff8
commit
ae499a2ac8
@ -549,23 +549,22 @@ void ViEEncoder::DeliverFrame(int id, webrtc::VideoFrame& videoFrame,
|
||||
if (_vcm.SendCodec() == webrtc::kVideoCodecVP8)
|
||||
{
|
||||
webrtc::CodecSpecificInfo codecSpecificInfo;
|
||||
codecSpecificInfo.codecType = webrtc::kVideoCodecUnknown;
|
||||
codecSpecificInfo.codecType = webrtc::kVideoCodecVP8;
|
||||
if (_hasReceivedSLI || _hasReceivedRPSI)
|
||||
{
|
||||
webrtc::VideoCodec currentSendCodec;
|
||||
_vcm.SendCodec(¤tSendCodec);
|
||||
if (currentSendCodec.codecType == webrtc::kVideoCodecVP8)
|
||||
{
|
||||
codecSpecificInfo.codecType = webrtc::kVideoCodecVP8;
|
||||
codecSpecificInfo.codecSpecific.VP8.hasReceivedRPSI = _hasReceivedRPSI;
|
||||
codecSpecificInfo.codecSpecific.VP8.hasReceivedSLI = _hasReceivedSLI;
|
||||
codecSpecificInfo.codecSpecific.VP8.pictureIdRPSI = _pictureIdRPSI;
|
||||
codecSpecificInfo.codecSpecific.VP8.pictureIdSLI = _pictureIdSLI;
|
||||
{
|
||||
codecSpecificInfo.codecSpecific.VP8.hasReceivedRPSI =
|
||||
_hasReceivedRPSI;
|
||||
codecSpecificInfo.codecSpecific.VP8.hasReceivedSLI =
|
||||
_hasReceivedSLI;
|
||||
codecSpecificInfo.codecSpecific.VP8.pictureIdRPSI =
|
||||
_pictureIdRPSI;
|
||||
codecSpecificInfo.codecSpecific.VP8.pictureIdSLI =
|
||||
_pictureIdSLI;
|
||||
}
|
||||
_hasReceivedSLI = false;
|
||||
_hasReceivedRPSI = false;
|
||||
_hasReceivedSLI = false;
|
||||
_hasReceivedRPSI = false;
|
||||
}
|
||||
// Pass frame via preprocessor
|
||||
VideoFrame *decimatedFrame = NULL;
|
||||
const int ret = _vpm.PreprocessFrame(&videoFrame, &decimatedFrame);
|
||||
if (ret == 1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user