source: 3DVCSoftware/trunk/source/Lib/TLibEncoder/TEncCfg.h @ 1179

Last change on this file since 1179 was 1179, checked in by tech, 9 years ago

Merged branch 13.1-dev0@1178.

  • Property svn:eol-style set to native
File size: 56.3 KB
Line 
1/* The copyright in this software is being made available under the BSD
2 * License, included below. This software may be subject to other third party
3 * and contributor rights, including patent rights, and no such rights are
4 * granted under this license. 
5 *
6* Copyright (c) 2010-2015, ITU/ISO/IEC
7 * All rights reserved.
8 *
9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions are met:
11 *
12 *  * Redistributions of source code must retain the above copyright notice,
13 *    this list of conditions and the following disclaimer.
14 *  * Redistributions in binary form must reproduce the above copyright notice,
15 *    this list of conditions and the following disclaimer in the documentation
16 *    and/or other materials provided with the distribution.
17 *  * Neither the name of the ITU/ISO/IEC nor the names of its contributors may
18 *    be used to endorse or promote products derived from this software without
19 *    specific prior written permission.
20 *
21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS
25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
31 * THE POSSIBILITY OF SUCH DAMAGE.
32 */
33
34/** \file     TEncCfg.h
35    \brief    encoder configuration class (header)
36*/
37
38#ifndef __TENCCFG__
39#define __TENCCFG__
40
41#if _MSC_VER > 1000
42#pragma once
43#endif // _MSC_VER > 1000
44
45#include "TLibCommon/CommonDef.h"
46#include "TLibCommon/TComSlice.h"
47#include <assert.h>
48#if H_3D
49#include "TAppCommon/TAppComCamPara.h"
50#include "TLibRenderer/TRenModSetupStrParser.h"
51#endif
52
53struct GOPEntry
54{
55  Int m_POC;
56  Int m_QPOffset;
57  Double m_QPFactor;
58  Int m_tcOffsetDiv2;
59  Int m_betaOffsetDiv2;
60  Int m_temporalId;
61  Bool m_refPic;
62  Int m_numRefPicsActive;
63  Char m_sliceType;
64  Int m_numRefPics;
65  Int m_referencePics[MAX_NUM_REF_PICS];
66  Int m_usedByCurrPic[MAX_NUM_REF_PICS];
67#if AUTO_INTER_RPS
68  Int m_interRPSPrediction;
69#else
70  Bool m_interRPSPrediction;
71#endif
72  Int m_deltaRPS;
73  Int m_numRefIdc;
74  Int m_refIdc[MAX_NUM_REF_PICS+1];
75#if H_MV
76  Int m_numActiveRefLayerPics;
77  Int m_interLayerPredLayerIdc [MAX_NUM_REF_PICS];
78  Int m_interViewRefPosL[2][MAX_NUM_REF_PICS]; 
79#endif
80#if HHI_INTER_COMP_PRED_K0052
81  Bool m_interCompPredFlag;
82#endif
83  GOPEntry()
84  : m_POC(-1)
85  , m_QPOffset(0)
86  , m_QPFactor(0)
87  , m_tcOffsetDiv2(0)
88  , m_betaOffsetDiv2(0)
89  , m_temporalId(0)
90  , m_refPic(false)
91  , m_numRefPicsActive(0)
92  , m_sliceType('P')
93  , m_numRefPics(0)
94  , m_interRPSPrediction(false)
95  , m_deltaRPS(0)
96  , m_numRefIdc(0)
97#if H_MV
98  , m_numActiveRefLayerPics(0)
99#endif
100#if HHI_INTER_COMP_PRED_K0052
101#if H_3D
102  , m_interCompPredFlag(false)
103#endif
104#endif
105  {
106    ::memset( m_referencePics, 0, sizeof(m_referencePics) );
107    ::memset( m_usedByCurrPic, 0, sizeof(m_usedByCurrPic) );
108    ::memset( m_refIdc,        0, sizeof(m_refIdc) );
109#if H_MV
110    ::memset( m_interLayerPredLayerIdc,   0, sizeof(m_interLayerPredLayerIdc) );
111    ::memset( m_interViewRefPosL[0], -1, sizeof(m_interViewRefPosL[0]) );
112    ::memset( m_interViewRefPosL[1], -1, sizeof(m_interViewRefPosL[1]) );
113#endif
114  }
115};
116
117std::istringstream &operator>>(std::istringstream &in, GOPEntry &entry);     //input
118//! \ingroup TLibEncoder
119//! \{
120
121// ====================================================================================================================
122// Class definition
123// ====================================================================================================================
124
125/// encoder configuration class
126class TEncCfg
127{
128protected:
129  //==== File I/O ========
130  Int       m_iFrameRate;
131  Int       m_FrameSkip;
132  Int       m_iSourceWidth;
133  Int       m_iSourceHeight;
134  Window    m_conformanceWindow;
135  Int       m_framesToBeEncoded;
136  Double    m_adLambdaModifier[ MAX_TLAYER ];
137
138  /* profile & level */
139  Profile::Name m_profile;
140  Level::Tier   m_levelTier;
141  Level::Name   m_level;
142  Bool m_progressiveSourceFlag;
143  Bool m_interlacedSourceFlag;
144  Bool m_nonPackedConstraintFlag;
145  Bool m_frameOnlyConstraintFlag;
146
147  //====== Coding Structure ========
148  UInt      m_uiIntraPeriod;
149  UInt      m_uiDecodingRefreshType;            ///< the type of decoding refresh employed for the random access.
150  Int       m_iGOPSize;
151#if H_MV
152  GOPEntry  m_GOPList[MAX_GOP+1];
153#else
154  GOPEntry  m_GOPList[MAX_GOP];
155#endif
156  Int       m_extraRPSs;
157  Int       m_maxDecPicBuffering[MAX_TLAYER];
158  Int       m_numReorderPics[MAX_TLAYER];
159 
160  Int       m_iQP;                              //  if (AdaptiveQP == OFF)
161 
162  Int       m_aiPad[2];
163 
164
165  Int       m_iMaxRefPicNum;                     ///< this is used to mimic the sliding mechanism used by the decoder
166                                                 // TODO: We need to have a common sliding mechanism used by both the encoder and decoder
167
168  Int       m_maxTempLayer;                      ///< Max temporal layer
169  Bool m_useAMP;
170  //======= Transform =============
171  UInt      m_uiQuadtreeTULog2MaxSize;
172  UInt      m_uiQuadtreeTULog2MinSize;
173  UInt      m_uiQuadtreeTUMaxDepthInter;
174  UInt      m_uiQuadtreeTUMaxDepthIntra;
175 
176  //====== Loop/Deblock Filter ========
177  Bool      m_bLoopFilterDisable;
178  Bool      m_loopFilterOffsetInPPS;
179  Int       m_loopFilterBetaOffsetDiv2;
180  Int       m_loopFilterTcOffsetDiv2;
181  Bool      m_DeblockingFilterControlPresent;
182  Bool      m_DeblockingFilterMetric;
183  Bool      m_bUseSAO;
184  Int       m_maxNumOffsetsPerPic;
185  Bool      m_saoLcuBoundary;
186  //====== Motion search ========
187  Int       m_iFastSearch;                      //  0:Full search  1:Diamond  2:PMVFAST
188  Int       m_iSearchRange;                     //  0:Full frame
189  Int       m_bipredSearchRange;
190#if SONY_MV_V_CONST_C0078
191  Bool      m_bUseDisparitySearchRangeRestriction;
192  Int       m_iVerticalDisparitySearchRange;
193#endif
194  //====== Quality control ========
195  Int       m_iMaxDeltaQP;                      //  Max. absolute delta QP (1:default)
196  Int       m_iMaxCuDQPDepth;                   //  Max. depth for a minimum CuDQP (0:default)
197
198  Int       m_chromaCbQpOffset;                 //  Chroma Cb QP Offset (0:default)
199  Int       m_chromaCrQpOffset;                 //  Chroma Cr Qp Offset (0:default)
200
201#if ADAPTIVE_QP_SELECTION
202  Bool      m_bUseAdaptQpSelect;
203#endif
204
205  Bool      m_bUseAdaptiveQP;
206  Int       m_iQPAdaptationRange;
207 
208  //====== Tool list ========
209  Bool      m_bUseASR;
210  Bool      m_bUseHADME;
211  Bool      m_useRDOQ;
212  Bool      m_useRDOQTS;
213  UInt      m_rdPenalty;
214  Bool      m_bUseFastEnc;
215  Bool      m_bUseEarlyCU;
216  Bool      m_useFastDecisionForMerge;
217  Bool      m_bUseCbfFastMode;
218  Bool      m_useEarlySkipDetection;
219  Bool      m_useTransformSkip;
220  Bool      m_useTransformSkipFast;
221  Int*      m_aidQP;
222  UInt      m_uiDeltaQpRD;
223 
224  Bool      m_bUseConstrainedIntraPred;
225  Bool      m_usePCM;
226  UInt      m_pcmLog2MaxSize;
227  UInt      m_uiPCMLog2MinSize;
228  //====== Slice ========
229  Int       m_sliceMode;
230  Int       m_sliceArgument; 
231  //====== Dependent Slice ========
232  Int       m_sliceSegmentMode;
233  Int       m_sliceSegmentArgument;
234  Bool      m_bLFCrossSliceBoundaryFlag;
235
236  Bool      m_bPCMInputBitDepthFlag;
237  UInt      m_uiPCMBitDepthLuma;
238  UInt      m_uiPCMBitDepthChroma;
239  Bool      m_bPCMFilterDisableFlag;
240  Bool      m_loopFilterAcrossTilesEnabledFlag;
241  Bool      m_tileUniformSpacingFlag;
242  Int       m_iNumColumnsMinus1;
243  Int       m_iNumRowsMinus1;
244  std::vector<Int> m_tileColumnWidth;
245  std::vector<Int> m_tileRowHeight;
246
247  Int       m_iWaveFrontSynchro;
248  Int       m_iWaveFrontSubstreams;
249
250  Int       m_decodedPictureHashSEIEnabled;              ///< Checksum(3)/CRC(2)/MD5(1)/disable(0) acting on decoded picture hash SEI message
251  Int       m_bufferingPeriodSEIEnabled;
252  Int       m_pictureTimingSEIEnabled;
253  Int       m_recoveryPointSEIEnabled;
254  Bool      m_toneMappingInfoSEIEnabled;
255  Int       m_toneMapId;
256  Bool      m_toneMapCancelFlag;
257  Bool      m_toneMapPersistenceFlag;
258  Int       m_codedDataBitDepth;
259  Int       m_targetBitDepth;
260  Int       m_modelId; 
261  Int       m_minValue;
262  Int       m_maxValue;
263  Int       m_sigmoidMidpoint;
264  Int       m_sigmoidWidth;
265  Int       m_numPivots;
266  Int       m_cameraIsoSpeedIdc;
267  Int       m_cameraIsoSpeedValue;
268  Int       m_exposureIndexIdc;
269  Int       m_exposureIndexValue;
270  Int       m_exposureCompensationValueSignFlag;
271  Int       m_exposureCompensationValueNumerator;
272  Int       m_exposureCompensationValueDenomIdc;
273  Int       m_refScreenLuminanceWhite;
274  Int       m_extendedRangeWhiteLevel;
275  Int       m_nominalBlackLevelLumaCodeValue;
276  Int       m_nominalWhiteLevelLumaCodeValue;
277  Int       m_extendedWhiteLevelLumaCodeValue;
278  Int*      m_startOfCodedInterval;
279  Int*      m_codedPivotValue;
280  Int*      m_targetPivotValue;
281  Int       m_framePackingSEIEnabled;
282  Int       m_framePackingSEIType;
283  Int       m_framePackingSEIId;
284  Int       m_framePackingSEIQuincunx;
285  Int       m_framePackingSEIInterpretation;
286  Int       m_displayOrientationSEIAngle;
287  Int       m_temporalLevel0IndexSEIEnabled;
288  Int       m_gradualDecodingRefreshInfoEnabled;
289  Int       m_decodingUnitInfoSEIEnabled;
290  Int       m_SOPDescriptionSEIEnabled;
291  Int       m_scalableNestingSEIEnabled;
292  //====== Weighted Prediction ========
293  Bool      m_useWeightedPred;       //< Use of Weighting Prediction (P_SLICE)
294  Bool      m_useWeightedBiPred;    //< Use of Bi-directional Weighting Prediction (B_SLICE)
295  UInt      m_log2ParallelMergeLevelMinus2;       ///< Parallel merge estimation region
296  UInt      m_maxNumMergeCand;                    ///< Maximum number of merge candidates
297  Int       m_useScalingListId;            ///< Using quantization matrix i.e. 0=off, 1=default, 2=file.
298  Char*     m_scalingListFile;          ///< quantization matrix file name
299  Int       m_TMVPModeId;
300  Int       m_signHideFlag;
301  Bool      m_RCEnableRateControl;
302  Int       m_RCTargetBitrate;
303  Int       m_RCKeepHierarchicalBit;
304  Bool      m_RCLCULevelRC;
305  Bool      m_RCUseLCUSeparateModel;
306  Int       m_RCInitialQP;
307  Bool      m_RCForceIntraQP;
308
309#if KWU_RC_MADPRED_E0227
310  UInt       m_depthMADPred;
311#endif
312#if KWU_RC_VIEWRC_E0227
313  Bool      m_bViewWiseRateCtrl;
314#endif
315  Bool      m_TransquantBypassEnableFlag;                     ///< transquant_bypass_enable_flag setting in PPS.
316  Bool      m_CUTransquantBypassFlagForce;                    ///< if transquant_bypass_enable_flag, then, if true, all CU transquant bypass flags will be set to true.
317#if H_MV
318  TComVPS*  m_cVPS;                                           ///< pointer to VPS, same for all layers
319#else
320  TComVPS                    m_cVPS;
321#endif
322
323#if H_3D
324  TComDLT*  m_cDLT;
325#endif
326
327  Bool      m_recalculateQPAccordingToLambda;                 ///< recalculate QP value according to the lambda value
328  Int       m_activeParameterSetsSEIEnabled;                  ///< enable active parameter set SEI message
329  Bool      m_vuiParametersPresentFlag;                       ///< enable generation of VUI parameters
330  Bool      m_aspectRatioInfoPresentFlag;                     ///< Signals whether aspect_ratio_idc is present
331  Int       m_aspectRatioIdc;                                 ///< aspect_ratio_idc
332  Int       m_sarWidth;                                       ///< horizontal size of the sample aspect ratio
333  Int       m_sarHeight;                                      ///< vertical size of the sample aspect ratio
334  Bool      m_overscanInfoPresentFlag;                        ///< Signals whether overscan_appropriate_flag is present
335  Bool      m_overscanAppropriateFlag;                        ///< Indicates whether conformant decoded pictures are suitable for display using overscan
336  Bool      m_videoSignalTypePresentFlag;                     ///< Signals whether video_format, video_full_range_flag, and colour_description_present_flag are present
337  Int       m_videoFormat;                                    ///< Indicates representation of pictures
338  Bool      m_videoFullRangeFlag;                             ///< Indicates the black level and range of luma and chroma signals
339  Bool      m_colourDescriptionPresentFlag;                   ///< Signals whether colour_primaries, transfer_characteristics and matrix_coefficients are present
340  Int       m_colourPrimaries;                                ///< Indicates chromaticity coordinates of the source primaries
341  Int       m_transferCharacteristics;                        ///< Indicates the opto-electronic transfer characteristics of the source
342  Int       m_matrixCoefficients;                             ///< Describes the matrix coefficients used in deriving luma and chroma from RGB primaries
343  Bool      m_chromaLocInfoPresentFlag;                       ///< Signals whether chroma_sample_loc_type_top_field and chroma_sample_loc_type_bottom_field are present
344  Int       m_chromaSampleLocTypeTopField;                    ///< Specifies the location of chroma samples for top field
345  Int       m_chromaSampleLocTypeBottomField;                 ///< Specifies the location of chroma samples for bottom field
346  Bool      m_neutralChromaIndicationFlag;                    ///< Indicates that the value of all decoded chroma samples is equal to 1<<(BitDepthCr-1)
347  Window    m_defaultDisplayWindow;                           ///< Represents the default display window parameters
348  Bool      m_frameFieldInfoPresentFlag;                      ///< Indicates that pic_struct and other field coding related values are present in picture timing SEI messages
349  Bool      m_pocProportionalToTimingFlag;                    ///< Indicates that the POC value is proportional to the output time w.r.t. first picture in CVS
350  Int       m_numTicksPocDiffOneMinus1;                       ///< Number of ticks minus 1 that for a POC difference of one
351  Bool      m_bitstreamRestrictionFlag;                       ///< Signals whether bitstream restriction parameters are present
352  Bool      m_tilesFixedStructureFlag;                        ///< Indicates that each active picture parameter set has the same values of the syntax elements related to tiles
353  Bool      m_motionVectorsOverPicBoundariesFlag;             ///< Indicates that no samples outside the picture boundaries are used for inter prediction
354  Int       m_minSpatialSegmentationIdc;                      ///< Indicates the maximum size of the spatial segments in the pictures in the coded video sequence
355  Int       m_maxBytesPerPicDenom;                            ///< Indicates a number of bytes not exceeded by the sum of the sizes of the VCL NAL units associated with any coded picture
356  Int       m_maxBitsPerMinCuDenom;                           ///< Indicates an upper bound for the number of bits of coding_unit() data
357  Int       m_log2MaxMvLengthHorizontal;                      ///< Indicate the maximum absolute value of a decoded horizontal MV component in quarter-pel luma units
358  Int       m_log2MaxMvLengthVertical;                        ///< Indicate the maximum absolute value of a decoded vertical MV component in quarter-pel luma units
359
360  Bool      m_useStrongIntraSmoothing;                        ///< enable the use of strong intra smoothing (bi_linear interpolation) for 32x32 blocks when reference samples are flat.
361#if H_MV
362  Bool              m_subBistreamPropSEIEnabled;
363  Int               m_numAdditionalSubStreams;
364  std::vector<Int>  m_subBitstreamMode;
365  std::vector<Int>  m_outputLayerSetIdxToVps;
366  std::vector<Int>  m_highestSublayerId;
367  std::vector<Int>  m_avgBitRate;
368  std::vector<Int>  m_maxBitRate;
369#endif
370
371#if H_MV
372  Int       m_layerId;
373  Int       m_layerIdInVps;
374  Int       m_viewId;
375  Int       m_viewIndex; 
376#endif
377
378#if H_3D
379  Bool      m_isDepth;
380
381  //====== Camera Parameters ======
382#if !HHI_CAM_PARA_K0052
383  UInt      m_uiCamParPrecision;
384  Bool      m_bCamParInSliceHeader;
385  Int**     m_aaiCodedScale;
386  Int**     m_aaiCodedOffset;
387#endif
388  TAppComCamPara* m_cameraParameters; 
389 
390#if H_3D_VSO
391  //====== View Synthesis Optimization ======
392  TRenModSetupStrParser* m_renderModelParameters; 
393  Bool      m_bUseVSO;
394  Bool      m_bForceLambdaScale;
395  Bool      m_bAllowNegDist;
396  Double    m_dLambdaScaleVSO;
397  UInt      m_uiVSOMode;
398  // LGE_WVSO_A0119
399  Bool      m_bUseWVSO;
400  Int       m_iVSOWeight;
401  Int       m_iVSDWeight;
402  Int       m_iDWeight;
403  // SAIT_VSO_EST_A0033
404  Bool      m_bUseEstimatedVSD; 
405  Double    m_dDispCoeff;
406#endif
407#if H_3D_IC
408  Bool      m_bUseIC;
409  Bool      m_bUseICLowLatencyEnc;
410#endif
411  //====== Depth Intra Modes ======
412#if H_3D_DIM
413  Bool      m_useDMM;
414  Bool      m_useSDC;
415  Bool      m_useDLT;
416#endif
417#if H_3D_QTLPC
418  Bool      m_bUseQTL;
419#endif
420#if H_3D_ANNEX_SELECTION_FIX
421  Int m_profileIdc;
422#endif
423
424#endif
425public:
426  TEncCfg()
427  : m_tileColumnWidth()
428  , m_tileRowHeight()
429#if H_MV
430  , m_layerId(-1)
431  , m_layerIdInVps(-1)
432  , m_viewId(-1)
433  , m_viewIndex(-1)
434#if H_3D
435  , m_isDepth(false)
436  , m_bUseVSO(false)
437#if H_3D_ANNEX_SELECTION_FIX
438  , m_profileIdc( -1 )
439#endif
440#endif
441#endif
442  {}
443
444  virtual ~TEncCfg()
445  {}
446 
447  Void setProfile(Profile::Name profile) { m_profile = profile; }
448  Void setLevel(Level::Tier tier, Level::Name level) { m_levelTier = tier; m_level = level; }
449
450  Void      setFrameRate                    ( Int   i )      { m_iFrameRate = i; }
451  Void      setFrameSkip                    ( UInt i ) { m_FrameSkip = i; }
452  Void      setSourceWidth                  ( Int   i )      { m_iSourceWidth = i; }
453  Void      setSourceHeight                 ( Int   i )      { m_iSourceHeight = i; }
454
455  Window   &getConformanceWindow()                           { return m_conformanceWindow; }
456  Void      setConformanceWindow (Int confLeft, Int confRight, Int confTop, Int confBottom ) { m_conformanceWindow.setWindow (confLeft, confRight, confTop, confBottom); }
457
458  Void      setFramesToBeEncoded            ( Int   i )      { m_framesToBeEncoded = i; }
459 
460#if H_MV
461  Void      setLayerId                       ( Int layerId )      { m_layerId = layerId; }
462  Int       getLayerId                       ()                   { return m_layerId;    }
463  Int       getLayerIdInVps                  ()                   { return m_layerIdInVps; }
464  Void      setLayerIdInVps                  ( Int layerIdInVps)  { m_layerIdInVps = layerIdInVps; }
465  Void      setViewId                        ( Int viewId  )      { m_viewId  = viewId;  }
466  Int       getViewId                        ()                   { return m_viewId;    }
467  Void      setViewIndex                     ( Int viewIndex  )   { m_viewIndex  = viewIndex;  }
468  Int       getViewIndex                     ()                   { return m_viewIndex;    }
469#if H_3D
470  Void      setIsDepth                       ( Bool isDepth )   { m_isDepth = isDepth; }
471  Bool      getIsDepth                       ()                 { return m_isDepth; }
472#endif
473#endif
474  //====== Coding Structure ========
475  Void      setIntraPeriod                  ( Int   i )      { m_uiIntraPeriod = (UInt)i; }
476  Void      setDecodingRefreshType          ( Int   i )      { m_uiDecodingRefreshType = (UInt)i; }
477  Void      setGOPSize                      ( Int   i )      { m_iGOPSize = i; }
478#if H_MV
479  Void      setGopList                      ( GOPEntry*  GOPList ) {  for ( Int i = 0; i < MAX_GOP+1; i++ ) m_GOPList[i] = GOPList[i]; }
480#else
481  Void      setGopList                      ( GOPEntry*  GOPList ) {  for ( Int i = 0; i < MAX_GOP; i++ ) m_GOPList[i] = GOPList[i]; }
482#endif
483  Void      setExtraRPSs                    ( Int   i )      { m_extraRPSs = i; }
484  GOPEntry  getGOPEntry                     ( Int   i )      { return m_GOPList[i]; }
485  Void      setMaxDecPicBuffering           ( UInt u, UInt tlayer ) { m_maxDecPicBuffering[tlayer] = u;    }
486  Void      setNumReorderPics               ( Int  i, UInt tlayer ) { m_numReorderPics[tlayer] = i;    }
487 
488  Void      setQP                           ( Int   i )      { m_iQP = i; }
489 
490  Void      setPad                          ( Int*  iPad                   )      { for ( Int i = 0; i < 2; i++ ) m_aiPad[i] = iPad[i]; }
491 
492  Int       getMaxRefPicNum                 ()                              { return m_iMaxRefPicNum;           }
493  Void      setMaxRefPicNum                 ( Int iMaxRefPicNum )           { m_iMaxRefPicNum = iMaxRefPicNum;  }
494
495  Int       getMaxTempLayer                 ()                              { return m_maxTempLayer;              } 
496  Void      setMaxTempLayer                 ( Int maxTempLayer )            { m_maxTempLayer = maxTempLayer;      }
497
498#if H_3D_IC
499  Void       setUseIC                       ( Bool bVal )    { m_bUseIC = bVal; }
500  Bool       getUseIC                       ()               { return m_bUseIC; }
501  Void       setUseICLowLatencyEnc          ( Bool bVal )    { m_bUseICLowLatencyEnc = bVal; }
502  Bool       getUseICLowLatencyEnc          ()               { return m_bUseICLowLatencyEnc; }
503#endif
504  //======== Transform =============
505  Void      setQuadtreeTULog2MaxSize        ( UInt  u )      { m_uiQuadtreeTULog2MaxSize = u; }
506  Void      setQuadtreeTULog2MinSize        ( UInt  u )      { m_uiQuadtreeTULog2MinSize = u; }
507  Void      setQuadtreeTUMaxDepthInter      ( UInt  u )      { m_uiQuadtreeTUMaxDepthInter = u; }
508  Void      setQuadtreeTUMaxDepthIntra      ( UInt  u )      { m_uiQuadtreeTUMaxDepthIntra = u; }
509 
510  Void setUseAMP( Bool b ) { m_useAMP = b; }
511 
512  //====== Loop/Deblock Filter ========
513  Void      setLoopFilterDisable            ( Bool  b )      { m_bLoopFilterDisable       = b; }
514  Void      setLoopFilterOffsetInPPS        ( Bool  b )      { m_loopFilterOffsetInPPS      = b; }
515  Void      setLoopFilterBetaOffset         ( Int   i )      { m_loopFilterBetaOffsetDiv2  = i; }
516  Void      setLoopFilterTcOffset           ( Int   i )      { m_loopFilterTcOffsetDiv2    = i; }
517  Void      setDeblockingFilterControlPresent ( Bool b ) { m_DeblockingFilterControlPresent = b; }
518  Void      setDeblockingFilterMetric       ( Bool  b )      { m_DeblockingFilterMetric = b; }
519
520  //====== Motion search ========
521  Void      setFastSearch                   ( Int   i )      { m_iFastSearch = i; }
522  Void      setSearchRange                  ( Int   i )      { m_iSearchRange = i; }
523  Void      setBipredSearchRange            ( Int   i )      { m_bipredSearchRange = i; }
524#if SONY_MV_V_CONST_C0078
525  Void      setUseDisparitySearchRangeRestriction ( Bool   b )      { m_bUseDisparitySearchRangeRestriction = b; }
526  Void      setVerticalDisparitySearchRange ( Int   i )      { m_iVerticalDisparitySearchRange = i; }
527#endif
528
529  //====== Quality control ========
530  Void      setMaxDeltaQP                   ( Int   i )      { m_iMaxDeltaQP = i; }
531  Void      setMaxCuDQPDepth                ( Int   i )      { m_iMaxCuDQPDepth = i; }
532
533  Void      setChromaCbQpOffset             ( Int   i )      { m_chromaCbQpOffset = i; }
534  Void      setChromaCrQpOffset             ( Int   i )      { m_chromaCrQpOffset = i; }
535
536#if ADAPTIVE_QP_SELECTION
537  Void      setUseAdaptQpSelect             ( Bool   i ) { m_bUseAdaptQpSelect    = i; }
538  Bool      getUseAdaptQpSelect             ()           { return   m_bUseAdaptQpSelect; }
539#endif
540
541  Void      setUseAdaptiveQP                ( Bool  b )      { m_bUseAdaptiveQP = b; }
542  Void      setQPAdaptationRange            ( Int   i )      { m_iQPAdaptationRange = i; }
543 
544  //====== Sequence ========
545  Int       getFrameRate                    ()      { return  m_iFrameRate; }
546  UInt      getFrameSkip                    ()      { return  m_FrameSkip; }
547  Int       getSourceWidth                  ()      { return  m_iSourceWidth; }
548  Int       getSourceHeight                 ()      { return  m_iSourceHeight; }
549  Int       getFramesToBeEncoded            ()      { return  m_framesToBeEncoded; }
550  void setLambdaModifier                    ( UInt uiIndex, Double dValue ) { m_adLambdaModifier[ uiIndex ] = dValue; }
551  Double getLambdaModifier                  ( UInt uiIndex ) const { return m_adLambdaModifier[ uiIndex ]; }
552
553  //==== Coding Structure ========
554  UInt      getIntraPeriod                  ()      { return  m_uiIntraPeriod; }
555  UInt      getDecodingRefreshType          ()      { return  m_uiDecodingRefreshType; }
556  Int       getGOPSize                      ()      { return  m_iGOPSize; }
557  Int       getMaxDecPicBuffering           (UInt tlayer) { return m_maxDecPicBuffering[tlayer]; }
558  Int       getNumReorderPics               (UInt tlayer) { return m_numReorderPics[tlayer]; }
559  Int       getQP                           ()      { return  m_iQP; }
560 
561  Int       getPad                          ( Int i )      { assert (i < 2 );                      return  m_aiPad[i]; }
562 
563  //======== Transform =============
564  UInt      getQuadtreeTULog2MaxSize        ()      const { return m_uiQuadtreeTULog2MaxSize; }
565  UInt      getQuadtreeTULog2MinSize        ()      const { return m_uiQuadtreeTULog2MinSize; }
566  UInt      getQuadtreeTUMaxDepthInter      ()      const { return m_uiQuadtreeTUMaxDepthInter; }
567  UInt      getQuadtreeTUMaxDepthIntra      ()      const { return m_uiQuadtreeTUMaxDepthIntra; }
568 
569  //==== Loop/Deblock Filter ========
570  Bool      getLoopFilterDisable            ()      { return  m_bLoopFilterDisable;       }
571  Bool      getLoopFilterOffsetInPPS        ()      { return m_loopFilterOffsetInPPS; }
572  Int       getLoopFilterBetaOffset         ()      { return m_loopFilterBetaOffsetDiv2; }
573  Int       getLoopFilterTcOffset           ()      { return m_loopFilterTcOffsetDiv2; }
574  Bool      getDeblockingFilterControlPresent()  { return  m_DeblockingFilterControlPresent; }
575  Bool      getDeblockingFilterMetric       ()      { return m_DeblockingFilterMetric; }
576
577  //==== Motion search ========
578  Int       getFastSearch                   ()      { return  m_iFastSearch; }
579  Int       getSearchRange                  ()      { return  m_iSearchRange; }
580#if SONY_MV_V_CONST_C0078
581  Bool      getUseDisparitySearchRangeRestriction ()      { return  m_bUseDisparitySearchRangeRestriction; }
582  Int       getVerticalDisparitySearchRange ()            { return  m_iVerticalDisparitySearchRange; }
583#endif
584
585  //==== Quality control ========
586  Int       getMaxDeltaQP                   ()      { return  m_iMaxDeltaQP; }
587  Int       getMaxCuDQPDepth                ()      { return  m_iMaxCuDQPDepth; }
588  Bool      getUseAdaptiveQP                ()      { return  m_bUseAdaptiveQP; }
589  Int       getQPAdaptationRange            ()      { return  m_iQPAdaptationRange; }
590 
591  //==== Tool list ========
592  Void      setUseASR                       ( Bool  b )     { m_bUseASR     = b; }
593  Void      setUseHADME                     ( Bool  b )     { m_bUseHADME   = b; }
594  Void      setUseRDOQ                      ( Bool  b )     { m_useRDOQ    = b; }
595  Void      setUseRDOQTS                    ( Bool  b )     { m_useRDOQTS  = b; }
596  Void      setRDpenalty                 ( UInt  b )     { m_rdPenalty  = b; }
597  Void      setUseFastEnc                   ( Bool  b )     { m_bUseFastEnc = b; }
598  Void      setUseEarlyCU                   ( Bool  b )     { m_bUseEarlyCU = b; }
599  Void      setUseFastDecisionForMerge      ( Bool  b )     { m_useFastDecisionForMerge = b; }
600  Void      setUseCbfFastMode            ( Bool  b )     { m_bUseCbfFastMode = b; }
601  Void      setUseEarlySkipDetection        ( Bool  b )     { m_useEarlySkipDetection = b; }
602  Void      setUseConstrainedIntraPred      ( Bool  b )     { m_bUseConstrainedIntraPred = b; }
603  Void      setPCMInputBitDepthFlag         ( Bool  b )     { m_bPCMInputBitDepthFlag = b; }
604  Void      setPCMFilterDisableFlag         ( Bool  b )     {  m_bPCMFilterDisableFlag = b; }
605  Void      setUsePCM                       ( Bool  b )     {  m_usePCM = b;               }
606  Void      setPCMLog2MaxSize               ( UInt u )      { m_pcmLog2MaxSize = u;      }
607  Void      setPCMLog2MinSize               ( UInt u )     { m_uiPCMLog2MinSize = u;      }
608  Void      setdQPs                         ( Int*  p )     { m_aidQP       = p; }
609  Void      setDeltaQpRD                    ( UInt  u )     {m_uiDeltaQpRD  = u; }
610  Bool      getUseASR                       ()      { return m_bUseASR;     }
611  Bool      getUseHADME                     ()      { return m_bUseHADME;   }
612  Bool      getUseRDOQ                      ()      { return m_useRDOQ;    }
613  Bool      getUseRDOQTS                    ()      { return m_useRDOQTS;  }
614  Int      getRDpenalty                  ()      { return m_rdPenalty;  }
615  Bool      getUseFastEnc                   ()      { return m_bUseFastEnc; }
616  Bool      getUseEarlyCU                   ()      { return m_bUseEarlyCU; }
617  Bool      getUseFastDecisionForMerge      ()      { return m_useFastDecisionForMerge; }
618  Bool      getUseCbfFastMode           ()      { return m_bUseCbfFastMode; }
619  Bool      getUseEarlySkipDetection        ()      { return m_useEarlySkipDetection; }
620  Bool      getUseConstrainedIntraPred      ()      { return m_bUseConstrainedIntraPred; }
621  Bool      getPCMInputBitDepthFlag         ()      { return m_bPCMInputBitDepthFlag;   }
622  Bool      getPCMFilterDisableFlag         ()      { return m_bPCMFilterDisableFlag;   } 
623  Bool      getUsePCM                       ()      { return m_usePCM;                 }
624  UInt      getPCMLog2MaxSize               ()      { return m_pcmLog2MaxSize;  }
625  UInt      getPCMLog2MinSize               ()      { return  m_uiPCMLog2MinSize;  }
626
627  Bool getUseTransformSkip                             ()      { return m_useTransformSkip;        }
628  Void setUseTransformSkip                             ( Bool b ) { m_useTransformSkip  = b;       }
629  Bool getUseTransformSkipFast                         ()      { return m_useTransformSkipFast;    }
630  Void setUseTransformSkipFast                         ( Bool b ) { m_useTransformSkipFast  = b;   }
631  Int*      getdQPs                         ()      { return m_aidQP;       }
632  UInt      getDeltaQpRD                    ()      { return m_uiDeltaQpRD; }
633
634  //====== Slice ========
635  Void  setSliceMode                   ( Int  i )       { m_sliceMode = i;              }
636  Void  setSliceArgument               ( Int  i )       { m_sliceArgument = i;          }
637  Int   getSliceMode                   ()              { return m_sliceMode;           }
638  Int   getSliceArgument               ()              { return m_sliceArgument;       }
639  //====== Dependent Slice ========
640  Void  setSliceSegmentMode            ( Int  i )      { m_sliceSegmentMode = i;       }
641  Void  setSliceSegmentArgument        ( Int  i )      { m_sliceSegmentArgument = i;   }
642  Int   getSliceSegmentMode            ()              { return m_sliceSegmentMode;    }
643  Int   getSliceSegmentArgument        ()              { return m_sliceSegmentArgument;}
644  Void      setLFCrossSliceBoundaryFlag     ( Bool   bValue  )    { m_bLFCrossSliceBoundaryFlag = bValue; }
645  Bool      getLFCrossSliceBoundaryFlag     ()                    { return m_bLFCrossSliceBoundaryFlag;   }
646
647  Void      setUseSAO                  (Bool bVal)     {m_bUseSAO = bVal;}
648  Bool      getUseSAO                  ()              {return m_bUseSAO;}
649  Void  setMaxNumOffsetsPerPic                   (Int iVal)            { m_maxNumOffsetsPerPic = iVal; }
650  Int   getMaxNumOffsetsPerPic                   ()                    { return m_maxNumOffsetsPerPic; }
651  Void  setSaoLcuBoundary              (Bool val)      { m_saoLcuBoundary = val; }
652  Bool  getSaoLcuBoundary              ()              { return m_saoLcuBoundary; }
653  Void  setLFCrossTileBoundaryFlag               ( Bool   val  )       { m_loopFilterAcrossTilesEnabledFlag = val; }
654  Bool  getLFCrossTileBoundaryFlag               ()                    { return m_loopFilterAcrossTilesEnabledFlag;   }
655  Void  setTileUniformSpacingFlag      ( Bool b )          { m_tileUniformSpacingFlag = b; }
656  Bool  getTileUniformSpacingFlag      ()                  { return m_tileUniformSpacingFlag; }
657  Void  setNumColumnsMinus1            ( Int i )           { m_iNumColumnsMinus1 = i; }
658  Int   getNumColumnsMinus1            ()                  { return m_iNumColumnsMinus1; }
659  Void  setColumnWidth ( const std::vector<Int>& columnWidth ) { m_tileColumnWidth = columnWidth; }
660  UInt  getColumnWidth                 ( UInt columnIdx )      { return m_tileColumnWidth[columnIdx]; }
661  Void  setNumRowsMinus1               ( Int i )           { m_iNumRowsMinus1 = i; }
662  Int   getNumRowsMinus1               ()                  { return m_iNumRowsMinus1; }
663  Void  setRowHeight ( const std::vector<Int>& rowHeight)      { m_tileRowHeight = rowHeight; }
664  UInt  getRowHeight                   ( UInt rowIdx )         { return m_tileRowHeight[rowIdx]; }
665  Void  xCheckGSParameters();
666  Void  setWaveFrontSynchro(Int iWaveFrontSynchro)       { m_iWaveFrontSynchro = iWaveFrontSynchro; }
667  Int   getWaveFrontsynchro()                            { return m_iWaveFrontSynchro; }
668  Void  setWaveFrontSubstreams(Int iWaveFrontSubstreams) { m_iWaveFrontSubstreams = iWaveFrontSubstreams; }
669  Int   getWaveFrontSubstreams()                         { return m_iWaveFrontSubstreams; }
670  Void  setDecodedPictureHashSEIEnabled(Int b)           { m_decodedPictureHashSEIEnabled = b; }
671  Int   getDecodedPictureHashSEIEnabled()                { return m_decodedPictureHashSEIEnabled; }
672  Void  setBufferingPeriodSEIEnabled(Int b)              { m_bufferingPeriodSEIEnabled = b; }
673  Int   getBufferingPeriodSEIEnabled()                   { return m_bufferingPeriodSEIEnabled; }
674  Void  setPictureTimingSEIEnabled(Int b)                { m_pictureTimingSEIEnabled = b; }
675  Int   getPictureTimingSEIEnabled()                     { return m_pictureTimingSEIEnabled; }
676  Void  setRecoveryPointSEIEnabled(Int b)                { m_recoveryPointSEIEnabled = b; }
677  Int   getRecoveryPointSEIEnabled()                     { return m_recoveryPointSEIEnabled; }
678  Void  setToneMappingInfoSEIEnabled(Bool b)                 {  m_toneMappingInfoSEIEnabled = b;  }
679  Bool  getToneMappingInfoSEIEnabled()                       {  return m_toneMappingInfoSEIEnabled;  }
680  Void  setTMISEIToneMapId(Int b)                            {  m_toneMapId = b;  }
681  Int   getTMISEIToneMapId()                                 {  return m_toneMapId;  }
682  Void  setTMISEIToneMapCancelFlag(Bool b)                   {  m_toneMapCancelFlag=b;  }
683  Bool  getTMISEIToneMapCancelFlag()                         {  return m_toneMapCancelFlag;  }
684  Void  setTMISEIToneMapPersistenceFlag(Bool b)              {  m_toneMapPersistenceFlag = b;  }
685  Bool   getTMISEIToneMapPersistenceFlag()                   {  return m_toneMapPersistenceFlag;  }
686  Void  setTMISEICodedDataBitDepth(Int b)                    {  m_codedDataBitDepth = b;  }
687  Int   getTMISEICodedDataBitDepth()                         {  return m_codedDataBitDepth;  }
688  Void  setTMISEITargetBitDepth(Int b)                       {  m_targetBitDepth = b;  }
689  Int   getTMISEITargetBitDepth()                            {  return m_targetBitDepth;  }
690  Void  setTMISEIModelID(Int b)                              {  m_modelId = b;  }
691  Int   getTMISEIModelID()                                   {  return m_modelId;  }
692  Void  setTMISEIMinValue(Int b)                             {  m_minValue = b;  }
693  Int   getTMISEIMinValue()                                  {  return m_minValue;  }
694  Void  setTMISEIMaxValue(Int b)                             {  m_maxValue = b;  }
695  Int   getTMISEIMaxValue()                                  {  return m_maxValue;  }
696  Void  setTMISEISigmoidMidpoint(Int b)                      {  m_sigmoidMidpoint = b;  }
697  Int   getTMISEISigmoidMidpoint()                           {  return m_sigmoidMidpoint;  }
698  Void  setTMISEISigmoidWidth(Int b)                         {  m_sigmoidWidth = b;  }
699  Int   getTMISEISigmoidWidth()                              {  return m_sigmoidWidth;  }
700  Void  setTMISEIStartOfCodedInterva( Int*  p )              {  m_startOfCodedInterval = p;  }
701  Int*  getTMISEIStartOfCodedInterva()                       {  return m_startOfCodedInterval;  }
702  Void  setTMISEINumPivots(Int b)                            {  m_numPivots = b;  }
703  Int   getTMISEINumPivots()                                 {  return m_numPivots;  }
704  Void  setTMISEICodedPivotValue( Int*  p )                  {  m_codedPivotValue = p;  }
705  Int*  getTMISEICodedPivotValue()                           {  return m_codedPivotValue;  }
706  Void  setTMISEITargetPivotValue( Int*  p )                 {  m_targetPivotValue = p;  }
707  Int*  getTMISEITargetPivotValue()                          {  return m_targetPivotValue;  }
708  Void  setTMISEICameraIsoSpeedIdc(Int b)                    {  m_cameraIsoSpeedIdc = b;  }
709  Int   getTMISEICameraIsoSpeedIdc()                         {  return m_cameraIsoSpeedIdc;  }
710  Void  setTMISEICameraIsoSpeedValue(Int b)                  {  m_cameraIsoSpeedValue = b;  }
711  Int   getTMISEICameraIsoSpeedValue()                       {  return m_cameraIsoSpeedValue;  }
712  Void  setTMISEIExposureIndexIdc(Int b)                     {  m_exposureIndexIdc = b;  }
713  Int   getTMISEIExposurIndexIdc()                           {  return m_exposureIndexIdc;  }
714  Void  setTMISEIExposureIndexValue(Int b)                   {  m_exposureIndexValue = b;  }
715  Int   getTMISEIExposurIndexValue()                         {  return m_exposureIndexValue;  }
716  Void  setTMISEIExposureCompensationValueSignFlag(Int b)    {  m_exposureCompensationValueSignFlag = b;  }
717  Int   getTMISEIExposureCompensationValueSignFlag()         {  return m_exposureCompensationValueSignFlag;  }
718  Void  setTMISEIExposureCompensationValueNumerator(Int b)   {  m_exposureCompensationValueNumerator = b;  }
719  Int   getTMISEIExposureCompensationValueNumerator()        {  return m_exposureCompensationValueNumerator;  }
720  Void  setTMISEIExposureCompensationValueDenomIdc(Int b)    {  m_exposureCompensationValueDenomIdc =b;  }
721  Int   getTMISEIExposureCompensationValueDenomIdc()         {  return m_exposureCompensationValueDenomIdc;  }
722  Void  setTMISEIRefScreenLuminanceWhite(Int b)              {  m_refScreenLuminanceWhite = b;  }
723  Int   getTMISEIRefScreenLuminanceWhite()                   {  return m_refScreenLuminanceWhite;  }
724  Void  setTMISEIExtendedRangeWhiteLevel(Int b)              {  m_extendedRangeWhiteLevel = b;  }
725  Int   getTMISEIExtendedRangeWhiteLevel()                   {  return m_extendedRangeWhiteLevel;  }
726  Void  setTMISEINominalBlackLevelLumaCodeValue(Int b)       {  m_nominalBlackLevelLumaCodeValue = b;  }
727  Int   getTMISEINominalBlackLevelLumaCodeValue()            {  return m_nominalBlackLevelLumaCodeValue;  }
728  Void  setTMISEINominalWhiteLevelLumaCodeValue(Int b)       {  m_nominalWhiteLevelLumaCodeValue = b;  }
729  Int   getTMISEINominalWhiteLevelLumaCodeValue()            {  return m_nominalWhiteLevelLumaCodeValue;  }
730  Void  setTMISEIExtendedWhiteLevelLumaCodeValue(Int b)      {  m_extendedWhiteLevelLumaCodeValue =b;  }
731  Int   getTMISEIExtendedWhiteLevelLumaCodeValue()           {  return m_extendedWhiteLevelLumaCodeValue;  }
732  Void  setFramePackingArrangementSEIEnabled(Int b)      { m_framePackingSEIEnabled = b; }
733  Int   getFramePackingArrangementSEIEnabled()           { return m_framePackingSEIEnabled; }
734  Void  setFramePackingArrangementSEIType(Int b)         { m_framePackingSEIType = b; }
735  Int   getFramePackingArrangementSEIType()              { return m_framePackingSEIType; }
736  Void  setFramePackingArrangementSEIId(Int b)           { m_framePackingSEIId = b; }
737  Int   getFramePackingArrangementSEIId()                { return m_framePackingSEIId; }
738  Void  setFramePackingArrangementSEIQuincunx(Int b)     { m_framePackingSEIQuincunx = b; }
739  Int   getFramePackingArrangementSEIQuincunx()          { return m_framePackingSEIQuincunx; }
740  Void  setFramePackingArrangementSEIInterpretation(Int b)  { m_framePackingSEIInterpretation = b; }
741  Int   getFramePackingArrangementSEIInterpretation()    { return m_framePackingSEIInterpretation; }
742  Void  setDisplayOrientationSEIAngle(Int b)             { m_displayOrientationSEIAngle = b; }
743  Int   getDisplayOrientationSEIAngle()                  { return m_displayOrientationSEIAngle; }
744  Void  setTemporalLevel0IndexSEIEnabled(Int b)          { m_temporalLevel0IndexSEIEnabled = b; }
745  Int   getTemporalLevel0IndexSEIEnabled()               { return m_temporalLevel0IndexSEIEnabled; }
746  Void  setGradualDecodingRefreshInfoEnabled(Int b)      { m_gradualDecodingRefreshInfoEnabled = b;    }
747  Int   getGradualDecodingRefreshInfoEnabled()           { return m_gradualDecodingRefreshInfoEnabled; }
748  Void  setDecodingUnitInfoSEIEnabled(Int b)                { m_decodingUnitInfoSEIEnabled = b;    }
749  Int   getDecodingUnitInfoSEIEnabled()                     { return m_decodingUnitInfoSEIEnabled; }
750  Void  setSOPDescriptionSEIEnabled(Int b)                { m_SOPDescriptionSEIEnabled = b; }
751  Int   getSOPDescriptionSEIEnabled()                     { return m_SOPDescriptionSEIEnabled; }
752  Void  setScalableNestingSEIEnabled(Int b)                { m_scalableNestingSEIEnabled = b; }
753  Int   getScalableNestingSEIEnabled()                     { return m_scalableNestingSEIEnabled; }
754
755#if H_MV
756  Bool   getSubBitstreamPropSEIEnabled()        { return m_subBistreamPropSEIEnabled;}
757  Void   setSubBitstreamPropSEIEnabled(Bool x)  { m_subBistreamPropSEIEnabled = x;}
758
759  Int    getNumAdditionalSubStreams()           { return m_numAdditionalSubStreams;}
760  Void   setNumAdditionalSubStreams(Int x)      { m_numAdditionalSubStreams = x;}
761
762  std::vector<Int> const &getSubBitstreamMode()  { return m_subBitstreamMode;}
763  Int   getSubBitstreamMode(Int idx)  { return m_subBitstreamMode[idx];}
764  Void  setSubBitstreamMode(std::vector<Int> &x)  { m_subBitstreamMode = x;}
765
766  std::vector<Int> const &getOutputLayerSetIdxToVps()  { return m_outputLayerSetIdxToVps;}
767  Int   getOutputLayerSetIdxToVps(Int idx)  { return m_outputLayerSetIdxToVps[idx];}
768  Void  setOutputLayerSetIdxToVps(std::vector<Int> &x)  { m_outputLayerSetIdxToVps = x;}
769
770  std::vector<Int> const &getHighestSublayerId()  { return m_highestSublayerId;}
771  Int   getHighestSublayerId(Int idx)  { return m_highestSublayerId[idx];}
772  Void  setHighestSublayerId(std::vector<Int> &x)  { m_highestSublayerId = x;}
773
774  std::vector<Int> const &getAvgBitRate()  { return m_avgBitRate;}
775  Int   getAvgBitRate(Int idx)  { return m_avgBitRate[idx];}
776  Void  setAvgBitRate(std::vector<Int> &x)  { m_avgBitRate = x;}
777
778  std::vector<Int> const &getMaxBitRate()  { return m_maxBitRate;}
779  Int   getMaxBitRate(Int idx)  { return m_maxBitRate[idx];}
780  Void  setMaxBitRate(std::vector<Int> &x)  { m_maxBitRate = x;}
781
782#endif
783  Void      setUseWP               ( Bool b )    { m_useWeightedPred   = b;    }
784  Void      setWPBiPred            ( Bool b )    { m_useWeightedBiPred = b;    }
785  Bool      getUseWP               ()            { return m_useWeightedPred;   }
786  Bool      getWPBiPred            ()            { return m_useWeightedBiPred; }
787  Void      setLog2ParallelMergeLevelMinus2   ( UInt u )    { m_log2ParallelMergeLevelMinus2       = u;    }
788  UInt      getLog2ParallelMergeLevelMinus2   ()            { return m_log2ParallelMergeLevelMinus2;       }
789  Void      setMaxNumMergeCand                ( UInt u )    { m_maxNumMergeCand = u;      }
790  UInt      getMaxNumMergeCand                ()            { return m_maxNumMergeCand;   }
791  Void      setUseScalingListId    ( Int  u )    { m_useScalingListId       = u;   }
792  Int       getUseScalingListId    ()            { return m_useScalingListId;      }
793  Void      setScalingListFile     ( Char*  pch ){ m_scalingListFile     = pch; }
794  Char*     getScalingListFile     ()            { return m_scalingListFile;    }
795  Void      setTMVPModeId ( Int  u ) { m_TMVPModeId = u;    }
796  Int       getTMVPModeId ()         { return m_TMVPModeId; }
797  Void      setSignHideFlag( Int signHideFlag ) { m_signHideFlag = signHideFlag; }
798  Int       getSignHideFlag()                    { return m_signHideFlag; }
799  Bool      getUseRateCtrl         ()              { return m_RCEnableRateControl;   }
800  Void      setUseRateCtrl         ( Bool b )      { m_RCEnableRateControl = b;      }
801  Int       getTargetBitrate       ()              { return m_RCTargetBitrate;       }
802  Void      setTargetBitrate       ( Int bitrate ) { m_RCTargetBitrate  = bitrate;   }
803  Int       getKeepHierBit         ()              { return m_RCKeepHierarchicalBit; }
804  Void      setKeepHierBit         ( Int i )       { m_RCKeepHierarchicalBit = i;    }
805  Bool      getLCULevelRC          ()              { return m_RCLCULevelRC; }
806  Void      setLCULevelRC          ( Bool b )      { m_RCLCULevelRC = b; }
807  Bool      getUseLCUSeparateModel ()              { return m_RCUseLCUSeparateModel; }
808  Void      setUseLCUSeparateModel ( Bool b )      { m_RCUseLCUSeparateModel = b;    }
809  Int       getInitialQP           ()              { return m_RCInitialQP;           }
810  Void      setInitialQP           ( Int QP )      { m_RCInitialQP = QP;             }
811  Bool      getForceIntraQP        ()              { return m_RCForceIntraQP;        }
812  Void      setForceIntraQP        ( Bool b )      { m_RCForceIntraQP = b;           }
813
814#if KWU_RC_MADPRED_E0227
815  UInt      getUseDepthMADPred    ()                { return m_depthMADPred;        }
816  Void      setUseDepthMADPred    (UInt b)          { m_depthMADPred    = b;        }
817#endif
818#if KWU_RC_VIEWRC_E0227
819  Bool      getUseViewWiseRateCtrl    ()                { return m_bViewWiseRateCtrl;        }
820  Void      setUseViewWiseRateCtrl    (Bool b)          { m_bViewWiseRateCtrl    = b;        }
821#endif
822  Bool      getTransquantBypassEnableFlag()           { return m_TransquantBypassEnableFlag; }
823  Void      setTransquantBypassEnableFlag(Bool flag)  { m_TransquantBypassEnableFlag = flag; }
824  Bool      getCUTransquantBypassFlagForceValue()          { return m_CUTransquantBypassFlagForce; }
825  Void      setCUTransquantBypassFlagForceValue(Bool flag) { m_CUTransquantBypassFlagForce = flag; }
826#if H_MV
827  Void      setVPS           ( TComVPS *p ) { m_cVPS = p;    }
828  TComVPS*  getVPS           ()             { return m_cVPS; }
829#else
830  Void setVPS(TComVPS *p) { m_cVPS = *p; }
831  TComVPS *getVPS() { return &m_cVPS; }
832#endif
833
834#if H_3D
835  Void      setDLT           ( TComDLT *p ) { m_cDLT = p; }
836  TComDLT*  getDLT           ()             { return m_cDLT; }
837#endif
838
839  Void      setUseRecalculateQPAccordingToLambda ( Bool b ) { m_recalculateQPAccordingToLambda = b;    }
840  Bool      getUseRecalculateQPAccordingToLambda ()         { return m_recalculateQPAccordingToLambda; }
841
842  Void      setUseStrongIntraSmoothing ( Bool b ) { m_useStrongIntraSmoothing = b;    }
843  Bool      getUseStrongIntraSmoothing ()         { return m_useStrongIntraSmoothing; }
844
845  Void      setActiveParameterSetsSEIEnabled ( Int b )  { m_activeParameterSetsSEIEnabled = b; } 
846  Int       getActiveParameterSetsSEIEnabled ()         { return m_activeParameterSetsSEIEnabled; }
847  Bool      getVuiParametersPresentFlag()                 { return m_vuiParametersPresentFlag; }
848  Void      setVuiParametersPresentFlag(Bool i)           { m_vuiParametersPresentFlag = i; }
849  Bool      getAspectRatioInfoPresentFlag()               { return m_aspectRatioInfoPresentFlag; }
850  Void      setAspectRatioInfoPresentFlag(Bool i)         { m_aspectRatioInfoPresentFlag = i; }
851  Int       getAspectRatioIdc()                           { return m_aspectRatioIdc; }
852  Void      setAspectRatioIdc(Int i)                      { m_aspectRatioIdc = i; }
853  Int       getSarWidth()                                 { return m_sarWidth; }
854  Void      setSarWidth(Int i)                            { m_sarWidth = i; }
855  Int       getSarHeight()                                { return m_sarHeight; }
856  Void      setSarHeight(Int i)                           { m_sarHeight = i; }
857  Bool      getOverscanInfoPresentFlag()                  { return m_overscanInfoPresentFlag; }
858  Void      setOverscanInfoPresentFlag(Bool i)            { m_overscanInfoPresentFlag = i; }
859  Bool      getOverscanAppropriateFlag()                  { return m_overscanAppropriateFlag; }
860  Void      setOverscanAppropriateFlag(Bool i)            { m_overscanAppropriateFlag = i; }
861  Bool      getVideoSignalTypePresentFlag()               { return m_videoSignalTypePresentFlag; }
862  Void      setVideoSignalTypePresentFlag(Bool i)         { m_videoSignalTypePresentFlag = i; }
863  Int       getVideoFormat()                              { return m_videoFormat; }
864  Void      setVideoFormat(Int i)                         { m_videoFormat = i; }
865  Bool      getVideoFullRangeFlag()                       { return m_videoFullRangeFlag; }
866  Void      setVideoFullRangeFlag(Bool i)                 { m_videoFullRangeFlag = i; }
867  Bool      getColourDescriptionPresentFlag()             { return m_colourDescriptionPresentFlag; }
868  Void      setColourDescriptionPresentFlag(Bool i)       { m_colourDescriptionPresentFlag = i; }
869  Int       getColourPrimaries()                          { return m_colourPrimaries; }
870  Void      setColourPrimaries(Int i)                     { m_colourPrimaries = i; }
871  Int       getTransferCharacteristics()                  { return m_transferCharacteristics; }
872  Void      setTransferCharacteristics(Int i)             { m_transferCharacteristics = i; }
873  Int       getMatrixCoefficients()                       { return m_matrixCoefficients; }
874  Void      setMatrixCoefficients(Int i)                  { m_matrixCoefficients = i; }
875  Bool      getChromaLocInfoPresentFlag()                 { return m_chromaLocInfoPresentFlag; }
876  Void      setChromaLocInfoPresentFlag(Bool i)           { m_chromaLocInfoPresentFlag = i; }
877  Int       getChromaSampleLocTypeTopField()              { return m_chromaSampleLocTypeTopField; }
878  Void      setChromaSampleLocTypeTopField(Int i)         { m_chromaSampleLocTypeTopField = i; }
879  Int       getChromaSampleLocTypeBottomField()           { return m_chromaSampleLocTypeBottomField; }
880  Void      setChromaSampleLocTypeBottomField(Int i)      { m_chromaSampleLocTypeBottomField = i; }
881  Bool      getNeutralChromaIndicationFlag()              { return m_neutralChromaIndicationFlag; }
882  Void      setNeutralChromaIndicationFlag(Bool i)        { m_neutralChromaIndicationFlag = i; }
883  Window   &getDefaultDisplayWindow()                     { return m_defaultDisplayWindow; }
884  Void      setDefaultDisplayWindow (Int offsetLeft, Int offsetRight, Int offsetTop, Int offsetBottom ) { m_defaultDisplayWindow.setWindow (offsetLeft, offsetRight, offsetTop, offsetBottom); }
885  Bool      getFrameFieldInfoPresentFlag()                { return m_frameFieldInfoPresentFlag; }
886  Void      setFrameFieldInfoPresentFlag(Bool i)          { m_frameFieldInfoPresentFlag = i; } 
887  Bool      getPocProportionalToTimingFlag()              { return m_pocProportionalToTimingFlag; }
888  Void      setPocProportionalToTimingFlag(Bool x)        { m_pocProportionalToTimingFlag = x;    }
889  Int       getNumTicksPocDiffOneMinus1()                 { return m_numTicksPocDiffOneMinus1;    }
890  Void      setNumTicksPocDiffOneMinus1(Int x)            { m_numTicksPocDiffOneMinus1 = x;       }
891  Bool      getBitstreamRestrictionFlag()                 { return m_bitstreamRestrictionFlag; }
892  Void      setBitstreamRestrictionFlag(Bool i)           { m_bitstreamRestrictionFlag = i; }
893  Bool      getTilesFixedStructureFlag()                  { return m_tilesFixedStructureFlag; }
894  Void      setTilesFixedStructureFlag(Bool i)            { m_tilesFixedStructureFlag = i; }
895  Bool      getMotionVectorsOverPicBoundariesFlag()       { return m_motionVectorsOverPicBoundariesFlag; }
896  Void      setMotionVectorsOverPicBoundariesFlag(Bool i) { m_motionVectorsOverPicBoundariesFlag = i; }
897  Int       getMinSpatialSegmentationIdc()                { return m_minSpatialSegmentationIdc; }
898  Void      setMinSpatialSegmentationIdc(Int i)           { m_minSpatialSegmentationIdc = i; }
899  Int       getMaxBytesPerPicDenom()                      { return m_maxBytesPerPicDenom; }
900  Void      setMaxBytesPerPicDenom(Int i)                 { m_maxBytesPerPicDenom = i; }
901  Int       getMaxBitsPerMinCuDenom()                     { return m_maxBitsPerMinCuDenom; }
902  Void      setMaxBitsPerMinCuDenom(Int i)                { m_maxBitsPerMinCuDenom = i; }
903  Int       getLog2MaxMvLengthHorizontal()                { return m_log2MaxMvLengthHorizontal; }
904  Void      setLog2MaxMvLengthHorizontal(Int i)           { m_log2MaxMvLengthHorizontal = i; }
905  Int       getLog2MaxMvLengthVertical()                  { return m_log2MaxMvLengthVertical; }
906  Void      setLog2MaxMvLengthVertical(Int i)             { m_log2MaxMvLengthVertical = i; }
907 
908  Bool getProgressiveSourceFlag() const { return m_progressiveSourceFlag; }
909  Void setProgressiveSourceFlag(Bool b) { m_progressiveSourceFlag = b; }
910 
911  Bool getInterlacedSourceFlag() const { return m_interlacedSourceFlag; }
912  Void setInterlacedSourceFlag(Bool b) { m_interlacedSourceFlag = b; }
913 
914  Bool getNonPackedConstraintFlag() const { return m_nonPackedConstraintFlag; }
915  Void setNonPackedConstraintFlag(Bool b) { m_nonPackedConstraintFlag = b; }
916 
917  Bool getFrameOnlyConstraintFlag() const { return m_frameOnlyConstraintFlag; }
918  Void setFrameOnlyConstraintFlag(Bool b) { m_frameOnlyConstraintFlag = b; }
919#if H_3D
920
921  // Only flags that are not in the SPS3dExtension should go here.
922  /// 3D Tools
923
924 //==== CAMERA PARAMETERS  ==========
925#if !HHI_CAM_PARA_K0052
926  Void      setCamParPrecision              ( UInt  u )      { m_uiCamParPrecision      = u; }
927  Void      setCamParInSliceHeader          ( Bool  b )      { m_bCamParInSliceHeader   = b; }
928  Void      setCodedScale                   ( Int** p )      { m_aaiCodedScale          = p; }
929  Void      setCodedOffset                  ( Int** p )      { m_aaiCodedOffset         = p; }
930#endif
931  Void      setCameraParameters             ( TAppComCamPara* c) { m_cameraParameters   = c; }
932
933#if H_3D_VSO
934 //==== VSO  ==========
935  Void      setRenderModelParameters ( TRenModSetupStrParser* c ) { m_renderModelParameters = c; }
936  Bool      getUseVSO                       ()              { return m_bUseVSO;     }
937  Void      setUseVSO                       ( Bool  b  )    { m_bUseVSO     = b; }
938  UInt      getVSOMode                      ()              { return m_uiVSOMode; }
939  Void      setVSOMode                      ( UInt  ui )    { m_uiVSOMode   = ui; }
940  Bool      getForceLambdaScaleVSO          ()              { return m_bForceLambdaScale; }
941  Void      setForceLambdaScaleVSO          ( Bool   b )    { m_bForceLambdaScale = b; };
942  Double    getLambdaScaleVSO               ()              { return m_dLambdaScaleVSO;   }
943  Void      setLambdaScaleVSO               ( Double d )    { m_dLambdaScaleVSO   = d; };
944  Bool      getAllowNegDist                 ()              { return m_bAllowNegDist;     }
945  Void      setAllowNegDist                 ( Bool   b )    { m_bAllowNegDist     = b; };
946
947  // LGE_WVSO_A0119
948  Bool      getUseWVSO                      ()              { return m_bUseWVSO;     }
949  Void      setUseWVSO                      ( Bool  b )     { m_bUseWVSO   = b; }
950  Int       getVSOWeight                    ()              { return m_iVSOWeight;    }
951  Void      setVSOWeight                    ( Int   i )     { m_iVSOWeight = i; }
952  Int       getVSDWeight                    ()              { return m_iVSDWeight;    }
953  Void      setVSDWeight                    ( Int   i )     { m_iVSDWeight = i; }
954  Int       getDWeight                      ()              { return m_iDWeight;    }
955  Void      setDWeight                      ( Int   i )     { m_iDWeight   = i; }
956
957  // SAIT_VSO_EST_A0033
958  Bool      getUseEstimatedVSD              ()              { return m_bUseEstimatedVSD; }
959  Void      setUseEstimatedVSD              ( Bool  b )     { m_bUseEstimatedVSD = b; }
960  Double    getDispCoeff                    ()              { return m_dDispCoeff;    }
961  Void      setDispCoeff                    ( Double  d )   { m_dDispCoeff  = d; }
962#endif // H_3D_VSO
963
964 //==== DIM  ==========
965#if H_3D_DIM
966  Bool      getUseDMM                       ()        { return m_useDMM; }
967  Void      setUseDMM                       ( Bool b) { m_useDMM = b;    }
968  Bool      getUseSDC                       ()        { return m_useSDC; }
969  Void      setUseSDC                       ( Bool b) { m_useSDC = b;    }
970
971  Bool      getUseDLT                       ()        { return m_useDLT; }
972  Void      setUseDLT                       ( Bool b) { m_useDLT = b;    }
973#endif
974#if H_3D_QTLPC
975  Void      setUseQTL                       ( Bool b ) { m_bUseQTL = b;    }
976  Bool      getUseQTL                       ()         { return m_bUseQTL; }
977#endif
978#if H_3D_ANNEX_SELECTION_FIX
979  Void                    setProfileIdc( Int a )    { assert( a == 1 || a == 6 || a == 8 ); m_profileIdc = a;  }
980  Bool                    decProcAnnexI()           { assert( m_profileIdc != -1 ); return ( m_profileIdc == 8); }   
981#endif
982
983#endif // H_3D
984};
985
986//! \}
987
988#endif // !defined(AFX_TENCCFG_H__6B99B797_F4DA_4E46_8E78_7656339A6C41__INCLUDED_)
Note: See TracBrowser for help on using the repository browser.