OLD | NEW |
1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 /* Copyright (c) 2012 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 | 5 |
6 /* From private/ppp_content_decryptor_private.idl, | 6 /* From private/ppp_content_decryptor_private.idl, |
7 * modified Tue Aug 14 11:06:05 2012. | 7 * modified Wed Aug 15 19:53:16 2012. |
8 */ | 8 */ |
9 | 9 |
10 #ifndef PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_ | 10 #ifndef PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_ |
11 #define PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_ | 11 #define PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_ |
12 | 12 |
13 #include "ppapi/c/pp_bool.h" | 13 #include "ppapi/c/pp_bool.h" |
14 #include "ppapi/c/pp_instance.h" | 14 #include "ppapi/c/pp_instance.h" |
15 #include "ppapi/c/pp_macros.h" | 15 #include "ppapi/c/pp_macros.h" |
16 #include "ppapi/c/pp_resource.h" | 16 #include "ppapi/c/pp_resource.h" |
17 #include "ppapi/c/pp_stdint.h" | 17 #include "ppapi/c/pp_stdint.h" |
18 #include "ppapi/c/pp_var.h" | 18 #include "ppapi/c/pp_var.h" |
| 19 #include "ppapi/c/private/pp_decrypt_config.h" |
19 | 20 |
20 #define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1 \ | 21 #define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1 \ |
21 "PPP_ContentDecryptor_Private;0.1" | 22 "PPP_ContentDecryptor_Private;0.1" |
22 #define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE \ | 23 #define PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE \ |
23 PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1 | 24 PPP_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1 |
24 | 25 |
25 /** | 26 /** |
26 * @file | 27 * @file |
27 * This file defines the <code>PPP_ContentDecryptor_Private</code> | 28 * This file defines the <code>PPP_ContentDecryptor_Private</code> |
28 * interface. Note: This is a special interface, only to be used for Content | 29 * interface. Note: This is a special interface, only to be used for Content |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 /** | 94 /** |
94 * Decrypts the block and returns the unencrypted block via | 95 * Decrypts the block and returns the unencrypted block via |
95 * <code>DeliverBlock()</code> on the | 96 * <code>DeliverBlock()</code> on the |
96 * <code>PPB_ContentDecryptor_Private</code> interface. The returned block | 97 * <code>PPB_ContentDecryptor_Private</code> interface. The returned block |
97 * contains encoded data. | 98 * contains encoded data. |
98 * | 99 * |
99 * @param[in] resource A <code>PP_Resource</code> corresponding to a | 100 * @param[in] resource A <code>PP_Resource</code> corresponding to a |
100 * <code>PPB_Buffer_Dev</code> resource that contains an encrypted data | 101 * <code>PPB_Buffer_Dev</code> resource that contains an encrypted data |
101 * block. | 102 * block. |
102 * | 103 * |
103 * @param[in] request_id A value used by the browser to associate data | 104 * @param[in] decrypt_config A <code>PP_DecryptConfig</code> that contains |
104 * returned via the <code>PPB_ContentDecryptor_Private</code> interface with | 105 * all auxiliary information needed for decryption of the |
105 * decryption method calls. | 106 * <code>encrypted_block</code>. |
106 */ | 107 */ |
107 PP_Bool (*Decrypt)(PP_Instance instance, | 108 PP_Bool (*Decrypt)(PP_Instance instance, |
108 PP_Resource encrypted_block, | 109 PP_Resource encrypted_block, |
109 int32_t request_id); | 110 const struct PP_DecryptConfig* decrypt_config); |
110 /** | 111 /** |
111 * Decrypts the block, decodes it, and returns the unencrypted uncompressed | 112 * Decrypts the block, decodes it, and returns the unencrypted uncompressed |
112 * (decoded) media to the browser via the | 113 * (decoded) media to the browser via the |
113 * <code>PPB_ContentDecryptor_Private</code> interface. | 114 * <code>PPB_ContentDecryptor_Private</code> interface. |
114 * | 115 * |
115 * Decrypted and decoded video frames are sent to <code>DeliverFrame()</code>, | 116 * Decrypted and decoded video frames are sent to <code>DeliverFrame()</code>, |
116 * and decrypted and decoded audio samples are sent to | 117 * and decrypted and decoded audio samples are sent to |
117 * <code>DeliverSamples()</code>. | 118 * <code>DeliverSamples()</code>. |
118 * | 119 * |
119 * @param[in] resource A <code>PP_Resource</code> corresponding to a | 120 * @param[in] resource A <code>PP_Resource</code> corresponding to a |
120 * <code>PPB_Buffer_Dev</code> resource that contains an encrypted data | 121 * <code>PPB_Buffer_Dev</code> resource that contains an encrypted data |
121 * block. | 122 * block. |
122 * | 123 * |
123 * @param[in] request_id A value used by the browser to associate data | 124 * @param[in] decrypt_config A <code>PP_DecryptConfig</code> that contains |
124 * returned via the <code>PPB_ContentDecryptor_Private</code> interface with | 125 * all auxiliary information needed for decryption of the |
125 * decryption method calls. | 126 * <code>encrypted_block</code>. |
126 */ | 127 */ |
127 PP_Bool (*DecryptAndDecode)(PP_Instance instance, | 128 PP_Bool (*DecryptAndDecode)(PP_Instance instance, |
128 PP_Resource encrypted_block, | 129 PP_Resource encrypted_block, |
129 int32_t request_id); | 130 const struct PP_DecryptConfig* decrypt_config); |
130 }; | 131 }; |
131 | 132 |
132 typedef struct PPP_ContentDecryptor_Private_0_1 PPP_ContentDecryptor_Private; | 133 typedef struct PPP_ContentDecryptor_Private_0_1 PPP_ContentDecryptor_Private; |
133 /** | 134 /** |
134 * @} | 135 * @} |
135 */ | 136 */ |
136 | 137 |
137 #endif /* PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_ */ | 138 #endif /* PPAPI_C_PRIVATE_PPP_CONTENT_DECRYPTOR_PRIVATE_H_ */ |
138 | 139 |
OLD | NEW |