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

Side by Side Diff: ppapi/api/pp_codecs.idl

Issue 1128023009: ppapi: define PPB_AudioEncoder API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: bbudge's nits & api release bump Created 5 years, 3 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
OLDNEW
1 /* Copyright (c) 2014 The Chromium Authors. All rights reserved. 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 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 5
6 /** 6 /**
7 * Video profiles. 7 * Video profiles.
8 */ 8 */
9 enum PP_VideoProfile { 9 enum PP_VideoProfile {
10 PP_VIDEOPROFILE_H264BASELINE = 0, 10 PP_VIDEOPROFILE_H264BASELINE = 0,
11 PP_VIDEOPROFILE_H264MAIN = 1, 11 PP_VIDEOPROFILE_H264MAIN = 1,
12 PP_VIDEOPROFILE_H264EXTENDED = 2, 12 PP_VIDEOPROFILE_H264EXTENDED = 2,
13 PP_VIDEOPROFILE_H264HIGH = 3, 13 PP_VIDEOPROFILE_H264HIGH = 3,
14 PP_VIDEOPROFILE_H264HIGH10PROFILE = 4, 14 PP_VIDEOPROFILE_H264HIGH10PROFILE = 4,
15 PP_VIDEOPROFILE_H264HIGH422PROFILE = 5, 15 PP_VIDEOPROFILE_H264HIGH422PROFILE = 5,
16 PP_VIDEOPROFILE_H264HIGH444PREDICTIVEPROFILE = 6, 16 PP_VIDEOPROFILE_H264HIGH444PREDICTIVEPROFILE = 6,
17 PP_VIDEOPROFILE_H264SCALABLEBASELINE = 7, 17 PP_VIDEOPROFILE_H264SCALABLEBASELINE = 7,
18 PP_VIDEOPROFILE_H264SCALABLEHIGH = 8, 18 PP_VIDEOPROFILE_H264SCALABLEHIGH = 8,
19 PP_VIDEOPROFILE_H264STEREOHIGH = 9, 19 PP_VIDEOPROFILE_H264STEREOHIGH = 9,
20 PP_VIDEOPROFILE_H264MULTIVIEWHIGH = 10, 20 PP_VIDEOPROFILE_H264MULTIVIEWHIGH = 10,
21 PP_VIDEOPROFILE_VP8_ANY = 11, 21 PP_VIDEOPROFILE_VP8_ANY = 11,
22 PP_VIDEOPROFILE_VP9_ANY = 12, 22 PP_VIDEOPROFILE_VP9_ANY = 12,
23 PP_VIDEOPROFILE_MAX = PP_VIDEOPROFILE_VP9_ANY 23 PP_VIDEOPROFILE_MAX = PP_VIDEOPROFILE_VP9_ANY
24 }; 24 };
25 25
26 /** 26 /**
27 * Audio profiles.
28 */
29 enum PP_AudioProfile {
30 PP_AUDIOPROFILE_OPUS = 0,
31 PP_AUDIOPROFILE_SPEEX = 1,
32 PP_AUDIOPROFILE_MAX = PP_AUDIOPROFILE_SPEEX
33 };
34
35 /**
27 * Hardware acceleration options. 36 * Hardware acceleration options.
28 */ 37 */
29 enum PP_HardwareAcceleration { 38 enum PP_HardwareAcceleration {
30 /** Create a hardware accelerated resource only. */ 39 /** Create a hardware accelerated resource only. */
31 PP_HARDWAREACCELERATION_ONLY = 0, 40 PP_HARDWAREACCELERATION_ONLY = 0,
32 41
33 /** 42 /**
34 * Create a hardware accelerated resource if possible. Otherwise, fall back 43 * Create a hardware accelerated resource if possible. Otherwise, fall back
35 * to the software implementation. 44 * to the software implementation.
36 */ 45 */
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 uint32_t max_framerate_denominator; 182 uint32_t max_framerate_denominator;
174 183
175 /** 184 /**
176 * A value indicating if the profile is available in hardware, software, or 185 * A value indicating if the profile is available in hardware, software, or
177 * both. 186 * both.
178 */ 187 */
179 PP_HardwareAcceleration acceleration; 188 PP_HardwareAcceleration acceleration;
180 }; 189 };
181 190
182 /** 191 /**
192 * Supported audio profile information. See the PPB_AudioEncoder function
193 * GetSupportedProfiles() for more details.
194 */
195 struct PP_AudioProfileDescription {
196 /**
197 * The codec profile.
198 */
199 PP_AudioProfile profile;
200
201 /**
202 * Maximum number of channels that can be encoded.
203 */
204 uint32_t max_channels;
205
206 /**
207 * Sample size.
208 */
209 uint32_t sample_size;
210
211 /**
212 * Sampling rate that can be encoded
213 */
214 uint32_t sample_rate;
215
216 /**
217 * Whether the profile is hardware accelerated.
218 */
219 PP_Bool hardware_accelerated;
220 };
221
222 /**
183 * Struct describing a bitstream buffer. 223 * Struct describing a bitstream buffer.
184 */ 224 */
185 struct PP_BitstreamBuffer { 225 struct PP_BitstreamBuffer {
186 /** 226 /**
187 * The size, in bytes, of the bitstream data. 227 * The size, in bytes, of the bitstream data.
188 */ 228 */
189 uint32_t size; 229 uint32_t size;
190 230
191 /** 231 /**
192 * The base address of the bitstream data. 232 * The base address of the bitstream data.
193 */ 233 */
194 mem_t buffer; 234 mem_t buffer;
195 235
196 /** 236 /**
197 * Whether the buffer represents a key frame. 237 * Whether the buffer represents a key frame.
198 */ 238 */
199 PP_Bool key_frame; 239 PP_Bool key_frame;
200 }; 240 };
241
242 /**
243 * Struct describing an audio bitstream buffer.
244 */
245 struct PP_AudioBitstreamBuffer {
246 /**
247 * The size, in bytes, of the bitstream data.
248 */
249 uint32_t size;
250
251 /**
252 * The base address of the bitstream data.
253 */
254 mem_t buffer;
255 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698