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

Side by Side Diff: media/mojo/interfaces/decryptor.mojom

Issue 1468153003: Define AudioBuffer and VideoFrame for mojo (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: switch statement Created 5 years 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 unified diff | Download patch
« no previous file with comments | « media/base/sample_format.cc ('k') | media/mojo/interfaces/media_types.mojom » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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.interfaces;
6 6
7 import "media/mojo/interfaces/demuxer_stream.mojom"; 7 import "media/mojo/interfaces/demuxer_stream.mojom";
8 import "media/mojo/interfaces/media_types.mojom"; 8 import "media/mojo/interfaces/media_types.mojom";
9 9
10 // TODO(xhwang): Add mojo types for AudioBuffer and VideoFrame.
11 struct AudioBuffer {};
12 struct VideoFrame {};
13
14 // Interface for decrypting (and decoding) encrypted streams. 10 // Interface for decrypting (and decoding) encrypted streams.
15 // See media/base/decryptor.h for details. 11 // See media/base/decryptor.h for details.
16 interface Decryptor { 12 interface Decryptor {
17 // Status of a decrypt or decrypt-and-decode operation. The returned 13 // Status of a decrypt or decrypt-and-decode operation. The returned
18 // buffer/frame of such an operation is NOT null iff the status is SUCCESS. 14 // buffer/frame of such an operation is NOT null iff the status is SUCCESS.
19 enum Status { 15 enum Status {
20 SUCCESS, // Successfully completed. Decrypted buffer ready. 16 SUCCESS, // Successfully completed. Decrypted buffer ready.
21 NO_KEY, // No key is available to decrypt. 17 NO_KEY, // No key is available to decrypt.
22 NEED_MORE_DATA, // Decoder needs more data to produce an output. 18 NEED_MORE_DATA, // Decoder needs more data to produce an output.
23 ERROR // Key is available but an error occurred during decryption. 19 ERROR // Key is available but an error occurred during decryption.
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 // After this operation, the decoder is set to an uninitialized state. 60 // After this operation, the decoder is set to an uninitialized state.
65 // The decoder can be reinitialized after it is deinitialized. 61 // The decoder can be reinitialized after it is deinitialized.
66 DeinitializeDecoder(DemuxerStream.Type stream_type); 62 DeinitializeDecoder(DemuxerStream.Type stream_type);
67 }; 63 };
68 64
69 interface DecryptorClient { 65 interface DecryptorClient {
70 // Indicates that a new usable key is available in the CDM associated with the 66 // Indicates that a new usable key is available in the CDM associated with the
71 // Decryptor. 67 // Decryptor.
72 OnNewUsableKey(); 68 OnNewUsableKey();
73 }; 69 };
OLDNEW
« no previous file with comments | « media/base/sample_format.cc ('k') | media/mojo/interfaces/media_types.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698