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

Side by Side Diff: ppapi/c/dev/ppp_video_decoder_dev.h

Issue 6901036: Update VideoDecode PPAPI structs to be consistent with media structures, part 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 months 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 | Annotate | Revision Log
OLDNEW
1 /* Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 /* Copyright (c) 2011 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 #ifndef PPAPI_C_DEV_PPP_VIDEO_DECODER_DEV_H_ 5 #ifndef PPAPI_C_DEV_PPP_VIDEO_DECODER_DEV_H_
6 #define PPAPI_C_DEV_PPP_VIDEO_DECODER_DEV_H_ 6 #define PPAPI_C_DEV_PPP_VIDEO_DECODER_DEV_H_
7 7
8 #include "ppapi/c/dev/pp_video_dev.h" 8 #include "ppapi/c/dev/pp_video_dev.h"
9 9
10 #define PPP_VIDEODECODER_DEV_INTERFACE "PPP_VideoDecoder(Dev);0.1" 10 #define PPP_VIDEODECODER_DEV_INTERFACE "PPP_VideoDecoder(Dev);0.1"
piman 2011/04/26 20:48:07 Drive-by: please bump the version if you change th
vrk (LEFT CHROMIUM) 2011/04/27 00:40:33 Done.
11 11
12 // PPP_VideoDecoder_Dev structure contains the function pointers that the 12 // PPP_VideoDecoder_Dev structure contains the function pointers that the
13 // plugin MUST implement to provide services needed by the video decoder 13 // plugin MUST implement to provide services needed by the video decoder
14 // implementation. 14 // implementation.
15 struct PPP_VideoDecoder_Dev { 15 struct PPP_VideoDecoder_Dev {
16 // Callback function to provide buffers for the decoded output pictures. If 16 // Callback function to provide buffers for the decoded output pictures. If
17 // succeeds plugin must provide buffers through AssignPictureBuffers function 17 // succeeds plugin must provide buffers through AssignPictureBuffers function
18 // to the API. If |req_num_of_bufs| matching exactly the specification 18 // to the API. If |req_num_of_bufs| matching exactly the specification
19 // given in |props| cannot be allocated decoder should be destroyed. 19 // given in |props| cannot be allocated decoder should be destroyed.
20 // 20 //
21 // Decoding will not proceed until buffers have been provided. 21 // Decoding will not proceed until buffers have been provided.
22 // 22 //
23 // Parameters: 23 // Parameters:
24 // |decoder| is pointer to the Pepper Video Decoder instance. 24 // |decoder| is pointer to the Pepper Video Decoder instance.
25 // |req_num_of_bufs| tells how many buffers are needed by the decoder. 25 // |req_num_of_bufs| tells how many buffers are needed by the decoder.
26 // |props| tells the properties that are required from the textures. 26 // |props| tells the properties that are required from the textures.
27 void (*ProvidePictureBuffers)( 27 void (*ProvidePictureBuffers)(
28 PP_Resource decoder, 28 PP_Resource decoder,
29 uint32_t req_num_of_bufs, 29 uint32_t req_num_of_bufs,
30 const struct PP_PictureBufferProperties_Dev* props); 30 const struct PP_PictureBufferProperties_Dev* props);
31 31
32 // Callback function for decoder to deliver unneeded picture buffers back to 32 // Callback function for decoder to deliver unneeded picture buffers back to
33 // the plugin. 33 // the plugin.
34 // 34 //
35 // Parameters: 35 // Parameters:
36 // |decoder| is pointer to the Pepper Video Decoder instance. 36 // |decoder| is pointer to the Pepper Video Decoder instance.
37 // |picture_buffer| points to the picture buffer that is no longer needed. 37 // |picture_buffer| points to the picture buffer that is no longer needed.
38 void (*DismissPictureBuffer)(PP_Resource decoder, 38 void (*DismissPictureBuffer)(PP_Resource decoder,
39 union PP_PictureData_Dev* picture_buffer); 39 int32_t picture_buffer_id);
40 40
41 // Callback function for decoder to deliver decoded pictures ready to be 41 // Callback function for decoder to deliver decoded pictures ready to be
42 // displayed. Decoder expects the plugin to return the buffer back to the 42 // displayed. Decoder expects the plugin to return the buffer back to the
43 // decoder through ReusePictureBuffer function in PPB Video Decoder API. 43 // decoder through ReusePictureBuffer function in PPB Video Decoder API.
44 // 44 //
45 // Parameters: 45 // Parameters:
46 // |decoder| is pointer to the Pepper Video Decoder instance. 46 // |decoder| is pointer to the Pepper Video Decoder instance.
47 // |picture| is the picture that is ready. 47 // |picture| is the picture that is ready.
48 void (*PictureReady)(PP_Resource decoder, 48 void (*PictureReady)(PP_Resource decoder,
49 struct PP_Picture_Dev* picture); 49 struct PP_Picture_Dev* picture);
(...skipping 11 matching lines...) Expand all
61 // 61 //
62 // TODO(vmr): Fill out error result codes and corresponding actions. 62 // TODO(vmr): Fill out error result codes and corresponding actions.
63 // 63 //
64 // Parameters: 64 // Parameters:
65 // |decoder| is pointer to the Pepper Video Decoder instance. 65 // |decoder| is pointer to the Pepper Video Decoder instance.
66 // |error| error is the enumeration specifying the error. 66 // |error| error is the enumeration specifying the error.
67 void (*NotifyError)(PP_Resource decoder, enum PP_VideoDecodeError_Dev error); 67 void (*NotifyError)(PP_Resource decoder, enum PP_VideoDecodeError_Dev error);
68 }; 68 };
69 69
70 #endif /* PPAPI_C_DEV_PPP_VIDEO_DECODER_DEV_H_ */ 70 #endif /* PPAPI_C_DEV_PPP_VIDEO_DECODER_DEV_H_ */
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698