os/mm/mmhais/videohai/devvideo/inc/H263.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
sl@0
     1
// Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
sl@0
     2
// All rights reserved.
sl@0
     3
// This component and the accompanying materials are made available
sl@0
     4
// under the terms of "Eclipse Public License v1.0"
sl@0
     5
// which accompanies this distribution, and is available
sl@0
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     7
//
sl@0
     8
// Initial Contributors:
sl@0
     9
// Nokia Corporation - initial contribution.
sl@0
    10
//
sl@0
    11
// Contributors:
sl@0
    12
//
sl@0
    13
// Description:
sl@0
    14
// Constants and structs specific to H.263.  See the DevVideo specs for more details.
sl@0
    15
// 
sl@0
    16
//
sl@0
    17
sl@0
    18
#ifndef __DEVVIDEO_H263_H__
sl@0
    19
#define __DEVVIDEO_H263_H__
sl@0
    20
sl@0
    21
#include <e32base.h>
sl@0
    22
sl@0
    23
sl@0
    24
/**
sl@0
    25
Specifies the H263 picture type.
sl@0
    26
@publishedAll
sl@0
    27
@released
sl@0
    28
*/
sl@0
    29
enum TH263PictureType
sl@0
    30
    {
sl@0
    31
	/**INTRA picture*/
sl@0
    32
    EH263PictureTypeI   = 0x01,
sl@0
    33
	/**INTER picture*/
sl@0
    34
    EH263PictureTypeP   = 0x02,
sl@0
    35
	/**B picture according to H.263 Annex O*/
sl@0
    36
    EH263PictureTypeB   = 0x04,
sl@0
    37
	/**EI picture according to H.263 Annex O*/
sl@0
    38
    EH263PictureTypeEI  = 0x08,
sl@0
    39
	/**EP picture according to H.263 Annex O*/
sl@0
    40
    EH263PictureTypeEP  = 0x10
sl@0
    41
    };
sl@0
    42
sl@0
    43
/**
sl@0
    44
These enumerations can be used in codec capability indication and/or bitstream property indication.
sl@0
    45
When used as part of an encoder capability indication, a signalled value indicates the capability
sl@0
    46
of an encoder to produce such supplemental information to the bitstream and the additional meanings
sl@0
    47
as specified below. When used as part of a decoder capability indication, a signalled value 
sl@0
    48
indicates the capability of a decoder to react to such supplemental information in a way as 
sl@0
    49
specified below. If a decoder does not have such capability, it shall be able to parse and discard
sl@0
    50
the supplemental information. When used as part of a bitstream property indication, a non-signalled
sl@0
    51
value indicates the absence of such information in the bitstream and a signalled value indicates 
sl@0
    52
the possibility of having such information in the bitstream.
sl@0
    53
@publishedAll
sl@0
    54
@released
sl@0
    55
*/
sl@0
    56
enum TH263SupplementalInformation
sl@0
    57
    {
sl@0
    58
	/**
sl@0
    59
	encoder capability:	no meaning
sl@0
    60
	decoder capability:	no meaning
sl@0
    61
	bitstream property:	existence of FTYPE equal to 1
sl@0
    62
	*/
sl@0
    63
    EH263SEIDoNothing			 					= 0x00000001,
sl@0
    64
sl@0
    65
	/**
sl@0
    66
	encoder capability:	no meaning
sl@0
    67
	decoder capability:	capability to freeze displayed picture according to subclause L.4 of H.263capability to release frozen displayed picture as a response to bit 5 of PTYPE
sl@0
    68
	bitstream property:	existence of FTYPE equal to 2
sl@0
    69
	*/
sl@0
    70
    EH263SEIFullPictureFreeze            			= 0x00000002,
sl@0
    71
sl@0
    72
	/**
sl@0
    73
	encoder capability:	no meaning
sl@0
    74
	decoder capability:	capability to freeze displayed picture partially (subclause L.5 of H.263)
sl@0
    75
	bitstream property:	existence of FTYPE equal to 3
sl@0
    76
	*/
sl@0
    77
    EH263SEIPartialPictureFreeze         			= 0x00000004,
sl@0
    78
sl@0
    79
	/**
sl@0
    80
	encoder capability:	no meaning
sl@0
    81
	decoder capability:	capability to freeze and resize displayed picture partially (H.263 L.6)
sl@0
    82
	bitstream property:	existence of FTYPE equal to 4
sl@0
    83
	*/
sl@0
    84
    EH263SEIResizingPartialPictureFreeze 			= 0x00000008,
sl@0
    85
sl@0
    86
	/**
sl@0
    87
	encoder capability:	no meaning
sl@0
    88
	decoder capability:	capability to release partially frozen picture (subclause L.7 of H.263)
sl@0
    89
	bitstream property:	existence of FTYPE equal to 5
sl@0
    90
	*/
sl@0
    91
    EH263SEIPartialPictureFreezeRelease  			= 0x00000010,
sl@0
    92
	
sl@0
    93
	/**
sl@0
    94
	encoder capability:	no meaning
sl@0
    95
	decoder capability:	no meaning
sl@0
    96
	bitstream property:	existence of FTYPE equal to 6
sl@0
    97
	*/
sl@0
    98
    EH263SEIFullPictureSnapshotTag       			= 0x00000020,
sl@0
    99
	
sl@0
   100
	/**
sl@0
   101
	encoder capability:	no meaning
sl@0
   102
	decoder capability:	no meaning
sl@0
   103
	bitstream property:	existence of FTYPE equal to 7
sl@0
   104
	*/
sl@0
   105
    EH263SEIPartialPictureSnapshotTag    			= 0x00000040,
sl@0
   106
	
sl@0
   107
	/**
sl@0
   108
	encoder capability:	no meaning
sl@0
   109
	decoder capability:	no meaning
sl@0
   110
	bitstream property:	existence of FTYPE equal to 8
sl@0
   111
	*/
sl@0
   112
    EH263SEIVideoTimeSegmentStartTag     			= 0x00000080,
sl@0
   113
	
sl@0
   114
	/**
sl@0
   115
	encoder capability:	no meaning
sl@0
   116
	decoder capability:	no meaning
sl@0
   117
	bitstream property:	existence of FTYPE equal to 9
sl@0
   118
	*/
sl@0
   119
    EH263SEIVideoTimeSegmentEndTag       			= 0x00000100,
sl@0
   120
	
sl@0
   121
	/**
sl@0
   122
	encoder capability:	no meaning
sl@0
   123
	decoder capability:	no meaning
sl@0
   124
	bitstream property:	existence of FTYPE equal to 10
sl@0
   125
	*/
sl@0
   126
    EH263SEIProgressiveRefinementStartTag   		= 0x00000200,
sl@0
   127
	
sl@0
   128
	/**
sl@0
   129
	encoder capability:	no meaning
sl@0
   130
	decoder capability:	no meaning
sl@0
   131
	bitstream property:	existence of FTYPE equal to 11
sl@0
   132
	*/
sl@0
   133
    EH263SEIProgressiveRefinementEndTag     		= 0x00000400,
sl@0
   134
	
sl@0
   135
	/**
sl@0
   136
	encoder capability:	no meaning
sl@0
   137
	decoder capability:	operation according to sublause L.14 of H.263
sl@0
   138
	bitstream property:	existence of FTYPE equal to 12
sl@0
   139
	*/
sl@0
   140
    EH263SEIChromaKeying                 			= 0x00000800,
sl@0
   141
	
sl@0
   142
	/**
sl@0
   143
	encoder capability:	use of the fixed-point IDCT algorithm specified in Annex W of H.263
sl@0
   144
	decoder capability:	use of the fixed-point IDCT algorithm specified in Annex W of H.263
sl@0
   145
	bitstream property:	existence of FTYPE equal to 13
sl@0
   146
	*/
sl@0
   147
    EH263SEIFixedPointIDCT               			= 0x00001000,
sl@0
   148
	
sl@0
   149
	/**
sl@0
   150
	encoder capability:	no meaning
sl@0
   151
	decoder capability:	no meaning
sl@0
   152
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 0
sl@0
   153
	*/
sl@0
   154
    EH263SEIArbitraryBinaryData          			= 0x00002000,
sl@0
   155
	
sl@0
   156
	/**
sl@0
   157
	encoder capability:	no meaning
sl@0
   158
	decoder capability:	no meaning
sl@0
   159
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 1
sl@0
   160
	*/
sl@0
   161
    EH263SEIArbitraryText                   		= 0x00004000,
sl@0
   162
	
sl@0
   163
	/**
sl@0
   164
	encoder capability:	no meaning
sl@0
   165
	decoder capability:	no meaning
sl@0
   166
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 2
sl@0
   167
	*/
sl@0
   168
    EH263SEICopyrightText                   		= 0x00008000,
sl@0
   169
	
sl@0
   170
	/**
sl@0
   171
	encoder capability:	no meaning
sl@0
   172
	decoder capability:	capability of display caption text as specified in subclause W.6.3.5 of H.263
sl@0
   173
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 3
sl@0
   174
	*/
sl@0
   175
    EH263SEICaptionText                     		= 0x00010000,
sl@0
   176
	
sl@0
   177
	/**
sl@0
   178
	encoder capability:	no meaning
sl@0
   179
	decoder capability:	no meaning
sl@0
   180
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 4
sl@0
   181
	*/
sl@0
   182
    EH263SEIVideoDescriptionText            		= 0x00020000,
sl@0
   183
	
sl@0
   184
	/**
sl@0
   185
	encoder capability:	no meaning
sl@0
   186
	decoder capability:	no meaning
sl@0
   187
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 5
sl@0
   188
	*/
sl@0
   189
    EH263SEIUniformResourceIdentifierText   		= 0x00040000,
sl@0
   190
	
sl@0
   191
	/**
sl@0
   192
	encoder capability:	capability to repeat the current picture header (subclause W.6.3.7 of H.263)
sl@0
   193
	decoder capability:	capability to recover a corrupted picture header with a repeated one
sl@0
   194
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 6
sl@0
   195
	*/
sl@0
   196
    EH263SEICurrentPictureHeaderRepetition  		= 0x00080000,
sl@0
   197
	
sl@0
   198
	/**
sl@0
   199
	encoder capability:	capability to repeat the previous picture header (subclause W.6.3.8 of H.263)
sl@0
   200
	decoder capability:	capability to recover a corrupted or lost picture header with a repeated one
sl@0
   201
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 7
sl@0
   202
	*/
sl@0
   203
    EH263SEIPreviousPictureHeaderRepetition 		= 0x00100000,
sl@0
   204
	
sl@0
   205
	/**
sl@0
   206
	encoder capability:	capability to repeat the next picture header (W.6.3.9 of H.263)
sl@0
   207
	decoder capability:	capability to recover a corrupted or lost picture header with a repeated one
sl@0
   208
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 8
sl@0
   209
	*/
sl@0
   210
    EH263SEINextPictureHeaderRepetitionReliableTR  	= 0x00200000,
sl@0
   211
	
sl@0
   212
	/**
sl@0
   213
	encoder capability:	capability to repeat the next picture header (W.6.3.10 of H.263)
sl@0
   214
	decoder capability:	capability to recover a corrupted or lost picture header with a repeated one
sl@0
   215
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 9
sl@0
   216
	*/
sl@0
   217
    EH263SEINextPictureHeaderRepetitionUnreliableTR	= 0x00400000,
sl@0
   218
	
sl@0
   219
	/**
sl@0
   220
	encoder capability:	capability to encode top fields of interlaced pictures 
sl@0
   221
	decoder capability:	capability to decode and display top fields of interlaced pictures (W.6.3.11of H.263)
sl@0
   222
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 10
sl@0
   223
	*/
sl@0
   224
    EH263SEITopInterlacedFieldIndication		   	= 0x00800000,
sl@0
   225
	
sl@0
   226
	/**
sl@0
   227
	encoder capability:	capability to encode bottom fields of interlaced pictures 
sl@0
   228
	decoder capability:	capability to decode and display bottom fields of interlaced pictures (W.6.3.11of H.263)
sl@0
   229
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 10
sl@0
   230
	*/
sl@0
   231
    EH263SEIBottomInterlacedFieldIndication       	= 0x01000000,
sl@0
   232
	
sl@0
   233
	/**
sl@0
   234
	encoder capability:	capability to transmit picture numbers (subclause W.6.3.12 of H.263)
sl@0
   235
	decoder capability:	capability to indicate reference picture losses from missing picture numbers
sl@0
   236
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 12
sl@0
   237
	*/
sl@0
   238
    EH263SEIPictureNumber                   		= 0x02000000,
sl@0
   239
	
sl@0
   240
	/**
sl@0
   241
	encoder capability:	capability to generate spare reference picture information (W.6.3.13 of H.263)
sl@0
   242
	decoder capability:	capability to use a spare reference picture in absence of real reference picture
sl@0
   243
	bitstream property:	existence of FTYPE equal to 14 and MTYPE equal to 13
sl@0
   244
	*/
sl@0
   245
    EH263SEISpareReferencePictures          		= 0x04000000
sl@0
   246
    };
sl@0
   247
sl@0
   248
sl@0
   249
/**
sl@0
   250
H.263 picture header.
sl@0
   251
@publishedAll
sl@0
   252
@released
sl@0
   253
*/
sl@0
   254
class TH263PictureHeader
sl@0
   255
    {
sl@0
   256
public:
sl@0
   257
	/**
sl@0
   258
	Indicates the temporal reference. iTemporalReference is equal to the value of TR or the value
sl@0
   259
	of (ETR << 8) + TR if ETR is present in the picture header.
sl@0
   260
	*/
sl@0
   261
    TUint iTemporalReference;
sl@0
   262
sl@0
   263
	/**
sl@0
   264
	iLongTermPicture equal to ETrue indicates that the picture has been marked as a long-term
sl@0
   265
	picture according to the memory management control operation (MMCO) commands as specified 
sl@0
   266
	in Annex U of H.263. Otherwise the picture is not a long-term picture.
sl@0
   267
	*/
sl@0
   268
    TBool iLongTermPicture;
sl@0
   269
sl@0
   270
	/**
sl@0
   271
	iSplitScreen is equal to the value of bit 3 of PTYPE.
sl@0
   272
	*/
sl@0
   273
    TBool iSplitScreen;
sl@0
   274
sl@0
   275
	/**
sl@0
   276
	iDocumentCamera is equal to the value of bit 4 of PTYPE.
sl@0
   277
	*/
sl@0
   278
    TBool iDocumentCamera;
sl@0
   279
sl@0
   280
	/**
sl@0
   281
	iFreezePictureRelease is equal to the value of bit 5 of PTYPE.
sl@0
   282
	*/
sl@0
   283
    TBool iFreezePictureRelease;
sl@0
   284
sl@0
   285
	/**
sl@0
   286
	Indicates the picture coding type. iPictureType is set according to the picture header as one 
sl@0
   287
	of the values defined in TH263PictureType.
sl@0
   288
	*/
sl@0
   289
    TH263PictureType iPictureType;
sl@0
   290
sl@0
   291
	/**
sl@0
   292
	Indicates the initial value of the quantization parameter. iPQuant is equal to the value of 
sl@0
   293
	the PQUANT syntax element.
sl@0
   294
	*/
sl@0
   295
    TUint iPQuant;
sl@0
   296
sl@0
   297
	/**
sl@0
   298
	Indicates the presence of the extended PTYPE field in the picture layer. The extended PTYPE 
sl@0
   299
	field is specified in ITU-T Recommendation H.263 version 2 and later. iPlusPType is equal to 1 
sl@0
   300
	if bits 6 - 8 of PTYPE are equal to '111'. Otherwise, iPlusPType is equal to 0.
sl@0
   301
	*/
sl@0
   302
    TBool iPlusPType;
sl@0
   303
sl@0
   304
	/**
sl@0
   305
	Indicates the presence of the full extended PTYPE field in the picture layer. If iPlusPType is 
sl@0
   306
	EFalse, the value of of iUpdateFullExtendedPType is not valid. Otherwise, 
sl@0
   307
	iUpdateFullExtendedPType is equal to the value of the UFEP syntax element.
sl@0
   308
	*/
sl@0
   309
    TBool iUpdateFullExtendedPType;
sl@0
   310
sl@0
   311
	/**
sl@0
   312
	Pixel aspect ratio numerator and denominator respectively. The pixel aspect ratio is defined as
sl@0
   313
	iAspectRatioNum/iAspectRatioDenom, where the values are positive integers and relatively prime.
sl@0
   314
	If iPlusPType is equal to 0, or iPlusPType is ETrue and iUpdateFullExtendedPType is ETrue and 
sl@0
   315
	bits 1 - 3 of the OPPTYPE syntax element are not equal to '110', iAspectRatioNum shall be equal
sl@0
   316
	to 12 and iAspectRatioDenom shall be equal to 11 (as specified in subclause 4.1 of ITU-T 
sl@0
   317
	Recommendation H.263). If iPlusPType is ETrue and iUpdateFullExtendedPType is ETrue and bits
sl@0
   318
	1 - 3 of the OPPTYPE syntax element are equal to '110', the values of iAspectRatioNum and 
sl@0
   319
	iAspectRatioDenom are set as specified in subclauses 5.1.5 and 5.1.6 of ITU-T Recommendation
sl@0
   320
	H.263. Otherwise (iPlusPType is ETrue and iUpdateFullExtendedPType is EFalse), the values of
sl@0
   321
	iAspectRatioNum and iAspectRatioDenom are not valid.
sl@0
   322
	*/
sl@0
   323
    TUint iAspectRatioNum;
sl@0
   324
sl@0
   325
	/**
sl@0
   326
	Pixel aspect ratio numerator and denominator respectively. The pixel aspect ratio is defined as
sl@0
   327
	iAspectRatioNum/iAspectRatioDenom, where the values are positive integers and relatively prime.
sl@0
   328
	If iPlusPType is equal to 0, or iPlusPType is ETrue and iUpdateFullExtendedPType is ETrue and 
sl@0
   329
	bits 1 - 3 of the OPPTYPE syntax element are not equal to '110', iAspectRatioNum shall be equal
sl@0
   330
	to 12 and iAspectRatioDenom shall be equal to 11 (as specified in subclause 4.1 of ITU-T 
sl@0
   331
	Recommendation H.263). If iPlusPType is ETrue and iUpdateFullExtendedPType is ETrue and bits
sl@0
   332
	1 - 3 of the OPPTYPE syntax element are equal to '110', the values of iAspectRatioNum and 
sl@0
   333
	iAspectRatioDenom are set as specified in subclauses 5.1.5 and 5.1.6 of ITU-T Recommendation
sl@0
   334
	H.263. Otherwise (iPlusPType is ETrue and iUpdateFullExtendedPType is EFalse), the values of
sl@0
   335
	iAspectRatioNum and iAspectRatioDenom are not valid.
sl@0
   336
	*/
sl@0
   337
    TUint iAspectRatioDenom;
sl@0
   338
sl@0
   339
	/**
sl@0
   340
	Picture clock frequency numerator and denominator respectively. The picture clock frequency 
sl@0
   341
	for temporal reference is defined as iPictureClockFrequencyRate / iPictureClockFrequencyScale
sl@0
   342
	in floating point arithmetic and where the values are positive integers and relatively prime. 
sl@0
   343
	If iPlusPType is equal to 0, or iPlusPType is equal to 1 and iUpdateFullExtendedPType is equal 
sl@0
   344
	to 1 and bit 4 of the OPPTYPE syntax element is equal to 0, iPictureClockFrequencyRate shall be 
sl@0
   345
	equal to 30000 and iPictureClockFrequencyScale shall be equal to 1001 (as specified in subclause
sl@0
   346
	4.1 of ITU-T Recommendation H.263). If iPlusPType is equal to 1 and iUpdateFullExtendedPType is
sl@0
   347
	equal to 1 and bit 4 of the OPPTYPE syntax element is equal to 1, the values of 
sl@0
   348
	iPictureClockFrequencyRate and iPictureClockFrequencyScale are set as specified in subclause
sl@0
   349
	5.1.7 of ITU-T Recommendation H.263. Otherwise (iPlusPType is equal to 1 and 
sl@0
   350
	iUpdateFullExtendedPType is equal to 0), the values of iPictureClockFrequencyRate and
sl@0
   351
	iPictureClockFrequencyScale are not valid.
sl@0
   352
	*/
sl@0
   353
    TUint iPictureClockFrequencyRate;
sl@0
   354
sl@0
   355
	/**
sl@0
   356
	Picture clock frequency numerator and denominator respectively. The picture clock frequency 
sl@0
   357
	for temporal reference is defined as iPictureClockFrequencyRate / iPictureClockFrequencyScale
sl@0
   358
	in floating point arithmetic and where the values are positive integers and relatively prime. 
sl@0
   359
	If iPlusPType is equal to 0, or iPlusPType is equal to 1 and iUpdateFullExtendedPType is equal 
sl@0
   360
	to 1 and bit 4 of the OPPTYPE syntax element is equal to 0, iPictureClockFrequencyRate shall be 
sl@0
   361
	equal to 30000 and iPictureClockFrequencyScale shall be equal to 1001 (as specified in subclause
sl@0
   362
	4.1 of ITU-T Recommendation H.263). If iPlusPType is equal to 1 and iUpdateFullExtendedPType is
sl@0
   363
	equal to 1 and bit 4 of the OPPTYPE syntax element is equal to 1, the values of 
sl@0
   364
	iPictureClockFrequencyRate and iPictureClockFrequencyScale are set as specified in subclause
sl@0
   365
	5.1.7 of ITU-T Recommendation H.263. Otherwise (iPlusPType is equal to 1 and 
sl@0
   366
	iUpdateFullExtendedPType is equal to 0), the values of iPictureClockFrequencyRate and
sl@0
   367
	iPictureClockFrequencyScale are not valid.
sl@0
   368
	*/
sl@0
   369
    TUint iPictureClockFrequencyScale;
sl@0
   370
    };
sl@0
   371
sl@0
   372
/**
sl@0
   373
This class is used to signal decoder or encoder capabilities or bitstream properties.
sl@0
   374
@publishedAll
sl@0
   375
@released
sl@0
   376
*/
sl@0
   377
class TH263VideoCapability
sl@0
   378
    {
sl@0
   379
public:
sl@0
   380
	/**
sl@0
   381
	When part of a codec capability indication, iProfileLevel[ProfileNumber] indicates the 
sl@0
   382
	maximum processing level that a decoder or an encoder supports for a particular profile 
sl@0
   383
	indicated by ProfileNumber. A negative value indicates that the profile is not supported.
sl@0
   384
	When part of a stream property indication, iProfileLevel[ProfileNumber] indicates the maximum
sl@0
   385
	processing level that is present in the stream for a particular profile indicated by 
sl@0
   386
	ProfileNumber. A negative value indicates that the stream does not contain data coded according 
sl@0
   387
	to the indicated profile.
sl@0
   388
	*/
sl@0
   389
    TInt iProfileLevel[9];
sl@0
   390
sl@0
   391
	/**
sl@0
   392
	When equal to ETrue, indicating that it is allowed to use PLUSPTYPE (specified in the 1998 
sl@0
   393
	version of H.263) to indicate custom picture sizes or clock frequencies. When equal to EFalse,
sl@0
   394
	PLUSPTYPE shall not be used.
sl@0
   395
	*/
sl@0
   396
    TBool iPLUSPTYPEAllowed;
sl@0
   397
sl@0
   398
	/**
sl@0
   399
	iSupplementalInformationCap indicates the supported supplemental enhancement functions. The
sl@0
   400
	value is a binary OR of values from TH263SupplementalInformation.
sl@0
   401
	*/
sl@0
   402
    TUint32 iSupplementalInformationCap;
sl@0
   403
    };
sl@0
   404
sl@0
   405
sl@0
   406
/**
sl@0
   407
This class is used to set the encoder operation mode.
sl@0
   408
@publishedAll
sl@0
   409
@released
sl@0
   410
*/
sl@0
   411
class TH263VideoMode
sl@0
   412
    {
sl@0
   413
public:
sl@0
   414
	/**
sl@0
   415
	Specifies the picture types allowed in the bitstream. The value is a binary OR of values from
sl@0
   416
	TH263PictureType. Signaled picture types that are not included in the prevailing coding profile
sl@0
   417
	are ignored.
sl@0
   418
	*/
sl@0
   419
    TUint32 iAllowedPictureTypes;
sl@0
   420
sl@0
   421
	/**
sl@0
   422
	iForceRoundingTypeToZero equal to EFalse specifies that the value of the RTYPE bit (bit 6 of 
sl@0
   423
	MPPTYPE) is not constrained. It is recommended to change the value of the RTYPE bit for each 
sl@0
   424
	reference picture in error-free communication (subclause 5.1.4.3 of ITU-T H.263 Recommendation).
sl@0
   425
	iForceRoundingTypeToZero equal to ETrue specifies that the value of the RTYPE bit shall be equal 
sl@0
   426
	to 0 or that the RTYPE field shall not be present in the picture layer. It is recommended to set 
sl@0
   427
	iForceRoundingTypeToZero equal to ETrue (and consequently RTYPE equal to 0) in error-prone 
sl@0
   428
	communication as recommended in section 4.2.6 of H.263 Appendix III [R6] and [R7].
sl@0
   429
	*/
sl@0
   430
    TBool iForceRoundingTypeToZero;
sl@0
   431
sl@0
   432
	/**
sl@0
   433
	Specifies the frequency of picture header repetition as specified in this paragraph. If 
sl@0
   434
	iPictureHeaderRepetition is equal to 0, picture headers are not repeated. Otherwise, a picture 
sl@0
   435
	header is repeated, if the value of the GFID syntax element is not equal to the value of the 
sl@0
   436
	GFID syntax element of the previous picture in bitstream order. If EDuRtpPayload data unit 
sl@0
   437
	encapsulation is in use, a picture header is repeated the number of times indicated by the value 
sl@0
   438
	of iPictureHeaderRepetition in those RTP payloads of the picture where the P bit according to 
sl@0
   439
	RFC 2429 [R8] is set equal to 1 and which do not contain the original picture header. If 
sl@0
   440
	EDuElementaryStream data unit encapsulation is in use, the picture header is repeated once in 
sl@0
   441
	the supplemental enhancement information of the next picture as specified in subclause W.6.3.8
sl@0
   442
	of ITU-T Recommendation H.263 and section 4.2.6 of H.263 Appendix III [R6].
sl@0
   443
	*/
sl@0
   444
    TUint iPictureHeaderRepetition;
sl@0
   445
sl@0
   446
	/**
sl@0
   447
	Specifies the interval of non-empty GOB headers in units of GOBs. The value of 
sl@0
   448
	iGOBHeaderInterval is valid if no slice structured coding mode (Annex K or Annex V) is in use. 
sl@0
   449
	If iGOBHeaderInterval is equal to 0 and an unlimited segment size is specified with the 
sl@0
   450
	SetSegmentTargetSize method, the encoder should not generate GOB headers. If iGOBHeaderInterval 
sl@0
   451
	is greater than 0 and an unlimited segment size is specified with the SetSegmentTargetSize 
sl@0
   452
	method, the encoder should generate a non-empty GOB header for every iGOBHeaderInterval-th GOB.
sl@0
   453
	If SetSegmentTargetSize is used to set a limited segment size, the encoder should generate 
sl@0
   454
	segments (i.e., insert non-empty GOB headers) so that the length of the segment is no larger
sl@0
   455
	than the target size in bytes and no larger than the GOB header frequency specified with the 
sl@0
   456
	value of iGOBHeaderInterval.
sl@0
   457
	*/
sl@0
   458
    TUint iGOBHeaderInterval;
sl@0
   459
    };
sl@0
   460
sl@0
   461
/**
sl@0
   462
H.263 HRD parameters.
sl@0
   463
@publishedAll
sl@0
   464
@released
sl@0
   465
*/
sl@0
   466
class TH263HrdParams
sl@0
   467
    {
sl@0
   468
public:
sl@0
   469
	/**
sl@0
   470
	When iAnnexXConstraints is equal to EFalse, iBPPmaxKb, iB, and iRmax indicate the values of HRD 
sl@0
   471
	parameters. When iAnnexXConstraints is equal to ETrue, the values of iBPPmaxKb, iB, and iRmax in 
sl@0
   472
	this class are ignored but rather their values are specified in Annex X of ITU-T Recommendation
sl@0
   473
	H.263. 
sl@0
   474
	*/
sl@0
   475
    TBool iAnnexXConstraints;
sl@0
   476
sl@0
   477
	/**
sl@0
   478
	Signals the BPPmaxKb parameter of H.263. As specified in ITU-T Recommendation H.263. The number 
sl@0
   479
	of bits created by coding any single picture shall not exceed a maximum value specified by the 
sl@0
   480
	parameter BPPmaxKb that is measured in units of 1024 bits. The minimum value of BPPmaxKb is 
sl@0
   481
	specified in Table 1 of ITU-T Recommendation H.263.
sl@0
   482
	*/
sl@0
   483
    TUint iBPPmaxKb;
sl@0
   484
sl@0
   485
	/**
sl@0
   486
	Signals the B parameter of H.263 Annex B. As specified in Annex B of ITU-T Recommendation H.263. 
sl@0
   487
	The value of B shall be equal to or greater than 4 * Rmax / PCF, where PCF is the picture clock 
sl@0
   488
	frequency specified in subclause 5.1.7 of ITU-T Recommendation H.263. The HRD receiving buffer 
sl@0
   489
	size is equal to (B + BPPmaxKb * 1024 bits).
sl@0
   490
	*/
sl@0
   491
    TUint iB;
sl@0
   492
sl@0
   493
	/**
sl@0
   494
	Signals the maximum video bit rate in bits per second, i.e., the Rmax parameter of H.263 Annex B. 
sl@0
   495
	*/
sl@0
   496
    TUint iRmax;
sl@0
   497
    };
sl@0
   498
sl@0
   499
/**
sl@0
   500
H.263 redundant picture header.
sl@0
   501
Points to a buffer to contain the redundant picture header in the orignal bitstream order. The
sl@0
   502
buffer may be used by the MSL client in playback to pass the decapsulated redundant picture header 
sl@0
   503
from an RTP payload formatted according to RFC 2429, or used by the MSL client in recording to pass
sl@0
   504
the picture header to the RTP encapsulator.
sl@0
   505
@publishedAll
sl@0
   506
@released
sl@0
   507
*/
sl@0
   508
typedef TPtr8* TH263RedundantPictureHeader;
sl@0
   509
sl@0
   510
#endif