[313] | 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 |
---|
[1029] | 4 | * granted under this license. |
---|
[313] | 5 | * |
---|
[1549] | 6 | * Copyright (c) 2010-2016, ITU/ISO/IEC |
---|
[313] | 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 TAppEncCfg.h |
---|
| 35 | \brief Handle encoder configuration parameters (header) |
---|
| 36 | */ |
---|
| 37 | |
---|
| 38 | #ifndef __TAPPENCCFG__ |
---|
| 39 | #define __TAPPENCCFG__ |
---|
| 40 | |
---|
| 41 | #include "TLibCommon/CommonDef.h" |
---|
| 42 | |
---|
| 43 | #include "TLibEncoder/TEncCfg.h" |
---|
| 44 | #if SVC_EXTENSION |
---|
| 45 | #include "TAppEncLayerCfg.h" |
---|
| 46 | #endif |
---|
| 47 | #include <sstream> |
---|
[823] | 48 | #include <vector> |
---|
[313] | 49 | //! \ingroup TAppEncoder |
---|
| 50 | //! \{ |
---|
| 51 | |
---|
[1487] | 52 | #if SCALABLE_REXT |
---|
| 53 | enum ExtendedProfileName // this is used for determining profile strings, where multiple profiles map to a single profile idc with various constraint flag combinations |
---|
| 54 | { |
---|
| 55 | NONE = 0, |
---|
| 56 | MAIN = 1, |
---|
| 57 | MAIN10 = 2, |
---|
| 58 | MAINSTILLPICTURE = 3, |
---|
| 59 | MAINREXT = 4, |
---|
| 60 | HIGHTHROUGHPUTREXT = 5, // Placeholder profile for development |
---|
| 61 | #if SVC_EXTENSION |
---|
| 62 | MULTIVIEWMAIN = 6, |
---|
| 63 | SCALABLEMAIN = 7, |
---|
| 64 | SCALABLEMAIN10 = 8, |
---|
| 65 | #if SCALABLE_REXT |
---|
| 66 | SCALABLEREXT = 10, |
---|
| 67 | #endif |
---|
| 68 | #endif |
---|
| 69 | // The following are RExt profiles, which would map to the MAINREXT profile idc. |
---|
| 70 | // The enumeration indicates the bit-depth constraint in the bottom 2 digits |
---|
| 71 | // the chroma format in the next digit |
---|
| 72 | // the intra constraint in the next digit |
---|
| 73 | // If it is a RExt still picture, there is a '1' for the next digit, |
---|
| 74 | // If it is a Scalable Rext profile, there is a '1' for the top digit. |
---|
| 75 | MONOCHROME_8 = 1008, |
---|
| 76 | MONOCHROME_12 = 1012, |
---|
| 77 | MONOCHROME_16 = 1016, |
---|
| 78 | MAIN_12 = 1112, |
---|
| 79 | MAIN_422_10 = 1210, |
---|
| 80 | MAIN_422_12 = 1212, |
---|
| 81 | MAIN_444 = 1308, |
---|
| 82 | MAIN_444_10 = 1310, |
---|
| 83 | MAIN_444_12 = 1312, |
---|
| 84 | MAIN_444_16 = 1316, // non-standard profile definition, used for development purposes |
---|
| 85 | MAIN_INTRA = 2108, |
---|
| 86 | MAIN_10_INTRA = 2110, |
---|
| 87 | MAIN_12_INTRA = 2112, |
---|
| 88 | MAIN_422_10_INTRA = 2210, |
---|
| 89 | MAIN_422_12_INTRA = 2212, |
---|
| 90 | MAIN_444_INTRA = 2308, |
---|
| 91 | MAIN_444_10_INTRA = 2310, |
---|
| 92 | MAIN_444_12_INTRA = 2312, |
---|
| 93 | MAIN_444_16_INTRA = 2316, |
---|
| 94 | MAIN_444_STILL_PICTURE = 11308, |
---|
| 95 | MAIN_444_16_STILL_PICTURE = 12316 |
---|
| 96 | #if SCALABLE_REXT |
---|
| 97 | , |
---|
| 98 | SCALABLE_MONOCHROME_8 = 101008, |
---|
| 99 | SCALABLE_MONOCHROME_12 = 101012, |
---|
| 100 | SCALABLE_MONOCHROME_16 = 101016, |
---|
| 101 | SCALABLE_MAIN_444 = 101308 |
---|
| 102 | #endif |
---|
| 103 | }; |
---|
| 104 | #endif |
---|
| 105 | |
---|
[313] | 106 | // ==================================================================================================================== |
---|
| 107 | // Class definition |
---|
| 108 | // ==================================================================================================================== |
---|
| 109 | |
---|
| 110 | /// encoder configuration class |
---|
| 111 | class TAppEncCfg |
---|
| 112 | { |
---|
| 113 | protected: |
---|
| 114 | // file I/O |
---|
| 115 | #if SVC_EXTENSION |
---|
[1377] | 116 | TAppEncLayerCfg* m_apcLayerCfg[MAX_LAYERS]; |
---|
[1057] | 117 | Int m_layerId; |
---|
[313] | 118 | Int m_numLayers; ///< number of layers |
---|
| 119 | Int m_scalabilityMask[MAX_VPS_NUM_SCALABILITY_TYPES]; ///< scalability_mask |
---|
[1534] | 120 | #if VIEW_SCALABILITY |
---|
| 121 | Int m_iNumberOfViews; ///< number of views |
---|
| 122 | std::vector<Int> m_ViewIdVal; |
---|
| 123 | #endif |
---|
[442] | 124 | Bool m_maxTidRefPresentFlag; |
---|
[1172] | 125 | |
---|
[815] | 126 | Int m_numLayerSets; |
---|
[1172] | 127 | Int m_numAddLayerSets; |
---|
[815] | 128 | Int m_numLayerInIdList[MAX_VPS_LAYER_SETS_PLUS1]; |
---|
[1045] | 129 | Int m_layerSetLayerIdList[MAX_VPS_LAYER_SETS_PLUS1][MAX_VPS_LAYER_IDX_PLUS1]; |
---|
[815] | 130 | Int m_numHighestLayerIdx[MAX_VPS_LAYER_SETS_PLUS1]; |
---|
[1045] | 131 | Int m_highestLayerIdx[MAX_VPS_LAYER_SETS_PLUS1][MAX_VPS_LAYER_IDX_PLUS1]; |
---|
[1172] | 132 | |
---|
[861] | 133 | Int m_defaultTargetOutputLayerIdc; |
---|
| 134 | Int m_numOutputLayerSets; |
---|
[1162] | 135 | std::vector<Int> m_outputLayerSetIdx; |
---|
[950] | 136 | std::vector<Int> m_numOutputLayersInOutputLayerSet; |
---|
[861] | 137 | std::vector< std::vector<Int> > m_listOfOutputLayers; |
---|
[313] | 138 | #else |
---|
[1442] | 139 | std::string m_inputFileName; ///< source file name |
---|
[1366] | 140 | #endif |
---|
[1442] | 141 | std::string m_bitstreamFileName; ///< output bitstream file |
---|
[1366] | 142 | #if !SVC_EXTENSION |
---|
[1442] | 143 | std::string m_reconFileName; ///< output reconstruction file |
---|
[1366] | 144 | #endif |
---|
[1391] | 145 | // Lambda modifiers |
---|
[313] | 146 | Double m_adLambdaModifier[ MAX_TLAYER ]; ///< Lambda modifier array for each temporal layer |
---|
[1391] | 147 | std::vector<Double> m_adIntraLambdaModifier; ///< Lambda modifier for Intra pictures, one for each temporal layer. If size>temporalLayer, then use [temporalLayer], else if size>0, use [size()-1], else use m_adLambdaModifier. |
---|
| 148 | Double m_dIntraQpFactor; ///< Intra Q Factor. If negative, use a default equation: 0.57*(1.0 - Clip3( 0.0, 0.5, 0.05*(Double)(isField ? (GopSize-1)/2 : GopSize-1) )) |
---|
| 149 | |
---|
[313] | 150 | // source specification |
---|
[1366] | 151 | #if !SVC_EXTENSION |
---|
[313] | 152 | Int m_iFrameRate; ///< source frame-rates (Hz) |
---|
[1366] | 153 | #endif |
---|
[1544] | 154 | UInt m_FrameSkip; ///< number of skipped frames from the beginning |
---|
| 155 | UInt m_temporalSubsampleRatio; ///< temporal subsample ratio, 2 means code every two frames |
---|
[1366] | 156 | #if !SVC_EXTENSION |
---|
[313] | 157 | Int m_iSourceWidth; ///< source width in pixel |
---|
[442] | 158 | Int m_iSourceHeight; ///< source height in pixel (when interlaced = field height) |
---|
[1029] | 159 | |
---|
[442] | 160 | Int m_iSourceHeightOrg; ///< original source height in pixel (when interlaced = frame height) |
---|
[1326] | 161 | #endif |
---|
[1029] | 162 | Bool m_isField; ///< enable field coding |
---|
| 163 | Bool m_isTopFieldFirst; |
---|
[1325] | 164 | Bool m_bEfficientFieldIRAPEnabled; ///< enable an efficient field IRAP structure. |
---|
[1329] | 165 | Bool m_bHarmonizeGopFirstFieldCoupleEnabled; |
---|
[1029] | 166 | |
---|
[1326] | 167 | #if !SVC_EXTENSION |
---|
[823] | 168 | Int m_conformanceWindowMode; |
---|
| 169 | Int m_confWinLeft; |
---|
| 170 | Int m_confWinRight; |
---|
| 171 | Int m_confWinTop; |
---|
| 172 | Int m_confWinBottom; |
---|
[1366] | 173 | #endif |
---|
[313] | 174 | Int m_framesToBeEncoded; ///< number of encoded frames |
---|
[1366] | 175 | #if !SVC_EXTENSION |
---|
[313] | 176 | Int m_aiPad[2]; ///< number of padded pixels for width and height |
---|
[1415] | 177 | #endif |
---|
| 178 | Bool m_AccessUnitDelimiter; ///< add Access Unit Delimiter NAL units |
---|
[1029] | 179 | InputColourSpaceConversion m_inputColourSpaceConvert; ///< colour space conversion to apply to input video |
---|
| 180 | Bool m_snrInternalColourSpace; ///< if true, then no colour space conversion is applied for snr calculation, otherwise inverse of input is applied. |
---|
| 181 | Bool m_outputInternalColourSpace; ///< if true, then no colour space conversion is applied for reconstructed video, otherwise inverse of input is applied. |
---|
| 182 | #if !SVC_EXTENSION |
---|
[494] | 183 | ChromaFormat m_InputChromaFormatIDC; |
---|
| 184 | #endif |
---|
[442] | 185 | |
---|
[1029] | 186 | Bool m_printMSEBasedSequencePSNR; |
---|
| 187 | Bool m_printFrameMSE; |
---|
| 188 | Bool m_printSequenceMSE; |
---|
| 189 | Bool m_cabacZeroWordPaddingEnabled; |
---|
[1323] | 190 | Bool m_bClipInputVideoToRec709Range; |
---|
| 191 | Bool m_bClipOutputVideoToRec709Range; |
---|
[1029] | 192 | |
---|
[1182] | 193 | #if SVC_EXTENSION |
---|
[941] | 194 | Int m_numPTLInfo; |
---|
[951] | 195 | Profile::Name m_profileList[MAX_NUM_LAYER_IDS + 1]; |
---|
| 196 | Level::Tier m_levelTierList[MAX_NUM_LAYER_IDS + 1]; |
---|
| 197 | Level::Name m_levelList[MAX_NUM_LAYER_IDS + 1]; |
---|
| 198 | Profile::Name m_profileCompatibility[MAX_NUM_LAYER_IDS + 1]; |
---|
| 199 | Bool m_progressiveSourceFlagList[MAX_NUM_LAYER_IDS + 1]; |
---|
| 200 | Bool m_interlacedSourceFlagList[MAX_NUM_LAYER_IDS + 1]; |
---|
| 201 | Bool m_nonPackedConstraintFlagList[MAX_NUM_LAYER_IDS + 1]; |
---|
| 202 | Bool m_frameOnlyConstraintFlagList[MAX_NUM_LAYER_IDS + 1]; |
---|
[941] | 203 | |
---|
| 204 | std::vector< std::vector<Int> > m_listOfLayerPTLofOlss; |
---|
[942] | 205 | #else |
---|
[1029] | 206 | // profile/level |
---|
[942] | 207 | Profile::Name m_profile; |
---|
| 208 | Level::Tier m_levelTier; |
---|
| 209 | Level::Name m_level; |
---|
[1029] | 210 | UInt m_bitDepthConstraint; |
---|
| 211 | ChromaFormat m_chromaFormatConstraint; |
---|
| 212 | Bool m_intraConstraintFlag; |
---|
[1356] | 213 | Bool m_onePictureOnlyConstraintFlag; |
---|
[1029] | 214 | Bool m_lowerBitRateConstraintFlag; |
---|
[942] | 215 | Bool m_progressiveSourceFlag; |
---|
| 216 | Bool m_interlacedSourceFlag; |
---|
| 217 | Bool m_nonPackedConstraintFlag; |
---|
| 218 | Bool m_frameOnlyConstraintFlag; |
---|
[941] | 219 | #endif |
---|
[942] | 220 | |
---|
[313] | 221 | // coding structure |
---|
| 222 | #if !SVC_EXTENSION |
---|
| 223 | Int m_iIntraPeriod; ///< period of I-slice (random access period) |
---|
| 224 | #endif |
---|
| 225 | Int m_iDecodingRefreshType; ///< random access type |
---|
| 226 | Int m_iGOPSize; ///< GOP size of hierarchical structure |
---|
[815] | 227 | |
---|
[1448] | 228 | #if !SVC_EXTENSION |
---|
[1211] | 229 | Int m_extraRPSs; ///< extra RPSs added to handle CRA |
---|
| 230 | GOPEntry m_GOPList[MAX_GOP]; ///< the coding structure entries from the config file |
---|
[1448] | 231 | #endif |
---|
[313] | 232 | Int m_numReorderPics[MAX_TLAYER]; ///< total number of reorder pictures |
---|
| 233 | Int m_maxDecPicBuffering[MAX_TLAYER]; ///< total number of pictures in the decoded picture buffer |
---|
[1316] | 234 | Bool m_crossComponentPredictionEnabledFlag; ///< flag enabling the use of cross-component prediction |
---|
[1029] | 235 | Bool m_reconBasedCrossCPredictionEstimate; ///< causes the alpha calculation in encoder search to be based on the decoded residual rather than the pre-transform encoder-side residual |
---|
[1316] | 236 | UInt m_log2SaoOffsetScale[MAX_NUM_CHANNEL_TYPE]; ///< number of bits for the upward bit shift operation on the decoded SAO offsets |
---|
[313] | 237 | Bool m_useTransformSkip; ///< flag for enabling intra transform skipping |
---|
| 238 | Bool m_useTransformSkipFast; ///< flag for enabling fast intra transform skipping |
---|
[1316] | 239 | UInt m_log2MaxTransformSkipBlockSize; ///< transform-skip maximum size (minimum of 2) |
---|
| 240 | Bool m_transformSkipRotationEnabledFlag; ///< control flag for transform-skip/transquant-bypass residual rotation |
---|
| 241 | Bool m_transformSkipContextEnabledFlag; ///< control flag for transform-skip/transquant-bypass single significance map context |
---|
| 242 | Bool m_rdpcmEnabledFlag[NUMBER_OF_RDPCM_SIGNALLING_MODES];///< control flags for residual DPCM |
---|
[313] | 243 | Bool m_enableAMP; |
---|
[1316] | 244 | Bool m_persistentRiceAdaptationEnabledFlag; ///< control flag for Golomb-Rice parameter adaptation over each slice |
---|
| 245 | Bool m_cabacBypassAlignmentEnabledFlag; |
---|
[1029] | 246 | |
---|
[313] | 247 | // coding quality |
---|
| 248 | #if !SVC_EXTENSION |
---|
| 249 | Double m_fQP; ///< QP value of key-picture (floating point) |
---|
| 250 | Int m_iQP; ///< QP value of key-picture (integer) |
---|
[1442] | 251 | std::string m_dQPFileName; ///< QP offset for each slice (initialized from external file) |
---|
[313] | 252 | Int* m_aidQP; ///< array of slice QP values |
---|
| 253 | #endif |
---|
| 254 | Int m_iMaxDeltaQP; ///< max. |delta QP| |
---|
| 255 | UInt m_uiDeltaQpRD; ///< dQP range for multi-pass slice QP optimization |
---|
[1235] | 256 | #if !SVC_EXTENSION |
---|
[313] | 257 | Int m_iMaxCuDQPDepth; ///< Max. depth for a minimum CuDQPSize (0:default) |
---|
[1235] | 258 | #endif |
---|
[1316] | 259 | Int m_diffCuChromaQpOffsetDepth; ///< If negative, then do not apply chroma qp offsets. |
---|
[1369] | 260 | Bool m_bFastDeltaQP; ///< Fast Delta QP (false:default) |
---|
[313] | 261 | |
---|
[1029] | 262 | Int m_cbQpOffset; ///< Chroma Cb QP Offset (0:default) |
---|
[313] | 263 | Int m_crQpOffset; ///< Chroma Cr QP Offset (0:default) |
---|
[1545] | 264 | #if W0038_CQP_ADJ |
---|
| 265 | UInt m_sliceChromaQpOffsetPeriodicity; ///< Used in conjunction with Slice Cb/Cr QpOffsetIntraOrPeriodic. Use 0 (default) to disable periodic nature. |
---|
| 266 | Int m_sliceChromaQpOffsetIntraOrPeriodic[2/*Cb,Cr*/]; ///< Chroma Cb QP Offset at slice level for I slice or for periodic inter slices as defined by SliceChromaQPOffsetPeriodicity. Replaces offset in the GOP table. |
---|
| 267 | #endif |
---|
[313] | 268 | #if ADAPTIVE_QP_SELECTION |
---|
| 269 | Bool m_bUseAdaptQpSelect; |
---|
| 270 | #endif |
---|
[1029] | 271 | TComSEIMasteringDisplay m_masteringDisplay; |
---|
[313] | 272 | |
---|
| 273 | Bool m_bUseAdaptiveQP; ///< Flag for enabling QP adaptation based on a psycho-visual model |
---|
| 274 | Int m_iQPAdaptationRange; ///< dQP range by QP adaptation |
---|
[1029] | 275 | |
---|
[1448] | 276 | #if !SVC_EXTENSION |
---|
[313] | 277 | Int m_maxTempLayer; ///< Max temporal layer |
---|
[1448] | 278 | #endif |
---|
[313] | 279 | |
---|
| 280 | // coding unit (CU) definition |
---|
[1029] | 281 | // TODO: Remove MaxCUWidth/MaxCUHeight and replace with MaxCUSize. |
---|
[1235] | 282 | #if !SVC_EXTENSION |
---|
[313] | 283 | UInt m_uiMaxCUWidth; ///< max. CU width in pixel |
---|
| 284 | UInt m_uiMaxCUHeight; ///< max. CU height in pixel |
---|
[1290] | 285 | UInt m_uiMaxCUDepth; ///< max. CU depth (as specified by command line) |
---|
| 286 | UInt m_uiMaxTotalCUDepth; ///< max. total CU depth - includes depth of transform-block structure |
---|
| 287 | UInt m_uiLog2DiffMaxMinCodingBlockSize; ///< difference between largest and smallest CU depth |
---|
[1029] | 288 | |
---|
[313] | 289 | // transfom unit (TU) definition |
---|
| 290 | UInt m_uiQuadtreeTULog2MaxSize; |
---|
| 291 | UInt m_uiQuadtreeTULog2MinSize; |
---|
[1029] | 292 | |
---|
[313] | 293 | UInt m_uiQuadtreeTUMaxDepthInter; |
---|
| 294 | UInt m_uiQuadtreeTUMaxDepthIntra; |
---|
[494] | 295 | #endif |
---|
[1459] | 296 | |
---|
[313] | 297 | // coding tools (bit-depth) |
---|
[1200] | 298 | #if !SVC_EXTENSION |
---|
[1029] | 299 | Int m_inputBitDepth [MAX_NUM_CHANNEL_TYPE]; ///< bit-depth of input file |
---|
| 300 | Int m_outputBitDepth [MAX_NUM_CHANNEL_TYPE]; ///< bit-depth of output file |
---|
| 301 | Int m_MSBExtendedBitDepth[MAX_NUM_CHANNEL_TYPE]; ///< bit-depth of input samples after MSB extension |
---|
| 302 | Int m_internalBitDepth[MAX_NUM_CHANNEL_TYPE]; ///< bit-depth codec operates at (input/output files will be converted) |
---|
[1437] | 303 | #endif |
---|
[1316] | 304 | Bool m_extendedPrecisionProcessingFlag; |
---|
| 305 | Bool m_highPrecisionOffsetsEnabledFlag; |
---|
[1200] | 306 | |
---|
[1029] | 307 | //coding tools (chroma format) |
---|
[1437] | 308 | #if !SVC_EXTENSION |
---|
[494] | 309 | ChromaFormat m_chromaFormatIDC; |
---|
| 310 | #endif |
---|
[313] | 311 | |
---|
| 312 | // coding tools (PCM bit-depth) |
---|
| 313 | Bool m_bPCMInputBitDepthFlag; ///< 0: PCM bit-depth is internal bit-depth. 1: PCM bit-depth is input bit-depth. |
---|
| 314 | |
---|
[595] | 315 | // coding tool (SAO) |
---|
[1437] | 316 | #if !SVC_EXTENSION |
---|
[1029] | 317 | Bool m_bUseSAO; |
---|
[1437] | 318 | #endif |
---|
[1331] | 319 | Bool m_bTestSAODisableAtPictureLevel; |
---|
[1332] | 320 | Double m_saoEncodingRate; ///< When >0 SAO early picture termination is enabled for luma and chroma |
---|
| 321 | Double m_saoEncodingRateChroma; ///< The SAO early picture termination rate to use for chroma (when m_SaoEncodingRate is >0). If <=0, use results for luma. |
---|
[313] | 322 | Int m_maxNumOffsetsPerPic; ///< SAO maximun number of offset per picture |
---|
[1029] | 323 | Bool m_saoCtuBoundary; ///< SAO parameter estimation using non-deblocked pixels for CTU bottom and right boundary areas |
---|
[1548] | 324 | #if OPTIONAL_RESET_SAO_ENCODING_AFTER_IRAP |
---|
| 325 | Bool m_saoResetEncoderStateAfterIRAP; ///< When true, SAO encoder state will be reset following an IRAP. |
---|
| 326 | #endif |
---|
[313] | 327 | // coding tools (loop filter) |
---|
| 328 | Bool m_bLoopFilterDisable; ///< flag for using deblocking filter |
---|
| 329 | Bool m_loopFilterOffsetInPPS; ///< offset for deblocking filter in 0 = slice header, 1 = PPS |
---|
| 330 | Int m_loopFilterBetaOffsetDiv2; ///< beta offset for deblocking filter |
---|
| 331 | Int m_loopFilterTcOffsetDiv2; ///< tc offset for deblocking filter |
---|
[1545] | 332 | #if W0038_DB_OPT |
---|
| 333 | Int m_deblockingFilterMetric; ///< blockiness metric in encoder |
---|
| 334 | #else |
---|
[313] | 335 | Bool m_DeblockingFilterMetric; ///< blockiness metric in encoder |
---|
[1545] | 336 | #endif |
---|
[313] | 337 | // coding tools (PCM) |
---|
| 338 | Bool m_usePCM; ///< flag for using IPCM |
---|
| 339 | UInt m_pcmLog2MaxSize; ///< log2 of maximum PCM block size |
---|
| 340 | UInt m_uiPCMLog2MinSize; ///< log2 of minimum PCM block size |
---|
| 341 | Bool m_bPCMFilterDisableFlag; ///< PCM filter disable flag |
---|
[1029] | 342 | Bool m_enableIntraReferenceSmoothing; ///< flag for enabling(default)/disabling intra reference smoothing/filtering |
---|
[313] | 343 | |
---|
| 344 | // coding tools (encoder-only parameters) |
---|
| 345 | Bool m_bUseASR; ///< flag for using adaptive motion search range |
---|
| 346 | Bool m_bUseHADME; ///< flag for using HAD in sub-pel ME |
---|
| 347 | Bool m_useRDOQ; ///< flag for using RD optimized quantization |
---|
| 348 | Bool m_useRDOQTS; ///< flag for using RD optimized quantization for transform skip |
---|
[1298] | 349 | #if T0196_SELECTIVE_RDOQ |
---|
| 350 | Bool m_useSelectiveRDOQ; ///< flag for using selective RDOQ |
---|
| 351 | #endif |
---|
[1029] | 352 | Int m_rdPenalty; ///< RD-penalty for 32x32 TU for intra in non-intra slices (0: no RD-penalty, 1: RD-penalty, 2: maximum RD-penalty) |
---|
[1311] | 353 | Bool m_bDisableIntraPUsInInterSlices; ///< Flag for disabling intra predicted PUs in inter slices. |
---|
[1406] | 354 | MESearchMethod m_motionEstimationSearchMethod; |
---|
[1405] | 355 | Bool m_bRestrictMESampling; ///< Restrict sampling for the Selective ME |
---|
[313] | 356 | Int m_iSearchRange; ///< ME search range |
---|
| 357 | Int m_bipredSearchRange; ///< ME search range for bipred refinement |
---|
[1401] | 358 | Int m_minSearchWindow; ///< ME minimum search window size for the Adaptive Window ME |
---|
[1324] | 359 | Bool m_bClipForBiPredMeEnabled; ///< Enables clipping for Bi-Pred ME. |
---|
[1326] | 360 | Bool m_bFastMEAssumingSmootherMVEnabled; ///< Enables fast ME assuming a smoother MV. |
---|
[1402] | 361 | FastInterSearchMode m_fastInterSearchMode; ///< Parameter that controls fast encoder settings |
---|
[313] | 362 | Bool m_bUseEarlyCU; ///< flag for using Early CU setting |
---|
[1029] | 363 | Bool m_useFastDecisionForMerge; ///< flag for using Fast Decision Merge RD-Cost |
---|
[1401] | 364 | Bool m_bUseCbfFastMode; ///< flag for using Cbf Fast PU Mode Decision |
---|
| 365 | Bool m_useEarlySkipDetection; ///< flag for using Early SKIP Detection |
---|
[1459] | 366 | SliceConstraint m_sliceMode; |
---|
| 367 | Int m_sliceArgument; ///< argument according to selected slice mode |
---|
| 368 | SliceConstraint m_sliceSegmentMode; |
---|
| 369 | Int m_sliceSegmentArgument; ///< argument according to selected slice segment mode |
---|
[313] | 370 | |
---|
| 371 | Bool m_bLFCrossSliceBoundaryFlag; ///< 1: filter across slice boundaries 0: do not filter across slice boundaries |
---|
| 372 | Bool m_bLFCrossTileBoundaryFlag; ///< 1: filter across tile boundaries 0: do not filter across tile boundaries |
---|
[823] | 373 | Bool m_tileUniformSpacingFlag; |
---|
| 374 | Int m_numTileColumnsMinus1; |
---|
| 375 | Int m_numTileRowsMinus1; |
---|
| 376 | std::vector<Int> m_tileColumnWidth; |
---|
| 377 | std::vector<Int> m_tileRowHeight; |
---|
[1235] | 378 | |
---|
[875] | 379 | #if !SVC_EXTENSION |
---|
[1459] | 380 | Bool m_entropyCodingSyncEnabledFlag; |
---|
[313] | 381 | #endif |
---|
[1235] | 382 | |
---|
[313] | 383 | Bool m_bUseConstrainedIntraPred; ///< flag for using constrained intra prediction |
---|
[1327] | 384 | Bool m_bFastUDIUseMPMEnabled; |
---|
[1328] | 385 | Bool m_bFastMEForGenBLowDelayEnabled; |
---|
[1330] | 386 | Bool m_bUseBLambdaForNonKeyLowDelayPictures; |
---|
[1029] | 387 | |
---|
[1459] | 388 | HashType m_decodedPictureHashSEIType; ///< Checksum mode for decoded picture hash SEI message |
---|
| 389 | Bool m_recoveryPointSEIEnabled; |
---|
| 390 | Bool m_bufferingPeriodSEIEnabled; |
---|
| 391 | Bool m_pictureTimingSEIEnabled; |
---|
[313] | 392 | Bool m_toneMappingInfoSEIEnabled; |
---|
[1434] | 393 | Bool m_chromaResamplingFilterSEIenabled; |
---|
| 394 | Int m_chromaResamplingHorFilterIdc; |
---|
| 395 | Int m_chromaResamplingVerFilterIdc; |
---|
[313] | 396 | Int m_toneMapId; |
---|
| 397 | Bool m_toneMapCancelFlag; |
---|
| 398 | Bool m_toneMapPersistenceFlag; |
---|
| 399 | Int m_toneMapCodedDataBitDepth; |
---|
| 400 | Int m_toneMapTargetBitDepth; |
---|
[1029] | 401 | Int m_toneMapModelId; |
---|
[313] | 402 | Int m_toneMapMinValue; |
---|
| 403 | Int m_toneMapMaxValue; |
---|
| 404 | Int m_sigmoidMidpoint; |
---|
| 405 | Int m_sigmoidWidth; |
---|
| 406 | Int m_numPivots; |
---|
| 407 | Int m_cameraIsoSpeedIdc; |
---|
| 408 | Int m_cameraIsoSpeedValue; |
---|
[713] | 409 | Int m_exposureIndexIdc; |
---|
| 410 | Int m_exposureIndexValue; |
---|
[1230] | 411 | Bool m_exposureCompensationValueSignFlag; |
---|
[313] | 412 | Int m_exposureCompensationValueNumerator; |
---|
| 413 | Int m_exposureCompensationValueDenomIdc; |
---|
| 414 | Int m_refScreenLuminanceWhite; |
---|
| 415 | Int m_extendedRangeWhiteLevel; |
---|
| 416 | Int m_nominalBlackLevelLumaCodeValue; |
---|
| 417 | Int m_nominalWhiteLevelLumaCodeValue; |
---|
| 418 | Int m_extendedWhiteLevelLumaCodeValue; |
---|
| 419 | Int* m_startOfCodedInterval; |
---|
| 420 | Int* m_codedPivotValue; |
---|
| 421 | Int* m_targetPivotValue; |
---|
[1459] | 422 | Bool m_framePackingSEIEnabled; |
---|
[313] | 423 | Int m_framePackingSEIType; |
---|
| 424 | Int m_framePackingSEIId; |
---|
| 425 | Int m_framePackingSEIQuincunx; |
---|
| 426 | Int m_framePackingSEIInterpretation; |
---|
[1459] | 427 | Bool m_segmentedRectFramePackingSEIEnabled; |
---|
[1029] | 428 | Bool m_segmentedRectFramePackingSEICancel; |
---|
| 429 | Int m_segmentedRectFramePackingSEIType; |
---|
| 430 | Bool m_segmentedRectFramePackingSEIPersistence; |
---|
[313] | 431 | Int m_displayOrientationSEIAngle; |
---|
[1459] | 432 | Bool m_temporalLevel0IndexSEIEnabled; |
---|
| 433 | Bool m_gradualDecodingRefreshInfoEnabled; |
---|
[1029] | 434 | Int m_noDisplaySEITLayer; |
---|
[1459] | 435 | Bool m_decodingUnitInfoSEIEnabled; |
---|
| 436 | Bool m_SOPDescriptionSEIEnabled; |
---|
| 437 | Bool m_scalableNestingSEIEnabled; |
---|
[1029] | 438 | Bool m_tmctsSEIEnabled; |
---|
| 439 | Bool m_timeCodeSEIEnabled; |
---|
| 440 | Int m_timeCodeSEINumTs; |
---|
| 441 | TComSEITimeSet m_timeSetArray[MAX_TIMECODE_SEI_SETS]; |
---|
| 442 | Bool m_kneeSEIEnabled; |
---|
| 443 | Int m_kneeSEIId; |
---|
| 444 | Bool m_kneeSEICancelFlag; |
---|
| 445 | Bool m_kneeSEIPersistenceFlag; |
---|
| 446 | Int m_kneeSEIInputDrange; |
---|
| 447 | Int m_kneeSEIInputDispLuminance; |
---|
| 448 | Int m_kneeSEIOutputDrange; |
---|
| 449 | Int m_kneeSEIOutputDispLuminance; |
---|
| 450 | Int m_kneeSEINumKneePointsMinus1; |
---|
| 451 | Int* m_kneeSEIInputKneePoint; |
---|
| 452 | Int* m_kneeSEIOutputKneePoint; |
---|
[1538] | 453 | #if U0033_ALTERNATIVE_TRANSFER_CHARACTERISTICS_SEI |
---|
| 454 | Int m_preferredTransferCharacteristics; |
---|
| 455 | #endif |
---|
[1572] | 456 | UInt m_greenMetadataType; |
---|
| 457 | UInt m_xsdMetricType; |
---|
[1538] | 458 | |
---|
[313] | 459 | // weighted prediction |
---|
| 460 | Bool m_useWeightedPred; ///< Use of weighted prediction in P slices |
---|
| 461 | Bool m_useWeightedBiPred; ///< Use of bi-directional weighted prediction in B slices |
---|
[1400] | 462 | WeightedPredictionMethod m_weightedPredictionMethod; |
---|
[1029] | 463 | |
---|
[313] | 464 | UInt m_log2ParallelMergeLevel; ///< Parallel merge estimation region |
---|
| 465 | UInt m_maxNumMergeCand; ///< Max number of merge candidates |
---|
| 466 | |
---|
| 467 | Int m_TMVPModeId; |
---|
[1569] | 468 | Bool m_signDataHidingEnabledFlag; |
---|
[313] | 469 | #if !RC_SHVC_HARMONIZATION |
---|
| 470 | Bool m_RCEnableRateControl; ///< enable rate control or not |
---|
| 471 | Int m_RCTargetBitrate; ///< target bitrate when rate control is enabled |
---|
| 472 | Int m_RCKeepHierarchicalBit; ///< 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation |
---|
[1029] | 473 | Bool m_RCLCULevelRC; ///< true: LCU level rate control; false: picture level rate control NOTE: code-tidy - rename to m_RCCtuLevelRC |
---|
| 474 | Bool m_RCUseLCUSeparateModel; ///< use separate R-lambda model at LCU level NOTE: code-tidy - rename to m_RCUseCtuSeparateModel |
---|
[313] | 475 | Int m_RCInitialQP; ///< inital QP for rate control |
---|
| 476 | Bool m_RCForceIntraQP; ///< force all intra picture to use initial QP or not |
---|
[1433] | 477 | #if U0132_TARGET_BITS_SATURATION |
---|
| 478 | Bool m_RCCpbSaturationEnabled; ///< enable target bits saturation to avoid CPB overflow and underflow |
---|
| 479 | UInt m_RCCpbSize; ///< CPB size |
---|
| 480 | Double m_RCInitialCpbFullness; ///< initial CPB fullness |
---|
[313] | 481 | #endif |
---|
[1433] | 482 | #endif |
---|
[1381] | 483 | #if !SVC_EXTENSION |
---|
[1029] | 484 | ScalingListMode m_useScalingListId; ///< using quantization matrix |
---|
[1442] | 485 | std::string m_scalingListFileName; ///< quantization matrix file name |
---|
[1381] | 486 | #endif |
---|
[313] | 487 | |
---|
[1526] | 488 | #if !PER_LAYER_LOSSLESS |
---|
[1567] | 489 | Bool m_TransquantBypassEnabledFlag; ///< transquant_bypass_enabled_flag setting in PPS. |
---|
| 490 | Bool m_CUTransquantBypassFlagForce; ///< if transquant_bypass_enabled_flag, then, if true, all CU transquant bypass flags will be set to true. |
---|
[1029] | 491 | CostMode m_costMode; ///< Cost mode to use |
---|
[1526] | 492 | #endif |
---|
[313] | 493 | |
---|
| 494 | Bool m_recalculateQPAccordingToLambda; ///< recalculate QP value according to the lambda value |
---|
| 495 | Bool m_useStrongIntraSmoothing; ///< enable strong intra smoothing for 32x32 blocks where the reference samples are flat |
---|
| 496 | Int m_activeParameterSetsSEIEnabled; |
---|
| 497 | |
---|
| 498 | Bool m_vuiParametersPresentFlag; ///< enable generation of VUI parameters |
---|
| 499 | Bool m_aspectRatioInfoPresentFlag; ///< Signals whether aspect_ratio_idc is present |
---|
| 500 | Int m_aspectRatioIdc; ///< aspect_ratio_idc |
---|
| 501 | Int m_sarWidth; ///< horizontal size of the sample aspect ratio |
---|
| 502 | Int m_sarHeight; ///< vertical size of the sample aspect ratio |
---|
| 503 | Bool m_overscanInfoPresentFlag; ///< Signals whether overscan_appropriate_flag is present |
---|
| 504 | Bool m_overscanAppropriateFlag; ///< Indicates whether conformant decoded pictures are suitable for display using overscan |
---|
| 505 | Bool m_videoSignalTypePresentFlag; ///< Signals whether video_format, video_full_range_flag, and colour_description_present_flag are present |
---|
| 506 | Int m_videoFormat; ///< Indicates representation of pictures |
---|
| 507 | Bool m_videoFullRangeFlag; ///< Indicates the black level and range of luma and chroma signals |
---|
| 508 | Bool m_colourDescriptionPresentFlag; ///< Signals whether colour_primaries, transfer_characteristics and matrix_coefficients are present |
---|
| 509 | Int m_colourPrimaries; ///< Indicates chromaticity coordinates of the source primaries |
---|
| 510 | Int m_transferCharacteristics; ///< Indicates the opto-electronic transfer characteristics of the source |
---|
| 511 | Int m_matrixCoefficients; ///< Describes the matrix coefficients used in deriving luma and chroma from RGB primaries |
---|
| 512 | Bool m_chromaLocInfoPresentFlag; ///< Signals whether chroma_sample_loc_type_top_field and chroma_sample_loc_type_bottom_field are present |
---|
| 513 | Int m_chromaSampleLocTypeTopField; ///< Specifies the location of chroma samples for top field |
---|
| 514 | Int m_chromaSampleLocTypeBottomField; ///< Specifies the location of chroma samples for bottom field |
---|
| 515 | Bool m_neutralChromaIndicationFlag; ///< Indicates that the value of all decoded chroma samples is equal to 1<<(BitDepthCr-1) |
---|
| 516 | Bool m_defaultDisplayWindowFlag; ///< Indicates the presence of the default window parameters |
---|
| 517 | Int m_defDispWinLeftOffset; ///< Specifies the left offset from the conformance window of the default window |
---|
| 518 | Int m_defDispWinRightOffset; ///< Specifies the right offset from the conformance window of the default window |
---|
| 519 | Int m_defDispWinTopOffset; ///< Specifies the top offset from the conformance window of the default window |
---|
| 520 | Int m_defDispWinBottomOffset; ///< Specifies the bottom offset from the conformance window of the default window |
---|
| 521 | Bool m_frameFieldInfoPresentFlag; ///< Indicates that pic_struct values are present in picture timing SEI messages |
---|
| 522 | Bool m_pocProportionalToTimingFlag; ///< Indicates that the POC value is proportional to the output time w.r.t. first picture in CVS |
---|
| 523 | Int m_numTicksPocDiffOneMinus1; ///< Number of ticks minus 1 that for a POC difference of one |
---|
| 524 | Bool m_bitstreamRestrictionFlag; ///< Signals whether bitstream restriction parameters are present |
---|
| 525 | Bool m_tilesFixedStructureFlag; ///< Indicates that each active picture parameter set has the same values of the syntax elements related to tiles |
---|
| 526 | Bool m_motionVectorsOverPicBoundariesFlag; ///< Indicates that no samples outside the picture boundaries are used for inter prediction |
---|
| 527 | Int m_minSpatialSegmentationIdc; ///< Indicates the maximum size of the spatial segments in the pictures in the coded video sequence |
---|
| 528 | 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 |
---|
| 529 | Int m_maxBitsPerMinCuDenom; ///< Indicates an upper bound for the number of bits of coding_unit() data |
---|
| 530 | Int m_log2MaxMvLengthHorizontal; ///< Indicate the maximum absolute value of a decoded horizontal MV component in quarter-pel luma units |
---|
| 531 | Int m_log2MaxMvLengthVertical; ///< Indicate the maximum absolute value of a decoded vertical MV component in quarter-pel luma units |
---|
[1460] | 532 | #if !SVC_EXTENSION |
---|
| 533 | std::string m_colourRemapSEIFileRoot; |
---|
| 534 | #endif |
---|
[1029] | 535 | |
---|
[1333] | 536 | std::string m_summaryOutFilename; ///< filename to use for producing summary output file. |
---|
| 537 | std::string m_summaryPicFilenameBase; ///< Base filename to use for producing summary picture output files. The actual filenames used will have I.txt, P.txt and B.txt appended. |
---|
[1334] | 538 | UInt m_summaryVerboseness; ///< Specifies the level of the verboseness of the text output. |
---|
[1333] | 539 | |
---|
[1029] | 540 | #if LAYERS_NOT_PRESENT_SEI |
---|
| 541 | Int m_layersNotPresentSEIEnabled; |
---|
| 542 | #endif |
---|
[1037] | 543 | #if P0123_ALPHA_CHANNEL_SEI |
---|
| 544 | Bool m_alphaSEIEnabled; |
---|
| 545 | Bool m_alphaCancelFlag; |
---|
| 546 | Int m_alphaUseIdc; |
---|
| 547 | Int m_alphaBitDepthMinus8; |
---|
| 548 | Int m_alphaTransparentValue; |
---|
| 549 | Int m_alphaOpaqueValue; |
---|
| 550 | Bool m_alphaIncrementFlag; |
---|
| 551 | Bool m_alphaClipFlag; |
---|
| 552 | Bool m_alphaClipTypeFlag; |
---|
| 553 | #endif |
---|
[1029] | 554 | #if SVC_EXTENSION |
---|
| 555 | #if FAST_INTRA_SHVC |
---|
| 556 | Bool m_useFastIntraScalable; ///< flag for using Fast Intra Decision for Scalable HEVC |
---|
| 557 | #endif |
---|
| 558 | #if Q0189_TMVP_CONSTRAINTS |
---|
| 559 | Int m_TMVPConstraintsSEIEnabled; |
---|
| 560 | #endif |
---|
[540] | 561 | Bool m_altOutputLayerFlag; ///< Specifies the value of alt_output_laye_flag in VPS extension |
---|
[1424] | 562 | Bool m_elRapSliceBEnabled; |
---|
[1524] | 563 | #if AVC_BASE |
---|
| 564 | Bool m_nonHEVCBaseLayerFlag; ///< non HEVC BL |
---|
[313] | 565 | #endif |
---|
[1524] | 566 | #endif |
---|
[1460] | 567 | |
---|
[313] | 568 | // internal member functions |
---|
[1235] | 569 | #if SVC_EXTENSION |
---|
[494] | 570 | Void xSetGlobal (UInt layerId); ///< set global variables |
---|
[1235] | 571 | Void xCheckParameter (UInt layerIdx); ///< check validity of configuration values per layer |
---|
[494] | 572 | #else |
---|
[313] | 573 | Void xSetGlobal (); ///< set global variables |
---|
| 574 | Void xCheckParameter (); ///< check validity of configuration values |
---|
[1029] | 575 | #endif |
---|
[313] | 576 | Void xPrintParameter (); ///< print configuration values |
---|
| 577 | Void xPrintUsage (); ///< print usage |
---|
[815] | 578 | #if SVC_EXTENSION |
---|
[313] | 579 | Int m_adaptiveResolutionChange; ///< Indicate adaptive resolution change frame |
---|
[540] | 580 | Bool m_skipPictureAtArcSwitch; ///< Indicates that when ARC up-switching is performed the higher layer picture is a skip picture |
---|
[1203] | 581 | |
---|
[442] | 582 | RepFormatCfg m_repFormatCfg[16]; ///< Rep_format structures |
---|
| 583 | #if N0383_IL_CONSTRAINED_TILE_SETS_SEI |
---|
| 584 | Bool m_interLayerConstrainedTileSetsSEIEnabled; |
---|
| 585 | UInt m_ilNumSetsInMessage; |
---|
| 586 | Bool m_skippedTileSetPresentFlag; |
---|
| 587 | UInt m_topLeftTileIndex[1024]; |
---|
| 588 | UInt m_bottomRightTileIndex[1024]; |
---|
| 589 | UInt m_ilcIdc[1024]; |
---|
| 590 | #endif |
---|
[588] | 591 | Bool m_crossLayerPictureTypeAlignFlag; |
---|
| 592 | Bool m_crossLayerIrapAlignFlag; |
---|
[912] | 593 | #if Q0096_OVERLAY_SEI |
---|
| 594 | Bool m_overlaySEIEnabled; |
---|
| 595 | Bool m_overlayInfoCancelFlag; |
---|
| 596 | UInt m_overlayContentAuxIdMinus128; |
---|
| 597 | UInt m_overlayLabelAuxIdMinus128; |
---|
| 598 | UInt m_overlayAlphaAuxIdMinus128; |
---|
| 599 | UInt m_overlayElementLabelValueLengthMinus8; |
---|
| 600 | UInt m_numOverlaysMinus1; |
---|
| 601 | std::vector<UInt> m_overlayIdx; |
---|
| 602 | std::vector<Bool> m_overlayLanguagePresentFlag; |
---|
| 603 | std::vector<UInt> m_overlayContentLayerId; |
---|
| 604 | std::vector<Bool> m_overlayLabelPresentFlag; |
---|
| 605 | std::vector<UInt> m_overlayLabelLayerId; |
---|
| 606 | std::vector<Bool> m_overlayAlphaPresentFlag; |
---|
| 607 | std::vector<UInt> m_overlayAlphaLayerId; |
---|
| 608 | std::vector<UInt> m_numOverlayElementsMinus1; |
---|
| 609 | std::vector< std::vector<UInt> > m_overlayElementLabelMin; |
---|
| 610 | std::vector< std::vector<UInt> > m_overlayElementLabelMax; |
---|
| 611 | std::vector<string> m_overlayLanguage; |
---|
| 612 | std::vector<string> m_overlayName; |
---|
| 613 | std::vector< std::vector<string> > m_overlayElementName; |
---|
| 614 | Bool m_overlayInfoPersistenceFlag; |
---|
| 615 | #endif |
---|
[644] | 616 | Bool m_crossLayerAlignedIdrOnlyFlag; |
---|
[588] | 617 | Bool m_crossLayerBLAFlag; |
---|
| 618 | Bool m_useInterLayerWeightedPred; |
---|
[1212] | 619 | #if CGS_3D_ASYMLUT |
---|
[1150] | 620 | Int m_nCGSFlag; |
---|
| 621 | Int m_nCGSMaxOctantDepth; |
---|
| 622 | Int m_nCGSMaxYPartNumLog2; |
---|
| 623 | Int m_nCGSLUTBit; |
---|
| 624 | Int m_nCGSAdaptiveChroma; |
---|
[877] | 625 | #if R0179_ENC_OPT_3DLUT_SIZE |
---|
[1150] | 626 | Int m_nCGSLutSizeRDO; |
---|
[877] | 627 | #endif |
---|
[825] | 628 | #endif |
---|
[815] | 629 | #endif //SVC_EXTENSION |
---|
[313] | 630 | public: |
---|
| 631 | TAppEncCfg(); |
---|
| 632 | virtual ~TAppEncCfg(); |
---|
[1029] | 633 | |
---|
[313] | 634 | public: |
---|
| 635 | Void create (); ///< create option handling class |
---|
| 636 | Void destroy (); ///< destroy option handling class |
---|
[1442] | 637 | Bool parseCfg ( Int argc, TChar* argv[] ); ///< parse configuration file to fill member variables |
---|
[1459] | 638 | |
---|
[313] | 639 | #if SVC_EXTENSION |
---|
[1442] | 640 | Bool parseCfgNumLayersAndInit( Int argc, TChar* argv[] ); ///< parse configuration file to to get number of layers and allocate memory |
---|
[1235] | 641 | Int getNumFrameToBeEncoded() { return m_framesToBeEncoded; } |
---|
| 642 | Int getNumLayer() { return m_numLayers; } |
---|
| 643 | Int getGOPSize() { return m_iGOPSize; } |
---|
[1200] | 644 | |
---|
[1235] | 645 | RepFormatCfg* getRepFormatCfg(Int i) { return &m_repFormatCfg[i]; } |
---|
| 646 | Bool getUsePCM() { return m_usePCM; } |
---|
| 647 | UInt getPCMLog2MinSize () { return m_uiPCMLog2MinSize; } |
---|
[1200] | 648 | |
---|
[1377] | 649 | UInt getInternalBitDepth(Int layer, ChannelType type) { return m_apcLayerCfg[layer]->m_internalBitDepth[type];} |
---|
| 650 | Bool getPCMInputBitDepthFlag() { return m_bPCMInputBitDepthFlag; } |
---|
[1235] | 651 | |
---|
| 652 | Int getDecodingRefreshType() { return m_iDecodingRefreshType; } |
---|
[313] | 653 | Void getDirFilename(string& filename, string& dir, const string path); |
---|
[1162] | 654 | |
---|
[861] | 655 | Bool scanStringToArray(string const cfgString, Int const numEntries, const char* logString, Int * const returnArray); |
---|
| 656 | Bool scanStringToArray(string const cfgString, Int const numEntries, const char* logString, std::vector<Int> & returnVector); |
---|
| 657 | Void cfgStringToArray(Int **arr, string const cfgString, Int const numEntries, const char* logString); |
---|
[1005] | 658 | Bool scanStringToArrayNumEntries(string const cfgString, Int &numEntries, const char* logString, Int * const returnArray); |
---|
| 659 | Bool scanStringToArrayNumEntries(string const cfgString, Int &numEntries, const char* logString, std::vector<Int> & returnVector); |
---|
| 660 | Void cfgStringToArrayNumEntries(Int **arr, string const cfgString, Int &numEntries, const char* logString); |
---|
[1511] | 661 | Void printChromaFormat( const ChromaFormat inputChromaFormatIDC, const ChromaFormat chromaFormatIDC ); |
---|
[1487] | 662 | |
---|
| 663 | #if SCALABLE_REXT |
---|
| 664 | Profile::Name extendedToShortProfileName(ExtendedProfileName uiExtendedProfileName) |
---|
| 665 | { |
---|
| 666 | if(uiExtendedProfileName < MONOCHROME_8) |
---|
| 667 | { |
---|
| 668 | return Profile::Name(uiExtendedProfileName); |
---|
| 669 | } |
---|
| 670 | else if(uiExtendedProfileName < SCALABLE_MONOCHROME_8) |
---|
| 671 | { |
---|
| 672 | return Profile::MAINREXT; |
---|
| 673 | } |
---|
| 674 | else |
---|
| 675 | { |
---|
| 676 | return Profile::SCALABLEREXT; |
---|
| 677 | } |
---|
| 678 | } |
---|
[442] | 679 | #endif |
---|
[1487] | 680 | #endif |
---|
[313] | 681 | };// END CLASS DEFINITION TAppEncCfg |
---|
| 682 | |
---|
| 683 | //! \} |
---|
| 684 | |
---|
| 685 | #endif // __TAPPENCCFG__ |
---|
| 686 | |
---|