summaryrefslogtreecommitdiffstats
path: root/ppapi
diff options
context:
space:
mode:
authortomfinegan@chromium.org <tomfinegan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-10-03 22:53:48 +0000
committertomfinegan@chromium.org <tomfinegan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-10-03 22:53:48 +0000
commit181d9c16af3887741c245400041a4c3796eca8b4 (patch)
tree0ab79d414a4dfc0a02da1a2ac05cd70779f0cdbd /ppapi
parentbe83c65d3b440b53c9dce0105f4f72f4df5a2a64 (diff)
downloadchromium_src-181d9c16af3887741c245400041a4c3796eca8b4.zip
chromium_src-181d9c16af3887741c245400041a4c3796eca8b4.tar.gz
chromium_src-181d9c16af3887741c245400041a4c3796eca8b4.tar.bz2
Update PPB side of Pepper CDM API to support video decoding.
This adds the PPB half of the video decoding support changes. BUG=141780 TEST= Review URL: https://chromiumcodereview.appspot.com/10989069 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@159999 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi')
-rw-r--r--ppapi/api/private/pp_content_decryptor.idl78
-rw-r--r--ppapi/api/private/ppb_content_decryptor_private.idl12
-rw-r--r--ppapi/c/private/pp_content_decryptor.h90
-rw-r--r--ppapi/c/private/ppb_content_decryptor_private.h22
-rw-r--r--ppapi/cpp/private/content_decryptor_private.cc4
-rw-r--r--ppapi/cpp/private/content_decryptor_private.h2
-rw-r--r--ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c38
-rw-r--r--ppapi/proxy/content_decryptor_private_serializer.h5
-rw-r--r--ppapi/proxy/ppb_instance_proxy.cc12
-rw-r--r--ppapi/proxy/ppb_instance_proxy.h3
-rw-r--r--ppapi/thunk/interfaces_ppb_private.h4
-rw-r--r--ppapi/thunk/ppb_content_decryptor_private_thunk.cc6
-rw-r--r--ppapi/thunk/ppb_instance_api.h3
13 files changed, 211 insertions, 68 deletions
diff --git a/ppapi/api/private/pp_content_decryptor.idl b/ppapi/api/private/pp_content_decryptor.idl
index 14d9c1c..8fb33a5 100644
--- a/ppapi/api/private/pp_content_decryptor.idl
+++ b/ppapi/api/private/pp_content_decryptor.idl
@@ -130,24 +130,90 @@ enum PP_DecryptResult {
};
/**
- * The <code>PP_DecryptedBlockInfo</code> struct contains the tracking info and
- * the decryption (and/or decoding) result associated with the decrypted block.
+ * <code>PP_DecryptedBlockInfo</code> struct contains the decryption result and
+ * tracking info associated with the decrypted block.
*/
[assert_size(24)]
struct PP_DecryptedBlockInfo {
/**
+ * Result of the decryption (and/or decoding) operation.
+ */
+ PP_DecryptResult result;
+
+ /**
+ * 4-byte padding to make the size of <code>PP_DecryptedBlockInfo</code>
+ * a multiple of 8 bytes and make sure |tracking_info| starts on an 8-byte
+ * boundary. The value of this field should not be used.
+ */
+ uint32_t padding;
+
+ /**
* Information needed by the client to track the block to be decrypted.
*/
PP_DecryptTrackingInfo tracking_info;
+};
+
+/**
+ * <code>PP_DecryptedFrameFormat</code> contains video frame formats.
+ */
+[assert_size(4)]
+enum PP_DecryptedFrameFormat {
+ PP_DECRYPTEDFRAMEFORMAT_UNKNOWN = 0,
+ PP_DECRYPTEDFRAMEFORMAT_EMPTY = 1,
+ PP_DECRYPTEDFRAMEFORMAT_YV12 = 2,
+ PP_DECRYPTEDFRAMEFORMAT_I420 = 3
+};
+
+/**
+ * <code>PP_DecryptedFramePlanes</code> provides YUV plane index values for
+ * accessing plane offsets stored in <code>PP_DecryptedFrameInfo</code>.
+ */
+[assert_size(4)]
+enum PP_DecryptedFramePlanes {
+ PP_DECRYPTEDFRAMEPLANES_Y = 0,
+ PP_DECRYPTEDFRAMEPLANES_U = 1,
+ PP_DECRYPTEDFRAMEPLANES_V = 2
+};
+/**
+ * <code>PP_DecryptedFrameInfo</code> contains the result of the
+ * decrypt and decode operation on the associated frame, information required
+ * to access the frame data in buffer, and tracking info.
+ */
+[assert_size(56)]
+struct PP_DecryptedFrameInfo {
/**
- * Result of the decryption (and/or decoding) operation.
+ * Result of the decrypt and decode operation.
*/
PP_DecryptResult result;
/**
- * 4-byte padding to make the size of <code>PP_DecryptedBlockInfo</code>
- * a multiple of 8 bytes. The value of this field should not be used.
+ * Format of the decrypted frame.
*/
- uint32_t padding;
+ PP_DecryptedFrameFormat format;
+
+ /**
+ * Offsets into the buffer resource for accessing video planes.
+ */
+ int32_t[3] plane_offsets;
+
+ /**
+ * Stride of each plane.
+ */
+ int32_t[3] strides;
+
+ /**
+ * Width of the video frame, in pixels.
+ */
+ int32_t width;
+
+ /**
+ * Height of the video frame, in pixels.
+ */
+ int32_t height;
+
+ /**
+ * Information needed by the client to track the decrypted frame.
+ */
+ PP_DecryptTrackingInfo tracking_info;
};
diff --git a/ppapi/api/private/ppb_content_decryptor_private.idl b/ppapi/api/private/ppb_content_decryptor_private.idl
index a07a045..d73cae1 100644
--- a/ppapi/api/private/ppb_content_decryptor_private.idl
+++ b/ppapi/api/private/ppb_content_decryptor_private.idl
@@ -9,7 +9,7 @@
* Decryption Modules, not normal plugins.
*/
label Chrome {
- M23 = 0.1
+ M23 = 0.2
};
/**
@@ -137,7 +137,7 @@ interface PPB_ContentDecryptor_Private {
* block.
*
* @param[in] decrypted_block_info A <code>PP_DecryptedBlockInfo</code> that
- * contains the tracking info and result code associated with the
+ * contains the result code and tracking info associated with the
* <code>decrypted_block</code>.
*/
void DeliverBlock(
@@ -153,14 +153,14 @@ interface PPB_ContentDecryptor_Private {
* @param[in] decrypted_frame A <code>PP_Resource</code> corresponding to a
* <code>PPB_Buffer_Dev</code> resource that contains a video frame.
*
- * @param[in] decrypted_block_info A <code>PP_DecryptedBlockInfo</code> that
- * contains the tracking info and result code associated with the
- * <code>decrypted_block</code>.
+ * @param[in] decrypted_frame_info A <code>PP_DecryptedFrameInfo</code> that
+ * contains the result code, tracking info, and buffer format associated with
+ * <code>decrypted_frame</code>.
*/
void DeliverFrame(
[in] PP_Instance instance,
[in] PP_Resource decrypted_frame,
- [in] PP_DecryptedBlockInfo decrypted_block_info);
+ [in] PP_DecryptedFrameInfo decrypted_frame_info);
/**
* Called after the <code>DecryptAndDecode()</code> method on the
diff --git a/ppapi/c/private/pp_content_decryptor.h b/ppapi/c/private/pp_content_decryptor.h
index fba09da..6d0d81b 100644
--- a/ppapi/c/private/pp_content_decryptor.h
+++ b/ppapi/c/private/pp_content_decryptor.h
@@ -3,7 +3,7 @@
* found in the LICENSE file.
*/
-/* From private/pp_content_decryptor.idl modified Mon Sep 17 09:50:39 2012. */
+/* From private/pp_content_decryptor.idl modified Wed Oct 3 12:52:47 2012. */
#ifndef PPAPI_C_PRIVATE_PP_CONTENT_DECRYPTOR_H_
#define PPAPI_C_PRIVATE_PP_CONTENT_DECRYPTOR_H_
@@ -152,28 +152,102 @@ PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_DecryptResult, 4);
* @{
*/
/**
- * The <code>PP_DecryptedBlockInfo</code> struct contains the tracking info and
- * the decryption (and/or decoding) result associated with the decrypted block.
+ * <code>PP_DecryptedBlockInfo</code> struct contains the decryption result and
+ * tracking info associated with the decrypted block.
*/
struct PP_DecryptedBlockInfo {
/**
- * Information needed by the client to track the block to be decrypted.
- */
- struct PP_DecryptTrackingInfo tracking_info;
- /**
* Result of the decryption (and/or decoding) operation.
*/
PP_DecryptResult result;
/**
* 4-byte padding to make the size of <code>PP_DecryptedBlockInfo</code>
- * a multiple of 8 bytes. The value of this field should not be used.
+ * a multiple of 8 bytes and make sure |tracking_info| starts on an 8-byte
+ * boundary. The value of this field should not be used.
*/
uint32_t padding;
+ /**
+ * Information needed by the client to track the block to be decrypted.
+ */
+ struct PP_DecryptTrackingInfo tracking_info;
};
PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_DecryptedBlockInfo, 24);
/**
* @}
*/
+/**
+ * @addtogroup Enums
+ * @{
+ */
+/**
+ * <code>PP_DecryptedFrameFormat</code> contains video frame formats.
+ */
+typedef enum {
+ PP_DECRYPTEDFRAMEFORMAT_UNKNOWN = 0,
+ PP_DECRYPTEDFRAMEFORMAT_EMPTY = 1,
+ PP_DECRYPTEDFRAMEFORMAT_YV12 = 2,
+ PP_DECRYPTEDFRAMEFORMAT_I420 = 3
+} PP_DecryptedFrameFormat;
+PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_DecryptedFrameFormat, 4);
+
+/**
+ * <code>PP_DecryptedFramePlanes</code> provides YUV plane index values for
+ * accessing plane offsets stored in <code>PP_DecryptedFrameInfo</code>.
+ */
+typedef enum {
+ PP_DECRYPTEDFRAMEPLANES_Y = 0,
+ PP_DECRYPTEDFRAMEPLANES_U = 1,
+ PP_DECRYPTEDFRAMEPLANES_V = 2
+} PP_DecryptedFramePlanes;
+PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_DecryptedFramePlanes, 4);
+/**
+ * @}
+ */
+
+/**
+ * @addtogroup Structs
+ * @{
+ */
+/**
+ * <code>PP_DecryptedFrameInfo</code> contains the result of the
+ * decrypt and decode operation on the associated frame, information required
+ * to access the frame data in buffer, and tracking info.
+ */
+struct PP_DecryptedFrameInfo {
+ /**
+ * Result of the decrypt and decode operation.
+ */
+ PP_DecryptResult result;
+ /**
+ * Format of the decrypted frame.
+ */
+ PP_DecryptedFrameFormat format;
+ /**
+ * Offsets into the buffer resource for accessing video planes.
+ */
+ int32_t plane_offsets[3];
+ /**
+ * Stride of each plane.
+ */
+ int32_t strides[3];
+ /**
+ * Width of the video frame, in pixels.
+ */
+ int32_t width;
+ /**
+ * Height of the video frame, in pixels.
+ */
+ int32_t height;
+ /**
+ * Information needed by the client to track the decrypted frame.
+ */
+ struct PP_DecryptTrackingInfo tracking_info;
+};
+PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_DecryptedFrameInfo, 56);
+/**
+ * @}
+ */
+
#endif /* PPAPI_C_PRIVATE_PP_CONTENT_DECRYPTOR_H_ */
diff --git a/ppapi/c/private/ppb_content_decryptor_private.h b/ppapi/c/private/ppb_content_decryptor_private.h
index 0e9aead..070ee05 100644
--- a/ppapi/c/private/ppb_content_decryptor_private.h
+++ b/ppapi/c/private/ppb_content_decryptor_private.h
@@ -4,7 +4,7 @@
*/
/* From private/ppb_content_decryptor_private.idl,
- * modified Thu Aug 16 20:19:22 2012.
+ * modified Mon Oct 01 20:33:45 2012.
*/
#ifndef PPAPI_C_PRIVATE_PPB_CONTENT_DECRYPTOR_PRIVATE_H_
@@ -18,10 +18,10 @@
#include "ppapi/c/pp_var.h"
#include "ppapi/c/private/pp_content_decryptor.h"
-#define PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1 \
- "PPB_ContentDecryptor_Private;0.1"
+#define PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_2 \
+ "PPB_ContentDecryptor_Private;0.2"
#define PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE \
- PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1
+ PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_2
/**
* @file
@@ -42,7 +42,7 @@
* browser side support for the Content Decryption Module (CDM) for v0.1 of the
* proposed Encrypted Media Extensions: http://goo.gl/rbdnR
*/
-struct PPB_ContentDecryptor_Private_0_1 {
+struct PPB_ContentDecryptor_Private_0_2 {
/**
* The decryptor requires a key that has not been provided.
*
@@ -152,7 +152,7 @@ struct PPB_ContentDecryptor_Private_0_1 {
* block.
*
* @param[in] decrypted_block_info A <code>PP_DecryptedBlockInfo</code> that
- * contains the tracking info and result code associated with the
+ * contains the result code and tracking info associated with the
* <code>decrypted_block</code>.
*/
void (*DeliverBlock)(
@@ -167,14 +167,14 @@ struct PPB_ContentDecryptor_Private_0_1 {
* @param[in] decrypted_frame A <code>PP_Resource</code> corresponding to a
* <code>PPB_Buffer_Dev</code> resource that contains a video frame.
*
- * @param[in] decrypted_block_info A <code>PP_DecryptedBlockInfo</code> that
- * contains the tracking info and result code associated with the
- * <code>decrypted_block</code>.
+ * @param[in] decrypted_frame_info A <code>PP_DecryptedFrameInfo</code> that
+ * contains the result code, tracking info, and buffer format associated with
+ * <code>decrypted_frame</code>.
*/
void (*DeliverFrame)(
PP_Instance instance,
PP_Resource decrypted_frame,
- const struct PP_DecryptedBlockInfo* decrypted_block_info);
+ const struct PP_DecryptedFrameInfo* decrypted_frame_info);
/**
* Called after the <code>DecryptAndDecode()</code> method on the
* <code>PPP_ContentDecryptor_Private</code> interface completes to
@@ -195,7 +195,7 @@ struct PPB_ContentDecryptor_Private_0_1 {
const struct PP_DecryptedBlockInfo* decrypted_block_info);
};
-typedef struct PPB_ContentDecryptor_Private_0_1 PPB_ContentDecryptor_Private;
+typedef struct PPB_ContentDecryptor_Private_0_2 PPB_ContentDecryptor_Private;
/**
* @}
*/
diff --git a/ppapi/cpp/private/content_decryptor_private.cc b/ppapi/cpp/private/content_decryptor_private.cc
index 1be92a8..585f1fb 100644
--- a/ppapi/cpp/private/content_decryptor_private.cc
+++ b/ppapi/cpp/private/content_decryptor_private.cc
@@ -221,12 +221,12 @@ void ContentDecryptor_Private::DeliverBlock(
void ContentDecryptor_Private::DeliverFrame(
pp::Buffer_Dev decrypted_frame,
- const PP_DecryptedBlockInfo& decrypted_block_info) {
+ const PP_DecryptedFrameInfo& decrypted_frame_info) {
if (has_interface<PPB_ContentDecryptor_Private>()) {
get_interface<PPB_ContentDecryptor_Private>()->DeliverFrame(
associated_instance_.pp_instance(),
decrypted_frame.pp_resource(),
- &decrypted_block_info);
+ &decrypted_frame_info);
}
}
diff --git a/ppapi/cpp/private/content_decryptor_private.h b/ppapi/cpp/private/content_decryptor_private.h
index ec7c044..3a88876 100644
--- a/ppapi/cpp/private/content_decryptor_private.h
+++ b/ppapi/cpp/private/content_decryptor_private.h
@@ -58,7 +58,7 @@ class ContentDecryptor_Private {
void DeliverBlock(pp::Buffer_Dev decrypted_block,
const PP_DecryptedBlockInfo& decrypted_block_info);
void DeliverFrame(pp::Buffer_Dev decrypted_frame,
- const PP_DecryptedBlockInfo& decrypted_block_info);
+ const PP_DecryptedFrameInfo& decrypted_frame_info);
void DeliverSamples(pp::Buffer_Dev decrypted_samples,
const PP_DecryptedBlockInfo& decrypted_block_info);
diff --git a/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c b/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c
index 2d38115..b870c48 100644
--- a/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c
+++ b/ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c
@@ -3,7 +3,7 @@
* found in the LICENSE file.
*/
-/* Last generated from IDL: Tue Oct 2 11:33:39 2012. */
+/* Last generated from IDL: Wed Oct 3 12:53:07 2012. */
#include "ppapi/generators/pnacl_shim.h"
#include "ppapi/c/ppb.h"
@@ -199,7 +199,7 @@ static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_VideoDecoder_Dev_0_10;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_VideoDecoder_Dev_0_11;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_Widget_Dev_0_2;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_Zoom_Dev_0_3;
-static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1;
+static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_FileRefPrivate_0_1;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_Flash_12_0;
static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_Flash_12_1;
@@ -1946,51 +1946,51 @@ void Pnacl_M14_PPB_VideoDecoder_Dev_Destroy(PP_Resource video_decoder) {
/* Not generating wrapper methods for PPP_Zoom_Dev_0_3 */
-/* Begin wrapper methods for PPB_ContentDecryptor_Private_0_1 */
+/* Begin wrapper methods for PPB_ContentDecryptor_Private_0_2 */
static __attribute__((pnaclcall))
void Pnacl_M23_PPB_ContentDecryptor_Private_NeedKey(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id, struct PP_Var init_data) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
iface->NeedKey(instance, key_system, session_id, init_data);
}
static __attribute__((pnaclcall))
void Pnacl_M23_PPB_ContentDecryptor_Private_KeyAdded(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
iface->KeyAdded(instance, key_system, session_id);
}
static __attribute__((pnaclcall))
void Pnacl_M23_PPB_ContentDecryptor_Private_KeyMessage(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id, PP_Resource message, struct PP_Var default_url) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
iface->KeyMessage(instance, key_system, session_id, message, default_url);
}
static __attribute__((pnaclcall))
void Pnacl_M23_PPB_ContentDecryptor_Private_KeyError(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id, int32_t media_error, int32_t system_code) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
iface->KeyError(instance, key_system, session_id, media_error, system_code);
}
static __attribute__((pnaclcall))
void Pnacl_M23_PPB_ContentDecryptor_Private_DeliverBlock(PP_Instance instance, PP_Resource decrypted_block, const struct PP_DecryptedBlockInfo* decrypted_block_info) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
iface->DeliverBlock(instance, decrypted_block, decrypted_block_info);
}
static __attribute__((pnaclcall))
-void Pnacl_M23_PPB_ContentDecryptor_Private_DeliverFrame(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedBlockInfo* decrypted_block_info) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
- iface->DeliverFrame(instance, decrypted_frame, decrypted_block_info);
+void Pnacl_M23_PPB_ContentDecryptor_Private_DeliverFrame(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedFrameInfo* decrypted_frame_info) {
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
+ iface->DeliverFrame(instance, decrypted_frame, decrypted_frame_info);
}
static __attribute__((pnaclcall))
void Pnacl_M23_PPB_ContentDecryptor_Private_DeliverSamples(PP_Instance instance, PP_Resource decrypted_samples, const struct PP_DecryptedBlockInfo* decrypted_block_info) {
- const struct PPB_ContentDecryptor_Private_0_1 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1.real_iface;
+ const struct PPB_ContentDecryptor_Private_0_2 *iface = Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2.real_iface;
iface->DeliverSamples(instance, decrypted_samples, decrypted_block_info);
}
-/* End wrapper methods for PPB_ContentDecryptor_Private_0_1 */
+/* End wrapper methods for PPB_ContentDecryptor_Private_0_2 */
/* Begin wrapper methods for PPB_FileRefPrivate_0_1 */
@@ -3807,13 +3807,13 @@ struct PPB_VideoDecoder_Dev_0_16 Pnacl_Wrappers_PPB_VideoDecoder_Dev_0_16 = {
/* Not generating wrapper interface for PPP_Zoom_Dev_0_3 */
-struct PPB_ContentDecryptor_Private_0_1 Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_1 = {
+struct PPB_ContentDecryptor_Private_0_2 Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_2 = {
.NeedKey = (void (*)(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id, struct PP_Var init_data))&Pnacl_M23_PPB_ContentDecryptor_Private_NeedKey,
.KeyAdded = (void (*)(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id))&Pnacl_M23_PPB_ContentDecryptor_Private_KeyAdded,
.KeyMessage = (void (*)(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id, PP_Resource message, struct PP_Var default_url))&Pnacl_M23_PPB_ContentDecryptor_Private_KeyMessage,
.KeyError = (void (*)(PP_Instance instance, struct PP_Var key_system, struct PP_Var session_id, int32_t media_error, int32_t system_code))&Pnacl_M23_PPB_ContentDecryptor_Private_KeyError,
.DeliverBlock = (void (*)(PP_Instance instance, PP_Resource decrypted_block, const struct PP_DecryptedBlockInfo* decrypted_block_info))&Pnacl_M23_PPB_ContentDecryptor_Private_DeliverBlock,
- .DeliverFrame = (void (*)(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedBlockInfo* decrypted_block_info))&Pnacl_M23_PPB_ContentDecryptor_Private_DeliverFrame,
+ .DeliverFrame = (void (*)(PP_Instance instance, PP_Resource decrypted_frame, const struct PP_DecryptedFrameInfo* decrypted_frame_info))&Pnacl_M23_PPB_ContentDecryptor_Private_DeliverFrame,
.DeliverSamples = (void (*)(PP_Instance instance, PP_Resource decrypted_samples, const struct PP_DecryptedBlockInfo* decrypted_block_info))&Pnacl_M23_PPB_ContentDecryptor_Private_DeliverSamples
};
@@ -4656,9 +4656,9 @@ static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPP_Zoom_Dev_0_3 = {
.real_iface = NULL
};
-static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1 = {
- .iface_macro = PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1,
- .wrapped_iface = (void *) &Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_1,
+static struct __PnaclWrapperInfo Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2 = {
+ .iface_macro = PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_2,
+ .wrapped_iface = (void *) &Pnacl_Wrappers_PPB_ContentDecryptor_Private_0_2,
.real_iface = NULL
};
@@ -4943,7 +4943,7 @@ static struct __PnaclWrapperInfo *s_ppb_wrappers[] = {
&Pnacl_WrapperInfo_PPB_Widget_Dev_0_3,
&Pnacl_WrapperInfo_PPB_Widget_Dev_0_4,
&Pnacl_WrapperInfo_PPB_Zoom_Dev_0_2,
- &Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_1,
+ &Pnacl_WrapperInfo_PPB_ContentDecryptor_Private_0_2,
&Pnacl_WrapperInfo_PPB_FileRefPrivate_0_1,
&Pnacl_WrapperInfo_PPB_Flash_12_0,
&Pnacl_WrapperInfo_PPB_Flash_12_1,
diff --git a/ppapi/proxy/content_decryptor_private_serializer.h b/ppapi/proxy/content_decryptor_private_serializer.h
index e8d7213..249b01c 100644
--- a/ppapi/proxy/content_decryptor_private_serializer.h
+++ b/ppapi/proxy/content_decryptor_private_serializer.h
@@ -14,8 +14,9 @@ namespace ppapi {
namespace proxy {
// Serialization/deserialization utility functions for storing/extracting
-// PP_{De|En}cryptedBlockInfo structs within std::string's for passing through
-// IPC. Both functions return true upon success, and false upon failure.
+// PP_DecryptedBlockInfo, PP_EncryptedBlockInfo, and PP_DecompressedFrameInfo
+// structs within std::string's for passing through IPC. Both functions return
+// true upon success, and false upon failure.
//
// Note, these functions check the size of |block_info| against the size of
// the "serialized" data stored within |serialized_block_info|, and will report
diff --git a/ppapi/proxy/ppb_instance_proxy.cc b/ppapi/proxy/ppb_instance_proxy.cc
index 8ea3702..5f0c163 100644
--- a/ppapi/proxy/ppb_instance_proxy.cc
+++ b/ppapi/proxy/ppb_instance_proxy.cc
@@ -510,14 +510,14 @@ void PPB_Instance_Proxy::DeliverBlock(PP_Instance instance,
void PPB_Instance_Proxy::DeliverFrame(PP_Instance instance,
PP_Resource decrypted_frame,
- const PP_DecryptedBlockInfo* block_info) {
+ const PP_DecryptedFrameInfo* frame_info) {
Resource* object =
PpapiGlobals::Get()->GetResourceTracker()->GetResource(decrypted_frame);
if (!object || object->pp_instance() != instance)
return;
std::string serialized_block_info;
- if (!SerializeBlockInfo(*block_info, &serialized_block_info))
+ if (!SerializeBlockInfo(*frame_info, &serialized_block_info))
return;
dispatcher()->Send(new PpapiHostMsg_PPBInstance_DeliverFrame(
@@ -931,14 +931,14 @@ void PPB_Instance_Proxy::OnHostMsgDeliverBlock(
void PPB_Instance_Proxy::OnHostMsgDeliverFrame(
PP_Instance instance,
PP_Resource decrypted_frame,
- const std::string& serialized_block_info) {
- PP_DecryptedBlockInfo block_info;
- if (!DeserializeBlockInfo(serialized_block_info, &block_info))
+ const std::string& serialized_frame_info) {
+ PP_DecryptedFrameInfo frame_info;
+ if (!DeserializeBlockInfo(serialized_frame_info, &frame_info))
return;
EnterInstanceNoLock enter(instance);
if (enter.succeeded())
- enter.functions()->DeliverFrame(instance, decrypted_frame, &block_info);
+ enter.functions()->DeliverFrame(instance, decrypted_frame, &frame_info);
}
void PPB_Instance_Proxy::OnHostMsgDeliverSamples(
diff --git a/ppapi/proxy/ppb_instance_proxy.h b/ppapi/proxy/ppb_instance_proxy.h
index 9a21185..61155b6d 100644
--- a/ppapi/proxy/ppb_instance_proxy.h
+++ b/ppapi/proxy/ppb_instance_proxy.h
@@ -24,6 +24,7 @@
#endif
struct PP_DecryptedBlockInfo;
+struct PP_DecryptedFrameInfo;
namespace ppapi {
namespace proxy {
@@ -137,7 +138,7 @@ class PPB_Instance_Proxy : public InterfaceProxy,
const PP_DecryptedBlockInfo* block_info) OVERRIDE;
virtual void DeliverFrame(PP_Instance instance,
PP_Resource decrypted_frame,
- const PP_DecryptedBlockInfo* block_info) OVERRIDE;
+ const PP_DecryptedFrameInfo* frame_info) OVERRIDE;
virtual void DeliverSamples(PP_Instance instance,
PP_Resource decrypted_samples,
const PP_DecryptedBlockInfo* block_info) OVERRIDE;
diff --git a/ppapi/thunk/interfaces_ppb_private.h b/ppapi/thunk/interfaces_ppb_private.h
index 6c3efc2..ce64356 100644
--- a/ppapi/thunk/interfaces_ppb_private.h
+++ b/ppapi/thunk/interfaces_ppb_private.h
@@ -22,8 +22,8 @@ PROXIED_IFACE(PPB_Broker, PPB_BROKER_TRUSTED_INTERFACE_0_2,
PROXIED_IFACE(PPB_Instance, PPB_BROWSERFONT_TRUSTED_INTERFACE_1_0,
PPB_BrowserFont_Trusted_1_0)
PROXIED_IFACE(PPB_Instance,
- PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_1,
- PPB_ContentDecryptor_Private_0_1)
+ PPB_CONTENTDECRYPTOR_PRIVATE_INTERFACE_0_2,
+ PPB_ContentDecryptor_Private_0_2)
PROXIED_IFACE(PPB_Instance, PPB_CHARSET_TRUSTED_INTERFACE_1_0,
PPB_CharSet_Trusted_1_0)
PROXIED_IFACE(NoAPIName, PPB_FILECHOOSER_TRUSTED_INTERFACE_0_5,
diff --git a/ppapi/thunk/ppb_content_decryptor_private_thunk.cc b/ppapi/thunk/ppb_content_decryptor_private_thunk.cc
index 77760f3..3f57a38 100644
--- a/ppapi/thunk/ppb_content_decryptor_private_thunk.cc
+++ b/ppapi/thunk/ppb_content_decryptor_private_thunk.cc
@@ -63,10 +63,10 @@ void DeliverBlock(PP_Instance instance,
void DeliverFrame(PP_Instance instance,
PP_Resource decrypted_frame,
- const PP_DecryptedBlockInfo* block_info) {
+ const PP_DecryptedFrameInfo* frame_info) {
EnterInstance enter(instance);
if (enter.succeeded())
- enter.functions()->DeliverFrame(instance, decrypted_frame, block_info);
+ enter.functions()->DeliverFrame(instance, decrypted_frame, frame_info);
}
void DeliverSamples(PP_Instance instance,
@@ -90,7 +90,7 @@ const PPB_ContentDecryptor_Private g_ppb_decryption_thunk = {
} // namespace
const PPB_ContentDecryptor_Private*
- GetPPB_ContentDecryptor_Private_0_1_Thunk() {
+ GetPPB_ContentDecryptor_Private_0_2_Thunk() {
return &g_ppb_decryption_thunk;
}
diff --git a/ppapi/thunk/ppb_instance_api.h b/ppapi/thunk/ppb_instance_api.h
index 94640e8..b919e31 100644
--- a/ppapi/thunk/ppb_instance_api.h
+++ b/ppapi/thunk/ppb_instance_api.h
@@ -27,6 +27,7 @@
#endif
struct PP_DecryptedBlockInfo;
+struct PP_DecryptedFrameInfo;
namespace ppapi {
@@ -158,7 +159,7 @@ class PPB_Instance_API {
const PP_DecryptedBlockInfo* block_info) = 0;
virtual void DeliverFrame(PP_Instance instance,
PP_Resource decrypted_frame,
- const PP_DecryptedBlockInfo* block_info) = 0;
+ const PP_DecryptedFrameInfo* frame_info) = 0;
virtual void DeliverSamples(PP_Instance instance,
PP_Resource decrypted_samples,
const PP_DecryptedBlockInfo* block_info) = 0;