Pepper_47_C_interfaces
Main Page
Modules
Classes
Files
File List
File Members
samsung
pp_media_player_samsung.h
Go to the documentation of this file.
1
/* Copyright (c) 2016 Samsung Electronics. All rights reserved.
2
*/
3
4
/* From samsung/pp_media_player_samsung.idl,
5
* modified Thu Sep 8 15:41:29 2016.
6
*/
7
8
#ifndef PPAPI_C_SAMSUNG_PP_MEDIA_PLAYER_SAMSUNG_H_
9
#define PPAPI_C_SAMSUNG_PP_MEDIA_PLAYER_SAMSUNG_H_
10
11
#include "
ppapi/c/pp_bool.h
"
12
#include "
ppapi/c/pp_macros.h
"
13
#include "
ppapi/c/pp_size.h
"
14
#include "
ppapi/c/pp_stdint.h
"
15
#include "
ppapi/c/pp_time.h
"
16
#include "
ppapi/c/samsung/pp_media_common_samsung.h
"
17
18
/**
19
* @file
20
* This file defines common structures used with the
21
* <code>PPB_MediaPlayer</code> interface.
22
*
23
* Part of Pepper Media Player interfaces (Samsung's extension).
24
* See comments in ppb_media_player_samsung.
25
*/
26
27
28
/**
29
* @addtogroup Enums
30
* @{
31
*/
32
/**
33
* List of media player states.
34
*/
35
typedef
enum
{
36
/**
37
* Indicates invalid state for the player
38
*/
39
PP_MEDIAPLAYERSTATE_NONE
= 0,
40
/**
41
* Player has been created but no data sources hasn't been attached yet.
42
*/
43
PP_MEDIAPLAYERSTATE_UNINITIALIZED
= 1,
44
/**
45
* Player has been created and data sources has been attached.
46
* Playback is ready to be started.
47
*/
48
PP_MEDIAPLAYERSTATE_READY
= 2,
49
/**
50
* Player is playing media. Media time is advancing.
51
*/
52
PP_MEDIAPLAYERSTATE_PLAYING
= 3,
53
/**
54
* Playback has been paused and can be resumed.
55
*/
56
PP_MEDIAPLAYERSTATE_PAUSED
= 4,
57
PP_MEDIAPLAYERSTATE_LAST
=
PP_MEDIAPLAYERSTATE_PAUSED
58
}
PP_MediaPlayerState
;
59
PP_COMPILE_ASSERT_SIZE_IN_BYTES
(
PP_MediaPlayerState
, 4);
60
61
/**
62
* List of errors which might be reported by the player.
63
*/
64
typedef
enum
{
65
/** No error has occurred */
66
PP_MEDIAPLAYERERROR_NONE
= 0,
67
/** Input error has occured */
68
PP_MEDIAPLAYERERROR_BAD_ARGUMENT
= 1,
69
/** Network error has occurred */
70
PP_MEDIAPLAYERERROR_NETWORK
= 2,
71
/** Demuxer error has occured */
72
PP_MEDIAPLAYERERROR_DEMUX
= 3,
73
/** Decryptor error has occured */
74
PP_MEDIAPLAYERERROR_DECRYPT
= 4,
75
/** Decoder error has occurred */
76
PP_MEDIAPLAYERERROR_DECODE
= 5,
77
/** Rendering error has occurred */
78
PP_MEDIAPLAYERERROR_RENDER
= 6,
79
/** Media is encoded using unsupported codec */
80
PP_MEDIAPLAYERERROR_UNSUPPORTED_CODEC
= 7,
81
/** Container is not supported */
82
PP_MEDIAPLAYERERROR_UNSUPPORTED_CONTAINER
= 8,
83
/** Resource error has occured (i.e. no space left on device, no such file) */
84
PP_MEDIAPLAYERERROR_RESOURCE
= 9,
85
/** Unknown error has occurred */
86
PP_MEDIAPLAYERERROR_UNKNOWN
= 10,
87
PP_MEDIAPLAYERERROR_LAST
=
PP_MEDIAPLAYERERROR_UNKNOWN
88
}
PP_MediaPlayerError
;
89
PP_COMPILE_ASSERT_SIZE_IN_BYTES
(
PP_MediaPlayerError
, 4);
90
/**
91
* @}
92
*/
93
94
/**
95
* @addtogroup Structs
96
* @{
97
*/
98
/**
99
* Structure describing video track from played media.
100
*/
101
struct
PP_VideoTrackInfo
{
102
/**
103
* Index of the track in currently played media.
104
* Note this index is only valid for currently attached data source.
105
*/
106
uint32_t
index
;
107
/**
108
* Minimal bandwidth (in bits per second - bps) of delivery channel
109
* required to deliver given video track.
110
*/
111
uint32_t
bitrate
;
112
/**
113
* Decoded video frame size in pixels.
114
*/
115
struct
PP_Size
size
;
116
};
117
PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES
(
PP_VideoTrackInfo
, 16);
118
119
/**
120
* Structure describing audio track from played media.
121
*/
122
struct
PP_AudioTrackInfo
{
123
/**
124
* Index of the track in currently played media.
125
* Note this index is only valid for currently attached data source.
126
*/
127
uint32_t
index
;
128
/**
129
* C style string representing language of audio track
130
* encoded in IETF RFC 5646
131
*/
132
char
language
[64];
133
};
134
PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES
(
PP_AudioTrackInfo
, 68);
135
136
/**
137
* Structure describing text/subtitles track from played media.
138
*/
139
struct
PP_TextTrackInfo
{
140
/**
141
* Index of the track in currently played media.
142
* Note this index is only valid for currently attached data source.
143
*/
144
uint32_t
index
;
145
/**
146
* Is current text track internal (contained in media clip)
147
* or external (loaded from separate file).
148
*
149
* Remarks:
150
* This flag is deprecated. Value of this variable is undefined and should be
151
* ignored.
152
*/
153
PP_Bool
is_external
;
154
/**
155
* C style string representing language of text track
156
* encoded in IETF RFC 5646
157
*/
158
char
language
[64];
159
};
160
PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES
(
PP_TextTrackInfo
, 72);
161
/**
162
* @}
163
*/
164
165
/**
166
* @addtogroup Enums
167
* @{
168
*/
169
/**
170
* List of supported types of DRM systems.
171
*/
172
typedef
enum
{
173
/** Unknown DRM system */
174
PP_MEDIAPLAYERDRMTYPE_UNKNOWN
= 0,
175
/** Playready DRM system */
176
PP_MEDIAPLAYERDRMTYPE_PLAYREADY
= 1,
177
/** Marlin DRM system */
178
PP_MEDIAPLAYERDRMTYPE_MARLIN
= 2,
179
/** Verimatrix DRM system */
180
PP_MEDIAPLAYERDRMTYPE_VERIMATRIX
= 3,
181
/** Widevine classic DRM system */
182
PP_MEDIAPLAYERDRMTYPE_WIDEVINE_CLASSIC
= 4,
183
/** Widevine modular (used with MPEG-DASH) DRM system */
184
PP_MEDIAPLAYERDRMTYPE_WIDEVINE_MODULAR
= 5,
185
/** Securemedia DRM system */
186
PP_MEDIAPLAYERDRMTYPE_SECUREMEDIA
= 6,
187
/** SDRM system */
188
PP_MEDIAPLAYERDRMTYPE_SDRM
= 7,
189
/** ClearKey system */
190
PP_MEDIAPLAYERDRMTYPE_CLEARKEY
= 8,
191
PP_MEDIAPLAYERDRMTYPE_LAST
=
PP_MEDIAPLAYERDRMTYPE_CLEARKEY
192
}
PP_MediaPlayerDRMType
;
193
PP_COMPILE_ASSERT_SIZE_IN_BYTES
(
PP_MediaPlayerDRMType
, 4);
194
195
/**
196
* List of possible DRM system operation.
197
*/
198
typedef
enum
{
199
/**
200
* Setting properties of a DRM instance.
201
*/
202
PP_MEDIAPLAYERDRMOPERATION_SETPROPERTIES
= 1,
203
/**
204
* Enabling challenge message instead of DRM's
205
* connecting to a license server.
206
*/
207
PP_MEDIAPLAYERDRMOPERATION_GENCHALLENGE
= 2,
208
/**
209
* Installing a license into a DRM instance.
210
*/
211
PP_MEDIAPLAYERDRMOPERATION_INSTALLLICENSE
= 3,
212
/**
213
* Deleting a license into a DRM instance.
214
*/
215
PP_MEDIAPLAYERDRMOPERATION_DELETELICENSE
= 4,
216
/**
217
* Requesting key to DRM license server with the initiator information.
218
*/
219
PP_MEDIAPLAYERDRMOPERATION_PROCESSINITIATOR
= 5,
220
/**
221
* Querying the version of DRM system.
222
*/
223
PP_MEDIAPLAYERDRMOPERATION_GETVERSION
= 6,
224
PP_MEDIAPLAYERDRMOPERATION_LAST
=
PP_MEDIAPLAYERDRMOPERATION_GETVERSION
225
}
PP_MediaPlayerDRMOperation
;
226
PP_COMPILE_ASSERT_SIZE_IN_BYTES
(
PP_MediaPlayerDRMOperation
, 4);
227
228
/**
229
* Enum describing available streaming properties which can be set
230
* by the user.
231
*/
232
typedef
enum
{
233
/**
234
* The cookie for streaming playback.
235
* This corresponds to a string (PP_VARTYPE_STRING)
236
*/
237
PP_STREAMINGPROPERTY_COOKIE
= 1,
238
/**
239
* The user agent for streaming playback.
240
* This corresponds to a string (PP_VARTYPE_STRING)
241
*/
242
PP_STREAMINGPROPERTY_USER_AGENT
= 2,
243
/**
244
* Sets adaptive streaming format specific properties.
245
*
246
* Eg. for smooth streaming (strings should be concatenated):
247
* "|BITRATES=50000~2500000"
248
* "|STARTBITRATE=150000"
249
* "|SKIPBITRATE=100000"
250
*
251
* Eg. for DRM (strings should be concatenated):
252
* "DEVICE_ID=null"
253
* "DEVICET_TYPE_ID=60"
254
* "DRM_URL=https://..."
255
*
256
* This corresponds to a string (PP_VARTYPE_STRING).
257
*/
258
PP_STREAMINGPROPERTY_ADAPTIVE_INFO
= 3,
259
/**
260
* Sets streaming type.
261
*
262
* Eg. :
263
* "WIDEVINE"
264
* "HLS"
265
* "VUDU"
266
* "HAS"
267
* "SMOOTH"
268
*
269
* This corresponds to a string (PP_VARTYPE_STRING).
270
*/
271
PP_STREAMINGPROPERTY_TYPE
= 4,
272
/**
273
* Gets available bitrates in bps (bits per second).
274
*
275
* Eg. (values are concatenated and separated by '|'):
276
* "100|500|1000"
277
*
278
* Result is a string (PP_VARTYPE_STRING).
279
*/
280
PP_STREAMINGPROPERTY_AVAILABLE_BITRATES
= 5,
281
/**
282
* Gets throughput in bps.
283
*
284
* Throughput is how much data actually does travel through
285
* the 'channel' successfully.
286
*
287
* Result is a string (PP_VARTYPE_STRING).
288
*/
289
PP_STREAMINGPROPERTY_THROUGHPUT
= 6,
290
/**
291
* Gets duration of the clip in seconds.
292
*
293
* Result is a string (PP_VARTYPE_STRING).
294
*/
295
PP_STREAMINGPROPERTY_DURATION
= 7,
296
/**
297
* Gets current bitrate in bps.
298
*
299
* Result is a string (PP_VARTYPE_STRING).
300
*/
301
PP_STREAMINGPROPERTY_CURRENT_BITRATE
= 8,
302
PP_STREAMINGPROPERTY_LAST
=
PP_STREAMINGPROPERTY_CURRENT_BITRATE
303
}
PP_StreamingProperty
;
304
PP_COMPILE_ASSERT_SIZE_IN_BYTES
(
PP_StreamingProperty
, 4);
305
/**
306
* @}
307
*/
308
309
/**
310
* @addtogroup Structs
311
* @{
312
*/
313
/**
314
* Structure describing Elementary Stream packet. It contains
315
* all necessary timing information to display sent packets in appropriate
316
* order and synchronize different streams.
317
*/
318
struct
PP_ESPacket
{
319
/**
320
* Presentation Timestamp, indicates time relative to begging of
321
* the stream when packet must be rendered.
322
*/
323
PP_TimeTicks
pts
;
324
/**
325
* Decode Timestamp, indicates time relative to begging of the stream
326
* when packet must be sent to decoder.
327
*
328
* Usually equals to pts except rare cases like B-Frames.
329
*/
330
PP_TimeTicks
dts
;
331
/**
332
* Duration of the packet.
333
*/
334
PP_TimeDelta
duration
;
335
/**
336
* Whether the packet represents a key frame.
337
*/
338
PP_Bool
is_key_frame
;
339
/**
340
* Size in bytes of packet data
341
*/
342
uint32_t
size
;
343
/**
344
* Base address of buffer containing data of the packet.
345
*/
346
void
*
buffer
;
347
};
348
349
/**
350
* Structure describing encrypted packet.
351
*/
352
struct
PP_ESPacketEncryptionInfo
{
353
/**
354
* Size in bytes of the |key_id| field.
355
*/
356
uint32_t
key_id_size
;
357
/**
358
* Base address of buffer containing id of the key needed to decrypt given
359
packet.
360
*/
361
void
*
key_id
;
362
/**
363
* Size in bytes of the |iv| field.
364
*/
365
uint32_t
iv_size
;
366
/**
367
* Base address of buffer containing Initialization Vector (IV)
368
* needed to decrypt given packet.
369
*/
370
void
*
iv
;
371
/**
372
* Number of subsamples for given ES packet (sample).
373
*/
374
uint32_t
num_subsamples
;
375
/**
376
* Description of subsamples of which given ES packet consists of.
377
* Size of the array is |num_subsamples|.
378
*/
379
struct
PP_EncryptedSubsampleDescription
*
subsamples
;
380
};
381
/**
382
* @}
383
*/
384
385
#endif
/* PPAPI_C_SAMSUNG_PP_MEDIA_PLAYER_SAMSUNG_H_ */
386
PP_TextTrackInfo
Definition:
pp_media_player_samsung.h:139
PP_STREAMINGPROPERTY_TYPE
Definition:
pp_media_player_samsung.h:271
pp_macros.h
PP_MEDIAPLAYERSTATE_READY
Definition:
pp_media_player_samsung.h:48
PP_MEDIAPLAYERERROR_RESOURCE
Definition:
pp_media_player_samsung.h:84
PP_STREAMINGPROPERTY_LAST
Definition:
pp_media_player_samsung.h:302
PP_STREAMINGPROPERTY_ADAPTIVE_INFO
Definition:
pp_media_player_samsung.h:258
PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES
PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoTrackInfo, 16)
PP_ESPacket::size
uint32_t size
Definition:
pp_media_player_samsung.h:342
PP_TextTrackInfo::is_external
PP_Bool is_external
Definition:
pp_media_player_samsung.h:153
PP_MEDIAPLAYERERROR_DEMUX
Definition:
pp_media_player_samsung.h:72
PP_MEDIAPLAYERERROR_UNSUPPORTED_CONTAINER
Definition:
pp_media_player_samsung.h:82
PP_STREAMINGPROPERTY_THROUGHPUT
Definition:
pp_media_player_samsung.h:289
PP_TextTrackInfo::index
uint32_t index
Definition:
pp_media_player_samsung.h:144
PP_ESPacketEncryptionInfo::iv_size
uint32_t iv_size
Definition:
pp_media_player_samsung.h:365
PP_MEDIAPLAYERDRMTYPE_PLAYREADY
Definition:
pp_media_player_samsung.h:176
PP_MEDIAPLAYERDRMTYPE_UNKNOWN
Definition:
pp_media_player_samsung.h:174
PP_MEDIAPLAYERERROR_LAST
Definition:
pp_media_player_samsung.h:87
PP_MEDIAPLAYERERROR_NONE
Definition:
pp_media_player_samsung.h:66
pp_bool.h
PP_ESPacket::dts
PP_TimeTicks dts
Definition:
pp_media_player_samsung.h:330
PP_STREAMINGPROPERTY_CURRENT_BITRATE
Definition:
pp_media_player_samsung.h:301
PP_MEDIAPLAYERERROR_RENDER
Definition:
pp_media_player_samsung.h:78
PP_STREAMINGPROPERTY_USER_AGENT
Definition:
pp_media_player_samsung.h:242
pp_size.h
PP_MediaPlayerState
PP_MediaPlayerState
Definition:
pp_media_player_samsung.h:35
PP_STREAMINGPROPERTY_DURATION
Definition:
pp_media_player_samsung.h:295
PP_MEDIAPLAYERDRMOPERATION_LAST
Definition:
pp_media_player_samsung.h:224
PP_ESPacketEncryptionInfo::key_id_size
uint32_t key_id_size
Definition:
pp_media_player_samsung.h:356
PP_MEDIAPLAYERERROR_DECRYPT
Definition:
pp_media_player_samsung.h:74
PP_MEDIAPLAYERDRMTYPE_MARLIN
Definition:
pp_media_player_samsung.h:178
PP_VideoTrackInfo::size
struct PP_Size size
Definition:
pp_media_player_samsung.h:115
PP_MEDIAPLAYERDRMTYPE_WIDEVINE_MODULAR
Definition:
pp_media_player_samsung.h:184
PP_STREAMINGPROPERTY_COOKIE
Definition:
pp_media_player_samsung.h:237
PP_ESPacketEncryptionInfo
Definition:
pp_media_player_samsung.h:352
PP_MEDIAPLAYERDRMTYPE_LAST
Definition:
pp_media_player_samsung.h:191
PP_AudioTrackInfo::language
char language[64]
Definition:
pp_media_player_samsung.h:132
PP_ESPacketEncryptionInfo::iv
void * iv
Definition:
pp_media_player_samsung.h:370
PP_MEDIAPLAYERDRMOPERATION_GETVERSION
Definition:
pp_media_player_samsung.h:223
PP_TimeTicks
double PP_TimeTicks
Definition:
pp_time.h:42
PP_ESPacket::is_key_frame
PP_Bool is_key_frame
Definition:
pp_media_player_samsung.h:338
PP_MEDIAPLAYERSTATE_LAST
Definition:
pp_media_player_samsung.h:57
PP_COMPILE_ASSERT_SIZE_IN_BYTES
PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_MediaPlayerState, 4)
PP_MediaPlayerDRMOperation
PP_MediaPlayerDRMOperation
Definition:
pp_media_player_samsung.h:198
PP_VideoTrackInfo::index
uint32_t index
Definition:
pp_media_player_samsung.h:106
PP_TextTrackInfo::language
char language[64]
Definition:
pp_media_player_samsung.h:158
PP_MEDIAPLAYERDRMOPERATION_GENCHALLENGE
Definition:
pp_media_player_samsung.h:207
PP_MEDIAPLAYERDRMTYPE_CLEARKEY
Definition:
pp_media_player_samsung.h:190
PP_ESPacket
Definition:
pp_media_player_samsung.h:318
PP_MEDIAPLAYERERROR_BAD_ARGUMENT
Definition:
pp_media_player_samsung.h:68
PP_EncryptedSubsampleDescription
Definition:
pp_media_common_samsung.h:98
PP_MEDIAPLAYERERROR_UNSUPPORTED_CODEC
Definition:
pp_media_player_samsung.h:80
PP_STREAMINGPROPERTY_AVAILABLE_BITRATES
Definition:
pp_media_player_samsung.h:280
PP_MEDIAPLAYERDRMTYPE_SECUREMEDIA
Definition:
pp_media_player_samsung.h:186
PP_MEDIAPLAYERDRMOPERATION_DELETELICENSE
Definition:
pp_media_player_samsung.h:215
PP_MEDIAPLAYERSTATE_PLAYING
Definition:
pp_media_player_samsung.h:52
PP_StreamingProperty
PP_StreamingProperty
Definition:
pp_media_player_samsung.h:232
PP_ESPacketEncryptionInfo::subsamples
struct PP_EncryptedSubsampleDescription * subsamples
Definition:
pp_media_player_samsung.h:379
PP_MediaPlayerError
PP_MediaPlayerError
Definition:
pp_media_player_samsung.h:64
PP_MEDIAPLAYERDRMOPERATION_INSTALLLICENSE
Definition:
pp_media_player_samsung.h:211
PP_ESPacket::duration
PP_TimeDelta duration
Definition:
pp_media_player_samsung.h:334
PP_MEDIAPLAYERDRMTYPE_WIDEVINE_CLASSIC
Definition:
pp_media_player_samsung.h:182
PP_MEDIAPLAYERDRMOPERATION_PROCESSINITIATOR
Definition:
pp_media_player_samsung.h:219
PP_MEDIAPLAYERSTATE_UNINITIALIZED
Definition:
pp_media_player_samsung.h:43
PP_VideoTrackInfo::bitrate
uint32_t bitrate
Definition:
pp_media_player_samsung.h:111
PP_MEDIAPLAYERERROR_UNKNOWN
Definition:
pp_media_player_samsung.h:86
PP_ESPacket::buffer
void * buffer
Definition:
pp_media_player_samsung.h:346
PP_ESPacketEncryptionInfo::num_subsamples
uint32_t num_subsamples
Definition:
pp_media_player_samsung.h:374
PP_MEDIAPLAYERDRMOPERATION_SETPROPERTIES
Definition:
pp_media_player_samsung.h:202
pp_stdint.h
PP_MEDIAPLAYERDRMTYPE_VERIMATRIX
Definition:
pp_media_player_samsung.h:180
PP_MEDIAPLAYERDRMTYPE_SDRM
Definition:
pp_media_player_samsung.h:188
PP_ESPacket::pts
PP_TimeTicks pts
Definition:
pp_media_player_samsung.h:323
pp_media_common_samsung.h
PP_Bool
PP_Bool
Definition:
pp_bool.h:30
PP_TimeDelta
double PP_TimeDelta
Definition:
pp_time.h:49
PP_MEDIAPLAYERERROR_DECODE
Definition:
pp_media_player_samsung.h:76
PP_ESPacketEncryptionInfo::key_id
void * key_id
Definition:
pp_media_player_samsung.h:361
PP_VideoTrackInfo
Definition:
pp_media_player_samsung.h:101
PP_AudioTrackInfo::index
uint32_t index
Definition:
pp_media_player_samsung.h:127
PP_AudioTrackInfo
Definition:
pp_media_player_samsung.h:122
PP_MEDIAPLAYERSTATE_PAUSED
Definition:
pp_media_player_samsung.h:56
PP_MEDIAPLAYERSTATE_NONE
Definition:
pp_media_player_samsung.h:39
PP_MediaPlayerDRMType
PP_MediaPlayerDRMType
Definition:
pp_media_player_samsung.h:172
PP_MEDIAPLAYERERROR_NETWORK
Definition:
pp_media_player_samsung.h:70
pp_time.h
PP_Size
Definition:
pp_size.h:27
Generated on Wed Apr 5 2017 11:09:17 for Pepper_47_C_interfaces by
1.8.6