Changeset 964 in 3DVCSoftware for trunk/source/Lib/TLibCommon/TComSlice.cpp
- Timestamp:
- 5 Jul 2014, 05:16:45 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibCommon/TComSlice.cpp
r950 r964 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); … … 1712 1863 #endif 1713 1864 { 1865 #if H_MV_HLS_8_SYN_Q0041_03 1866 m_vpsBaseLayerInternalFlag = true; 1867 #endif 1868 1714 1869 for( Int i = 0; i < MAX_TLAYER; i++) 1715 1870 { … … 1728 1883 m_vpsNumProfileTierLevelMinus1 = -1; 1729 1884 1730 m_numAddOutputLayerSets = -1; 1731 m_defaultTargetOutputLayerIdc = 0; 1885 #if H_MV_HLS_8_SYN_39_19 1886 m_numAddLayerSets = 0; 1887 m_numAddOlss = 0; 1888 #else 1889 m_numAddLayerSets = -1; 1890 #endif 1891 m_defaultOutputLayerIdc = 0; 1732 1892 1733 1893 for ( Int i = 0; i < MAX_VPS_OUTPUTLAYER_SETS; i++) 1734 1894 { 1735 m_ outputLayerSetIdxMinus1[i] = -1;1895 m_layerSetIdxForOlsMinus1[i] = -1; 1736 1896 m_profileLevelTierIdx[i] = 0; 1737 1897 for ( Int j = 0; j < MAX_VPS_NUH_LAYER_ID_PLUS1; j++) … … 1741 1901 m_altOutputLayerFlag[ i ] = false; 1742 1902 } 1903 1904 #if H_MV_HLS_8_PMS_Q0195_20 1905 m_repFormatIdxPresentFlag = false; 1906 #endif 1743 1907 m_maxOneActiveRefLayerFlag = false; 1744 1908 m_directDepTypeLenMinus2 = 0; 1745 1909 1746 1910 1911 #if H_MV_HLS_8_RPS_Q0100_36 1912 m_vpsExtensionFlag = true; 1913 #endif 1747 1914 m_avcBaseLayerFlag = false; 1748 1915 m_vpsNonVuiExtensionLength = 0; … … 1760 1927 { 1761 1928 m_vpsProfilePresentFlag [i] = false; 1762 m_ outputLayerSetIdxMinus1 [i] = 0;1929 m_layerSetIdxForOlsMinus1 [i] = 0; 1763 1930 for( Int j = 0; j < MAX_VPS_NUH_LAYER_ID_PLUS1; j++ ) 1764 1931 { … … 1864 2031 assert( getLayerIdInNuh( layer ) > getLayerIdInNuh( layer -1 ) ); 1865 2032 } 2033 2034 2035 #if H_MV_HLS_8_PMS_Q0195_20 2036 //The value of vps_num_rep_formats_minus1 shall be in the range of 0 to 255, inclusive. 2037 assert( getVpsNumRepFormatsMinus1() >= 0 ); 2038 assert( getVpsNumRepFormatsMinus1() <= 255 ); 2039 #endif 2040 1866 2041 return true; 1867 2042 } … … 1907 2082 } 1908 2083 } 2084 2085 #if H_MV_HLS_8 2086 for (Int i = 0 ; i < MAX_NUM_LAYER_IDS; i++ ) 2087 { 2088 m_numRefLayers[i] = 0; 2089 } 2090 2091 for (Int currLayerId = 0; currLayerId <= 62; currLayerId++ ) 2092 { 2093 for (Int i = 0 ; i < MAX_NUM_LAYER_IDS; i++ ) 2094 { 2095 m_recursiveRefLayerFlag[currLayerId][i] = 0; 2096 } 2097 } 2098 2099 2100 for( Int i = 0; i <= getMaxLayersMinus1(); i++ ) 2101 { 2102 Int iNuhLId = getLayerIdInNuh( i ); 2103 xSetRefLayerFlags( iNuhLId ); 2104 for( Int j = 0; j < 63; j++ ) 2105 { 2106 m_numRefLayers[ iNuhLId ] += m_recursiveRefLayerFlag[ iNuhLId ][ j ]; 2107 } 2108 } 2109 2110 2111 for( Int i = 0; i <= getMaxLayersMinus1(); i++ ) // Bug in spec "<" instead of "<=" 2112 { 2113 Int iNuhLId = getLayerIdInNuh( i ); 2114 Int predIdx = 0; 2115 for( Int j = iNuhLId + 1; j < 63; j++ ) 2116 { 2117 if( m_recursiveRefLayerFlag[ j ][ iNuhLId ] ) 2118 { 2119 m_predictedLayerId[ iNuhLId ][ predIdx++ ] = j; 2120 } 2121 } 2122 m_numPredictedLayers[ iNuhLId ] = predIdx; 2123 } 2124 2125 Bool countedLayerIdxFlag[ MAX_NUM_LAYERS ]; 2126 for( Int i = 0; i <= getMaxLayersMinus1(); i++ ) 2127 { 2128 countedLayerIdxFlag[ i ] = 0; 2129 } 2130 2131 for( Int i = 0, k = 0; i <= getMaxLayersMinus1(); i++ ) 2132 { 2133 Int iNuhLId = getLayerIdInNuh( i ); 2134 if( m_numDirectRefLayers[ iNuhLId ] == 0 ) 2135 { 2136 m_treePartitionLayerIdList[ k ][ 0 ] = iNuhLId; 2137 m_numLayersInTreePartition[ k ] = 1; 2138 for( Int j = 0; j < m_numPredictedLayers[ iNuhLId ]; j++ ) 2139 { 2140 if( !countedLayerIdxFlag[ getLayerIdInVps( m_predictedLayerId[ iNuhLId ][ j ] ) ] ) 2141 { 2142 m_treePartitionLayerIdList[ k ][ m_numLayersInTreePartition[ k ] ] = m_predictedLayerId[ iNuhLId ][ j ]; 2143 m_numLayersInTreePartition[ k ]++; 2144 countedLayerIdxFlag[ getLayerIdInVps( m_predictedLayerId[ iNuhLId ][ j ] ) ] = 1; 2145 } 2146 } 2147 k++; 2148 } 2149 m_numIndependentLayers = k; 2150 } 2151 #endif 1909 2152 } 1910 2153 … … 1936 2179 } 1937 2180 } 2181 #if !BUG_FIX_TK65 1938 2182 assert( foundLayerIdinNuh != -1 ); 1939 2183 #endif 1940 2184 return foundLayerIdinNuh; 1941 2185 } … … 2070 2314 Int TComVPS::getNumOutputLayerSets() 2071 2315 { 2072 return getNumAddOutputLayerSets() + getVpsNumLayerSetsMinus1() + 1; 2316 #if H_MV_HLS_8_SYN_39_19 2317 return getNumAddOlss() + getNumLayerSets(); 2318 #else 2319 return getNumAddLayerSets() + getVpsNumLayerSetsMinus1() + 1; 2320 #endif 2073 2321 } 2074 2322 … … 2126 2374 Void TComVPS::deriveTargetLayerIdList( Int i ) 2127 2375 { 2128 Int lsIdx = getLayerSetIdxForOutputLayerSet( i );2376 Int lsIdx = olsIdxToLsIdx( i ); 2129 2377 2130 2378 for( Int j = 0; j < getNumLayersInIdList( lsIdx ); j++ ) … … 2136 2384 } 2137 2385 } 2386 #if H_MV_HLS_8_PMS_Q0165_18 2387 assert( getNumOutputLayersInOutputLayerSet( i ) > 0 ); 2388 #endif 2138 2389 } 2139 2390 … … 2141 2392 { 2142 2393 Bool outputLayerFlag; 2143 switch ( getDefault TargetOutputLayerIdc( ) )2394 switch ( getDefaultOutputLayerIdc( ) ) 2144 2395 { 2145 2396 case 0: … … 2147 2398 break; 2148 2399 case 1: 2149 outputLayerFlag = ( j == m_layerSetLayerIdList[ getLayerSetIdxForOutputLayerSet( i ) ].size() - 1 );2400 outputLayerFlag = ( j == m_layerSetLayerIdList[ olsIdxToLsIdx( i ) ].size() - 1 ); 2150 2401 break; 2151 2402 case 2: … … 2169 2420 { 2170 2421 Int maxSLMinus1 = 0; 2171 Int optLsIdx = getLayerSetIdxForOutputLayerSet( i ); 2422 #if H_MV_HLS_8_MIS_Q0102_30 2423 for( Int k = 0; k < getNumLayersInIdList( i ); k++ ) 2424 { 2425 Int lId = m_layerSetLayerIdList[i][k]; 2426 #else 2427 Int optLsIdx = olsIdxToLsIdx( i ); 2428 2172 2429 for( Int k = 0; k < getNumLayersInIdList( optLsIdx ); k++ ) 2173 2430 { 2174 2431 Int lId = m_layerSetLayerIdList[optLsIdx][k]; 2432 #endif 2175 2433 maxSLMinus1 = std::max( maxSLMinus1, getSubLayersVpsMaxMinus1( getLayerIdInVps( lId ) )); 2176 2434 } 2177 2435 return maxSLMinus1; 2178 2436 } 2179 2437 #if H_MV_HLS_8_RPS_Q0100_36 2438 Void TComVPS::inferDbpSizeLayerSetZero( TComSPS* sps, Bool encoder ) 2439 { 2440 for( Int j = 0; j <= getMaxSubLayersInLayerSetMinus1( 0 ); j++ ) 2441 { 2442 Int maxDecPicBufferingMinus1 = sps->getMaxDecPicBuffering( j ) - 1; 2443 Int numReorderPics = sps->getNumReorderPics ( j ); 2444 Int maxLatencyIncreasePlus1 = sps->getMaxLatencyIncrease( j ); 2445 2446 if ( encoder ) 2447 { 2448 assert( getDpbSize()->getMaxVpsDecPicBufferingMinus1(0, 0, j ) == maxDecPicBufferingMinus1 ); 2449 assert( getDpbSize()->getMaxVpsNumReorderPics (0, j ) == numReorderPics ); 2450 assert( getDpbSize()->getMaxVpsLatencyIncreasePlus1 (0, j ) == maxLatencyIncreasePlus1 ); 2451 } 2452 else 2453 { 2454 getDpbSize()->setMaxVpsDecPicBufferingMinus1(0, 0, j, maxDecPicBufferingMinus1 ); 2455 getDpbSize()->setMaxVpsNumReorderPics (0, j, numReorderPics ); 2456 getDpbSize()->setMaxVpsLatencyIncreasePlus1 (0, j, maxLatencyIncreasePlus1 ); 2457 } 2458 } 2459 } 2460 #endif 2180 2461 #endif // H_MV 2181 2462 … … 2249 2530 ::memset(m_usedByCurrPicLtSPSFlag, 0, sizeof(m_usedByCurrPicLtSPSFlag)); 2250 2531 #if H_MV 2251 m_spsExtensionFlag = false; 2532 #if !H_MV_HLS_8_SPS_NODOC_48 2533 m_spsExtensionPresentFlag = false; 2252 2534 for( Int i = 0; i < PS_EX_T_MAX_NUM; i++ ) 2253 2535 { 2254 2536 m_spsExtensionTypeFlag[ i ] = false; 2255 2537 } 2538 #else 2539 m_spsRangeExtensionsFlag = false; 2540 m_spsMultilayerExtensionFlag = false; 2541 #if H_3D 2542 m_spsExtension5bits = 0; 2543 m_sps3dExtensionFlag = false; 2544 #else 2545 m_spsExtension6bits = 0; 2546 #endif 2547 #endif 2548 2256 2549 m_numScaledRefLayerOffsets = 0; 2257 2550 … … 2433 2726 2434 2727 #if H_MV 2728 #if H_MV_HLS_8_SPS_NODOC_48 2729 m_ppsRangeExtensionsFlag = false; 2730 m_ppsMultilayerExtensionFlag = false; 2731 #if !H_3D 2732 m_ppsExtension6bits = 0; 2733 #else 2734 m_pps3dExtensionFlag = false; 2735 m_ppsExtension5bits = 0; 2736 #endif 2737 #else 2435 2738 for( Int i = 0; i < PS_EX_T_MAX_NUM; i++ ) 2436 2739 { 2437 2740 m_ppsExtensionTypeFlag[ i ] = false; 2438 2741 } 2742 #endif 2439 2743 #endif 2440 2744 } … … 2962 3266 Void TComSlice::markIvRefPicsAsShortTerm( std::vector<TComPic*> refPicSetInterLayer0, std::vector<TComPic*> refPicSetInterLayer1 ) 2963 3267 { 2964 // Mark as short term3268 // Mark as short-term 2965 3269 for ( Int i = 0; i < refPicSetInterLayer0.size(); i++ ) 2966 3270 { … … 2974 3278 2975 3279 } 3280 3281 #if !H_MV_HLS_8_DBP_NODOC_42 2976 3282 Void TComSlice::markIvRefPicsAsUnused( TComPicLists* ivPicLists, std::vector<Int> targetDecLayerIdSet, TComVPS* vps, Int curLayerId, Int curPoc ) 2977 3283 { … … 3028 3334 } 3029 3335 } 3030 3336 #endif 3031 3337 Void TComSlice::printRefPicList() 3032 3338 { … … 3045 3351 Void TComSlice::markCurrPic( TComPic* currPic ) 3046 3352 { 3353 3354 #if !H_MV_HLS_8_DBP_NODOC_42 3047 3355 if ( !currPic->getSlice(0)->getDiscardableFlag() ) 3048 3356 { 3357 #endif 3049 3358 currPic->getSlice(0)->setReferenced( true ) ; 3050 3359 currPic->setIsLongTerm( false ); 3360 #if !H_MV_HLS_8_DBP_NODOC_42 3051 3361 } 3052 3362 else … … 3054 3364 currPic->getSlice(0)->setReferenced( false ) ; 3055 3365 } 3366 #endif 3367 3368 #if H_MV_HLS_7_VPS_P0300_27 3369 currPic->setReconMark( true ); 3370 currPic->setPicOutputFlag( currPic->getSlice(0)->getPicOutputFlag() ); 3371 #endif 3056 3372 } 3057 3373 … … 3087 3403 Int refLayerIdx = vps->getLayerIdInVps( vps->getRefLayerId( getLayerId(), i ) ); 3088 3404 3405 #if H_MV_HLS_8_RPS_Q0060_17 3406 Bool refLayerPicFlag = ( vps->getSubLayersVpsMaxMinus1( refLayerIdx ) >= getTLayer() ) && ( getTLayer() == 0 ) && 3407 ( vps->getMaxTidIlRefPicsPlus1( refLayerIdx, vps->getLayerIdInVps( getLayerId() )) > getTLayer() ); 3408 #else 3089 3409 Bool refLayerPicFlag = ( vps->getSubLayersVpsMaxMinus1( refLayerIdx ) >= getTLayer() ) && 3090 3410 ( vps->getMaxTidIlRefPicsPlus1( refLayerIdx, vps->getLayerIdInVps( getLayerId() )) > getTLayer() ); 3411 #endif 3091 3412 3092 3413 return refLayerPicFlag; … … 3969 4290 } 3970 4291 } 4292 4293 // --------------- 4294 // To be added: 4295 // 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 4296 // 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, 4297 // inclusive, the value of layer_in_bsp_flag[ h ][ i ][ j ] for at least one value of j in the range of 1 to 4298 // NumLayersInIdList[ h ] - 1, inclusive, shall be equal to 1. 4299 // --------------- 4300 4301 4302 // 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, 4303 // 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 4304 // NumLayersInIdList[ h ] − 1, inclusive. 4305 4306 4307 if ( getNumBitstreamPartitions( h ) == 1 ) 4308 { 4309 Bool atLeastOneZero = false; 4310 for ( Int j = 0; j <= vps->getNumLayersInIdList( h ) - 1; j++ ) 4311 { 4312 atLeastOneZero = atLeastOneZero || !getLayerInBspFlag( h, 0, j ); 4313 } 4314 assert( atLeastOneZero ); 4315 } 4316 4317 4318 // 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 ] 4319 // shall be equal to 1 for at most one value of i in the range of 0 to num_bitstream_partitions[ h ] − 1, inclusive. 4320 4321 for ( Int j = 0; j <= vps->getNumLayersInIdList( h ) - 1; j++ ) 4322 { 4323 Int numLayerInBsp = 0; 4324 for ( Int i = 0; i <= getNumBitstreamPartitions( h ) - 1; i++ ) 4325 { 4326 numLayerInBsp += ( getLayerInBspFlag( h, i, j ) ? 1 : 0 ); 4327 } 4328 assert( numLayerInBsp <= 1 ); 4329 } 4330 3971 4331 } 3972 4332
Note: See TracChangeset for help on using the changeset viewer.