OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 module media.interfaces; | 5 module media.mojom; |
6 | 6 |
7 import "media/mojo/interfaces/media_types.mojom"; | 7 import "media/mojo/interfaces/media_types.mojom"; |
8 | 8 |
9 interface AudioDecoder { | 9 interface AudioDecoder { |
10 // Status of a decode operation. See media::AudioDecoder for description. | 10 // Status of a decode operation. See media::AudioDecoder for description. |
11 enum DecodeStatus { | 11 enum DecodeStatus { |
12 OK, // We're all good. | 12 OK, // We're all good. |
13 ABORTED, // We aborted as a result of Reset() or destruction. | 13 ABORTED, // We aborted as a result of Reset() or destruction. |
14 DECODE_ERROR, // A decoding error occurred. | 14 DECODE_ERROR, // A decoding error occurred. |
15 }; | 15 }; |
(...skipping 21 matching lines...) Expand all Loading... |
37 // Resets decoder state. Should be called only if Initialize() succeeds. | 37 // Resets decoder state. Should be called only if Initialize() succeeds. |
38 // All pending Decode() requests will be finished or aborted, then the method | 38 // All pending Decode() requests will be finished or aborted, then the method |
39 // executes the callback. | 39 // executes the callback. |
40 Reset() => (); | 40 Reset() => (); |
41 }; | 41 }; |
42 | 42 |
43 interface AudioDecoderClient { | 43 interface AudioDecoderClient { |
44 // Sends the decoded audio buffer back to the proxy. | 44 // Sends the decoded audio buffer back to the proxy. |
45 OnBufferDecoded(AudioBuffer buffer); | 45 OnBufferDecoded(AudioBuffer buffer); |
46 }; | 46 }; |
OLD | NEW |