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

Unified Diff: content/renderer/media/media_stream_constraints_util.h

Issue 227743004: Added a kEchoCancellation constraint to turn off the audio processing. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 6 years, 8 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
Index: content/renderer/media/media_stream_constraints_util.h
diff --git a/content/renderer/media/media_stream_constraints_util.h b/content/renderer/media/media_stream_constraints_util.h
new file mode 100644
index 0000000000000000000000000000000000000000..c3c08c74a645154e3f0109d986933cced35764c2
--- /dev/null
+++ b/content/renderer/media/media_stream_constraints_util.h
@@ -0,0 +1,45 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_RENDERER_MEDIA_MEDIA_STREAM_CONSTRAINTS_UTIL_H_
+#define CONTENT_RENDERER_MEDIA_MEDIA_STREAM_CONSTRAINTS_UTIL_H_
+
+#include <string>
+
+namespace blink {
+class WebMediaConstraints;
+class WebString;
+}
+
+namespace content {
+
+// Method to get boolean value of constraint with key |name| from constraints.
+// Returns true if the constraint is specified in either manatory or optinal
+// constraints.
+bool GetConstraintValue(const blink::WebMediaConstraints& constraints,
+ const std::string& name,
+ bool* value);
+
+// Method to get int value of constraint with key |name| from constraints.
+// Returns true if the constraint is specified in either manatory or optinal
+// constraints.
+bool GetConstraintValue(const blink::WebMediaConstraints& constraints,
+ const std::string& name,
+ int* value);
+
+// Method to get int value of constraint with key |name| from the
+// manatory constraints.
+bool GetManatoryConstraintValue(const blink::WebMediaConstraints& constraints,
tommi (sloooow) - chröme 2014/04/08 10:49:30 fix typo
no longer working on chromium 2014/04/11 08:56:30 Done.
+ const std::string& name,
+ int* value);
+
+// Method to get int value of constraint with key |name| from the
+// optional constraints.
+bool GetOptionalConstraintValue(const blink::WebMediaConstraints& constraints,
+ const std::string& name,
+ int* value);
+
+} // namespace content
+
+#endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_CONSTRAINTS_UTIL_H_

Powered by Google App Engine
This is Rietveld 408576698