Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 84 // From content/common/media/media_stream_options.cc | 84 // From content/common/media/media_stream_options.cc |
| 85 const char kMediaStreamSource[] = "chromeMediaSource"; | 85 const char kMediaStreamSource[] = "chromeMediaSource"; |
| 86 const char kMediaStreamSourceId[] = "chromeMediaSourceId"; // mapped to deviceId | 86 const char kMediaStreamSourceId[] = "chromeMediaSourceId"; // mapped to deviceId |
| 87 const char kMediaStreamSourceInfoId[] = "sourceId"; // mapped to deviceId | 87 const char kMediaStreamSourceInfoId[] = "sourceId"; // mapped to deviceId |
| 88 const char kMediaStreamRenderToAssociatedSink[] = "chromeRenderToAssociatedSink" ; | 88 const char kMediaStreamRenderToAssociatedSink[] = "chromeRenderToAssociatedSink" ; |
| 89 // RenderToAssociatedSink will be going away in M50-M60 some time. | 89 // RenderToAssociatedSink will be going away in M50-M60 some time. |
| 90 const char kMediaStreamAudioHotword[] = "googHotword"; | 90 const char kMediaStreamAudioHotword[] = "googHotword"; |
| 91 // TODO(hta): googHotword should go away. https://crbug.com/577627 | 91 // TODO(hta): googHotword should go away. https://crbug.com/577627 |
| 92 // From content/renderer/media/media_stream_audio_processor_options.cc | 92 // From content/renderer/media/media_stream_audio_processor_options.cc |
| 93 const char kEchoCancellation[] = "echoCancellation"; | 93 const char kEchoCancellation[] = "echoCancellation"; |
| 94 const char kGoogDisableLocalEcho[] = "googDisableLocalEcho"; | |
|
Mike West
2016/09/27 08:03:41
Is this web-exposed? That is, does a developer typ
qiangchen
2016/09/27 16:16:47
It is web exposed. But it is not an API function n
Avi (use Gerrit)
2016/09/27 16:20:34
Waaaaaait. I see lots of "googXXXX" constants in t
qiangchen
2016/09/27 16:32:49
Yes. You can search them on google, and you will f
| |
| 94 const char kGoogEchoCancellation[] = "googEchoCancellation"; | 95 const char kGoogEchoCancellation[] = "googEchoCancellation"; |
| 95 const char kGoogExperimentalEchoCancellation[] = "googEchoCancellation2"; | 96 const char kGoogExperimentalEchoCancellation[] = "googEchoCancellation2"; |
| 96 const char kGoogAutoGainControl[] = "googAutoGainControl"; | 97 const char kGoogAutoGainControl[] = "googAutoGainControl"; |
| 97 const char kGoogExperimentalAutoGainControl[] = "googAutoGainControl2"; | 98 const char kGoogExperimentalAutoGainControl[] = "googAutoGainControl2"; |
| 98 const char kGoogNoiseSuppression[] = "googNoiseSuppression"; | 99 const char kGoogNoiseSuppression[] = "googNoiseSuppression"; |
| 99 const char kGoogExperimentalNoiseSuppression[] = "googNoiseSuppression2"; | 100 const char kGoogExperimentalNoiseSuppression[] = "googNoiseSuppression2"; |
| 100 const char kGoogBeamforming[] = "googBeamforming"; | 101 const char kGoogBeamforming[] = "googBeamforming"; |
| 101 const char kGoogArrayGeometry[] = "googArrayGeometry"; | 102 const char kGoogArrayGeometry[] = "googArrayGeometry"; |
| 102 const char kGoogHighpassFilter[] = "googHighpassFilter"; | 103 const char kGoogHighpassFilter[] = "googHighpassFilter"; |
| 103 const char kGoogTypingNoiseDetection[] = "googTypingNoiseDetection"; | 104 const char kGoogTypingNoiseDetection[] = "googTypingNoiseDetection"; |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 287 result.frameRate.setMin(atof(constraint.m_value.utf8().c_str())); | 288 result.frameRate.setMin(atof(constraint.m_value.utf8().c_str())); |
| 288 } else if (constraint.m_name.equals(kMaxFrameRate)) { | 289 } else if (constraint.m_name.equals(kMaxFrameRate)) { |
| 289 result.frameRate.setMax(atof(constraint.m_value.utf8().c_str())); | 290 result.frameRate.setMax(atof(constraint.m_value.utf8().c_str())); |
| 290 } else if (constraint.m_name.equals(kEchoCancellation)) { | 291 } else if (constraint.m_name.equals(kEchoCancellation)) { |
| 291 result.echoCancellation.setExact(toBoolean(constraint.m_value)); | 292 result.echoCancellation.setExact(toBoolean(constraint.m_value)); |
| 292 } else if (constraint.m_name.equals(kMediaStreamSource)) { | 293 } else if (constraint.m_name.equals(kMediaStreamSource)) { |
| 293 // TODO(hta): This has only a few legal values. Should be | 294 // TODO(hta): This has only a few legal values. Should be |
| 294 // represented as an enum, and cause type errors. | 295 // represented as an enum, and cause type errors. |
| 295 // https://crbug.com/576582 | 296 // https://crbug.com/576582 |
| 296 result.mediaStreamSource.setExact(constraint.m_value); | 297 result.mediaStreamSource.setExact(constraint.m_value); |
| 298 } else if (constraint.m_name.equals(kGoogDisableLocalEcho)) { | |
| 299 result.googDisableLocalEcho.setExact(toBoolean(constraint.m_value)); | |
| 297 } else if (constraint.m_name.equals(kMediaStreamSourceId) | 300 } else if (constraint.m_name.equals(kMediaStreamSourceId) |
| 298 || constraint.m_name.equals(kMediaStreamSourceInfoId)) { | 301 || constraint.m_name.equals(kMediaStreamSourceInfoId)) { |
| 299 result.deviceId.setExact(constraint.m_value); | 302 result.deviceId.setExact(constraint.m_value); |
| 300 } else if (constraint.m_name.equals(kMediaStreamRenderToAssociatedSink)) { | 303 } else if (constraint.m_name.equals(kMediaStreamRenderToAssociatedSink)) { |
| 301 // TODO(hta): This is a boolean represented as string. | 304 // TODO(hta): This is a boolean represented as string. |
| 302 // Should give TypeError when it's not parseable. | 305 // Should give TypeError when it's not parseable. |
| 303 // https://crbug.com/576582 | 306 // https://crbug.com/576582 |
| 304 result.renderToAssociatedSink.setExact(toBoolean(constraint.m_value) ); | 307 result.renderToAssociatedSink.setExact(toBoolean(constraint.m_value) ); |
| 305 } else if (constraint.m_name.equals(kMediaStreamAudioHotword)) { | 308 } else if (constraint.m_name.equals(kMediaStreamAudioHotword)) { |
| 306 result.hotwordEnabled.setExact(toBoolean(constraint.m_value)); | 309 result.hotwordEnabled.setExact(toBoolean(constraint.m_value)); |
| (...skipping 458 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 765 MediaTrackConstraintSet element; | 768 MediaTrackConstraintSet element; |
| 766 convertConstraintSet(it, element); | 769 convertConstraintSet(it, element); |
| 767 advancedVector.append(element); | 770 advancedVector.append(element); |
| 768 } | 771 } |
| 769 if (!advancedVector.isEmpty()) | 772 if (!advancedVector.isEmpty()) |
| 770 output.setAdvanced(advancedVector); | 773 output.setAdvanced(advancedVector); |
| 771 } | 774 } |
| 772 | 775 |
| 773 } // namespace MediaConstraintsImpl | 776 } // namespace MediaConstraintsImpl |
| 774 } // namespace blink | 777 } // namespace blink |
| OLD | NEW |