Changeset 962 in 3DVCSoftware for branches/HTM-11.0-dev0/source/Lib/TLibCommon/TComSlice.cpp
- Timestamp:
- 2 Jul 2014, 18:11:25 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-11.0-dev0/source/Lib/TLibCommon/TComSlice.cpp
r956 r962 1 /* The copyright in this software is being made available under the BSD1 /* The copyright in this software is being made available under the BSD 2 2 * License, included below. This software may be subject to other third party 3 3 * and contributor rights, including patent rights, and no such rights are … … 45 45 //! \{ 46 46 47 47 48 TComSlice::TComSlice() 48 49 : m_iPPSId ( -1 ) 50 #if H_MV_HLS_8_POC_Q0142_32 51 , m_slicePicOrderCntLsb ( 0 ) 52 #endif 49 53 , m_iPOC ( 0 ) 50 54 , m_iLastIDR ( 0 ) … … 70 74 , m_pcPic ( NULL ) 71 75 , m_colFromL0Flag ( 1 ) 76 #if SETTING_NO_OUT_PIC_PRIOR 77 , m_noOutputPriorPicsFlag ( false ) 78 , m_noRaslOutputFlag ( false ) 79 , m_handleCraAsBlaFlag ( false ) 80 #endif 72 81 , m_colRefIdx ( 0 ) 73 82 , m_uiTLayer ( 0 ) … … 459 468 { 460 469 // The variable NumPocTotalCurr is derived as specified in subclause 7.4.7.2. It is a requirement of bitstream conformance that the following applies to the value of NumPocTotalCurr: 461 // ?If the current picture is a BLA or CRA picture, the value of NumPocTotalCurr shall be equal to 0.462 // ?Otherwise, when the current picture contains a P or B slice, the value of NumPocTotalCurr shall not be equal to 0.470 // - If the current picture is a BLA or CRA picture, the value of NumPocTotalCurr shall be equal to 0. 471 // - Otherwise, when the current picture contains a P or B slice, the value of NumPocTotalCurr shall not be equal to 0. 463 472 if (getRapPicFlag()) 464 473 { … … 903 912 pocCRA = pocCurr; 904 913 } 914 #if EFFICIENT_FIELD_IRAP 915 bRefreshPending = true; 916 #endif 905 917 } 906 918 else // CRA or No DR 907 919 { 920 #if EFFICIENT_FIELD_IRAP 921 if(getAssociatedIRAPType() == NAL_UNIT_CODED_SLICE_IDR_N_LP || getAssociatedIRAPType() == NAL_UNIT_CODED_SLICE_IDR_W_RADL) 922 { 923 if (bRefreshPending==true && pocCurr > m_iLastIDR) // IDR reference marking pending 924 { 925 TComList<TComPic*>::iterator iterPic = rcListPic.begin(); 926 while (iterPic != rcListPic.end()) 927 { 928 rpcPic = *(iterPic); 929 if (rpcPic->getPOC() != pocCurr && rpcPic->getPOC() != m_iLastIDR) 930 { 931 rpcPic->getSlice(0)->setReferenced(false); 932 } 933 iterPic++; 934 } 935 bRefreshPending = false; 936 } 937 } 938 else 939 { 940 #endif 908 941 if (bRefreshPending==true && pocCurr > pocCRA) // CRA reference marking pending 909 942 { … … 920 953 bRefreshPending = false; 921 954 } 955 #if EFFICIENT_FIELD_IRAP 956 } 957 #endif 922 958 if ( getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA ) // CRA picture found 923 959 { … … 1194 1230 // in decoding order shall precede the IRAP picture in output order. 1195 1231 // (Note that any picture following in output order would be present in the DPB) 1232 #if !SETTING_NO_OUT_PIC_PRIOR 1196 1233 if(rpcPic->getSlice(0)->getPicOutputFlag() == 1) 1234 #else 1235 if(rpcPic->getSlice(0)->getPicOutputFlag() == 1 && !this->getNoOutputPriorPicsFlag()) 1236 #endif 1197 1237 { 1198 1238 if(nalUnitType == NAL_UNIT_CODED_SLICE_BLA_N_LP || … … 1370 1410 /** Function for applying picture marking based on the Reference Picture Set in pReferencePictureSet. 1371 1411 */ 1412 #if ALLOW_RECOVERY_POINT_AS_RAP 1413 Int TComSlice::checkThatAllRefPicsAreAvailable( TComList<TComPic*>& rcListPic, TComReferencePictureSet *pReferencePictureSet, Bool printErrors, Int pocRandomAccess, Bool bUseRecoveryPoint) 1414 #else 1372 1415 Int TComSlice::checkThatAllRefPicsAreAvailable( TComList<TComPic*>& rcListPic, TComReferencePictureSet *pReferencePictureSet, Bool printErrors, Int pocRandomAccess) 1373 { 1416 #endif 1417 { 1418 #if ALLOW_RECOVERY_POINT_AS_RAP 1419 Int atLeastOneUnabledByRecoveryPoint = 0; 1420 Int atLeastOneFlushedByPreviousIDR = 0; 1421 #endif 1374 1422 TComPic* rpcPic; 1375 1423 Int i, isAvailable; … … 1392 1440 if(rpcPic->getIsLongTerm() && (rpcPic->getPicSym()->getSlice(0)->getPOC()) == pReferencePictureSet->getPOC(i) && rpcPic->getSlice(0)->isReferenced()) 1393 1441 { 1442 #if ALLOW_RECOVERY_POINT_AS_RAP 1443 if(bUseRecoveryPoint && this->getPOC() > pocRandomAccess && this->getPOC() + pReferencePictureSet->getDeltaPOC(i) < pocRandomAccess) 1444 { 1445 isAvailable = 0; 1446 } 1447 else 1448 { 1394 1449 isAvailable = 1; 1450 } 1451 #else 1452 isAvailable = 1; 1453 #endif 1395 1454 } 1396 1455 } … … 1402 1461 if(rpcPic->getIsLongTerm() && curPoc == refPoc && rpcPic->getSlice(0)->isReferenced()) 1403 1462 { 1463 #if ALLOW_RECOVERY_POINT_AS_RAP 1464 if(bUseRecoveryPoint && this->getPOC() > pocRandomAccess && this->getPOC() + pReferencePictureSet->getDeltaPOC(i) < pocRandomAccess) 1465 { 1466 isAvailable = 0; 1467 } 1468 else 1469 { 1404 1470 isAvailable = 1; 1471 } 1472 #else 1473 isAvailable = 1; 1474 #endif 1405 1475 } 1406 1476 } … … 1425 1495 if (rpcPic->getSlice(0)->isReferenced() && curPoc == refPoc) 1426 1496 { 1497 #if ALLOW_RECOVERY_POINT_AS_RAP 1498 if(bUseRecoveryPoint && this->getPOC() > pocRandomAccess && this->getPOC() + pReferencePictureSet->getDeltaPOC(i) < pocRandomAccess) 1499 { 1500 isAvailable = 0; 1501 } 1502 else 1503 { 1427 1504 isAvailable = 1; 1428 1505 rpcPic->setIsLongTerm(1); 1429 1506 break; 1507 } 1508 #else 1509 isAvailable = 1; 1510 rpcPic->setIsLongTerm(1); 1511 break; 1512 #endif 1430 1513 } 1431 1514 } … … 1455 1538 } 1456 1539 } 1540 #if ALLOW_RECOVERY_POINT_AS_RAP 1541 else if(bUseRecoveryPoint && this->getPOC() > pocRandomAccess) 1542 { 1543 atLeastOneUnabledByRecoveryPoint = 1; 1544 } 1545 else if(bUseRecoveryPoint && (this->getAssociatedIRAPType()==NAL_UNIT_CODED_SLICE_IDR_N_LP || this->getAssociatedIRAPType()==NAL_UNIT_CODED_SLICE_IDR_W_RADL)) 1546 { 1547 atLeastOneFlushedByPreviousIDR = 1; 1548 } 1549 #endif 1457 1550 } 1458 1551 } … … 1470 1563 if(!rpcPic->getIsLongTerm() && rpcPic->getPicSym()->getSlice(0)->getPOC() == this->getPOC() + pReferencePictureSet->getDeltaPOC(i) && rpcPic->getSlice(0)->isReferenced()) 1471 1564 { 1565 #if ALLOW_RECOVERY_POINT_AS_RAP 1566 if(bUseRecoveryPoint && this->getPOC() > pocRandomAccess && this->getPOC() + pReferencePictureSet->getDeltaPOC(i) < pocRandomAccess) 1567 { 1568 isAvailable = 0; 1569 } 1570 else 1571 { 1472 1572 isAvailable = 1; 1573 } 1574 #else 1575 isAvailable = 1; 1576 #endif 1473 1577 } 1474 1578 } … … 1497 1601 } 1498 1602 } 1499 } 1603 #if ALLOW_RECOVERY_POINT_AS_RAP 1604 else if(bUseRecoveryPoint && this->getPOC() > pocRandomAccess) 1605 { 1606 atLeastOneUnabledByRecoveryPoint = 1; 1607 } 1608 else if(bUseRecoveryPoint && (this->getAssociatedIRAPType()==NAL_UNIT_CODED_SLICE_IDR_N_LP || this->getAssociatedIRAPType()==NAL_UNIT_CODED_SLICE_IDR_W_RADL)) 1609 { 1610 atLeastOneFlushedByPreviousIDR = 1; 1500 1611 } 1612 #endif 1613 } 1614 } 1615 #if ALLOW_RECOVERY_POINT_AS_RAP 1616 if(atLeastOneUnabledByRecoveryPoint || atLeastOneFlushedByPreviousIDR) 1617 { 1618 return -1; 1619 } 1620 #endif 1501 1621 if(atLeastOneLost) 1502 1622 { … … 1515 1635 /** Function for constructing an explicit Reference Picture Set out of the available pictures in a referenced Reference Picture Set 1516 1636 */ 1637 #if ALLOW_RECOVERY_POINT_AS_RAP 1638 Void TComSlice::createExplicitReferencePictureSetFromReference( TComList<TComPic*>& rcListPic, TComReferencePictureSet *pReferencePictureSet, Bool isRAP, Int pocRandomAccess, Bool bUseRecoveryPoint) 1639 #else 1517 1640 Void TComSlice::createExplicitReferencePictureSetFromReference( TComList<TComPic*>& rcListPic, TComReferencePictureSet *pReferencePictureSet, Bool isRAP) 1641 #endif 1518 1642 { 1519 1643 TComPic* rpcPic; … … 1541 1665 pcRPS->setDeltaPOC(k, pReferencePictureSet->getDeltaPOC(i)); 1542 1666 pcRPS->setUsed(k, pReferencePictureSet->getUsed(i) && (!isRAP)); 1667 #if ALLOW_RECOVERY_POINT_AS_RAP 1668 pcRPS->setUsed(k, pcRPS->getUsed(k) && !(bUseRecoveryPoint && this->getPOC() > pocRandomAccess && this->getPOC() + pReferencePictureSet->getDeltaPOC(i) < pocRandomAccess) ); 1669 #endif 1543 1670 if(pcRPS->getDeltaPOC(k) < 0) 1544 1671 { … … 1553 1680 } 1554 1681 } 1682 #if EFFICIENT_FIELD_IRAP 1683 Bool useNewRPS = false; 1684 // if current picture is complimentary field associated to IRAP, add the IRAP to its RPS. 1685 if(m_pcPic->isField()) 1686 { 1687 TComList<TComPic*>::iterator iterPic = rcListPic.begin(); 1688 while ( iterPic != rcListPic.end()) 1689 { 1690 rpcPic = *(iterPic++); 1691 if(rpcPic->getPicSym()->getSlice(0)->getPOC() == this->getAssociatedIRAPPOC() && this->getAssociatedIRAPPOC() == this->getPOC()+1) 1692 { 1693 pcRPS->setDeltaPOC(k, 1); 1694 pcRPS->setUsed(k, true); 1695 nrOfPositivePictures++; 1696 k ++; 1697 useNewRPS = true; 1698 } 1699 } 1700 } 1701 #endif 1555 1702 pcRPS->setNumberOfNegativePictures(nrOfNegativePictures); 1556 1703 pcRPS->setNumberOfPositivePictures(nrOfPositivePictures); … … 1559 1706 // inter RPS prediction with. Here we just use the reference used by pReferencePictureSet. 1560 1707 // If pReferencePictureSet is not inter_RPS_predicted, then inter_RPS_prediction is for the current RPS also disabled. 1561 if (!pReferencePictureSet->getInterRPSPrediction()) 1708 if (!pReferencePictureSet->getInterRPSPrediction() 1709 #if EFFICIENT_FIELD_IRAP 1710 || useNewRPS 1711 #endif 1712 ) 1562 1713 { 1563 1714 pcRPS->setInterRPSPrediction(false); … … 1728 1879 m_vpsNumProfileTierLevelMinus1 = -1; 1729 1880 1730 m_numAdd OutputLayerSets = -1;1731 m_default TargetOutputLayerIdc = 0;1881 m_numAddLayerSets = -1; 1882 m_defaultOutputLayerIdc = 0; 1732 1883 1733 1884 for ( Int i = 0; i < MAX_VPS_OUTPUTLAYER_SETS; i++) 1734 1885 { 1735 m_ outputLayerSetIdxMinus1[i] = -1;1886 m_layerSetIdxForOlsMinus1[i] = -1; 1736 1887 m_profileLevelTierIdx[i] = 0; 1737 1888 for ( Int j = 0; j < MAX_VPS_NUH_LAYER_ID_PLUS1; j++) … … 1741 1892 m_altOutputLayerFlag[ i ] = false; 1742 1893 } 1894 1895 #if H_MV_HLS_8_PMS_Q0195_20 1896 m_repFormatIdxPresentFlag = false; 1897 #endif 1743 1898 m_maxOneActiveRefLayerFlag = false; 1744 1899 m_directDepTypeLenMinus2 = 0; 1745 1900 1746 1901 1902 #if H_MV_HLS_8_RPS_Q0100_36 1903 m_vpsExtensionFlag = true; 1904 #endif 1747 1905 m_avcBaseLayerFlag = false; 1748 1906 m_vpsNonVuiExtensionLength = 0; … … 1760 1918 { 1761 1919 m_vpsProfilePresentFlag [i] = false; 1762 m_ outputLayerSetIdxMinus1 [i] = 0;1920 m_layerSetIdxForOlsMinus1 [i] = 0; 1763 1921 for( Int j = 0; j < MAX_VPS_NUH_LAYER_ID_PLUS1; j++ ) 1764 1922 { … … 1864 2022 assert( getLayerIdInNuh( layer ) > getLayerIdInNuh( layer -1 ) ); 1865 2023 } 2024 2025 2026 #if H_MV_HLS_8_PMS_Q0195_20 2027 //The value of vps_num_rep_formats_minus1 shall be in the range of 0 to 255, inclusive. 2028 assert( getVpsNumRepFormatsMinus1() >= 0 ); 2029 assert( getVpsNumRepFormatsMinus1() <= 255 ); 2030 #endif 2031 1866 2032 return true; 1867 2033 } … … 1907 2073 } 1908 2074 } 2075 2076 #if H_MV_HLS_8 2077 for (Int i = 0 ; i < MAX_NUM_LAYER_IDS; i++ ) 2078 { 2079 m_numRefLayers[i] = 0; 2080 } 2081 2082 for (Int currLayerId = 0; currLayerId <= 62; currLayerId++ ) 2083 { 2084 for (Int i = 0 ; i < MAX_NUM_LAYER_IDS; i++ ) 2085 { 2086 m_recursiveRefLayerFlag[currLayerId][i] = 0; 2087 } 2088 } 2089 2090 2091 for( Int i = 0; i <= getMaxLayersMinus1(); i++ ) 2092 { 2093 Int iNuhLId = getLayerIdInNuh( i ); 2094 xSetRefLayerFlags( iNuhLId ); 2095 for( Int j = 0; j < 63; j++ ) 2096 { 2097 m_numRefLayers[ iNuhLId ] += m_recursiveRefLayerFlag[ iNuhLId ][ j ]; 2098 } 2099 } 2100 2101 2102 for( Int i = 0; i <= getMaxLayersMinus1(); i++ ) // Bug in spec "<" instead of "<=" 2103 { 2104 Int iNuhLId = getLayerIdInNuh( i ); 2105 Int predIdx = 0; 2106 for( Int j = iNuhLId + 1; j < 63; j++ ) 2107 { 2108 if( m_recursiveRefLayerFlag[ j ][ iNuhLId ] ) 2109 { 2110 m_predictedLayerId[ iNuhLId ][ predIdx++ ] = j; 2111 } 2112 } 2113 m_numPredictedLayers[ iNuhLId ] = predIdx; 2114 } 2115 2116 Bool countedLayerIdxFlag[ MAX_NUM_LAYERS ]; 2117 for( Int i = 0; i <= getMaxLayersMinus1(); i++ ) 2118 { 2119 countedLayerIdxFlag[ i ] = 0; 2120 } 2121 2122 for( Int i = 0, k = 0; i <= getMaxLayersMinus1(); i++ ) 2123 { 2124 Int iNuhLId = getLayerIdInNuh( i ); 2125 if( m_numDirectRefLayers[ iNuhLId ] == 0 ) 2126 { 2127 m_treePartitionLayerIdList[ k ][ 0 ] = iNuhLId; 2128 m_numLayersInTreePartition[ k ] = 1; 2129 for( Int j = 0; j < m_numPredictedLayers[ iNuhLId ]; j++ ) 2130 { 2131 if( !countedLayerIdxFlag[ getLayerIdInVps( m_predictedLayerId[ iNuhLId ][ j ] ) ] ) 2132 { 2133 m_treePartitionLayerIdList[ k ][ m_numLayersInTreePartition[ k ] ] = m_predictedLayerId[ iNuhLId ][ j ]; 2134 m_numLayersInTreePartition[ k ]++; 2135 countedLayerIdxFlag[ getLayerIdInVps( m_predictedLayerId[ iNuhLId ][ j ] ) ] = 1; 2136 } 2137 } 2138 k++; 2139 } 2140 m_numIndependentLayers = k; 2141 } 2142 #endif 1909 2143 } 1910 2144 … … 2071 2305 Int TComVPS::getNumOutputLayerSets() 2072 2306 { 2073 return getNumAddOutputLayerSets() + getVpsNumLayerSetsMinus1() + 1; 2307 #if H_MV_HLS_8_SYN_39_19 2308 return getNumAddOlss() + getNumLayerSets(); 2309 #else 2310 return getNumAddLayerSets() + getVpsNumLayerSetsMinus1() + 1; 2311 #endif 2074 2312 } 2075 2313 … … 2127 2365 Void TComVPS::deriveTargetLayerIdList( Int i ) 2128 2366 { 2129 Int lsIdx = getLayerSetIdxForOutputLayerSet( i );2367 Int lsIdx = olsIdxToLsIdx( i ); 2130 2368 2131 2369 for( Int j = 0; j < getNumLayersInIdList( lsIdx ); j++ ) … … 2137 2375 } 2138 2376 } 2377 #if H_MV_HLS_8_PMS_Q0165_18 2378 assert( getNumOutputLayersInOutputLayerSet( i ) > 0 ); 2379 #endif 2139 2380 } 2140 2381 … … 2142 2383 { 2143 2384 Bool outputLayerFlag; 2144 switch ( getDefault TargetOutputLayerIdc( ) )2385 switch ( getDefaultOutputLayerIdc( ) ) 2145 2386 { 2146 2387 case 0: … … 2148 2389 break; 2149 2390 case 1: 2150 outputLayerFlag = ( j == m_layerSetLayerIdList[ getLayerSetIdxForOutputLayerSet( i ) ].size() - 1 );2391 outputLayerFlag = ( j == m_layerSetLayerIdList[ olsIdxToLsIdx( i ) ].size() - 1 ); 2151 2392 break; 2152 2393 case 2: … … 2170 2411 { 2171 2412 Int maxSLMinus1 = 0; 2172 Int optLsIdx = getLayerSetIdxForOutputLayerSet( i ); 2413 #if H_MV_HLS_8_MIS_Q0102_30 2414 for( Int k = 0; k < getNumLayersInIdList( i ); k++ ) 2415 { 2416 Int lId = m_layerSetLayerIdList[i][k]; 2417 #else 2418 Int optLsIdx = olsIdxToLsIdx( i ); 2419 2173 2420 for( Int k = 0; k < getNumLayersInIdList( optLsIdx ); k++ ) 2174 2421 { 2175 2422 Int lId = m_layerSetLayerIdList[optLsIdx][k]; 2423 #endif 2176 2424 maxSLMinus1 = std::max( maxSLMinus1, getSubLayersVpsMaxMinus1( getLayerIdInVps( lId ) )); 2177 2425 } 2178 2426 return maxSLMinus1; 2179 2427 } 2180 2428 #if H_MV_HLS_8_RPS_Q0100_36 2429 Void TComVPS::inferDbpSizeLayerSetZero( TComSPS* sps, Bool encoder ) 2430 { 2431 for( Int j = 0; j <= getMaxSubLayersInLayerSetMinus1( 0 ); j++ ) 2432 { 2433 Int maxDecPicBufferingMinus1 = sps->getMaxDecPicBuffering( j ) - 1; 2434 Int numReorderPics = sps->getNumReorderPics ( j ); 2435 Int maxLatencyIncreasePlus1 = sps->getMaxLatencyIncrease( j ); 2436 2437 if ( encoder ) 2438 { 2439 assert( getDpbSize()->getMaxVpsDecPicBufferingMinus1(0, 0, j ) == maxDecPicBufferingMinus1 ); 2440 assert( getDpbSize()->getMaxVpsNumReorderPics (0, j ) == numReorderPics ); 2441 assert( getDpbSize()->getMaxVpsLatencyIncreasePlus1 (0, j ) == maxLatencyIncreasePlus1 ); 2442 } 2443 else 2444 { 2445 getDpbSize()->setMaxVpsDecPicBufferingMinus1(0, 0, j, maxDecPicBufferingMinus1 ); 2446 getDpbSize()->setMaxVpsNumReorderPics (0, j, numReorderPics ); 2447 getDpbSize()->setMaxVpsLatencyIncreasePlus1 (0, j, maxLatencyIncreasePlus1 ); 2448 } 2449 } 2450 } 2451 #endif 2181 2452 #endif // H_MV 2182 2453 … … 2250 2521 ::memset(m_usedByCurrPicLtSPSFlag, 0, sizeof(m_usedByCurrPicLtSPSFlag)); 2251 2522 #if H_MV 2252 m_spsExtensionFlag = false; 2523 #if !H_MV_HLS_8_SPS_NODOC_48 2524 m_spsExtensionPresentFlag = false; 2253 2525 for( Int i = 0; i < PS_EX_T_MAX_NUM; i++ ) 2254 2526 { 2255 2527 m_spsExtensionTypeFlag[ i ] = false; 2256 2528 } 2529 #else 2530 m_spsRangeExtensionsFlag = false; 2531 m_spsMultilayerExtensionFlag = false; 2532 #if H_3D 2533 m_spsExtension5bits = 0; 2534 m_sps3dExtensionFlag = false; 2535 #else 2536 m_spsExtension6bits = 0; 2537 #endif 2538 #endif 2539 2257 2540 m_numScaledRefLayerOffsets = 0; 2258 2541 … … 2434 2717 2435 2718 #if H_MV 2719 #if H_MV_HLS_8_SPS_NODOC_48 2720 m_ppsRangeExtensionsFlag = false; 2721 m_ppsMultilayerExtensionFlag = false; 2722 #if !H_3D 2723 m_ppsExtension6bits = 0; 2724 #else 2725 m_pps3dExtensionFlag = false; 2726 m_ppsExtension5bits = 0; 2727 #endif 2728 #else 2436 2729 for( Int i = 0; i < PS_EX_T_MAX_NUM; i++ ) 2437 2730 { 2438 2731 m_ppsExtensionTypeFlag[ i ] = false; 2439 2732 } 2733 #endif 2440 2734 #endif 2441 2735 } … … 2963 3257 Void TComSlice::markIvRefPicsAsShortTerm( std::vector<TComPic*> refPicSetInterLayer0, std::vector<TComPic*> refPicSetInterLayer1 ) 2964 3258 { 2965 // Mark as short term3259 // Mark as short-term 2966 3260 for ( Int i = 0; i < refPicSetInterLayer0.size(); i++ ) 2967 3261 { … … 2975 3269 2976 3270 } 3271 3272 #if !H_MV_HLS_8_DBP_NODOC_42 2977 3273 Void TComSlice::markIvRefPicsAsUnused( TComPicLists* ivPicLists, std::vector<Int> targetDecLayerIdSet, TComVPS* vps, Int curLayerId, Int curPoc ) 2978 3274 { … … 3029 3325 } 3030 3326 } 3031 3327 #endif 3032 3328 Void TComSlice::printRefPicList() 3033 3329 { … … 3046 3342 Void TComSlice::markCurrPic( TComPic* currPic ) 3047 3343 { 3344 3345 #if !H_MV_HLS_8_DBP_NODOC_42 3048 3346 if ( !currPic->getSlice(0)->getDiscardableFlag() ) 3049 3347 { 3348 #endif 3050 3349 currPic->getSlice(0)->setReferenced( true ) ; 3051 3350 currPic->setIsLongTerm( false ); 3351 #if !H_MV_HLS_8_DBP_NODOC_42 3052 3352 } 3053 3353 else … … 3055 3355 currPic->getSlice(0)->setReferenced( false ) ; 3056 3356 } 3357 #endif 3358 3359 #if H_MV_HLS_7_VPS_P0300_27 3360 currPic->setReconMark( true ); 3361 currPic->setPicOutputFlag( currPic->getSlice(0)->getPicOutputFlag() ); 3362 #endif 3057 3363 } 3058 3364 … … 3088 3394 Int refLayerIdx = vps->getLayerIdInVps( vps->getRefLayerId( getLayerId(), i ) ); 3089 3395 3396 #if H_MV_HLS_8_RPS_Q0060_17 3397 Bool refLayerPicFlag = ( vps->getSubLayersVpsMaxMinus1( refLayerIdx ) >= getTLayer() ) && ( getTLayer() == 0 ) && 3398 ( vps->getMaxTidIlRefPicsPlus1( refLayerIdx, vps->getLayerIdInVps( getLayerId() )) > getTLayer() ); 3399 #else 3090 3400 Bool refLayerPicFlag = ( vps->getSubLayersVpsMaxMinus1( refLayerIdx ) >= getTLayer() ) && 3091 3401 ( vps->getMaxTidIlRefPicsPlus1( refLayerIdx, vps->getLayerIdInVps( getLayerId() )) > getTLayer() ); 3402 #endif 3092 3403 3093 3404 return refLayerPicFlag; … … 3970 4281 } 3971 4282 } 4283 4284 // --------------- 4285 // To be added: 4286 // When vps_base_layer_internal_flag is equal to 0 and layer_in_bsp_flag[ h ][ i ][ 0 ] is equal to 1 for any value of h in the 4287 // range of 1 to vps_num_layer_sets_minus1, inclusive, and any value of i in the range of 0 to num_bitstream_partitions[ h ] - 1, 4288 // inclusive, the value of layer_in_bsp_flag[ h ][ i ][ j ] for at least one value of j in the range of 1 to 4289 // NumLayersInIdList[ h ] - 1, inclusive, shall be equal to 1. 4290 // --------------- 4291 4292 4293 // When num_bitstream_partitions[ h ] is equal to 1 for any value of h in the range 1 to vps_num_layer_set_minus1, inclusive, 4294 // the value of layer_in_bsp_flag[ h ][ 0 ][ j ] should be equal to 0 for at least one value of j in the range 0 to 4295 // NumLayersInIdList[ h ] − 1, inclusive. 4296 4297 4298 if ( getNumBitstreamPartitions( h ) == 1 ) 4299 { 4300 Bool atLeastOneZero = false; 4301 for ( Int j = 0; j <= vps->getNumLayersInIdList( h ) - 1; j++ ) 4302 { 4303 atLeastOneZero = atLeastOneZero || !getLayerInBspFlag( h, 0, j ); 4304 } 4305 assert( atLeastOneZero ); 4306 } 4307 4308 4309 // For any value of h in the range 1 to vps_num_layer_set_minus1, inclusive, the value of layer_in_bsp_flag[ h ][ i ][ j ] 4310 // shall be equal to 1 for at most one value of i in the range of 0 to num_bitstream_partitions[ h ] − 1, inclusive. 4311 4312 for ( Int j = 0; j <= vps->getNumLayersInIdList( h ) - 1; j++ ) 4313 { 4314 Int numLayerInBsp = 0; 4315 for ( Int i = 0; i <= getNumBitstreamPartitions( h ) - 1; i++ ) 4316 { 4317 numLayerInBsp += ( getLayerInBspFlag( h, i, j ) ? 1 : 0 ); 4318 } 4319 assert( numLayerInBsp <= 1 ); 4320 } 4321 3972 4322 } 3973 4323
Note: See TracChangeset for help on using the changeset viewer.