| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // The <code>chrome.webrtcAudioPrivate</code> API allows enumeration | 5 // The <code>chrome.webrtcAudioPrivate</code> API allows enumeration |
| 6 // of audio output (sink) devices as well as getting and setting the | 6 // of audio output (sink) devices as well as getting and setting the |
| 7 // active device for a given requesting process. | 7 // active device for a given requesting process. |
| 8 // | 8 // |
| 9 // Note that device IDs as used in this API are opaque (i.e. they are | 9 // Note that device IDs as used in this API are opaque (i.e. they are |
| 10 // not the hardware identifier of the device) and while they are | 10 // not the hardware identifier of the device) and while they are |
| 11 // unique and persistent across sessions, they are valid only to the | 11 // unique and persistent across sessions, they are valid only to the |
| 12 // extension calling this API (i.e. they cannot be shared between | 12 // extension calling this API (i.e. they cannot be shared between |
| 13 // extensions). | 13 // extensions). |
| 14 // | 14 // |
| 15 // See http://goo.gl/8rOmgk for further documentation of this API. | 15 // See http://goo.gl/8rOmgk for further documentation of this API. |
| 16 | 16 |
| 17 namespace webrtcAudioPrivate { | 17 [use_movable_types=true] namespace webrtcAudioPrivate { |
| 18 | 18 |
| 19 dictionary SinkInfo { | 19 dictionary SinkInfo { |
| 20 // The opaque identifier of the audio sink device, which is unique | 20 // The opaque identifier of the audio sink device, which is unique |
| 21 // and static for the extension calling the API but invalid for | 21 // and static for the extension calling the API but invalid for |
| 22 // others. | 22 // others. |
| 23 DOMString sinkId; | 23 DOMString sinkId; |
| 24 // The user-friendly name (e.g. "Bose Amplifier"). | 24 // The user-friendly name (e.g. "Bose Amplifier"). |
| 25 DOMString sinkLabel; | 25 DOMString sinkLabel; |
| 26 // Current sample rate of the device, in Hz. Useful e.g. to know | 26 // Current sample rate of the device, in Hz. Useful e.g. to know |
| 27 // if the remote side should be asked to send a lower sampling | 27 // if the remote side should be asked to send a lower sampling |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 static void getAssociatedSink(DOMString securityOrigin, | 75 static void getAssociatedSink(DOMString securityOrigin, |
| 76 DOMString sourceIdInOrigin, | 76 DOMString sourceIdInOrigin, |
| 77 SinkIdCallback cb); | 77 SinkIdCallback cb); |
| 78 }; | 78 }; |
| 79 | 79 |
| 80 interface Events { | 80 interface Events { |
| 81 // Fired when audio sink devices are added or removed. | 81 // Fired when audio sink devices are added or removed. |
| 82 static void onSinksChanged(); | 82 static void onSinksChanged(); |
| 83 }; | 83 }; |
| 84 }; | 84 }; |
| OLD | NEW |