Bug Fix: Peers Cannot Communicate If One With Stereo Codec, One Not
When Chromium hooks up with the stereo codec, then it has difficulty communicating with a google chrome without stereo codec. By design, we do allow codec choice for the standalone codecs, but the problem is that we do not handle the payload correctly, and thus the existence of stereo codec will remove the payload registry of the standalone version of its associated codec. (For example, stereo codec on top of VP9 will remove the payload registry of standalone VP9 codec.) This CL fixes the issue. When generating payload data, we should use "stereo" as payload name, instead of its associated codecs. Bug: webrtc:8657 Change-Id: I9e0b54de6bd41d370b9353f9553c998e4049789f Reviewed-on: https://webrtc-review.googlesource.com/33122 Reviewed-by: Emircan Uysaler <emircan@webrtc.org> Reviewed-by: Stefan Holmer <stefan@webrtc.org> Commit-Queue: Qiang Chen <qiangchen@chromium.org> Cr-Commit-Position: refs/heads/master@{#21523}
This commit is contained in:
@ -50,6 +50,8 @@ bool VideoCodecInitializer::SetupCodec(
|
||||
return false;
|
||||
}
|
||||
codec->codecType = kVideoCodecStereo;
|
||||
strncpy(codec->plName, settings.payload_name.c_str(),
|
||||
sizeof(codec->plName));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@ -65,6 +65,8 @@ VideoCodec CreateDecoderVideoCodec(const VideoReceiveStream::Decoder& decoder) {
|
||||
associated_decoder.payload_name = CodecTypeToPayloadString(kVideoCodecVP9);
|
||||
VideoCodec associated_codec = CreateDecoderVideoCodec(associated_decoder);
|
||||
associated_codec.codecType = kVideoCodecStereo;
|
||||
strncpy(associated_codec.plName, decoder.payload_name.c_str(),
|
||||
sizeof(associated_codec.plName));
|
||||
return associated_codec;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user