Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1034)

Unified Diff: webrtc/media/base/codec.cc

Issue 2990463002: [EXPERIMENTAL] Generic stereo codec with index header sending merged frames
Patch Set: Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/media/base/codec.h ('k') | webrtc/media/base/mediaconstants.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/media/base/codec.cc
diff --git a/webrtc/media/base/codec.cc b/webrtc/media/base/codec.cc
index a94940227bd0967677e82d03258a0a241d38ec6e..bbf33e025cad511d9024ad2c567171c2911c84ab 100644
--- a/webrtc/media/base/codec.cc
+++ b/webrtc/media/base/codec.cc
@@ -263,6 +263,19 @@ VideoCodec VideoCodec::CreateRtxCodec(int rtx_payload_type,
return rtx_codec;
}
+// static
+VideoCodec VideoCodec::CreateStereoCodec(int stereo_payload_type,
+ const VideoCodec& codec) {
+ VideoCodec stereo_codec(stereo_payload_type, kStereoCodecName);
+ stereo_codec.SetParam(kCodecParamAssociatedPayloadType, codec.id);
+ return stereo_codec;
+}
+
+// static
+bool VideoCodec::IsStereoCodec(const VideoCodec& codec) {
+ return CodecNamesEq(codec.name.c_str(), kStereoCodecName);
+}
+
VideoCodec::CodecType VideoCodec::GetCodecType() const {
const char* payload_name = name.c_str();
if (_stricmp(payload_name, kRedCodecName) == 0) {
« no previous file with comments | « webrtc/media/base/codec.h ('k') | webrtc/media/base/mediaconstants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698