Changeset 302 in SHVCSoftware for branches/SHM-2.1-dev/source/App/TAppEncoder
- Timestamp:
- 28 Jun 2013, 00:40:00 (12 years ago)
- Location:
- branches/SHM-2.1-dev/source/App/TAppEncoder
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-2.1-dev/source/App/TAppEncoder/TAppEncCfg.cpp
r298 r302 96 96 { 97 97 m_aidQP = NULL; 98 #if J0149_TONE_MAPPING_SEI99 98 m_startOfCodedInterval = NULL; 100 99 m_codedPivotValue = NULL; 101 100 m_targetPivotValue = NULL; 102 #endif103 101 } 104 102 #endif … … 114 112 delete[] m_aidQP; 115 113 } 116 #if J0149_TONE_MAPPING_SEI117 114 if ( m_startOfCodedInterval ) 118 115 { … … 130 127 m_targetPivotValue = NULL; 131 128 } 132 #endif133 129 free(m_pchInputFile); 134 130 #endif … … 326 322 } 327 323 328 #if SIGNAL_BITRATE_PICRATE_IN_VPS329 Void readBoolString(const string inpString, const Int numEntries, Bool* &memberArray, const char *elementName);330 Void readIntString(const string inpString, const Int numEntries, Int* &memberArray, const char *elementName);331 #endif332 324 // ==================================================================================================================== 333 325 // Public member functions … … 450 442 string cfg_RowHeight; 451 443 string cfg_ScalingListFile; 452 #if J0149_TONE_MAPPING_SEI453 444 string cfg_startOfCodedInterval; 454 445 string cfg_codedPivotValue; 455 446 string cfg_targetPivotValue; 456 #endif457 #if SIGNAL_BITRATE_PICRATE_IN_VPS458 string cfg_bitRateInfoPresentFlag;459 string cfg_picRateInfoPresentFlag;460 string cfg_avgBitRate;461 string cfg_maxBitRate;462 string cfg_avgPicRate;463 string cfg_constantPicRateIdc;464 #endif465 447 po::Options opts; 466 448 opts.addOptions() … … 556 538 ("Tier", m_levelTier, Level::MAIN, "Tier to use for interpretation of --Level") 557 539 558 #if L0046_CONSTRAINT_FLAGS559 540 ("ProgressiveSource", m_progressiveSourceFlag, false, "Indicate that source is progressive") 560 541 ("InterlacedSource", m_interlacedSourceFlag, false, "Indicate that source is interlaced") 561 542 ("NonPackedSource", m_nonPackedConstraintFlag, false, "Indicate that source does not contain frame packing") 562 543 ("FrameOnly", m_frameOnlyConstraintFlag, false, "Indicate that the bitstream contains only frames") 563 #endif564 544 565 545 // Unit definition parameters … … 585 565 ("DecodingRefreshType,-dr", m_iDecodingRefreshType, 0, "Intra refresh type (0:none 1:CRA 2:IDR)") 586 566 ("GOPSize,g", m_iGOPSize, 1, "GOP size of temporal structure") 587 #if !L0034_COMBINED_LIST_CLEANUP588 ("ListCombination,-lc", m_bUseLComb, true, "Combined reference list for uni-prediction estimation in B-slices")589 #endif590 567 // motion options 591 568 ("FastSearch", m_iFastSearch, 1, "0:Full search 1:Diamond 2:PMVFAST") … … 633 610 ("RDOQ", m_useRDOQ, true ) 634 611 ("RDOQTS", m_useRDOQTS, true ) 635 #if L0232_RD_PENALTY636 612 ("RDpenalty", m_rdPenalty, 0, "RD-penalty for 32x32 TU for intra in non-intra slices. 0:disbaled 1:RD-penalty 2:maximum RD-penalty") 637 #endif638 613 // Entropy coding parameters 639 614 ("SBACRD", m_bUseSBACRD, true, "SBAC based RD estimation") … … 645 620 ("LoopFilterTcOffset_div2", m_loopFilterTcOffsetDiv2, 0 ) 646 621 ("DeblockingFilterControlPresent", m_DeblockingFilterControlPresent, false ) 647 #if L0386_DB_METRIC648 622 ("DeblockingFilterMetric", m_DeblockingFilterMetric, false ) 649 #endif650 623 651 624 // Coding tools … … 722 695 ( "RateControl", m_RCEnableRateControl, false, "Rate control: enable rate control" ) 723 696 ( "TargetBitrate", m_RCTargetBitrate, 0, "Rate control: target bitrate" ) 697 #if M0036_RC_IMPROVEMENT 698 ( "KeepHierarchicalBit", m_RCKeepHierarchicalBit, 0, "Rate control: 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation" ) 699 #else 724 700 ( "KeepHierarchicalBit", m_RCKeepHierarchicalBit, false, "Rate control: keep hierarchical bit allocation in rate control algorithm" ) 701 #endif 725 702 ( "LCULevelRateControl", m_RCLCULevelRC, true, "Rate control: true: LCU level RC; false: picture level RC" ) 726 703 ( "RCLCUSeparateModel", m_RCUseLCUSeparateModel, true, "Rate control: use LCU level separate R-lambda model" ) … … 775 752 ("SEIBufferingPeriod", m_bufferingPeriodSEIEnabled, 0, "Control generation of buffering period SEI messages") 776 753 ("SEIPictureTiming", m_pictureTimingSEIEnabled, 0, "Control generation of picture timing SEI messages") 777 #if J0149_TONE_MAPPING_SEI778 754 ("SEIToneMappingInfo", m_toneMappingInfoSEIEnabled, false, "Control generation of Tone Mapping SEI messages") 779 755 ("SEIToneMapId", m_toneMapId, 0, "Specifies Id of Tone Mapping SEI message for a given session") … … 806 782 ("SEIToneMapNominalWhiteLevelLumaCodeValue", m_nominalWhiteLevelLumaCodeValue, 235, "Specifies luma sample value of the nominal white level assigned decoded pictures") 807 783 ("SEIToneMapExtendedWhiteLevelLumaCodeValue", m_extendedWhiteLevelLumaCodeValue, 300, "Specifies luma sample value of the extended dynamic range assigned decoded pictures") 808 #endif809 784 ("SEIFramePacking", m_framePackingSEIEnabled, 0, "Control generation of frame packing SEI messages") 810 785 ("SEIFramePackingType", m_framePackingSEIType, 0, "Define frame packing arrangement\n" … … 830 805 ("SEILayersPresent", m_layersPresentSEIEnabled, 0, "Control generation of layers present SEI message") 831 806 #endif 832 #if L0208_SOP_DESCRIPTION_SEI833 807 ("SEISOPDescription", m_SOPDescriptionSEIEnabled, 0, "Control generation of SOP description SEI messages") 834 #endif835 #if K0180_SCALABLE_NESTING_SEI836 808 ("SEIScalableNesting", m_scalableNestingSEIEnabled, 0, "Control generation of scalable nesting SEI messages") 837 #endif838 #if SIGNAL_BITRATE_PICRATE_IN_VPS839 ("BitRatePicRateMaxTLayers", m_bitRatePicRateMaxTLayers, 0, "Maximum number of sub-layers signalled; can be inferred otherwise; here for easy parsing of config. file")840 ("BitRateInfoPresent", cfg_bitRateInfoPresentFlag, string(""), "Control signalling of bit rate information of avg. bit rate and max. bit rate in VPS\n"841 "\t0: Do not sent bit rate info\n"842 "\tN (N > 0): Send bit rate info for N sub-layers. N should equal maxTempLayers.")843 ("PicRateInfoPresent", cfg_picRateInfoPresentFlag, string(""), "Control signalling of picture rate information of avg. bit rate and max. bit rate in VPS\n"844 "\t0: Do not sent picture rate info\n"845 "\tN (N > 0): Send picture rate info for N sub-layers. N should equal maxTempLayers.")846 ("AvgBitRate", cfg_avgBitRate, string(""), "List of avg. bit rates for the different sub-layers; include non-negative number even if corresponding flag is 0")847 ("MaxBitRate", cfg_maxBitRate, string(""), "List of max. bit rates for the different sub-layers; include non-negative number even if corresponding flag is 0")848 ("AvgPicRate", cfg_avgPicRate, string(""), "List of avg. picture rates for the different sub-layers; include non-negative number even if corresponding flag is 0")849 ("ConstantPicRateIdc", cfg_constantPicRateIdc, string(""), "List of constant picture rate IDCs; include non-negative number even if corresponding flag is 0")850 #endif851 809 #if M0040_ADAPTIVE_RESOLUTION_CHANGE 852 810 ("AdaptiveResolutionChange", m_adaptiveResolutionChange, 0, "Adaptive resolution change frame number. Should coincide with EL RAP picture. (0: disable)") … … 1153 1111 } 1154 1112 #endif 1155 #if SIGNAL_BITRATE_PICRATE_IN_VPS1156 readBoolString(cfg_bitRateInfoPresentFlag, m_bitRatePicRateMaxTLayers, m_bitRateInfoPresentFlag, "bit rate info. present flag" );1157 readIntString (cfg_avgBitRate, m_bitRatePicRateMaxTLayers, m_avgBitRate, "avg. bit rate" );1158 readIntString (cfg_maxBitRate, m_bitRatePicRateMaxTLayers, m_maxBitRate, "max. bit rate" );1159 readBoolString(cfg_picRateInfoPresentFlag, m_bitRatePicRateMaxTLayers, m_picRateInfoPresentFlag, "bit rate info. present flag" );1160 readIntString (cfg_avgPicRate, m_bitRatePicRateMaxTLayers, m_avgPicRate, "avg. pic rate" );1161 readIntString (cfg_constantPicRateIdc, m_bitRatePicRateMaxTLayers, m_constantPicRateIdc, "constant pic rate Idc" );1162 #endif1163 1113 m_scalingListFile = cfg_ScalingListFile.empty() ? NULL : strdup(cfg_ScalingListFile.c_str()); 1164 1114 … … 1269 1219 m_iWaveFrontSubstreams = m_iWaveFrontSynchro ? (m_iSourceHeight + m_uiMaxCUHeight - 1) / m_uiMaxCUHeight : 1; 1270 1220 #endif 1271 #if J0149_TONE_MAPPING_SEI1272 1221 if( m_toneMappingInfoSEIEnabled && !m_toneMapCancelFlag ) 1273 1222 { … … 1328 1277 } 1329 1278 } 1330 #endif1331 1279 // check validity of input parameters 1332 1280 xCheckParameter(); … … 1340 1288 return true; 1341 1289 } 1342 #if SIGNAL_BITRATE_PICRATE_IN_VPS1343 Void readBoolString(const string inpString, const Int numEntries, Bool* &memberArray, const char *elementName)1344 {1345 Char* inpArray = inpString.empty() ? NULL : strdup(inpString.c_str());1346 Int i = 0;1347 if(numEntries)1348 {1349 Char* tempArray = strtok(inpArray, " ,-");1350 memberArray = new Bool[numEntries];1351 while( tempArray != NULL )1352 {1353 if( i >= numEntries )1354 {1355 printf( "The number of %s defined is larger than the allowed number\n", elementName );1356 exit( EXIT_FAILURE );1357 }1358 assert( (atoi(tempArray) == 0) || (atoi(tempArray) == 1) );1359 *( memberArray + i ) = atoi(tempArray);1360 tempArray = strtok(NULL, " ,-");1361 i++;1362 }1363 if( i < numEntries )1364 {1365 printf( "Some %s are not defined\n", elementName );1366 exit( EXIT_FAILURE );1367 }1368 }1369 else1370 {1371 memberArray = NULL;1372 }1373 }1374 1375 Void readIntString(const string inpString, const Int numEntries, Int* &memberArray, const char *elementName)1376 {1377 Char* inpArray = inpString.empty() ? NULL : strdup(inpString.c_str());1378 Int i = 0;1379 if(numEntries)1380 {1381 Char* tempArray = strtok(inpArray, " ,-");1382 memberArray = new Int[numEntries];1383 while( tempArray != NULL )1384 {1385 if( i >= numEntries )1386 {1387 printf( "The number of %s defined is larger than the allowed number\n", elementName );1388 exit( EXIT_FAILURE );1389 }1390 *( memberArray + i ) = atoi(tempArray);1391 tempArray = strtok(NULL, " ,-");1392 i++;1393 }1394 if( i < numEntries )1395 {1396 printf( "Some %s are not defined\n", elementName );1397 exit( EXIT_FAILURE );1398 }1399 }1400 else1401 {1402 memberArray = NULL;1403 }1404 }1405 #endif1406 1290 // ==================================================================================================================== 1407 1291 // Private member functions … … 1419 1303 fprintf(stderr, "** decoder requires this option to be enabled. **\n"); 1420 1304 fprintf(stderr, "******************************************************************\n"); 1305 } 1306 if( m_profile==Profile::NONE ) 1307 { 1308 fprintf(stderr, "***************************************************************************\n"); 1309 fprintf(stderr, "** WARNING: For conforming bitstreams a valid Profile value must be set! **\n"); 1310 fprintf(stderr, "***************************************************************************\n"); 1311 } 1312 if( m_level==Level::NONE ) 1313 { 1314 fprintf(stderr, "***************************************************************************\n"); 1315 fprintf(stderr, "** WARNING: For conforming bitstreams a valid Level value must be set! **\n"); 1316 fprintf(stderr, "***************************************************************************\n"); 1421 1317 } 1422 1318 … … 1439 1335 xConfirmPara( m_iQP < -6 * (m_internalBitDepthY - 8) || m_iQP > 51, "QP exceeds supported range (-QpBDOffsety to 51)" ); 1440 1336 #endif 1441 xConfirmPara( m_loopFilterBetaOffsetDiv2 < - 13 || m_loopFilterBetaOffsetDiv2 > 13, "Loop Filter Beta Offset div. 2 exceeds supported range (-13 to 13)");1442 xConfirmPara( m_loopFilterTcOffsetDiv2 < - 13 || m_loopFilterTcOffsetDiv2 > 13, "Loop Filter Tc Offset div. 2 exceeds supported range (-13 to 13)");1337 xConfirmPara( m_loopFilterBetaOffsetDiv2 < -6 || m_loopFilterBetaOffsetDiv2 > 6, "Loop Filter Beta Offset div. 2 exceeds supported range (-6 to 6)"); 1338 xConfirmPara( m_loopFilterTcOffsetDiv2 < -6 || m_loopFilterTcOffsetDiv2 > 6, "Loop Filter Tc Offset div. 2 exceeds supported range (-6 to 6)"); 1443 1339 xConfirmPara( m_iFastSearch < 0 || m_iFastSearch > 2, "Fast Search Mode is not supported value (0:Full search 1:Diamond 2:PMVFAST)" ); 1444 1340 xConfirmPara( m_iSearchRange < 0 , "Search Range must be more than 0" ); … … 1601 1497 } 1602 1498 } 1603 #endif 1604 1605 #if SVC_EXTENSION 1499 1606 1500 // verify layer configuration parameters 1607 1501 for(UInt layer=0; layer<m_numLayers; layer++) … … 1828 1722 { 1829 1723 m_numReorderPics[i] = 0; 1830 #if L0323_DPB1831 1724 m_maxDecPicBuffering[i] = 1; 1832 #else1833 m_maxDecPicBuffering[i] = 0;1834 #endif1835 1725 } 1836 1726 for(Int i=0; i<m_iGOPSize; i++) 1837 1727 { 1838 #if L0323_DPB1839 1728 if(m_GOPList[i].m_numRefPics+1 > m_maxDecPicBuffering[m_GOPList[i].m_temporalId]) 1840 #else 1841 if(m_GOPList[i].m_numRefPics > m_maxDecPicBuffering[m_GOPList[i].m_temporalId]) 1842 #endif 1843 { 1844 #if L0323_DPB 1729 { 1845 1730 m_maxDecPicBuffering[m_GOPList[i].m_temporalId] = m_GOPList[i].m_numRefPics + 1; 1846 #else1847 m_maxDecPicBuffering[m_GOPList[i].m_temporalId] = m_GOPList[i].m_numRefPics;1848 #endif1849 1731 } 1850 1732 Int highestDecodingNumberWithLowerPOC = 0; … … 1877 1759 m_numReorderPics[i+1] = m_numReorderPics[i]; 1878 1760 } 1879 #if L0323_DPB1880 1761 // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ] - 1, inclusive 1881 1762 if(m_numReorderPics[i] > m_maxDecPicBuffering[i] - 1) … … 1883 1764 m_maxDecPicBuffering[i] = m_numReorderPics[i] + 1; 1884 1765 } 1885 #else1886 // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ], inclusive1887 if(m_numReorderPics[i] > m_maxDecPicBuffering[i])1888 {1889 m_maxDecPicBuffering[i] = m_numReorderPics[i];1890 }1891 #endif1892 1766 // a lower layer can not have higher value of m_uiMaxDecPicBuffering than a higher layer 1893 1767 if(m_maxDecPicBuffering[i+1] < m_maxDecPicBuffering[i]) … … 1898 1772 1899 1773 1900 #if L0323_DPB1901 1774 // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ] - 1, inclusive 1902 1775 if(m_numReorderPics[MAX_TLAYER-1] > m_maxDecPicBuffering[MAX_TLAYER-1] - 1) … … 1904 1777 m_maxDecPicBuffering[MAX_TLAYER-1] = m_numReorderPics[MAX_TLAYER-1] + 1; 1905 1778 } 1906 #else1907 // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ], inclusive1908 if(m_numReorderPics[MAX_TLAYER-1] > m_maxDecPicBuffering[MAX_TLAYER-1])1909 {1910 m_maxDecPicBuffering[MAX_TLAYER-1] = m_numReorderPics[MAX_TLAYER-1];1911 }1912 #endif1913 1779 1914 1780 #if SVC_EXTENSION // ToDo: it should be checked for the case when parameters are different for the layers … … 1994 1860 } 1995 1861 #endif 1996 #if !L0034_COMBINED_LIST_CLEANUP1997 xConfirmPara( m_bUseLComb==false && m_numReorderPics[MAX_TLAYER-1]!=0, "ListCombination can only be 0 in low delay coding (more precisely when L0 and L1 are identical)" ); // Note however this is not the full necessary condition as ref_pic_list_combination_flag can only be 0 if L0 == L1.1998 #endif1999 1862 xConfirmPara( m_iWaveFrontSynchro < 0, "WaveFrontSynchro cannot be negative" ); 2000 1863 #if !SVC_EXTENSION … … 2005 1868 xConfirmPara( m_decodedPictureHashSEIEnabled<0 || m_decodedPictureHashSEIEnabled>3, "this hash type is not correct!\n"); 2006 1869 2007 #if J0149_TONE_MAPPING_SEI2008 1870 if (m_toneMappingInfoSEIEnabled) 2009 1871 { … … 2016 1878 xConfirmPara( m_extendedWhiteLevelLumaCodeValue < m_nominalWhiteLevelLumaCodeValue, "SEIToneMapExtendedWhiteLevelLumaCodeValue shall be greater than or equal to SEIToneMapNominalWhiteLevelLumaCodeValue"); 2017 1879 } 2018 #endif2019 1880 2020 1881 #if RATE_CONTROL_LAMBDA_DOMAIN … … 2066 1927 2067 1928 xConfirmPara(m_log2ParallelMergeLevel < 2, "Log2ParallelMergeLevel should be larger than or equal to 2"); 2068 #if L0444_FPA_TYPE2069 1929 if (m_framePackingSEIEnabled) 2070 1930 { 2071 1931 xConfirmPara(m_framePackingSEIType < 3 || m_framePackingSEIType > 5 , "SEIFramePackingType must be in rage 3 to 5"); 2072 1932 } 2073 #endif2074 1933 #if VPS_EXTN_DIRECT_REF_LAYERS 2075 1934 #if M0457_PREDICTION_INDICATIONS … … 2266 2125 printf("RDQ:%d ", m_useRDOQ ); 2267 2126 printf("RDQTS:%d ", m_useRDOQTS ); 2268 #if L0232_RD_PENALTY2269 2127 printf("RDpenalty:%d ", m_rdPenalty ); 2270 #endif2271 2128 printf("SQP:%d ", m_uiDeltaQpRD ); 2272 2129 printf("ASR:%d ", m_bUseASR ); 2273 #if !L0034_COMBINED_LIST_CLEANUP2274 printf("LComb:%d ", m_bUseLComb );2275 #endif2276 2130 printf("FEN:%d ", m_bUseFastEnc ); 2277 2131 printf("ECU:%d ", m_bUseEarlyCU ); -
branches/SHM-2.1-dev/source/App/TAppEncoder/TAppEncCfg.h
r297 r302 99 99 Level::Tier m_levelTier; 100 100 Level::Name m_level; 101 #if L0046_CONSTRAINT_FLAGS102 101 Bool m_progressiveSourceFlag; 103 102 Bool m_interlacedSourceFlag; 104 103 Bool m_nonPackedConstraintFlag; 105 104 Bool m_frameOnlyConstraintFlag; 106 #endif107 105 108 106 // coding structure … … 115 113 GOPEntry m_GOPList[MAX_GOP]; ///< the coding structure entries from the config file 116 114 Int m_numReorderPics[MAX_TLAYER]; ///< total number of reorder pictures 117 #if L0323_DPB118 115 Int m_maxDecPicBuffering[MAX_TLAYER]; ///< total number of pictures in the decoded picture buffer 119 #else120 Int m_maxDecPicBuffering[MAX_TLAYER]; ///< total number of reference pictures needed for decoding121 #endif122 #if !L0034_COMBINED_LIST_CLEANUP123 Bool m_bUseLComb; ///< flag for using combined reference list for uni-prediction in B-slices (JCTVC-D421)124 #endif125 116 Bool m_useTransformSkip; ///< flag for enabling intra transform skipping 126 117 Bool m_useTransformSkipFast; ///< flag for enabling fast intra transform skipping … … 184 175 Int m_loopFilterTcOffsetDiv2; ///< tc offset for deblocking filter 185 176 Bool m_DeblockingFilterControlPresent; ///< deblocking filter control present flag in PPS 186 #if L0386_DB_METRIC187 177 Bool m_DeblockingFilterMetric; ///< blockiness metric in encoder 188 #endif189 178 190 179 // coding tools (PCM) … … 200 189 Bool m_useRDOQ; ///< flag for using RD optimized quantization 201 190 Bool m_useRDOQTS; ///< flag for using RD optimized quantization for transform skip 202 #if L0232_RD_PENALTY203 191 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) 204 #endif205 192 Int m_iFastSearch; ///< ME mode, 0 = full, 1 = diamond, 2 = PMVFAST 206 193 Int m_iSearchRange; ///< ME search range … … 241 228 Int m_bufferingPeriodSEIEnabled; 242 229 Int m_pictureTimingSEIEnabled; 243 #if J0149_TONE_MAPPING_SEI244 230 Bool m_toneMappingInfoSEIEnabled; 245 231 Int m_toneMapId; … … 267 253 Int* m_codedPivotValue; 268 254 Int* m_targetPivotValue; 269 #endif270 255 Int m_framePackingSEIEnabled; 271 256 Int m_framePackingSEIType; … … 280 265 Int m_layersPresentSEIEnabled; 281 266 #endif 282 #if L0208_SOP_DESCRIPTION_SEI283 267 Int m_SOPDescriptionSEIEnabled; 284 #endif285 #if K0180_SCALABLE_NESTING_SEI286 268 Int m_scalableNestingSEIEnabled; 287 #endif288 269 // weighted prediction 289 270 Bool m_useWeightedPred; ///< Use of weighted prediction in P slices … … 299 280 Bool m_RCEnableRateControl; ///< enable rate control or not 300 281 Int m_RCTargetBitrate; ///< target bitrate when rate control is enabled 282 #if M0036_RC_IMPROVEMENT 283 Int m_RCKeepHierarchicalBit; ///< 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation 284 #else 301 285 Bool m_RCKeepHierarchicalBit; ///< whether keeping hierarchical bit allocation structure or not 286 #endif 302 287 Bool m_RCLCULevelRC; ///< true: LCU level rate control; false: picture level rate control 303 288 Bool m_RCUseLCUSeparateModel; ///< use separate R-lambda model at LCU level … … 363 348 Void xPrintParameter (); ///< print configuration values 364 349 Void xPrintUsage (); ///< print usage 365 #if SIGNAL_BITRATE_PICRATE_IN_VPS366 Int m_bitRatePicRateMaxTLayers; ///< Indicates max. number of sub-layers for which bit rate is signalled.367 Bool* m_bitRateInfoPresentFlag; ///< Indicates whether bit rate information is signalled368 Bool* m_picRateInfoPresentFlag; ///< Indicates whether pic rate information is signalled369 Int* m_avgBitRate; ///< Indicates avg. bit rate information for various sub-layers370 Int* m_maxBitRate; ///< Indicates max. bit rate information for various sub-layers371 Int* m_avgPicRate; ///< Indicates avg. picture rate information for various sub-layers372 Int* m_constantPicRateIdc; ///< Indicates constant picture rate idc for various sub-layers373 #endif374 350 #if M0040_ADAPTIVE_RESOLUTION_CHANGE 375 351 Int m_adaptiveResolutionChange; ///< Indicate adaptive resolution change frame -
branches/SHM-2.1-dev/source/App/TAppEncoder/TAppEncTop.cpp
r297 r302 104 104 m_acTEncTop[layer].setProfile(m_profile); 105 105 m_acTEncTop[layer].setLevel(m_levelTier, m_level); 106 #if L0046_CONSTRAINT_FLAGS107 106 m_acTEncTop[layer].setProgressiveSourceFlag(m_progressiveSourceFlag); 108 107 m_acTEncTop[layer].setInterlacedSourceFlag(m_interlacedSourceFlag); 109 108 m_acTEncTop[layer].setNonPackedConstraintFlag(m_nonPackedConstraintFlag); 110 109 m_acTEncTop[layer].setFrameOnlyConstraintFlag(m_frameOnlyConstraintFlag); 111 #endif112 110 113 111 #if REF_IDX_MFM … … 244 242 m_acTEncTop[layer].setLoopFilterTcOffset ( m_loopFilterTcOffsetDiv2 ); 245 243 m_acTEncTop[layer].setDeblockingFilterControlPresent( m_DeblockingFilterControlPresent); 246 #if L0386_DB_METRIC247 244 m_acTEncTop[layer].setDeblockingFilterMetric ( m_DeblockingFilterMetric ); 248 #endif249 245 250 246 //====== Motion search ======== … … 280 276 m_acTEncTop[layer].setUseHADME ( m_bUseHADME ); 281 277 m_acTEncTop[layer].setUseLossless ( m_useLossless ); 282 #if !L0034_COMBINED_LIST_CLEANUP283 m_cTEncTop.setUseLComb ( m_bUseLComb );284 #endif285 278 m_acTEncTop[layer].setdQPs ( m_acLayerCfg[layer].getdQPs() ); 286 279 m_acTEncTop[layer].setUseRDOQ ( m_useRDOQ ); 287 280 m_acTEncTop[layer].setUseRDOQTS ( m_useRDOQTS ); 288 #if L0232_RD_PENALTY289 281 m_acTEncTop[layer].setRDpenalty ( m_rdPenalty ); 290 #endif291 282 m_acTEncTop[layer].setQuadtreeTULog2MaxSize ( m_uiQuadtreeTULog2MaxSize ); 292 283 m_acTEncTop[layer].setQuadtreeTULog2MinSize ( m_uiQuadtreeTULog2MinSize ); … … 355 346 m_acTEncTop[layer].setBufferingPeriodSEIEnabled( m_bufferingPeriodSEIEnabled ); 356 347 m_acTEncTop[layer].setPictureTimingSEIEnabled( m_pictureTimingSEIEnabled ); 357 #if J0149_TONE_MAPPING_SEI358 348 m_acTEncTop[layer].setToneMappingInfoSEIEnabled ( m_toneMappingInfoSEIEnabled ); 359 349 m_acTEncTop[layer].setTMISEIToneMapId ( m_toneMapId ); … … 381 371 m_acTEncTop[layer].setTMISEINominalWhiteLevelLumaCodeValue ( m_nominalWhiteLevelLumaCodeValue ); 382 372 m_acTEncTop[layer].setTMISEIExtendedWhiteLevelLumaCodeValue ( m_extendedWhiteLevelLumaCodeValue ); 383 #endif384 373 m_acTEncTop[layer].setFramePackingArrangementSEIEnabled( m_framePackingSEIEnabled ); 385 374 m_acTEncTop[layer].setFramePackingArrangementSEIType( m_framePackingSEIType ); … … 394 383 m_acTEncTop[layer].setLayersPresentSEIEnabled( m_layersPresentSEIEnabled ); 395 384 #endif 396 #if L0208_SOP_DESCRIPTION_SEI397 385 m_acTEncTop[layer].setSOPDescriptionSEIEnabled( m_SOPDescriptionSEIEnabled ); 398 #endif399 #if K0180_SCALABLE_NESTING_SEI400 386 m_acTEncTop[layer].setScalableNestingSEIEnabled( m_scalableNestingSEIEnabled ); 401 #endif402 387 m_acTEncTop[layer].setUniformSpacingIdr ( m_iUniformSpacingIdr ); 403 388 m_acTEncTop[layer].setNumColumnsMinus1 ( m_iNumColumnsMinus1 ); … … 478 463 m_acTEncTop[layer].setLog2MaxMvLengthHorizontal( m_log2MaxMvLengthHorizontal ); 479 464 m_acTEncTop[layer].setLog2MaxMvLengthVertical( m_log2MaxMvLengthVertical ); 480 #if SIGNAL_BITRATE_PICRATE_IN_VPS481 TComBitRatePicRateInfo *bitRatePicRateInfo = m_cTEncTop[layer].getVPS()->getBitratePicrateInfo();482 // The number of bit rate/pic rate have to equal to number of sub-layers.483 if(m_bitRatePicRateMaxTLayers)484 {485 assert(m_bitRatePicRateMaxTLayers == m_cTEncTop[layer].getVPS()->getMaxTLayers());486 }487 for(Int i = 0; i < m_bitRatePicRateMaxTLayers; i++)488 {489 bitRatePicRateInfo->setBitRateInfoPresentFlag( i, m_bitRateInfoPresentFlag[i] );490 if( bitRatePicRateInfo->getBitRateInfoPresentFlag(i) )491 {492 bitRatePicRateInfo->setAvgBitRate(i, m_avgBitRate[i]);493 bitRatePicRateInfo->setMaxBitRate(i, m_maxBitRate[i]);494 }495 }496 for(Int i = 0; i < m_bitRatePicRateMaxTLayers; i++)497 {498 bitRatePicRateInfo->setPicRateInfoPresentFlag( i, m_picRateInfoPresentFlag[i] );499 if( bitRatePicRateInfo->getPicRateInfoPresentFlag(i) )500 {501 bitRatePicRateInfo->setAvgPicRate (i, m_avgPicRate[i]);502 bitRatePicRateInfo->setConstantPicRateIdc(i, m_constantPicRateIdc[i]);503 }504 }505 #endif506 465 #if REF_IDX_FRAMEWORK 507 466 m_acTEncTop[layer].setElRapSliceTypeB(layer == 0? 0 : m_elRapSliceBEnabled); … … 543 502 m_cTEncTop.setProfile(m_profile); 544 503 m_cTEncTop.setLevel(m_levelTier, m_level); 545 #if L0046_CONSTRAINT_FLAGS546 504 m_cTEncTop.setProgressiveSourceFlag(m_progressiveSourceFlag); 547 505 m_cTEncTop.setInterlacedSourceFlag(m_interlacedSourceFlag); 548 506 m_cTEncTop.setNonPackedConstraintFlag(m_nonPackedConstraintFlag); 549 507 m_cTEncTop.setFrameOnlyConstraintFlag(m_frameOnlyConstraintFlag); 550 #endif551 508 552 509 m_cTEncTop.setFrameRate ( m_iFrameRate ); … … 587 544 m_cTEncTop.setLoopFilterTcOffset ( m_loopFilterTcOffsetDiv2 ); 588 545 m_cTEncTop.setDeblockingFilterControlPresent( m_DeblockingFilterControlPresent); 589 #if L0386_DB_METRIC590 546 m_cTEncTop.setDeblockingFilterMetric ( m_DeblockingFilterMetric ); 591 #endif592 547 593 548 //====== Motion search ======== … … 623 578 m_cTEncTop.setUseHADME ( m_bUseHADME ); 624 579 m_cTEncTop.setUseLossless ( m_useLossless ); 625 #if !L0034_COMBINED_LIST_CLEANUP626 m_cTEncTop.setUseLComb ( m_bUseLComb );627 #endif628 580 m_cTEncTop.setdQPs ( m_aidQP ); 629 581 m_cTEncTop.setUseRDOQ ( m_useRDOQ ); 630 582 m_cTEncTop.setUseRDOQTS ( m_useRDOQTS ); 631 #if L0232_RD_PENALTY632 583 m_cTEncTop.setRDpenalty ( m_rdPenalty ); 633 #endif634 584 m_cTEncTop.setQuadtreeTULog2MaxSize ( m_uiQuadtreeTULog2MaxSize ); 635 585 m_cTEncTop.setQuadtreeTULog2MinSize ( m_uiQuadtreeTULog2MinSize ); … … 698 648 m_cTEncTop.setBufferingPeriodSEIEnabled( m_bufferingPeriodSEIEnabled ); 699 649 m_cTEncTop.setPictureTimingSEIEnabled( m_pictureTimingSEIEnabled ); 700 #if J0149_TONE_MAPPING_SEI701 650 m_cTEncTop.setToneMappingInfoSEIEnabled ( m_toneMappingInfoSEIEnabled ); 702 651 m_cTEncTop.setTMISEIToneMapId ( m_toneMapId ); … … 724 673 m_cTEncTop.setTMISEINominalWhiteLevelLumaCodeValue ( m_nominalWhiteLevelLumaCodeValue ); 725 674 m_cTEncTop.setTMISEIExtendedWhiteLevelLumaCodeValue ( m_extendedWhiteLevelLumaCodeValue ); 726 #endif727 675 m_cTEncTop.setFramePackingArrangementSEIEnabled( m_framePackingSEIEnabled ); 728 676 m_cTEncTop.setFramePackingArrangementSEIType( m_framePackingSEIType ); … … 737 685 m_cTEncTop.setLayersPresentSEIEnabled( m_layersPresentSEIEnabled ); 738 686 #endif 739 #if L0208_SOP_DESCRIPTION_SEI740 687 m_cTEncTop.setSOPDescriptionSEIEnabled( m_SOPDescriptionSEIEnabled ); 741 #endif742 #if K0180_SCALABLE_NESTING_SEI743 688 m_cTEncTop.setScalableNestingSEIEnabled( m_scalableNestingSEIEnabled ); 744 #endif745 689 m_cTEncTop.setUniformSpacingIdr ( m_iUniformSpacingIdr ); 746 690 m_cTEncTop.setNumColumnsMinus1 ( m_iNumColumnsMinus1 ); … … 811 755 m_cTEncTop.setLog2MaxMvLengthHorizontal( m_log2MaxMvLengthHorizontal ); 812 756 m_cTEncTop.setLog2MaxMvLengthVertical( m_log2MaxMvLengthVertical ); 813 #if SIGNAL_BITRATE_PICRATE_IN_VPS814 TComBitRatePicRateInfo *bitRatePicRateInfo = m_cTEncTop.getVPS()->getBitratePicrateInfo();815 // The number of bit rate/pic rate have to equal to number of sub-layers.816 if(m_bitRatePicRateMaxTLayers)817 {818 assert(m_bitRatePicRateMaxTLayers == m_cTEncTop.getVPS()->getMaxTLayers());819 }820 for(Int i = 0; i < m_bitRatePicRateMaxTLayers; i++)821 {822 bitRatePicRateInfo->setBitRateInfoPresentFlag( i, m_bitRateInfoPresentFlag[i] );823 if( bitRatePicRateInfo->getBitRateInfoPresentFlag(i) )824 {825 bitRatePicRateInfo->setAvgBitRate(i, m_avgBitRate[i]);826 bitRatePicRateInfo->setMaxBitRate(i, m_maxBitRate[i]);827 }828 }829 for(Int i = 0; i < m_bitRatePicRateMaxTLayers; i++)830 {831 bitRatePicRateInfo->setPicRateInfoPresentFlag( i, m_picRateInfoPresentFlag[i] );832 if( bitRatePicRateInfo->getPicRateInfoPresentFlag(i) )833 {834 bitRatePicRateInfo->setAvgPicRate (i, m_avgPicRate[i]);835 bitRatePicRateInfo->setConstantPicRateIdc(i, m_constantPicRateIdc[i]);836 }837 }838 #endif839 757 } 840 758 #endif -
branches/SHM-2.1-dev/source/App/TAppEncoder/encmain.cpp
r191 r302 57 57 // print information 58 58 fprintf( stdout, "\n" ); 59 #if SVC_EXTENSION 59 60 fprintf( stdout, "SHM software: Encoder Version [%s]", NV_VERSION ); 61 #else 62 fprintf( stdout, "HM software: Encoder Version [%s]", NV_VERSION ); 63 #endif 60 64 fprintf( stdout, NVM_ONOS ); 61 65 fprintf( stdout, NVM_COMPILEDBY );
Note: See TracChangeset for help on using the changeset viewer.