Changeset 1085 in SHVCSoftware for branches/SHM-dev/source
- Timestamp:
- 26 Mar 2015, 04:33:14 (10 years ago)
- Location:
- branches/SHM-dev/source
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp
r1081 r1085 1498 1498 for( i = 0; i < vps->getMaxLayers() - 1; i++ ) 1499 1499 { 1500 #if O0225_MAX_TID_FOR_REF_LAYERS1501 1500 for( Int j = i+1; j < vps->getMaxLayers(); j++) 1502 1501 { 1503 1502 vps->setMaxTidIlRefPicsPlus1(i, j, m_acTEncTop[i].getMaxTidIlRefPicsPlus1()); 1504 1503 } 1505 #else1506 vps->setMaxTidIlRefPicsPlus1(i, m_acTEncTop[i].getMaxTidIlRefPicsPlus1());1507 #endif1508 1504 } 1509 1505 } … … 1512 1508 for( i = 0; i < vps->getMaxLayers() - 1; i++ ) 1513 1509 { 1514 #if O0225_MAX_TID_FOR_REF_LAYERS1515 1510 for( Int j = i+1; j < vps->getMaxLayers(); j++) 1516 1511 { 1517 1512 vps->setMaxTidIlRefPicsPlus1(i, j, 7); 1518 1513 } 1519 #else1520 vps->setMaxTidIlRefPicsPlus1(i, 7);1521 #endif1522 1514 } 1523 1515 } -
branches/SHM-dev/source/Lib/TLibCommon/TComSlice.cpp
r1083 r1085 498 498 for( i=0; i < m_pcVPS->getNumDirectRefLayers( m_layerId ); i++ ) 499 499 { 500 #if O0225_MAX_TID_FOR_REF_LAYERS 501 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[i]->getSlice(0)->getLayerId(),m_layerId); 502 #else 503 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[i]->getSlice(0)->getLayerId()); 504 #endif 500 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[i]->getSlice(0)->getLayerIdx(), getLayerIdx()); 501 505 502 if( ((Int)(ilpPic[i]->getSlice(0)->getTLayer())<= maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[i]->getSlice(0)->getRapPicFlag() ) ) 506 503 { … … 654 651 { 655 652 Int refLayerIdc = m_interLayerPredLayerIdc[i]; 656 #if O0225_MAX_TID_FOR_REF_LAYERS 657 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId(),m_layerId); 658 #else 659 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId()); 660 #endif 653 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerIdx(), getLayerIdx()); 661 654 if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) ) 662 655 { … … 682 675 { 683 676 Int refLayerIdc = m_interLayerPredLayerIdc[i]; 684 #if O0225_MAX_TID_FOR_REF_LAYERS 685 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId(),m_layerId); 686 #else 687 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId()); 688 #endif 677 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerIdx(), getLayerIdx()); 689 678 if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) ) 690 679 { … … 719 708 { 720 709 Int refLayerIdc = m_interLayerPredLayerIdc[i]; 721 #if O0225_MAX_TID_FOR_REF_LAYERS 722 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId(),m_layerId); 723 #else 724 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId()); 725 #endif 710 Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1( ilpPic[refLayerIdc]->getSlice(0)->getLayerIdx(), getLayerIdx() ); 726 711 if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) ) 727 712 { … … 2127 2112 for( Int i = 0; i < MAX_VPS_LAYER_IDX_PLUS1 - 1; i++) 2128 2113 { 2129 #if O0225_MAX_TID_FOR_REF_LAYERS2130 2114 for( Int j = 0; j < MAX_VPS_LAYER_IDX_PLUS1; j++) 2131 2115 { 2132 2116 m_maxTidIlRefPicsPlus1[i][j] = m_uiMaxTLayers + 1; 2133 2117 } 2134 #else2135 m_maxTidIlRefPicsPlus1[i] = m_uiMaxTLayers + 1;2136 #endif2137 2118 } 2138 2119 #if VPS_VUI_TILES_NOT_IN_USE__FLAG … … 4371 4352 #endif 4372 4353 4373 #if O0225_MAX_TID_FOR_REF_LAYERS 4374 Int maxTidIlRefPicsPlus1 = m_pcVPS->getMaxTidIlRefPicsPlus1( pcIlpPic[refLayerIdc]->getSlice(0)->getLayerId(), m_layerId ); 4375 #else 4376 Int maxTidIlRefPicsPlus1 = m_pcVPS->getMaxTidIlRefPicsPlus1( pcIlpPic[refLayerIdc]->getSlice(0)->getLayerId() ); 4377 #endif 4354 Int maxTidIlRefPicsPlus1 = m_pcVPS->getMaxTidIlRefPicsPlus1( pcIlpPic[refLayerIdc]->getSlice(0)->getLayerIdx(), getLayerIdx() ); 4378 4355 assert( (Int)pcIlpPic[refLayerIdc]->getSlice(0)->getTLayer() < maxTidIlRefPicsPlus1 || ( !maxTidIlRefPicsPlus1 && pcIlpPic[refLayerIdc]->getSlice(0)->getRapPicFlag() ) ); 4379 4356 -
branches/SHM-dev/source/Lib/TLibCommon/TComSlice.h
r1078 r1085 750 750 Bool m_crossLayerAlignedIdrOnlyFlag; 751 751 #endif 752 #if O0225_MAX_TID_FOR_REF_LAYERS753 752 UInt m_maxTidIlRefPicsPlus1[MAX_VPS_LAYER_IDX_PLUS1 - 1][MAX_VPS_LAYER_IDX_PLUS1]; 754 #else755 UInt m_maxTidIlRefPicsPlus1[MAX_VPS_LAYER_IDX_PLUS1 - 1];756 #endif757 753 Bool m_maxTidRefPresentFlag; 758 754 #if VPS_TSLAYERS … … 1140 1136 Void setNumDirectRefLayers(Int layerId, UInt refLayerNum) { m_numDirectRefLayers[layerId] = refLayerNum; } 1141 1137 1142 UInt getRefLayerId(Int layerId, Int refLayerId x) { return m_refLayerId[layerId][refLayerIdx]; }1143 Void setRefLayerId(Int layerId, Int refLayerId x, UInt refLayerId) { m_refLayerId[layerId][refLayerIdx] = refLayerId; }1138 UInt getRefLayerId(Int layerId, Int refLayerIdc) { return m_refLayerId[layerId][refLayerIdc]; } 1139 Void setRefLayerId(Int layerId, Int refLayerIdc, UInt refLayerId) { m_refLayerId[layerId][refLayerIdc] = refLayerId; } 1144 1140 1145 1141 UInt getDirectDepTypeLen() { return m_directDepTypeLen; } … … 1213 1209 Bool getCrossLayerIrapAlignFlag() { return m_crossLayerIrapAlignFlag; } 1214 1210 Void setCrossLayerIrapAlignFlag(Bool x) { m_crossLayerIrapAlignFlag = x; } 1215 #if O0225_MAX_TID_FOR_REF_LAYERS 1216 UInt getMaxTidIlRefPicsPlus1(Int layerId, Int refLayerId) { return m_maxTidIlRefPicsPlus1[layerId][refLayerId]; } 1217 Void setMaxTidIlRefPicsPlus1(Int layerId, Int refLayerId, UInt maxSublayer) { m_maxTidIlRefPicsPlus1[layerId][refLayerId] = maxSublayer; } 1218 #else 1219 UInt getMaxTidIlRefPicsPlus1(Int layerId) { return m_maxTidIlRefPicsPlus1[layerId]; } 1220 Void setMaxTidIlRefPicsPlus1(Int layerId, UInt maxSublayer) { m_maxTidIlRefPicsPlus1[layerId] = maxSublayer; } 1221 #endif 1211 UInt getMaxTidIlRefPicsPlus1(Int refLayerIdx, Int layerIdx) { return m_maxTidIlRefPicsPlus1[refLayerIdx][layerIdx]; } 1212 Void setMaxTidIlRefPicsPlus1(Int refLayerIdx, Int layerIdx, UInt maxSublayer) { m_maxTidIlRefPicsPlus1[refLayerIdx][layerIdx] = maxSublayer; } 1222 1213 Bool getMaxTidRefPresentFlag() { return m_maxTidRefPresentFlag ;} 1223 1214 Void setMaxTidRefPresentFlag(Bool x) { m_maxTidRefPresentFlag = x;} … … 2726 2717 Void setActiveNumILRRefIdx ( Int i ) { m_activeNumILRRefIdx = i; } 2727 2718 2728 Int getInterLayerPredLayerIdc (UInt layerId x) { return m_interLayerPredLayerIdc[layerIdx];}2729 Void setInterLayerPredLayerIdc (UInt refLayerIdc, UInt layerId x) { m_interLayerPredLayerIdc[layerIdx] = refLayerIdc; }2719 Int getInterLayerPredLayerIdc (UInt layerIdc) { return m_interLayerPredLayerIdc[layerIdc];} 2720 Void setInterLayerPredLayerIdc (UInt refLayerIdc, UInt layerIdc) { m_interLayerPredLayerIdc[layerIdc] = refLayerIdc; } 2730 2721 2731 2722 Void setInterLayerPredEnabledFlag ( Bool val ) { m_interLayerPredEnabledFlag = val; } -
branches/SHM-dev/source/Lib/TLibCommon/TypeDef.h
r1046 r1085 203 203 #define EARLY_REF_PIC_MARKING 0 ///< Valencia meeting - remove early marking of inter-layer reference pictures 204 204 ///< Decoded picture marking of sub-layer non-reference pictures 205 #define O0225_MAX_TID_FOR_REF_LAYERS 1206 205 #define O0225_TID_BASED_IL_RPS_DERIV 1 207 206 #define VPS_TSLAYERS 1 ///< JCTVC-O0120 signal max temporal sub-layers for each layer -
branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp
r1079 r1085 1610 1610 { 1611 1611 #if Q0060_MAX_TID_REF_EQUAL_TO_ZERO 1612 if((pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerId()) > pcSlice->getTLayer() || pcSlice->getTLayer()==0) &&1612 if((pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerIdx()) > pcSlice->getTLayer() || pcSlice->getTLayer()==0) && 1613 1613 (pcSlice->getVPS()->getMaxTSLayersMinus1(pcSlice->getVPS()->getLayerIdxInVps(i)) >= pcSlice->getTLayer()) ) 1614 1614 #else 1615 if(pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerId()) > pcSlice->getTLayer() &&1615 if(pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerIdx()) > pcSlice->getTLayer() && 1616 1616 (pcSlice->getVPS()->getMaxTSLayersMinus1(pcSlice->getVPS()->getLayerIdxInVps(i)) >= pcSlice->getTLayer()) ) 1617 1617 #endif … … 1638 1638 { 1639 1639 READ_CODE( numBits,uiCode,"inter_layer_pred_layer_idc[i]" ); 1640 pcSlice->setInterLayerPredLayerIdc(uiCode, i);1640 pcSlice->setInterLayerPredLayerIdc(uiCode, i); 1641 1641 } 1642 1642 } … … 1645 1645 { 1646 1646 #if O0225_TID_BASED_IL_RPS_DERIV && TSLAYERS_IL_RPS 1647 Int refLayerId = pcSlice->getVPS()->getRefLayerId(pcSlice->getLayerId(), 0); 1648 Int refLayerIdx = pcSlice->getVPS()->getLayerIdxInVps(refLayerId); 1647 1649 #if Q0060_MAX_TID_REF_EQUAL_TO_ZERO 1648 if((pcSlice->getVPS()->getMaxTidIlRefPicsPlus1( 0,pcSlice->getLayerId()) > pcSlice->getTLayer() || pcSlice->getTLayer()==0) &&1649 (pcSlice->getVPS()->getMaxTSLayersMinus1( 0) >= pcSlice->getTLayer()) )1650 #else 1651 if( (pcSlice->getVPS()->getMaxTidIlRefPicsPlus1( 0,pcSlice->getLayerId()) > pcSlice->getTLayer()) &&1652 (pcSlice->getVPS()->getMaxTSLayersMinus1( 0) >= pcSlice->getTLayer()) )1650 if((pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(refLayerIdx, pcSlice->getLayerIdx()) > pcSlice->getTLayer() || pcSlice->getTLayer()==0) && 1651 (pcSlice->getVPS()->getMaxTSLayersMinus1(refLayerIdx) >= pcSlice->getTLayer()) ) 1652 #else 1653 if( (pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(refLayerIdx,pcSlice->getLayerIdx()) > pcSlice->getTLayer()) && 1654 (pcSlice->getVPS()->getMaxTSLayersMinus1(refLayerIdx) >= pcSlice->getTLayer()) ) 1653 1655 #endif 1654 1656 { 1655 1657 #endif 1656 1658 pcSlice->setActiveNumILRRefIdx(1); 1657 pcSlice->setInterLayerPredLayerIdc(0, 0);1659 pcSlice->setInterLayerPredLayerIdc(0, 0); 1658 1660 #if O0225_TID_BASED_IL_RPS_DERIV && TSLAYERS_IL_RPS 1659 1661 } … … 1673 1675 { 1674 1676 #if Q0060_MAX_TID_REF_EQUAL_TO_ZERO 1675 if((pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerId()) > pcSlice->getTLayer() || pcSlice->getTLayer()==0) &&1677 if((pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerIdx()) > pcSlice->getTLayer() || pcSlice->getTLayer()==0) && 1676 1678 (pcSlice->getVPS()->getMaxTSLayersMinus1(pcSlice->getVPS()->getLayerIdxInVps(i)) >= pcSlice->getTLayer()) ) 1677 1679 #else 1678 if(pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerId()) > pcSlice->getTLayer() &&1680 if(pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(i), pcSlice->getLayerIdx()) > pcSlice->getTLayer() && 1679 1681 (pcSlice->getVPS()->getMaxTSLayersMinus1(pcSlice->getVPS()->getLayerIdxInVps(i)) >= pcSlice->getTLayer()) ) 1680 1682 #endif … … 1686 1688 for( i = 0; i < pcSlice->getActiveNumILRRefIdx(); i++ ) 1687 1689 { 1688 pcSlice->setInterLayerPredLayerIdc(refLayerPicIdc[i], i);1689 } 1690 pcSlice->setInterLayerPredLayerIdc(refLayerPicIdc[i], i); 1691 } 1690 1692 #else 1691 1693 pcSlice->setActiveNumILRRefIdx(pcSlice->getNumILRRefIdx()); … … 2999 3001 for(i = 0; i < vps->getMaxLayers() - 1; i++) 3000 3002 { 3001 #if O0225_MAX_TID_FOR_REF_LAYERS3002 3003 for( j = i+1; j < vps->getMaxLayers(); j++) 3003 3004 { … … 3007 3008 } 3008 3009 } 3009 #else3010 READ_CODE( 3, uiCode, "max_tid_il_ref_pics_plus1[i]" ); vps->setMaxTidIlRefPicsPlus1(i, uiCode);3011 assert( uiCode <= vps->getMaxTLayers());3012 #endif3013 3010 } 3014 3011 } … … 3017 3014 for(i = 0; i < vps->getMaxLayers() - 1; i++) 3018 3015 { 3019 #if O0225_MAX_TID_FOR_REF_LAYERS3020 3016 for( j = i+1; j < vps->getMaxLayers(); j++) 3021 3017 { 3022 3018 vps->setMaxTidIlRefPicsPlus1(i, j, 7); 3023 3019 } 3024 #else3025 vps->setMaxTidIlRefPicsPlus1(i, 7);3026 #endif3027 3020 } 3028 3021 } … … 3691 3684 for( i = 0; i < vps->getMaxLayers() - 1; i++ ) 3692 3685 { 3693 #if O0225_MAX_TID_FOR_REF_LAYERS3694 3686 for( j = i + 1; j < vps->getMaxLayers(); j++ ) 3695 3687 { 3696 3688 vps->setMaxTidIlRefPicsPlus1(i, j, 7); 3697 3689 } 3698 #else3699 vps->setMaxTidIlRefPicsPlus1(i, 7);3700 #endif3701 3690 } 3702 3691 -
branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp
r1084 r1085 2848 2848 2849 2849 Int remainingInterLayerReferencesFlag = 0; 2850 #if O0225_MAX_TID_FOR_REF_LAYERS2851 2850 for ( Int j = latestDecIdx + 1; j < numTargetDecLayers; j++ ) 2852 2851 { 2853 2852 Int jLidx = pcSlice->getVPS()->getLayerIdxInVps(targetDecLayerIdList[j]); 2854 if ( currTid <= pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(latestDecLayerId,jLidx) - 1 ) 2855 { 2856 #else 2857 if ( currTid <= pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(latestDecLayerId) - 1 ) 2858 { 2859 for ( Int j = latestDecIdx + 1; j < numTargetDecLayers; j++ ) 2860 { 2861 #endif 2853 if ( currTid <= pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getVPS()->getLayerIdxInVps(latestDecLayerId),jLidx) - 1 ) 2854 { 2862 2855 for ( Int k = 0; k < m_ppcTDecTop[targetDecLayerIdList[j]]->getNumDirectRefLayers(); k++ ) 2863 2856 { -
branches/SHM-dev/source/Lib/TLibEncoder/TEncCavlc.cpp
r1073 r1085 2251 2251 for( i = 0; i < vps->getMaxLayers() - 1; i++) 2252 2252 { 2253 #if O0225_MAX_TID_FOR_REF_LAYERS2254 2253 for( j = i+1; j <= vps->getMaxLayers() - 1; j++) 2255 2254 { … … 2259 2258 } 2260 2259 } 2261 #else2262 WRITE_CODE(vps->getMaxTidIlRefPicsPlus1(i), 3, "max_tid_il_ref_pics_plus1[i]" );2263 #endif2264 2260 } 2265 2261 } -
branches/SHM-dev/source/Lib/TLibEncoder/TEncGOP.cpp
r1084 r1085 1323 1323 1324 1324 // Apply temporal layer restriction to inter-layer prediction 1325 #if O0225_MAX_TID_FOR_REF_LAYERS 1326 Int maxTidIlRefPicsPlus1 = m_pcEncTop->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getLayerId(),m_layerId); 1327 #else 1328 Int maxTidIlRefPicsPlus1 = m_pcEncTop->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getLayerId()); 1329 #endif 1325 Int maxTidIlRefPicsPlus1 = m_pcEncTop->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getLayerIdx(), pcSlice->getLayerIdx()); 1330 1326 if( ((Int)(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getRapPicFlag()) ) 1331 1327 {
Note: See TracChangeset for help on using the changeset viewer.