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

Side by Side Diff: ppapi/c/pp_media_codec.h

Issue 210373003: Pepper VideoDecoder API definition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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
(Empty)
1 /* Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can be
3 * found in the LICENSE file.
4 */
5
6 /* From pp_media_codec.idl modified Tue Apr 8 18:09:01 2014. */
7
8 #ifndef PPAPI_C_PP_MEDIA_CODEC_H_
9 #define PPAPI_C_PP_MEDIA_CODEC_H_
10
11 #include "ppapi/c/pp_macros.h"
12 #include "ppapi/c/pp_size.h"
13 #include "ppapi/c/pp_stdint.h"
14
15 /**
16 * @file
17 * Video decoder profiles.
18 */
19
20
21 /**
22 * @addtogroup Enums
23 * @{
24 */
25 typedef enum {
26 PP_MEDIACODEC_H264PROFILE_BASELINE = 0,
27 PP_MEDIACODEC_H264PROFILE_MAIN = 1,
28 PP_MEDIACODEC_H264PROFILE_EXTENDED = 2,
29 PP_MEDIACODEC_H264PROFILE_HIGH = 3,
30 PP_MEDIACODEC_H264PROFILE_HIGH10PROFILE = 4,
31 PP_MEDIACODEC_H264PROFILE_HIGH422PROFILE = 5,
32 PP_MEDIACODEC_H264PROFILE_HIGH444PREDICTIVEPROFILE = 6,
33 PP_MEDIACODEC_H264PROFILE_SCALABLEBASELINE = 7,
34 PP_MEDIACODEC_H264PROFILE_SCALABLEHIGH = 8,
35 PP_MEDIACODEC_H264PROFILE_STEREOHIGH = 9,
36 PP_MEDIACODEC_H264PROFILE_MULTIVIEWHIGH = 10,
37 PP_MEDIACODEC_VP8PROFILE_MAIN = 11,
38 PP_MEDIACODEC_VP9PROFILE_MAIN = 12,
39 PP_MEDIACODEC_PROFILE_MAX = PP_MEDIACODEC_VP9PROFILE_MAIN
40 } PP_MediaCodec_Profile;
41 /**
42 * @}
43 */
44
45 /**
46 * @addtogroup Structs
47 * @{
48 */
49 /**
50 * Struct describing a video bitstream buffer. This struct is read-only and
51 * should not be modified by the plugin.
52 */
53 struct PP_MediaCodec_BitstreamBuffer {
54 /**
55 * Buffer id. This can be used by the plugin to match bitstream buffers sent
56 * to the decoder with picture buffers received from the decoder.
57 */
58 int32_t buffer_id;
59 /**
60 * Size of buffer in bytes.
61 */
62 uint32_t size;
63 /**
64 * Pointer to buffer data. The plugin can safely write to the address range
65 * [addr, addr + size - 1].
66 */
67 void* addr;
68 };
69
70 /**
71 * Struct describing a decoded video picture. The decoded picture data from the
72 * bitstream buffer corresponding to |buffer_id| is stored in the GL texture
73 * corresponding to |texture_id|. This struct is read-only and should not be
74 * modified by the plugin.
75 */
76 struct PP_MediaCodec_PictureBuffer {
77 /**
78 * Identifier of the last bitstream buffer which decoded into this picture.
79 */
80 int32_t buffer_id;
81 /**
82 * Texture ID in the plugin's GL context. The plugin can use this to render
83 * the decoded picture.
84 */
85 uint32_t texture_id;
86 /**
87 * The type of GL texture used to hold the decoded picture. The possible
88 * values are:
89 * GL_TEXTURE_2D
90 * GL_TEXTURE_RECTANGLE_ARB
91 */
92 uint32_t texture_target;
93 /**
94 * Dimensions of the texture holding the decoded picture.
95 */
96 struct PP_Size texture_size;
97 };
98 /**
99 * @}
100 */
101
102 #endif /* PPAPI_C_PP_MEDIA_CODEC_H_ */
103
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698