blob: 759c1834a5db7b5fb555ac3ad123c5ec5a9d546c [file] [log] [blame]
henrike@webrtc.org28e20752013-07-10 00:45:36 +00001/*
kjellander1afca732016-02-07 20:46:45 -08002 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
henrike@webrtc.org28e20752013-07-10 00:45:36 +00003 *
kjellander1afca732016-02-07 20:46:45 -08004 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
henrike@webrtc.org28e20752013-07-10 00:45:36 +00009 */
10
kjellanderf4752772016-03-02 05:42:30 -080011#include "webrtc/media/base/mediaconstants.h"
henrike@webrtc.org28e20752013-07-10 00:45:36 +000012
13#include <string>
14
15namespace cricket {
16
17const int kVideoCodecClockrate = 90000;
18const int kDataCodecClockrate = 90000;
19const int kDataMaxBandwidth = 30720; // bps
20
21const float kHighSystemCpuThreshold = 0.85f;
22const float kLowSystemCpuThreshold = 0.65f;
23const float kProcessCpuThreshold = 0.10f;
24
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000025const char kRtxCodecName[] = "rtx";
pbos@webrtc.orgb5a22b12014-05-13 11:07:01 +000026const char kRedCodecName[] = "red";
27const char kUlpfecCodecName[] = "ulpfec";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000028
brandtr87d7d772016-11-07 03:03:41 -080029// TODO(brandtr): Change this to 'flexfec' when we are confident that the
30// header format is not changing anymore.
31const char kFlexfecCodecName[] = "flexfec-03";
32
33// draft-ietf-payload-flexible-fec-scheme-02.txt
34const char kFlexfecFmtpRepairWindow[] = "repair-window";
35
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000036const char kCodecParamAssociatedPayloadType[] = "apt";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000037
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000038const char kOpusCodecName[] = "opus";
ossu66753c32017-04-27 01:47:13 -070039const char kIsacCodecName[] = "ISAC";
40const char kL16CodecName[] = "L16";
41const char kG722CodecName[] = "G722";
42const char kIlbcCodecName[] = "ILBC";
43const char kPcmuCodecName[] = "PCMU";
44const char kPcmaCodecName[] = "PCMA";
45const char kCnCodecName[] = "CN";
Brave Yao5225dd82015-03-26 07:39:19 +080046const char kDtmfCodecName[] = "telephone-event";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000047
henrike@webrtc.org1e09a712013-07-26 19:17:59 +000048// draft-spittka-payload-rtp-opus-03.txt
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000049const char kCodecParamPTime[] = "ptime";
50const char kCodecParamMaxPTime[] = "maxptime";
51const char kCodecParamMinPTime[] = "minptime";
52const char kCodecParamSPropStereo[] = "sprop-stereo";
53const char kCodecParamStereo[] = "stereo";
54const char kCodecParamUseInbandFec[] = "useinbandfec";
Minyue Li7100dcd2015-03-27 05:05:59 +010055const char kCodecParamUseDtx[] = "usedtx";
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000056const char kCodecParamMaxAverageBitrate[] = "maxaveragebitrate";
buildbot@webrtc.org5d639b32014-09-10 07:57:12 +000057const char kCodecParamMaxPlaybackRate[] = "maxplaybackrate";
henrike@webrtc.org1e09a712013-07-26 19:17:59 +000058
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000059const char kCodecParamSctpProtocol[] = "protocol";
60const char kCodecParamSctpStreams[] = "streams";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000061
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000062const char kParamValueTrue[] = "1";
63const char kParamValueEmpty[] = "";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000064
65const int kOpusDefaultMaxPTime = 120;
66const int kOpusDefaultPTime = 20;
67const int kOpusDefaultMinPTime = 3;
68const int kOpusDefaultSPropStereo = 0;
69const int kOpusDefaultStereo = 0;
70const int kOpusDefaultUseInbandFec = 0;
Minyue Li7100dcd2015-03-27 05:05:59 +010071const int kOpusDefaultUseDtx = 0;
buildbot@webrtc.org5d639b32014-09-10 07:57:12 +000072const int kOpusDefaultMaxPlaybackRate = 48000;
henrike@webrtc.org28e20752013-07-10 00:45:36 +000073
minyuelb031a2e2016-05-10 15:35:21 +020074const int kPreferredMaxPTime = 120;
henrike@webrtc.org28e20752013-07-10 00:45:36 +000075const int kPreferredMinPTime = 10;
76const int kPreferredSPropStereo = 0;
77const int kPreferredStereo = 0;
78const int kPreferredUseInbandFec = 0;
79
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000080const char kRtcpFbParamNack[] = "nack";
henrika@webrtc.orgaebb1ad2014-01-14 10:00:58 +000081const char kRtcpFbNackParamPli[] = "pli";
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000082const char kRtcpFbParamRemb[] = "goog-remb";
stefan43edf0f2015-11-20 18:05:48 -080083const char kRtcpFbParamTransportCc[] = "transport-cc";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000084
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000085const char kRtcpFbParamCcm[] = "ccm";
86const char kRtcpFbCcmParamFir[] = "fir";
87const char kCodecParamMaxBitrate[] = "x-google-max-bitrate";
88const char kCodecParamMinBitrate[] = "x-google-min-bitrate";
buildbot@webrtc.orged97bb02014-05-07 11:15:20 +000089const char kCodecParamStartBitrate[] = "x-google-start-bitrate";
sergeyu@chromium.org32f485b2013-12-05 22:36:21 +000090const char kCodecParamMaxQuantization[] = "x-google-max-quantization";
91const char kCodecParamPort[] = "x-google-port";
henrike@webrtc.org28e20752013-07-10 00:45:36 +000092
solenberg9fa49752016-10-08 13:02:44 -070093const int kGoogleRtpDataCodecPlType = 109;
henrike@webrtc.org28e20752013-07-10 00:45:36 +000094const char kGoogleRtpDataCodecName[] = "google-data";
95
solenberg9fa49752016-10-08 13:02:44 -070096const int kGoogleSctpDataCodecPlType = 108;
henrike@webrtc.org28e20752013-07-10 00:45:36 +000097const char kGoogleSctpDataCodecName[] = "google-sctp-data";
98
99const char kComfortNoiseCodecName[] = "CN";
100
Shao Changbine62202f2015-04-21 20:24:50 +0800101const char kVp8CodecName[] = "VP8";
102const char kVp9CodecName[] = "VP9";
Zeke Chin71f6f442015-06-29 14:34:58 -0700103const char kH264CodecName[] = "H264";
henrike@webrtc.org704bf9e2014-02-27 17:52:04 +0000104
htaa6b99442016-04-12 10:29:17 -0700105// RFC 6184 RTP Payload Format for H.264 video
106const char kH264FmtpProfileLevelId[] = "profile-level-id";
107const char kH264FmtpLevelAsymmetryAllowed[] = "level-asymmetry-allowed";
108const char kH264FmtpPacketizationMode[] = "packetization-mode";
magjed5dfac562016-11-25 03:56:37 -0800109const char kH264FmtpSpropParameterSets[] = "sprop-parameter-sets";
htaa6b99442016-04-12 10:29:17 -0700110const char kH264ProfileLevelConstrainedBaseline[] = "42e01f";
111
perkj26752742016-10-24 01:21:16 -0700112const int kDefaultVideoMaxFramerate = 60;
henrike@webrtc.org28e20752013-07-10 00:45:36 +0000113} // namespace cricket