williamr@2
|
1 |
// Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
|
williamr@2
|
2 |
// All rights reserved.
|
williamr@2
|
3 |
// This component and the accompanying materials are made available
|
williamr@2
|
4 |
// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
|
williamr@2
|
5 |
// which accompanies this distribution, and is available
|
williamr@2
|
6 |
// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
|
williamr@2
|
7 |
//
|
williamr@2
|
8 |
// Initial Contributors:
|
williamr@2
|
9 |
// Nokia Corporation - initial contribution.
|
williamr@2
|
10 |
//
|
williamr@2
|
11 |
// Contributors:
|
williamr@2
|
12 |
//
|
williamr@2
|
13 |
// Description:
|
williamr@2
|
14 |
// Constants and structs specific to AVC. See the DevVideo specs for more details.
|
williamr@2
|
15 |
//
|
williamr@2
|
16 |
//
|
williamr@2
|
17 |
|
williamr@2
|
18 |
#ifndef __DEVVIDEO_AVC_H__
|
williamr@2
|
19 |
#define __DEVVIDEO_AVC_H__
|
williamr@2
|
20 |
|
williamr@2
|
21 |
#include <e32base.h>
|
williamr@2
|
22 |
|
williamr@2
|
23 |
/**
|
williamr@2
|
24 |
Specifies the picture type.
|
williamr@2
|
25 |
@publishedAll
|
williamr@2
|
26 |
@released
|
williamr@2
|
27 |
*/
|
williamr@2
|
28 |
enum TAvcPictureType
|
williamr@2
|
29 |
{
|
williamr@2
|
30 |
/**
|
williamr@2
|
31 |
INTRA picture, a picture consisted of at least one I slice and zero or more SI slices
|
williamr@2
|
32 |
*/
|
williamr@2
|
33 |
EAvcPictureTypeI = 0x01,
|
williamr@2
|
34 |
|
williamr@2
|
35 |
/**
|
williamr@2
|
36 |
INTER picture, a picture consisted of at least one P slice and zero or more I, SI and SP slices
|
williamr@2
|
37 |
*/
|
williamr@2
|
38 |
EAvcPictureTypeP = 0x02,
|
williamr@2
|
39 |
|
williamr@2
|
40 |
/**
|
williamr@2
|
41 |
Bi-predictive picture, a picture consisted of at least one B slice and zero or more I, P, SI,
|
williamr@2
|
42 |
and SP slices
|
williamr@2
|
43 |
*/
|
williamr@2
|
44 |
EAvcPictureTypeB = 0x04,
|
williamr@2
|
45 |
|
williamr@2
|
46 |
/**
|
williamr@2
|
47 |
SI picture or switching I picture, a picture consisted of SI slices
|
williamr@2
|
48 |
*/
|
williamr@2
|
49 |
EAvcPictureTypeSI = 0x08,
|
williamr@2
|
50 |
|
williamr@2
|
51 |
/**
|
williamr@2
|
52 |
SP picture or switching P picture, a picture consisted of at least one SP slice and zero or more
|
williamr@2
|
53 |
SI slices
|
williamr@2
|
54 |
*/
|
williamr@2
|
55 |
EAvcPictureTypeSP = 0x10
|
williamr@2
|
56 |
};
|
williamr@2
|
57 |
|
williamr@2
|
58 |
|
williamr@2
|
59 |
/**
|
williamr@2
|
60 |
These enumerations can be used in codec capability indication and/or bitstream property indication.
|
williamr@2
|
61 |
When used as part of an encoder capability indication, a signaled value indicates the capability
|
williamr@2
|
62 |
of an encoder to produce such Supplemental Enhancement Information (SEI) to the bitstream and the
|
williamr@2
|
63 |
additional meanings as specified below. When used as part of a decoder capability indication, a
|
williamr@2
|
64 |
signalled value indicates the capability of a decoder to react to such information in a way as
|
williamr@2
|
65 |
specified below. If a decoder does not have such capability, it shall be able to parse and discard
|
williamr@2
|
66 |
the information. When used as part of a bitstream property indication, a non-signalled value
|
williamr@2
|
67 |
indicates the absence of such information in the bitstream and a signalled value indicates the
|
williamr@2
|
68 |
possibility of having such information in the bitstream.
|
williamr@2
|
69 |
@publishedAll
|
williamr@2
|
70 |
@released
|
williamr@2
|
71 |
*/
|
williamr@2
|
72 |
enum TAvcSupplementalInformation
|
williamr@2
|
73 |
{
|
williamr@2
|
74 |
/**
|
williamr@2
|
75 |
encoder capability: no meaning
|
williamr@2
|
76 |
decoder capability: capability to initialize Hypothetical Reference Decoder (HRD) as specified
|
williamr@2
|
77 |
in AVC Annex C at any buffering period SEI message
|
williamr@2
|
78 |
bitstream property: existence of Network Abstraction Layer (NAL) units with nal_unit_type equal
|
williamr@2
|
79 |
to 6 and the SEI payload type (payloadType) equal to 0
|
williamr@2
|
80 |
*/
|
williamr@2
|
81 |
EAvcSeiBufferingPeriod = 0x00000001,
|
williamr@2
|
82 |
|
williamr@2
|
83 |
/**
|
williamr@2
|
84 |
encoder capability: no meaning
|
williamr@2
|
85 |
decoder capability: capability to operate HRD and decode/display video streams according to the
|
williamr@2
|
86 |
provided timing information
|
williamr@2
|
87 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
88 |
to 1
|
williamr@2
|
89 |
*/
|
williamr@2
|
90 |
EAvcSeiPictureTiming = 0x00000002,
|
williamr@2
|
91 |
|
williamr@2
|
92 |
/**
|
williamr@2
|
93 |
encoder capability: no meaning
|
williamr@2
|
94 |
decoder capability: capability to crop after decoding and to display the specified rectangular
|
williamr@2
|
95 |
region
|
williamr@2
|
96 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
97 |
to 2
|
williamr@2
|
98 |
*/
|
williamr@2
|
99 |
EAvcSeiPanScanRectangle = 0x00000004,
|
williamr@2
|
100 |
|
williamr@2
|
101 |
/**
|
williamr@2
|
102 |
encoder capability: no meaning
|
williamr@2
|
103 |
decoder capability: no meaning
|
williamr@2
|
104 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
105 |
to 3
|
williamr@2
|
106 |
*/
|
williamr@2
|
107 |
EAvcSeiFillerPayload = 0x00000008,
|
williamr@2
|
108 |
|
williamr@2
|
109 |
/**
|
williamr@2
|
110 |
encoder capability: no meaning
|
williamr@2
|
111 |
decoder capability: no meaning
|
williamr@2
|
112 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
113 |
to 4
|
williamr@2
|
114 |
*/
|
williamr@2
|
115 |
EAvcSeiUserDataRegisteredByITUTRecT35 = 0x00000010,
|
williamr@2
|
116 |
|
williamr@2
|
117 |
/**
|
williamr@2
|
118 |
encoder capability: no meaning
|
williamr@2
|
119 |
decoder capability: no meaning
|
williamr@2
|
120 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
121 |
to 5
|
williamr@2
|
122 |
*/
|
williamr@2
|
123 |
EAvcSeiUserDataUnRegistered = 0x00000020,
|
williamr@2
|
124 |
|
williamr@2
|
125 |
/**
|
williamr@2
|
126 |
encoder capability: no meaning
|
williamr@2
|
127 |
decoder capability: capability to start decoding from any access unit with a recovery point SEI
|
williamr@2
|
128 |
message
|
williamr@2
|
129 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
130 |
to 6
|
williamr@2
|
131 |
*/
|
williamr@2
|
132 |
EAvcSeiRecoveryPoint = 0x00000040,
|
williamr@2
|
133 |
|
williamr@2
|
134 |
/**
|
williamr@2
|
135 |
encoder capability: capability to repeat the decoded reference picture marking syntax structure
|
williamr@2
|
136 |
as specified in subclauses 7.3.3.3 and 7.4.3.3 of the AVC specification.
|
williamr@2
|
137 |
decoder capability: capability to recover the decoded reference picture marking process due to
|
williamr@2
|
138 |
losses of reference pictures with decoded reference picture marking syntax
|
williamr@2
|
139 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
140 |
to 7
|
williamr@2
|
141 |
*/
|
williamr@2
|
142 |
EAvcSeiDecodedReferencePictureMarkingRepetition = 0x00000080,
|
williamr@2
|
143 |
|
williamr@2
|
144 |
/**
|
williamr@2
|
145 |
encoder capability: capability to analyze video pictures for creation of spare picture information
|
williamr@2
|
146 |
decoder capability: capability to utilize the spare picture information to enhance video decoding
|
williamr@2
|
147 |
in case there is loss of reference pictures
|
williamr@2
|
148 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
149 |
to 8
|
williamr@2
|
150 |
*/
|
williamr@2
|
151 |
EAvcSeiSparePicture = 0x00000100,
|
williamr@2
|
152 |
|
williamr@2
|
153 |
/**
|
williamr@2
|
154 |
encoder capability: no meaning
|
williamr@2
|
155 |
decoder capability: capability to utilize the scene information to enhance error concealment
|
williamr@2
|
156 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
157 |
to 9
|
williamr@2
|
158 |
*/
|
williamr@2
|
159 |
EAvcSeiSceneInformation = 0x00000200,
|
williamr@2
|
160 |
|
williamr@2
|
161 |
/**
|
williamr@2
|
162 |
encoder capability: no meaning
|
williamr@2
|
163 |
decoder capability: capability to utilize the sub-sequence information to achieve temporal
|
williamr@2
|
164 |
scalability
|
williamr@2
|
165 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType
|
williamr@2
|
166 |
equal to 10
|
williamr@2
|
167 |
*/
|
williamr@2
|
168 |
EAvcSeiSubsequenceInformation = 0x00000400,
|
williamr@2
|
169 |
|
williamr@2
|
170 |
/**
|
williamr@2
|
171 |
encoder capability: no meaning
|
williamr@2
|
172 |
decoder capability: capability to utilize the sub-sequence information and the sub-sequence
|
williamr@2
|
173 |
layer characteristics to achieve temporal scalability
|
williamr@2
|
174 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType
|
williamr@2
|
175 |
equal to 11 (if sub-sequence layer characteristics SEI message is present,
|
williamr@2
|
176 |
sub-sequence information SEI message must be present)
|
williamr@2
|
177 |
*/
|
williamr@2
|
178 |
EAvcSeiSubsequenceLayerCharacteristics = 0x00000800,
|
williamr@2
|
179 |
|
williamr@2
|
180 |
/**
|
williamr@2
|
181 |
encoder capability: no meaning
|
williamr@2
|
182 |
decoder capability: capability to utilize the sub-sequence information and the sub-sequence
|
williamr@2
|
183 |
characteristics to achieve temporal scalability
|
williamr@2
|
184 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
185 |
to 12 (if sub-sequence characteristics SEI message is present, sub-sequence
|
williamr@2
|
186 |
information SEI message must be present)
|
williamr@2
|
187 |
*/
|
williamr@2
|
188 |
EAvcSeiSubsequenceCharacteristics = 0x00001000,
|
williamr@2
|
189 |
|
williamr@2
|
190 |
/**
|
williamr@2
|
191 |
encoder capability: no meaning
|
williamr@2
|
192 |
decoder capability: capability to freeze displayed picture according to AVC Annex D.2.14.
|
williamr@2
|
193 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
194 |
to 13
|
williamr@2
|
195 |
*/
|
williamr@2
|
196 |
EAvcSeiFullFrameFreeze = 0x00002000,
|
williamr@2
|
197 |
|
williamr@2
|
198 |
/**
|
williamr@2
|
199 |
encoder capability: no meaning
|
williamr@2
|
200 |
decoder capability: capability to release frozen displayed picture according to AVC Annex D.2.15
|
williamr@2
|
201 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType
|
williamr@2
|
202 |
equal to 14
|
williamr@2
|
203 |
*/
|
williamr@2
|
204 |
EAvcSeiFullFrameFreezeRelease = 0x00004000,
|
williamr@2
|
205 |
|
williamr@2
|
206 |
/**
|
williamr@2
|
207 |
encoder capability: no meaning
|
williamr@2
|
208 |
decoder capability: no meaning
|
williamr@2
|
209 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType
|
williamr@2
|
210 |
equal to 15
|
williamr@2
|
211 |
*/
|
williamr@2
|
212 |
EAvcSeiFullFrameSnapshot = 0x00008000,
|
williamr@2
|
213 |
|
williamr@2
|
214 |
/**
|
williamr@2
|
215 |
encoder capability: no meaning
|
williamr@2
|
216 |
decoder capability: no meaning
|
williamr@2
|
217 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType
|
williamr@2
|
218 |
equal to 16
|
williamr@2
|
219 |
*/
|
williamr@2
|
220 |
EAvcSeiProgressiveRefinementSegmentStrat = 0x00010000,
|
williamr@2
|
221 |
|
williamr@2
|
222 |
/**
|
williamr@2
|
223 |
encoder capability: no meaning
|
williamr@2
|
224 |
decoder capability: no meaning
|
williamr@2
|
225 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType
|
williamr@2
|
226 |
equal to 17
|
williamr@2
|
227 |
*/
|
williamr@2
|
228 |
EAvcSeiProgressiveRefinementSegmentEnd = 0x00020000,
|
williamr@2
|
229 |
|
williamr@2
|
230 |
/**
|
williamr@2
|
231 |
encoder capability: capability to constrain the inter prediction process according to
|
williamr@2
|
232 |
AVC Annex D.2.19
|
williamr@2
|
233 |
decoder capability: capability to decode only part of the pictures covered by the motion-
|
williamr@2
|
234 |
constrained slice group set
|
williamr@2
|
235 |
bitstream property: existence of NAL units with nal_unit_type equal to 6 and payloadType equal
|
williamr@2
|
236 |
to 18
|
williamr@2
|
237 |
*/
|
williamr@2
|
238 |
EAvcSeiMotionConstrainedSliceGroupSet = 0x00040000
|
williamr@2
|
239 |
};
|
williamr@2
|
240 |
|
williamr@2
|
241 |
|
williamr@2
|
242 |
/**
|
williamr@2
|
243 |
AVC Picture Header.
|
williamr@2
|
244 |
@publishedAll
|
williamr@2
|
245 |
@released
|
williamr@2
|
246 |
*/
|
williamr@2
|
247 |
class TAvcPictureHeader
|
williamr@2
|
248 |
{
|
williamr@2
|
249 |
public:
|
williamr@2
|
250 |
/**
|
williamr@2
|
251 |
Equal to ETrue indicates that the bitstream obeys all constraints specified in subclause A.2.1
|
williamr@2
|
252 |
of the AVC specification, equal to EFalse indicates that the bitstream may or may not obey the
|
williamr@2
|
253 |
constraints. The value is equal to ETrue (EFalse) if the syntax element constraint_set0_flag is
|
williamr@2
|
254 |
equal to 1 (0).
|
williamr@2
|
255 |
*/
|
williamr@2
|
256 |
TBool iBaselineProfileConstraintSet;
|
williamr@2
|
257 |
|
williamr@2
|
258 |
/**
|
williamr@2
|
259 |
Equal to ETrue indicates that the bitstream obeys all constraints specified in subclause A.2.2
|
williamr@2
|
260 |
of the AVC specification, equal to EFalse indicates that the bitstream may or may not obey the
|
williamr@2
|
261 |
constraints. The value is equal to ETrue (EFalse) if the syntax element constraint_set1_flag is
|
williamr@2
|
262 |
equal to 1 (0).
|
williamr@2
|
263 |
*/
|
williamr@2
|
264 |
TBool iMainProfileConstraintSet;
|
williamr@2
|
265 |
|
williamr@2
|
266 |
/**
|
williamr@2
|
267 |
Equal to ETrue indicates that the bitstream obeys all constraints specified in subclause A.2.3
|
williamr@2
|
268 |
of the AVC specification, equal to EFalse indicates that the bitstream may or may not obey the
|
williamr@2
|
269 |
constraints. The value is equal to ETrue (EFalse) if the syntax element constraint_set2_flag is
|
williamr@2
|
270 |
equal to 1 (0).
|
williamr@2
|
271 |
*/
|
williamr@2
|
272 |
TBool iExtendedProfileConstraintSet;
|
williamr@2
|
273 |
|
williamr@2
|
274 |
/**
|
williamr@2
|
275 |
Indicates the picture type. iPictureType is set as one of the values defined in TAvcPictureType.
|
williamr@2
|
276 |
*/
|
williamr@2
|
277 |
TAvcPictureType iPictureType;
|
williamr@2
|
278 |
|
williamr@2
|
279 |
/**
|
williamr@2
|
280 |
iLongTermPicture equal to ETrue indicates that the picture is a long-term picture, i.e., it has
|
williamr@2
|
281 |
been marked as "used for long-term reference" according to the decoded reference picture marking
|
williamr@2
|
282 |
process as specified in subclause 8.2.5 of the AVC specification. Otherwise the picture is not a
|
williamr@2
|
283 |
long-term picture.
|
williamr@2
|
284 |
*/
|
williamr@2
|
285 |
TBool iLongTermPicture;
|
williamr@2
|
286 |
|
williamr@2
|
287 |
/**
|
williamr@2
|
288 |
Indicates whether the picture is a frame or a field. iFrame is equal to ETrue if the picture is
|
williamr@2
|
289 |
a frame (field_pic_flag is equal to 0), EFalse if the picture is a field (field_pic_flag is equal
|
williamr@2
|
290 |
to 1).
|
williamr@2
|
291 |
*/
|
williamr@2
|
292 |
TBool iFrame;
|
williamr@2
|
293 |
|
williamr@2
|
294 |
/**
|
williamr@2
|
295 |
Valid only if iFrame is equal to EFalse. Indicates whether the field picture is a top field or a
|
williamr@2
|
296 |
bottom field. iTopField is equal to ETrue if the picture is a top field (bottom_field_flag is
|
williamr@2
|
297 |
equal to 0), EFalse if the picture is a bottom field (bottom_field_flag is equal to 0).
|
williamr@2
|
298 |
*/
|
williamr@2
|
299 |
TBool iTopField;
|
williamr@2
|
300 |
|
williamr@2
|
301 |
/**
|
williamr@2
|
302 |
Indicates the picture order count of the top field of a frame, the top field of a complementary
|
williamr@2
|
303 |
field pair, or a top field. iTopFieldOrderCount is equal to the value of TopFieldOrderCnt as
|
williamr@2
|
304 |
specified in subclause 8.2.1 of the AVC specification.
|
williamr@2
|
305 |
*/
|
williamr@2
|
306 |
TUint iTopFieldOrderCount;
|
williamr@2
|
307 |
|
williamr@2
|
308 |
/**
|
williamr@2
|
309 |
Indicates the picture order count of the bottom field of a frame, the bottom field of a
|
williamr@2
|
310 |
complementary field pair, or a bottom field. iBottomFieldOrderCount is equal to the value of
|
williamr@2
|
311 |
BottomFieldOrderCnt as specified in subclause 8.2.1 of the AVC specification.
|
williamr@2
|
312 |
*/
|
williamr@2
|
313 |
TUint iBottomFieldOrderCount;
|
williamr@2
|
314 |
|
williamr@2
|
315 |
/**
|
williamr@2
|
316 |
Equal to ETrue indicates that the picture is an Instantaneous Decoding Refresh (IDR) picture;
|
williamr@2
|
317 |
otherwise the picture is not an IDR picture. The value of nal_unit_type of all the Video Coding
|
williamr@2
|
318 |
Layer (VCL) NAL units of the primary coded picture of an IDR picture shall be equal to 5.
|
williamr@2
|
319 |
*/
|
williamr@2
|
320 |
TBool iIdrPicture;
|
williamr@2
|
321 |
|
williamr@2
|
322 |
/**
|
williamr@2
|
323 |
Indicates the initial value of the quantization parameter. If iPictureType is equal to
|
williamr@2
|
324 |
EAvcPictureTypeSI or EavcPictureTypeSP, iPQY is equal to pic_init_qs_minus26 + 26; otherwise
|
williamr@2
|
325 |
iPQY is equal to pic_init_qp_minus26 + 26.
|
williamr@2
|
326 |
*/
|
williamr@2
|
327 |
TUint iQPY;
|
williamr@2
|
328 |
|
williamr@2
|
329 |
/**
|
williamr@2
|
330 |
Pixel aspect ratio numerator. The pixel aspect ratio is defined as
|
williamr@2
|
331 |
iAspectRatioNum/iAspectRatioDenom, where the values are positive integers and relatively prime.
|
williamr@2
|
332 |
When aspect_ratio_idc is equal to 0 or sar_width is equal to 0 or sar_height is equal to 0, the
|
williamr@2
|
333 |
sample aspect ratio shall be considered unspecified, and iAspectRatioNum and iAspectRationDenom
|
williamr@2
|
334 |
are set to 0. When aspect_ratio_idc is equal to any of the value from 1 to 13, inclusive,
|
williamr@2
|
335 |
iAspectRatioNum and iAspectRatioDenom are set according to Table E-1 of the AVC specification.
|
williamr@2
|
336 |
When aspect_ratio_idc is equal to 255 (Extended_SAR), iAspectRatioNum is set to sar_width and
|
williamr@2
|
337 |
iAspectRatioDenom is set to sar_height.
|
williamr@2
|
338 |
*/
|
williamr@2
|
339 |
TUint iAspectRatioNum;
|
williamr@2
|
340 |
|
williamr@2
|
341 |
/**
|
williamr@2
|
342 |
Pixel aspect ratio denominator. The pixel aspect ratio is defined as
|
williamr@2
|
343 |
iAspectRatioNum/iAspectRatioDenom, where the values are positive integers and relatively prime.
|
williamr@2
|
344 |
When aspect_ratio_idc is equal to 0 or sar_width is equal to 0 or sar_height is equal to 0, the
|
williamr@2
|
345 |
sample aspect ratio shall be considered unspecified, and iAspectRatioNum and iAspectRationDenom
|
williamr@2
|
346 |
are set to 0. When aspect_ratio_idc is equal to any of the value from 1 to 13, inclusive,
|
williamr@2
|
347 |
iAspectRatioNum and iAspectRatioDenom are set according to Table E-1 of the AVC specification.
|
williamr@2
|
348 |
When aspect_ratio_idc is equal to 255 (Extended_SAR), iAspectRatioNum is set to sar_width and
|
williamr@2
|
349 |
iAspectRatioDenom is set to sar_height.
|
williamr@2
|
350 |
*/
|
williamr@2
|
351 |
TUint iAspectRatioDenom;
|
williamr@2
|
352 |
|
williamr@2
|
353 |
/**
|
williamr@2
|
354 |
Indicates the frame cropping rectangle as specified in subclause 7.4.2.1 of the AVC specification.
|
williamr@2
|
355 |
*/
|
williamr@2
|
356 |
TRect iFrameCropRect;
|
williamr@2
|
357 |
|
williamr@2
|
358 |
/**
|
williamr@2
|
359 |
Equal to 0 indicates that the cropped (according to the frame cropping rectangle) decoded
|
williamr@2
|
360 |
pictures output contain visually important information in the entire region out to the edges of
|
williamr@2
|
361 |
the cropping rectangle of the picture, such that the cropped decoded pictures output should not
|
williamr@2
|
362 |
be displayed using overscan. Instead, they should be displayed using either an exact match
|
williamr@2
|
363 |
between the display area and the cropping rectangle, or using underscan. Equal to 1 indicates
|
williamr@2
|
364 |
that the cropped decoded picture output is suitable for display using overscan. Otherwise, it is
|
williamr@2
|
365 |
unspecified whether the cropped decoded picture output is suitable for display using overscan or
|
williamr@2
|
366 |
not.
|
williamr@2
|
367 |
*/
|
williamr@2
|
368 |
TUint iOverscanInfo;
|
williamr@2
|
369 |
|
williamr@2
|
370 |
/**
|
williamr@2
|
371 |
Indicates the representation of the pictures as specified in Table E-2 of the AVC specification,
|
williamr@2
|
372 |
before being coded.
|
williamr@2
|
373 |
*/
|
williamr@2
|
374 |
TUint iVideoFormat;
|
williamr@2
|
375 |
|
williamr@2
|
376 |
/**
|
williamr@2
|
377 |
Indicates whether a picture should be displayed as a frame or one or more fields, according to
|
williamr@2
|
378 |
Table D-1. iPictureStructure is equal to the syntax element pic_struct.
|
williamr@2
|
379 |
*/
|
williamr@2
|
380 |
TUint iPictureStructure;
|
williamr@2
|
381 |
|
williamr@2
|
382 |
/**
|
williamr@2
|
383 |
Each picture has up to NumClockTS sets of clock timestamp information. The value of NumClockTS
|
williamr@2
|
384 |
is as specified in Table D-1 of the AVC specification, with a maximum value equal to 3. Each
|
williamr@2
|
385 |
instance of iClockTimestamp[i] indicates a time of origin, capture, or alternative ideal display,
|
williamr@2
|
386 |
in units of microseconds. iClockTimestamp[i] is equal to
|
williamr@2
|
387 |
(clockTimestamp[i] / time_scale * 1000000), where clockTimestamp[i] is the i-th set of clock
|
williamr@2
|
388 |
timestamp information as specified in subclause D.2.2 of the AVC specification.
|
williamr@2
|
389 |
iClockTimestamp[i] where i is larger than NumClockTS-1 is invalid. When picture timing
|
williamr@2
|
390 |
information is not available, NumClockTS is set to zero.
|
williamr@2
|
391 |
*/
|
williamr@2
|
392 |
TTimeIntervalMicroSeconds iClockTimestamp[3];
|
williamr@2
|
393 |
};
|
williamr@2
|
394 |
|
williamr@2
|
395 |
/**
|
williamr@2
|
396 |
This class is used to signal decoder or encoder capabilities or bitstream properties.
|
williamr@2
|
397 |
@publishedAll
|
williamr@2
|
398 |
@released
|
williamr@2
|
399 |
*/
|
williamr@2
|
400 |
class TAvcVideoCapability
|
williamr@2
|
401 |
{
|
williamr@2
|
402 |
public:
|
williamr@2
|
403 |
/**
|
williamr@2
|
404 |
When used as part of a codec capability indication, iProfileLevel[ProfileIdc] indicates the
|
williamr@2
|
405 |
maximum processing level that a decoder or an encoder supports for a particular profile set
|
williamr@2
|
406 |
indicated by ProfileIdc (the indication is described below). A negative value indicates that
|
williamr@2
|
407 |
the profile set is not supported. When used as part of a stream property indication,
|
williamr@2
|
408 |
iProfileLevel[ProfileIdc] indicates the maximum processing level that is present in the stream
|
williamr@2
|
409 |
for a particular profile set indicated by ProfileIdc. A negative value indicates that the stream
|
williamr@2
|
410 |
does not contain data coded according to the indicated profile set.
|
williamr@2
|
411 |
|
williamr@2
|
412 |
ProfileIdc equal to 0 indicates that all of constraint_set0_flag, constraint_set1_flag and
|
williamr@2
|
413 |
constraint_set2_flag are equal to 1, and profile_idc may indicate any of the profiles (baseline,
|
williamr@2
|
414 |
main or extended). ProfileIdc equal to 1 indicates that constraint_set0_flag and
|
williamr@2
|
415 |
constraint_set2_flag are equal to 1 while constraint_set1_flag is equal to 0, and
|
williamr@2
|
416 |
profile_idc may indicate either the baseline or extended profile. ProfileIdc equal to 2
|
williamr@2
|
417 |
indicates that constraint_set1_flag and constraint_set2_flag are equal to 1 while
|
williamr@2
|
418 |
constraint_set0_flag is equal to 0, and profile_idc may indicate either the main or extended
|
williamr@2
|
419 |
profile. ProfileIdc equal to 3 indicates that constraint_set1_flag is equal to 1 while the other
|
williamr@2
|
420 |
two flags are equal to 0, and profile_idc indicates the main profile. ProfileIdc equal to 4
|
williamr@2
|
421 |
indicates that constraint_set2_flag is equal to 1 while the other two flags are equal to 0, and
|
williamr@2
|
422 |
profile_idc indicates the extended profile.
|
williamr@2
|
423 |
*/
|
williamr@2
|
424 |
TInt iProfileLevel[5];
|
williamr@2
|
425 |
|
williamr@2
|
426 |
/**
|
williamr@2
|
427 |
iSupplementalInformationCap indicates the supported supplemental enhancement functions. The
|
williamr@2
|
428 |
value is a binary OR of values from TAvcSupplementalInformation.
|
williamr@2
|
429 |
*/
|
williamr@2
|
430 |
TUint32 iSupplementalInformationCap;
|
williamr@2
|
431 |
};
|
williamr@2
|
432 |
|
williamr@2
|
433 |
|
williamr@2
|
434 |
/**
|
williamr@2
|
435 |
This class is used to set the encoder operation mode.
|
williamr@2
|
436 |
@publishedAll
|
williamr@2
|
437 |
@released
|
williamr@2
|
438 |
*/
|
williamr@2
|
439 |
class TAvcVideoMode
|
williamr@2
|
440 |
{
|
williamr@2
|
441 |
public:
|
williamr@2
|
442 |
/**
|
williamr@2
|
443 |
Specifies the picture types allowed in the bitstream. The value is a binary OR of values from
|
williamr@2
|
444 |
TAvcPictureType. Signaled picture types that are not included in the prevailing coding profile
|
williamr@2
|
445 |
are ignored.
|
williamr@2
|
446 |
*/
|
williamr@2
|
447 |
TUint32 iAllowedPictureTypes;
|
williamr@2
|
448 |
|
williamr@2
|
449 |
/**
|
williamr@2
|
450 |
Specifies whether Flexible Macroblock Order (FMO) is allowed. Equal to ETrue indicates that
|
williamr@2
|
451 |
num_slice_groups_minus1 is in the range of 0 to 7, inclusive, i.e. FMO is allowed. Equal to
|
williamr@2
|
452 |
EFalse indicates that num_slice_groups_minus1 shall be equal to 0 only, i.e., FMO is not allowed.
|
williamr@2
|
453 |
*/
|
williamr@2
|
454 |
TBool iFlexibleMacroblockOrder;
|
williamr@2
|
455 |
|
williamr@2
|
456 |
/**
|
williamr@2
|
457 |
Specifies whether redundant pictures may be encoded. Equal to ETrue indicates that
|
williamr@2
|
458 |
redundant_pic_cnt_present_flag can be equal to either 0 or 1 (i.e., redundant pictures may be
|
williamr@2
|
459 |
encoded), while Equal to EFalse indicates that redundant_pic_cnt_present_flag shall be equal to
|
williamr@2
|
460 |
0 only (i.e., redundant pictures cannot be encoded).
|
williamr@2
|
461 |
*/
|
williamr@2
|
462 |
TBool iRedundantPictures;
|
williamr@2
|
463 |
|
williamr@2
|
464 |
/**
|
williamr@2
|
465 |
Specifies whether data partitioning is in use. When equal to ETrue, data partitioning is in use,
|
williamr@2
|
466 |
i.e., NAL unit streams can contain nal_unit_type values in the range of 2 to 4, inclusive. When
|
williamr@2
|
467 |
equal to EFalse, data partitioning is not in use, i.e., NAL unit streams shall not contain
|
williamr@2
|
468 |
nal_unit_type values in the range of 2 to 4, inclusive. If data partitioning is in use, the
|
williamr@2
|
469 |
SetErrorProtectionLevelsL method, if used, should set the number of unequal error protection
|
williamr@2
|
470 |
levels to be larger than one.
|
williamr@2
|
471 |
*/
|
williamr@2
|
472 |
TBool iDataPartitioning;
|
williamr@2
|
473 |
|
williamr@2
|
474 |
/**
|
williamr@2
|
475 |
iFrameMBsOnly equal to ETrue specifies that every coded picture of the coded video sequence is a
|
williamr@2
|
476 |
coded frame containing only frame macroblocks. Equal to EFalse specifies that coded pictures of
|
williamr@2
|
477 |
the coded video sequence may either be coded fields or coded frames.
|
williamr@2
|
478 |
*/
|
williamr@2
|
479 |
TBool iFrameMBsOnly;
|
williamr@2
|
480 |
|
williamr@2
|
481 |
/**
|
williamr@2
|
482 |
iMBAFFCoding equal to EFalse specifies no switching between frame and field
|
williamr@2
|
483 |
macroblocks within a picture. Equal to ETrue specifies the possible use of switching between
|
williamr@2
|
484 |
frame and field macroblocks within frames. Valid only when iFrameMBsOnly is equal to EFalse.
|
williamr@2
|
485 |
*/
|
williamr@2
|
486 |
TBool iMBAFFCoding;
|
williamr@2
|
487 |
|
williamr@2
|
488 |
/**
|
williamr@2
|
489 |
Specifies the entropy decoding method to be applied for the syntax elements for which two
|
williamr@2
|
490 |
descriptors appear in the syntax tables. Equal to EFalse indicates that Exp-Golomb codes or
|
williamr@2
|
491 |
CAVLC (Context-based Adaptive Variable Length Coding), as described in subclause 9.1 or 9.2 of
|
williamr@2
|
492 |
the AVC specification, is applied. Otherwise, CABAC (Context-based Adaptive Binary Arithmetic
|
williamr@2
|
493 |
Coding) as described in subclause 9.3 of the AVC specification is applied.
|
williamr@2
|
494 |
*/
|
williamr@2
|
495 |
TBool iEntropyCodingCABAC;
|
williamr@2
|
496 |
|
williamr@2
|
497 |
/**
|
williamr@2
|
498 |
Equal to EFalse specifies that weighted prediction shall not be applied to P and SP slices.
|
williamr@2
|
499 |
Equal to ETrue specifies that weighted prediction may be applied to P and SP slices.
|
williamr@2
|
500 |
*/
|
williamr@2
|
501 |
TBool iWeightedPPrediction;
|
williamr@2
|
502 |
|
williamr@2
|
503 |
/**
|
williamr@2
|
504 |
Equal to 0 specifies that the default weighted prediction is applied to B slices. Equal to 1
|
williamr@2
|
505 |
specifies that explicit weighted prediction is applied to B slices. Equal to 2 specifies that
|
williamr@2
|
506 |
implicit weighted prediction is applied to B slices.
|
williamr@2
|
507 |
*/
|
williamr@2
|
508 |
TUint iWeightedBipredicitonMode;
|
williamr@2
|
509 |
|
williamr@2
|
510 |
/**
|
williamr@2
|
511 |
Specifies the method used in the derivation process for luma motion vectors for B_Skip,
|
williamr@2
|
512 |
B_Direct_16x16 and B_Direct_8x8 as specified in subclause 8.4.1.2 of the AVC specification. When
|
williamr@2
|
513 |
iFrameMBsOnly is equal to EFalse, iDirect8x8Inference shall be equal to ETrue.
|
williamr@2
|
514 |
*/
|
williamr@2
|
515 |
TBool iDirect8x8Inference;
|
williamr@2
|
516 |
};
|
williamr@2
|
517 |
|
williamr@2
|
518 |
/**
|
williamr@2
|
519 |
TAvcHrdParams specifies a set of AVC-specific HRD parameters. All pointers included in the objects
|
williamr@2
|
520 |
have the same lifetime as the objects themselves, and the memory is allocated and deallocated by
|
williamr@2
|
521 |
the same instance that creates and owns the object.
|
williamr@2
|
522 |
@publishedAll
|
williamr@2
|
523 |
@released
|
williamr@2
|
524 |
*/
|
williamr@2
|
525 |
class TAvcHrdParams
|
williamr@2
|
526 |
{
|
williamr@2
|
527 |
public:
|
williamr@2
|
528 |
class TCpbParams
|
williamr@2
|
529 |
{
|
williamr@2
|
530 |
public:
|
williamr@2
|
531 |
/**
|
williamr@2
|
532 |
Specifies the delay for a CPB between the time of arrival in the CPB of the first bit of the
|
williamr@2
|
533 |
coded data associated with the access unit associated with the buffering period SEI message
|
williamr@2
|
534 |
and the time of removal from the CPB of the coded data associated with the same access unit,
|
williamr@2
|
535 |
for the first buffering period after HRD initialisation. It is in units of a 90 kHz clock.
|
williamr@2
|
536 |
The value is equal to the corresponding initinal_cpb_removal_delay of the NAL HRD parameters
|
williamr@2
|
537 |
if the current parameter is for the NAL HRD or of the VCL HRD parameters if the current
|
williamr@2
|
538 |
parameter is for the VCL HRD.
|
williamr@2
|
539 |
*/
|
williamr@2
|
540 |
TUint iInitialCpbRemovalDelay;
|
williamr@2
|
541 |
|
williamr@2
|
542 |
/**
|
williamr@2
|
543 |
This parameter is used for a CPB in combination with the cpb_removal_delay to specify the
|
williamr@2
|
544 |
initial delivery time of coded access units to the CPB. It is in units of a 90 kHz clock.
|
williamr@2
|
545 |
The value is equal to the corresponding initinal_cpb_removal_delay_offset of the NAL HRD
|
williamr@2
|
546 |
parameters if the current parameter is for the NAL HRD or of the VCL HRD parameters if the
|
williamr@2
|
547 |
current parameter is for the VCL HRD.
|
williamr@2
|
548 |
|
williamr@2
|
549 |
Note: Over the entire coded video sequence, the sum of iInitialCpbRemovalDelay and the
|
williamr@2
|
550 |
corresponding iInitialCpbRemovalDelayOffset shall be constant for either the NAL HRD
|
williamr@2
|
551 |
parameters or the VCL HRD parameters.
|
williamr@2
|
552 |
*/
|
williamr@2
|
553 |
TUint iInitialCpbRemovalDelayOffset;
|
williamr@2
|
554 |
|
williamr@2
|
555 |
/**
|
williamr@2
|
556 |
Equal to EFalse specifies that to decode this bitstream by the HRD using the CPB
|
williamr@2
|
557 |
specification, the hypothetical stream scheduler (HSS) operates in an intermittent bit
|
williamr@2
|
558 |
rate mode. Equal to 1 specifies that the HSS operates in a constant bit rate (CBR) mode.
|
williamr@2
|
559 |
*/
|
williamr@2
|
560 |
TBool iCbr;
|
williamr@2
|
561 |
|
williamr@2
|
562 |
/**
|
williamr@2
|
563 |
Specifies the maximum input bit rate, in bits per second, of a CPB. The value is equal to
|
williamr@2
|
564 |
Bitrate as specified in subclause E.2.2 of the AVC specification.
|
williamr@2
|
565 |
*/
|
williamr@2
|
566 |
TUint iBitrate;
|
williamr@2
|
567 |
|
williamr@2
|
568 |
/**
|
williamr@2
|
569 |
Specifies the size, in bytes, of a CPB. The value is equal to CpbSize/8, where CpbSize is as
|
williamr@2
|
570 |
specified in subclause E.2.2 of the AVC specification.
|
williamr@2
|
571 |
*/
|
williamr@2
|
572 |
TUint iCpbSize;
|
williamr@2
|
573 |
};
|
williamr@2
|
574 |
|
williamr@2
|
575 |
/**
|
williamr@2
|
576 |
Specifies the required size of the decoded picture buffer (DPB) in unit of bytes. The value is
|
williamr@2
|
577 |
equal to max_dec_frame_buffering* PicWidthInSamplesL*FrameHeightInMbs*2, where PicWidthInSamplesL
|
williamr@2
|
578 |
and FrameHeightInMbs are specified in subclause 7.4.2.1 of the AVC specification amd the syntax
|
williamr@2
|
579 |
element max_dec_frame_buffering as specified in subclause E.2.1 of the AVC specification.
|
williamr@2
|
580 |
*/
|
williamr@2
|
581 |
TUint iDpbSize;
|
williamr@2
|
582 |
|
williamr@2
|
583 |
/**
|
williamr@2
|
584 |
Specifies the HRD operational mode as specified in Annex C of the AVC specification. The value
|
williamr@2
|
585 |
of LowDelayHrd is equal to ETrue if the syntax element low_delay_hrd_flag is equal to 1, and
|
williamr@2
|
586 |
EFalse otherwise. This parameter is valid only if at least one of iNalCpbCount and iVclCpbCount
|
williamr@2
|
587 |
is larger than 0.
|
williamr@2
|
588 |
*/
|
williamr@2
|
589 |
TBool iLowDelayHrd;
|
williamr@2
|
590 |
|
williamr@2
|
591 |
/**
|
williamr@2
|
592 |
Specifies the number of alternative coded picture buffer (CPB) specifications for NAL HRD
|
williamr@2
|
593 |
parameters in the bitstream. The value of iNalCpbCount is equal to cpb_cnt_minus1 + 1 in the
|
williamr@2
|
594 |
NAL HRD parameters, if present. iNalCpbCount equal to 0 means that NAL HRD parameters are not
|
williamr@2
|
595 |
present.
|
williamr@2
|
596 |
*/
|
williamr@2
|
597 |
TUint iNalCpbCount;
|
williamr@2
|
598 |
|
williamr@2
|
599 |
/**
|
williamr@2
|
600 |
Valid only if iNalCpbCount is larger than zero. iNalCpbParams is a pointer to an object of
|
williamr@2
|
601 |
TCpbParams, which contains the parameters of an alternative CPB.
|
williamr@2
|
602 |
*/
|
williamr@2
|
603 |
TCpbParams* iNalCpbParams;
|
williamr@2
|
604 |
|
williamr@2
|
605 |
/**
|
williamr@2
|
606 |
Specifies the number of alternative coded picture buffer (CPB) specifications for VCL HRD
|
williamr@2
|
607 |
parameters in the bitstream. The value of iVclCpbCount is equal to cpb_cnt_minus1 + 1 in the
|
williamr@2
|
608 |
VCL HRD parameters, if present. iVclCpbCount equal to 0 means that VCL HRD parameters are not
|
williamr@2
|
609 |
present.
|
williamr@2
|
610 |
*/
|
williamr@2
|
611 |
TUint iVclCpbCount;
|
williamr@2
|
612 |
|
williamr@2
|
613 |
/**
|
williamr@2
|
614 |
Valid only if iVclCpbCount is larger than zero. iVclCpbParams is a pointer to an object of
|
williamr@2
|
615 |
TCpbParams, which contains the parameters of an alternative CPB.
|
williamr@2
|
616 |
*/
|
williamr@2
|
617 |
TCpbParams* iVclCpbParams;
|
williamr@2
|
618 |
};
|
williamr@2
|
619 |
|
williamr@2
|
620 |
|
williamr@2
|
621 |
|
williamr@2
|
622 |
|
williamr@2
|
623 |
|
williamr@2
|
624 |
#endif
|