Chromium Code Reviews| Index: content/common/media/media_devices.mojom |
| diff --git a/content/common/media/media_devices.mojom b/content/common/media/media_devices.mojom |
| index 93e943225af7e7d8a2a85ef8b9881283805dd712..339c30aed8168d0f67c1474f59c4104de63d975d 100644 |
| --- a/content/common/media/media_devices.mojom |
| +++ b/content/common/media/media_devices.mojom |
| @@ -5,6 +5,7 @@ |
| module mojom; |
| import "media/capture/mojo/video_capture_types.mojom"; |
| +import "media/mojo/interfaces/audio_parameters.mojom"; |
| import "url/mojo/origin.mojom"; |
| [Native] |
| @@ -31,6 +32,11 @@ struct VideoInputDeviceCapabilities { |
| FacingMode facing_mode; |
| }; |
| +struct AudioInputDeviceCapabilities { |
| + string device_id; |
| + media.mojom.AudioParameters parameters; |
| +}; |
| + |
| // This object lives in the browser and is responsible for processing device |
| // enumeration requests and managing subscriptions for device-change |
| // notifications. |
| @@ -43,15 +49,26 @@ interface MediaDevicesDispatcherHost { |
| bool request_audio_output, |
| url.mojom.Origin security_origin) |
| => (array<array<MediaDeviceInfo>> enumeration); |
| - |
| + |
| // Returns a list of video devices and their capabilities. |
| // If there is a user-preferred device, it is the first in the result. |
| // The result of this function is intended for the implementation details |
| // of algorithms such as settings selection for getUserMedia. |
| - // Do not expose the data contained in result of this function to JavaScript. |
| + // Do not expose the data contained in the result of this function to |
| + // JavaScript. |
| GetVideoInputCapabilities(url.mojom.Origin security_origin) |
| => (array<VideoInputDeviceCapabilities> video_input_device_capabilities); |
| + // Returns a list of audio input devices and their capabilities. |
| + // If there is a user-preferred device, it is the first in the result. |
| + // Otherwise, the system-default device is the first in the result. |
| + // The result of this function is intended for the implementation details |
| + // of algorithms such as settings selection for getUserMedia. |
| + // Do not expose the data contained in the result of this function to |
| + // JavaScript. |
| + GetAudioInputCapabilities(url.mojom.Origin security_origin) |
|
Mike West
2017/05/09 09:30:37
Do you need to pass in an origin? Shouldn't the br
Guido Urdaneta
2017/05/09 09:43:33
This is how it was done in older IPC-based messagi
|
| + => (array<AudioInputDeviceCapabilities> audio_input_device_capabilities); |
| + |
| // Creates a subscription for device-change notifications for the calling |
| // frame/security origin. It is the responsibility of the caller to send |
| // |subscription_id| values that are unique per device type. |