Delete unused media constraints

Bug: webrtc:9239
Change-Id: I3a0a6b3f8d08bcc589e4f6490731fbe1598d0463
Reviewed-on: https://webrtc-review.googlesource.com/c/121820
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26611}
diff --git a/api/media_constraints_interface.cc b/api/media_constraints_interface.cc
index ddf5559..e16fc19 100644
--- a/api/media_constraints_interface.cc
+++ b/api/media_constraints_interface.cc
@@ -80,18 +80,8 @@
 const char MediaConstraintsInterface::kValueFalse[] = "false";
 
 // Constraints declared as static members in mediastreaminterface.h
-// Specified by draft-alvestrand-constraints-resolution-00b
-const char MediaConstraintsInterface::kMinAspectRatio[] = "minAspectRatio";
-const char MediaConstraintsInterface::kMaxAspectRatio[] = "maxAspectRatio";
-const char MediaConstraintsInterface::kMaxWidth[] = "maxWidth";
-const char MediaConstraintsInterface::kMinWidth[] = "minWidth";
-const char MediaConstraintsInterface::kMaxHeight[] = "maxHeight";
-const char MediaConstraintsInterface::kMinHeight[] = "minHeight";
-const char MediaConstraintsInterface::kMaxFrameRate[] = "maxFrameRate";
-const char MediaConstraintsInterface::kMinFrameRate[] = "minFrameRate";
 
 // Audio constraints.
-const char MediaConstraintsInterface::kEchoCancellation[] = "echoCancellation";
 const char MediaConstraintsInterface::kGoogEchoCancellation[] =
     "googEchoCancellation";
 const char MediaConstraintsInterface::kExtendedFilterEchoCancellation[] =
@@ -113,9 +103,6 @@
 const char MediaConstraintsInterface::kAudioNetworkAdaptorConfig[] =
     "googAudioNetworkAdaptorConfig";
 
-// Google-specific constraint keys for a local video source (getUserMedia).
-const char MediaConstraintsInterface::kNoiseReduction[] = "googNoiseReduction";
-
 // Constraint keys for CreateOffer / CreateAnswer defined in W3C specification.
 const char MediaConstraintsInterface::kOfferToReceiveAudio[] =
     "OfferToReceiveAudio";
@@ -144,7 +131,6 @@
 // TODO(ronghuawu): Remove once cpu overuse detection is stable.
 const char MediaConstraintsInterface::kCpuOveruseDetection[] =
     "googCpuOveruseDetection";
-const char MediaConstraintsInterface::kPayloadPadding[] = "googPayloadPadding";
 
 const char MediaConstraintsInterface::kNumSimulcastLayers[] =
     "googNumSimulcastLayers";
diff --git a/api/media_constraints_interface.h b/api/media_constraints_interface.h
index fc49cbe..adfa2b5 100644
--- a/api/media_constraints_interface.h
+++ b/api/media_constraints_interface.h
@@ -51,19 +51,7 @@
     bool FindFirst(const std::string& key, std::string* value) const;
   };
 
-  // Constraint keys used by a local video source.
-  // Specified by draft-alvestrand-constraints-resolution-00b
-  static const char kMinAspectRatio[];  // minAspectRatio
-  static const char kMaxAspectRatio[];  // maxAspectRatio
-  static const char kMaxWidth[];        // maxWidth
-  static const char kMinWidth[];        // minWidth
-  static const char kMaxHeight[];       // maxHeight
-  static const char kMinHeight[];       // minHeight
-  static const char kMaxFrameRate[];    // maxFrameRate
-  static const char kMinFrameRate[];    // minFrameRate
-
   // Constraint keys used by a local audio source.
-  static const char kEchoCancellation[];  // echoCancellation
 
   // These keys are google specific.
   static const char kGoogEchoCancellation[];  // googEchoCancellation
@@ -80,9 +68,6 @@
   static const char
       kAudioNetworkAdaptorConfig[];  // goodAudioNetworkAdaptorConfig
 
-  // Google-specific constraint keys for a local video source
-  static const char kNoiseReduction[];  // googNoiseReduction
-
   // Constraint keys for CreateOffer / CreateAnswer
   // Specified by the W3C PeerConnection spec
   static const char kOfferToReceiveVideo[];     // OfferToReceiveVideo
@@ -113,11 +98,6 @@
   static const char kCombinedAudioVideoBwe[];  // googCombinedAudioVideoBwe
   static const char kScreencastMinBitrate[];   // googScreencastMinBitrate
   static const char kCpuOveruseDetection[];    // googCpuOveruseDetection
-  static const char kPayloadPadding[];         // googPayloadPadding
-
-  // The prefix of internal-only constraints whose JS set values should be
-  // stripped by Chrome before passed down to Libjingle.
-  static const char kInternalConstraintPrefix[];
 
   // Specifies number of simulcast layers for all video tracks
   // with a Plan B offer/answer
diff --git a/api/test/fake_constraints.h b/api/test/fake_constraints.h
index e2b26d1..7080fb2 100644
--- a/api/test/fake_constraints.h
+++ b/api/test/fake_constraints.h
@@ -53,26 +53,6 @@
     optional_.push_back(Constraint(key, rtc::ToString(value)));
   }
 
-  void SetMandatoryMinAspectRatio(double ratio) {
-    SetMandatory(MediaConstraintsInterface::kMinAspectRatio, ratio);
-  }
-
-  void SetMandatoryMinWidth(int width) {
-    SetMandatory(MediaConstraintsInterface::kMinWidth, width);
-  }
-
-  void SetMandatoryMinHeight(int height) {
-    SetMandatory(MediaConstraintsInterface::kMinHeight, height);
-  }
-
-  void SetOptionalMaxWidth(int width) {
-    AddOptional(MediaConstraintsInterface::kMaxWidth, width);
-  }
-
-  void SetMandatoryMaxFrameRate(int frame_rate) {
-    SetMandatory(MediaConstraintsInterface::kMaxFrameRate, frame_rate);
-  }
-
   void SetMandatoryReceiveAudio(bool enable) {
     SetMandatory(MediaConstraintsInterface::kOfferToReceiveAudio, enable);
   }
diff --git a/sdk/objc/api/peerconnection/RTCMediaConstraints.h b/sdk/objc/api/peerconnection/RTCMediaConstraints.h
index eb12a59..5c1a12e 100644
--- a/sdk/objc/api/peerconnection/RTCMediaConstraints.h
+++ b/sdk/objc/api/peerconnection/RTCMediaConstraints.h
@@ -15,14 +15,6 @@
 NS_ASSUME_NONNULL_BEGIN
 
 /** Constraint keys for media sources. */
-RTC_EXTERN NSString *const kRTCMediaConstraintsMinAspectRatio;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMaxAspectRatio;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMaxWidth;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMinWidth;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMaxHeight;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMinHeight;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMaxFrameRate;
-RTC_EXTERN NSString *const kRTCMediaConstraintsMinFrameRate;
 /** The value for this key should be a base64 encoded string containing
  *  the data from the serialized configuration proto.
  */
diff --git a/sdk/objc/api/peerconnection/RTCMediaConstraints.mm b/sdk/objc/api/peerconnection/RTCMediaConstraints.mm
index a45486f..0a6b9d8 100644
--- a/sdk/objc/api/peerconnection/RTCMediaConstraints.mm
+++ b/sdk/objc/api/peerconnection/RTCMediaConstraints.mm
@@ -14,22 +14,6 @@
 
 #include <memory>
 
-NSString * const kRTCMediaConstraintsMinAspectRatio =
-    @(webrtc::MediaConstraintsInterface::kMinAspectRatio);
-NSString * const kRTCMediaConstraintsMaxAspectRatio =
-    @(webrtc::MediaConstraintsInterface::kMaxAspectRatio);
-NSString * const kRTCMediaConstraintsMinWidth =
-    @(webrtc::MediaConstraintsInterface::kMinWidth);
-NSString * const kRTCMediaConstraintsMaxWidth =
-    @(webrtc::MediaConstraintsInterface::kMaxWidth);
-NSString * const kRTCMediaConstraintsMinHeight =
-    @(webrtc::MediaConstraintsInterface::kMinHeight);
-NSString * const kRTCMediaConstraintsMaxHeight =
-    @(webrtc::MediaConstraintsInterface::kMaxHeight);
-NSString * const kRTCMediaConstraintsMinFrameRate =
-    @(webrtc::MediaConstraintsInterface::kMinFrameRate);
-NSString * const kRTCMediaConstraintsMaxFrameRate =
-    @(webrtc::MediaConstraintsInterface::kMaxFrameRate);
 NSString * const kRTCMediaConstraintsAudioNetworkAdaptorConfig =
     @(webrtc::MediaConstraintsInterface::kAudioNetworkAdaptorConfig);