| Index: ppapi/api/dev/ppb_video_capture_dev.idl
|
| diff --git a/ppapi/api/dev/ppb_video_capture_dev.idl b/ppapi/api/dev/ppb_video_capture_dev.idl
|
| index fd7919094ba69a667362e5424cc2628df3c3a1e9..fe118c23d00cce1991f826fe37710abdfd3397c0 100644
|
| --- a/ppapi/api/dev/ppb_video_capture_dev.idl
|
| +++ b/ppapi/api/dev/ppb_video_capture_dev.idl
|
| @@ -7,7 +7,8 @@
|
| * This file defines the <code>PPB_VideoCapture_Dev</code> interface.
|
| */
|
| label Chrome {
|
| - M14 = 0.1
|
| + M14 = 0.1,
|
| + M18 = 0.2
|
| };
|
|
|
| /**
|
| @@ -52,7 +53,7 @@ interface PPB_VideoCapture_Dev {
|
| * Starts the capture. |requested_info| is a pointer to a structure containing
|
| * the requested resolution and frame rate. |buffer_count| is the number of
|
| * buffers requested by the plugin. Note: it is only used as advisory, the
|
| - * browser may allocate more of fewer based on available resources.
|
| + * browser may allocate more or fewer based on available resources.
|
| * How many buffers depends on usage. At least 2 to make sure latency doesn't
|
| * cause lost frames. If the plugin expects to hold on to more than one buffer
|
| * at a time (e.g. to do multi-frame processing, like video encoding), it
|
| @@ -67,6 +68,46 @@ interface PPB_VideoCapture_Dev {
|
| [in] uint32_t buffer_count);
|
|
|
| /**
|
| + * Enumerates video capture devices. Once the operation is completed
|
| + * successfully. |GetDevices()| can be used to retrieve the devices.
|
| + */
|
| + [version=0.2]
|
| + int32_t EnumerateDevices(
|
| + [in] PP_Resource video_capture,
|
| + [in] PP_CompletionCallback callback);
|
| +
|
| + /**
|
| + * Gets video capture devices. The returned value is a PPB_ResourceArray_Dev
|
| + * resource if successful, which holds a list of PPB_DeviceRef_Dev resources.
|
| + */
|
| + [version=0.2]
|
| + PP_Resource GetDevices(
|
| + [in] PP_Resource video_capture);
|
| +
|
| + /**
|
| + * Starts the capture. |device_ref| identifies a video capture device. It
|
| + * could be one of the resource in the array returned by |GetDevices()|, or 0
|
| + * which means the default device.
|
| + * |requested_info| is a pointer to a structure containing the requested
|
| + * resolution and frame rate. |buffer_count| is the number of buffers
|
| + * requested by the plugin. Note: it is only used as advisory, the browser may
|
| + * allocate more or fewer based on available resources. How many buffers
|
| + * depends on usage. At least 2 to make sure latency doesn't cause lost
|
| + * frames. If the plugin expects to hold on to more than one buffer at a time
|
| + * (e.g. to do multi-frame processing, like video encoding), it should request
|
| + * that many more.
|
| + *
|
| + * Returns PP_ERROR_FAILED if called when the capture was already started, or
|
| + * PP_OK on success.
|
| + */
|
| + [version=0.2]
|
| + int32_t StartCapture(
|
| + [in] PP_Resource video_capture,
|
| + [in] PP_Resource device_ref,
|
| + [in] PP_VideoCaptureDeviceInfo_Dev requested_info,
|
| + [in] uint32_t buffer_count);
|
| +
|
| + /**
|
| * Allows the browser to reuse a buffer that was previously sent by
|
| * PPP_VideoCapture_Dev.OnBufferReady. |buffer| is the index of the buffer in
|
| * the array returned by PPP_VideoCapture_Dev.OnDeviceInfo.
|
|
|