Changeset 959 in SHVCSoftware for branches/SHM-upgrade/source/App/TAppEncoder/TAppEncCfg.cpp
- Timestamp:
- 6 Jan 2015, 03:12:18 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-upgrade/source/App/TAppEncoder/TAppEncCfg.cpp
r957 r959 65 65 MAINREXT = 4, 66 66 HIGHTHROUGHPUTREXT = 5, // Placeholder profile for development 67 #if MULTIPLE_PTL_SUPPORT 68 MULTIVIEWMAIN = 6, 69 SCALABLEMAIN = 7, 70 SCALABLEMAIN10 = 7, 71 #endif 67 72 // The following are RExt profiles, which would map to the MAINREXT profile idc. 68 73 // The enumeration indicates the bit-depth constraint in the bottom 2 digits … … 338 343 {"main-RExt", Profile::MAINREXT }, 339 344 {"high-throughput-RExt", Profile::HIGHTHROUGHPUTREXT }, 345 #if MULTIPLE_PTL_SUPPORT 346 {"multiview-main", Profile::MULTIVIEWMAIN }, //This is not used in this software 347 {"scalable-main", Profile::SCALABLEMAIN }, 348 {"scalable-main10", Profile::SCALABLEMAIN10 }, 349 #endif 340 350 }; 341 351 … … 372 382 {"main_444_12_intra", MAIN_444_12_INTRA}, 373 383 {"main_444_16_intra", MAIN_444_16_INTRA}, 384 #if MULTIPLE_PTL_SUPPORT 385 {"multiview-main", MULTIVIEWMAIN }, 386 {"scalable-main", SCALABLEMAIN }, 387 {"scalable-main10", SCALABLEMAIN10 }, 388 #endif 374 389 }; 375 390 … … 515 530 return readStrToEnum(strToScalingListMode, sizeof(strToScalingListMode)/sizeof(*strToScalingListMode), in, mode); 516 531 } 532 533 #if MULTIPLE_PTL_SUPPORT 534 namespace Profile 535 { 536 static inline istream& operator >> (istream &in, Name &profile) 537 { 538 return readStrToEnum(strToProfile, sizeof(strToProfile)/sizeof(*strToProfile), in, profile); 539 } 540 } 541 #endif 517 542 518 543 template <class T> … … 1014 1039 string inputColourSpaceConvert; 1015 1040 #if MULTIPLE_PTL_SUPPORT 1016 ExtendedProfileName extendedProfile[ NUM_POSSIBLE_LEVEL];1041 ExtendedProfileName extendedProfile[MAX_NUM_LAYER_IDS + 1]; 1017 1042 #else 1018 1043 ExtendedProfileName extendedProfile; … … 1266 1291 // Profile and level 1267 1292 #if MULTIPLE_PTL_SUPPORT 1268 ("NumProfileTierLevel", m_numPTLInfo, 2, "Number of Profile, Tier and Level information")1269 ("Profile%d", extendedProfile, NONE, NUM_POSSIBLE_LEVEL, "Profile name to use for encoding. Use main (for main), main10 (for main10), main-still-picture, main-RExt (for Range Extensions profile), any of the RExt specific profile names, or none")1270 ("Level%d", m_levelList, Level::NONE, NUM_POSSIBLE_LEVEL, "Level limit to be used, eg 5.1, or none")1271 ("Tier%d", m_levelTierList, Level::MAIN, NUM_POSSIBLE_LEVEL, "Tier to use for interpretation of --Level (main or high only)")1293 ("NumProfileTierLevel", m_numPTLInfo, 1, "Number of Profile, Tier and Level information") 1294 ("Profile%d", extendedProfile, NONE, (MAX_NUM_LAYER_IDS + 1), "Profile name to use for encoding. Use main (for main), main10 (for main10), main-still-picture, main-RExt (for Range Extensions profile), any of the RExt specific profile names, or none") 1295 ("Level%d", m_levelList, Level::NONE, (MAX_NUM_LAYER_IDS + 1), "Level limit to be used, eg 5.1, or none") 1296 ("Tier%d", m_levelTierList, Level::MAIN, (MAX_NUM_LAYER_IDS + 1), "Tier to use for interpretation of --Level (main or high only)") 1272 1297 ("MaxBitDepthConstraint", tmpBitDepthConstraint, 0u, "Bit depth to use for profile-constraint for RExt profiles. 0=automatically choose based upon other parameters") 1273 1298 ("MaxChromaFormatConstraint", tmpConstraintChromaFormat, 0, "Chroma-format to use for the profile-constraint for RExt profiles. 0=automatically choose based upon other parameters") 1274 1299 ("IntraConstraintFlag", tmpIntraConstraintFlag, false, "Value of general_intra_constraint_flag to use for RExt profiles (not used if an explicit RExt sub-profile is specified)") 1275 1300 ("LowerBitRateConstraintFlag", tmpLowerBitRateConstraintFlag, true, "Value of general_lower_bit_rate_constraint_flag to use for RExt profiles") 1276 1277 ("ProgressiveSource%d", m_progressiveSourceFlagList, false, NUM_POSSIBLE_LEVEL, "Indicate that source is progressive") 1278 ("InterlacedSource%d", m_interlacedSourceFlagList, false, NUM_POSSIBLE_LEVEL, "Indicate that source is interlaced") 1279 ("NonPackedSource%d", m_nonPackedConstraintFlagList, false, NUM_POSSIBLE_LEVEL, "Indicate that source does not contain frame packing") 1280 ("FrameOnly%d", m_frameOnlyConstraintFlagList, false, NUM_POSSIBLE_LEVEL, "Indicate that the bitstream contains only frames") 1301 1302 ("ProfileCompatibility%d", m_profileCompatibility, Profile::NONE, (MAX_NUM_LAYER_IDS + 1), "Compatible profile to be used when encoding") 1303 ("ProgressiveSource%d", m_progressiveSourceFlagList, false, (MAX_NUM_LAYER_IDS + 1), "Indicate that source is progressive") 1304 ("InterlacedSource%d", m_interlacedSourceFlagList, false, (MAX_NUM_LAYER_IDS + 1), "Indicate that source is interlaced") 1305 ("NonPackedSource%d", m_nonPackedConstraintFlagList, false, (MAX_NUM_LAYER_IDS + 1), "Indicate that source does not contain frame packing") 1306 ("FrameOnly%d", m_frameOnlyConstraintFlagList, false, (MAX_NUM_LAYER_IDS + 1), "Indicate that the bitstream contains only frames") 1281 1307 1282 1308 ("LayerPTLIndex%d", cfg_layerPTLIdx, 0, MAX_VPS_LAYER_ID_PLUS1, "Index of PTL for each layer") 1283 ("ListOfProfileTierLevelOls%d", cfg_listOfLayerPTLOfOlss, string(""), MAX_VPS_ LAYER_ID_PLUS1, "PTL Index for each layer in each OLS except the first OLS. The PTL index for layer in the first OLS is set to 1")1309 ("ListOfProfileTierLevelOls%d", cfg_listOfLayerPTLOfOlss, string(""), MAX_VPS_OUTPUT_LAYER_SETS_PLUS1, "PTL Index for each layer in each OLS except the first OLS. The PTL index for layer in the first OLS is set to 1") 1284 1310 #else 1285 1311 ("Profile", extendedProfile, NONE, "Profile name to use for encoding. Use main (for main), main10 (for main10), main-still-picture, main-RExt (for Range Extensions profile), any of the RExt specific profile names, or none") … … 2622 2648 } 2623 2649 #if MULTIPLE_PTL_SUPPORT 2624 if( olsCtr > startOlsCtr ) // Non-default OLS 2625 { 2626 scanStringToArray( cfg_listOfLayerPTLOfOlss[olsCtr], m_numLayerInIdList[m_outputLayerSetIdx[olsCtr - startOlsCtr - 1]], "List of PTL for each layer in OLS", m_listOfLayerPTLofOlss[olsCtr] ); 2627 } 2628 else 2629 { 2630 scanStringToArray( cfg_listOfLayerPTLOfOlss[olsCtr], m_numLayerInIdList[olsCtr], "List of PTL for each layer in OLS", m_listOfLayerPTLofOlss[olsCtr] ); 2631 } 2650 Int olsToLsIndex = (olsCtr > startOlsCtr) ? m_outputLayerSetIdx[olsCtr - m_numLayerSets] : olsCtr; 2651 scanStringToArray( cfg_listOfLayerPTLOfOlss[olsCtr], m_numLayerInIdList[olsToLsIndex], "List of PTL for each layers in OLS", m_listOfLayerPTLofOlss[olsCtr] ); 2652 //For conformance checking 2653 //Conformance of a layer in an output operation point associated with an OLS in a bitstream to the Scalable Main profile is indicated as follows: 2654 //If OpTid of the output operation point is equal to vps_max_sub_layer_minus1, the conformance is indicated by general_profile_idc being equal to 7 or general_profile_compatibility_flag[ 7 ] being equal to 1 2655 //Conformance of a layer in an output operation point associated with an OLS in a bitstream to the Scalable Main 10 profile is indicated as follows: 2656 //If OpTid of the output operation point is equal to vps_max_sub_layer_minus1, the conformance is indicated by general_profile_idc being equal to 7 or general_profile_compatibility_flag[ 7 ] being equal to 1 2657 //The following assert may be updated / upgraded to take care of general_profile_compatibility_flag. 2658 for ( Int ii = 1; ii < m_numLayerInIdList[olsToLsIndex]; ii++) 2659 { 2660 if (m_layerSetLayerIdList[olsToLsIndex][ii - 1] != 0 && m_layerSetLayerIdList[olsToLsIndex][ii] != 0) //Profile / profile compatibility of enhancement layers must indicate the same profile. 2661 { 2662 assert( (m_profileList[m_listOfLayerPTLofOlss[olsCtr][ii]] == m_profileList[m_listOfLayerPTLofOlss[olsCtr][ii - 1]]) || 2663 (m_profileList[m_listOfLayerPTLofOlss[olsCtr][ii]] == m_profileCompatibility[m_listOfLayerPTLofOlss[olsCtr][ii - 1]]) || 2664 (m_profileCompatibility[m_listOfLayerPTLofOlss[olsCtr][ii]] == m_profileList[m_listOfLayerPTLofOlss[olsCtr][ii - 1]]) ); 2665 } 2666 } 2632 2667 #endif 2633 2668 }
Note: See TracChangeset for help on using the changeset viewer.