| Index: ppapi/c/dev/ppb_content_decryptor_dev.h
|
| diff --git a/ppapi/c/dev/ppb_content_decryptor_dev.h b/ppapi/c/dev/ppb_content_decryptor_dev.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..2e7a82e305979d12f8a94affc5b25491d134b550
|
| --- /dev/null
|
| +++ b/ppapi/c/dev/ppb_content_decryptor_dev.h
|
| @@ -0,0 +1,115 @@
|
| +/* Copyright (c) 2012 The Chromium Authors. All rights reserved.
|
| + * Use of this source code is governed by a BSD-style license that can be
|
| + * found in the LICENSE file.
|
| + */
|
| +
|
| +/* From dev/ppb_content_decryptor_dev.idl modified Mon Jul 16 17:58:07 2012. */
|
| +
|
| +#ifndef PPAPI_C_DEV_PPB_CONTENT_DECRYPTOR_DEV_H_
|
| +#define PPAPI_C_DEV_PPB_CONTENT_DECRYPTOR_DEV_H_
|
| +
|
| +#include "ppapi/c/pp_bool.h"
|
| +#include "ppapi/c/pp_completion_callback.h"
|
| +#include "ppapi/c/pp_instance.h"
|
| +#include "ppapi/c/pp_macros.h"
|
| +#include "ppapi/c/pp_resource.h"
|
| +#include "ppapi/c/pp_stdint.h"
|
| +#include "ppapi/c/pp_var.h"
|
| +
|
| +#define PPB_CONTENTDECRYPTOR_DEV_INTERFACE_0_1 "PPB_ContentDecryptor(Dev);0.1"
|
| +#define PPB_CONTENTDECRYPTOR_DEV_INTERFACE \
|
| + PPB_CONTENTDECRYPTOR_DEV_INTERFACE_0_1
|
| +
|
| +/**
|
| + * @file
|
| + * This file defines the <code>PPP_ContentDecryptor_Dev</code>
|
| + * interface.
|
| + */
|
| +
|
| +/**
|
| + * @addtogroup Interfaces
|
| + * @{
|
| + */
|
| +
|
| +/**
|
| + * <code>PPB_ContentDecryptor_Dev</code> structure contains the function
|
| + * pointers the browser may implement to support plugins implementing the
|
| + * <code>PPP_ContentDecryptor_Dev</code> interface.
|
| + */
|
| +struct PPB_ContentDecryptor_Dev_0_1 {
|
| + /**
|
| + * A key or license is needed to decrypt media data.
|
| + */
|
| + void (*NeedKey)(PP_Instance instance,
|
| + struct PP_Var key_system, /* String. */
|
| + struct PP_Var session_id, /* String. */
|
| + PP_Resource init_data); /* PPB_Buffer. */
|
| +
|
| + /**
|
| + * A key has been added as the result of a call to the <code>AddKey()</code>
|
| + * method on the <code>PPP_ContentDecryptor_Dev</code> interface.
|
| + */
|
| + void (*KeyAdded)(PP_Instance instance,
|
| + struct PP_Var key_system, /* String. */
|
| + struct PP_Var session_id); /* String. */
|
| +
|
| + /**
|
| + * A message or request has been generated by or for key_system. For example,
|
| + * a key request has been generated as the result of call to the
|
| + * <code>GenerateKeyRequest()</code> method on the
|
| + * <code>PPP_ContentDecryptor_Dev</code> interface or another message
|
| + * must be sent in response to an <code>AddKey()</code> call. Note that
|
| + * <code>KeyMessage</code> can be used for purposes other than results to
|
| + * <code>AddKey()</code> calls.
|
| + */
|
| + void (*KeyMessage)(PP_Instance instance,
|
| + struct PP_Var key_system, /* String. */
|
| + struct PP_Var session_id, /* String. */
|
| + PP_Resource message, /* PPB_Buffer. */
|
| + struct PP_Var default_url); /* String. */
|
| +
|
| + /**
|
| + * An error occured in a <code>PPP_ContentDecryptor_Dev</code> method,
|
| + * or within the plugin implementing the interface.
|
| + */
|
| + void (*KeyError)(PP_Instance instance,
|
| + struct PP_Var key_system, /* String. */
|
| + struct PP_Var session_id, /* String. */
|
| + uint16_t media_error,
|
| + uint16_t system_error);
|
| +
|
| + /**
|
| + * Called after the <code>Decrypt</code> method on the
|
| + * <code>PPP_ContentDecryptor_Dev</code> interface completes to
|
| + * deliver decrypted_block to the media stack.
|
| + */
|
| + void (*DeliverBlock)(PP_Instance instance,
|
| + PP_Resource decrypted_block, /* PPB_Buffer. */
|
| + struct PP_CompletionCallback callback);
|
| +
|
| + /**
|
| + * Called after the <code>DecryptAndDecode</code> method on the
|
| + * <code>PPP_ContentDecryptor_Dev</code> interface completes to
|
| + * deliver decrypted_frame to the media stack.
|
| + */
|
| + void (*DeliverFrame)(PP_Instance instance,
|
| + PP_Resource decrypted_frame, /* PPB_Buffer. */
|
| + struct PP_CompletionCallback callback);
|
| +
|
| + /**
|
| + * Called after the <code>DecryptAndDecode</code> method on the
|
| + * <code>PPP_ContentDecryptor_Dev</code> interface completes to
|
| + * deliver decrypted_samples to the media stack.
|
| + */
|
| + void (*DeliverSamples)(PP_Instance instance,
|
| + PP_Resource decrypted_samples, /* PPB_Buffer. */
|
| + struct PP_CompletionCallback callback);
|
| +};
|
| +
|
| +typedef struct PPB_ContentDecryptor_Dev_0_1 PPB_ContentDecryptor_Dev;
|
| +
|
| +/**
|
| + * @}
|
| + */
|
| +
|
| +#endif /* PPAPI_C_DEV_PPB_CONTENT_DECRYPTOR_DEV_H_ */
|
|
|