Changeset 972 in 3DVCSoftware
- Timestamp:
- 6 Jul 2014, 03:22:54 (10 years ago)
- Location:
- branches/HTM-11.1-dev0/source/Lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-11.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp
r971 r972 1071 1071 1072 1072 READ_CODE( 4, uiCode, "vps_video_parameter_set_id" ); pcVPS->setVPSId( uiCode ); 1073 #if H_MV _HLS_8_SYN_Q0041_031073 #if H_MV 1074 1074 READ_FLAG( uiCode, "vps_base_layer_internal_flag" ); pcVPS->setVpsBaseLayerInternalFlag( uiCode == 1 ); 1075 1075 READ_FLAG( uiCode, "vps_reserved_one_bit" ); assert( uiCode == 1 ); … … 1160 1160 } 1161 1161 } 1162 #if H_MV _HLS_8_RPS_Q0100_361162 #if H_MV 1163 1163 READ_FLAG( uiCode, "vps_extension_flag" ); pcVPS->setVpsExtensionFlag( uiCode == 1 ? true : false ); 1164 1164 if ( pcVPS->getVpsExtensionFlag() ) … … 1201 1201 { 1202 1202 UInt uiCode; 1203 #if !H_MV_HLS_8_SYN_Q0041_031204 READ_FLAG( uiCode, "avc_base_layer_flag" ); pcVPS->setAvcBaseLayerFlag( uiCode == 1 ? true : false );1205 #endif1206 1203 1207 1204 READ_FLAG( uiCode, "splitting_flag" ); pcVPS->setSplittingFlag( uiCode == 1 ? true : false ); … … 1323 1320 } 1324 1321 1325 #if H_MV_HLS_8_SYN_39_191326 1322 if ( pcVPS->getNumIndependentLayers() > 1 ) 1327 1323 { … … 1343 1339 pcVPS->initTargetLayerIdLists( ); 1344 1340 1345 #else1346 READ_UVLC( uiCode, "num_add_layer_sets" ); pcVPS->setNumAddLayerSets( uiCode );1347 pcVPS->initTargetLayerIdLists( );1348 if( pcVPS->getNumOutputLayerSets() > 1)1349 {1350 READ_CODE( 2, uiCode, "default_output_layer_idc" ); pcVPS->setDefaultOutputLayerIdc( std::min( uiCode, (UInt) 2 ) );1351 }1352 #endif1353 1341 1354 1342 pcVPS->setOutputLayerFlag(0, 0, pcVPS->inferOutputLayerFlag( 0, 0 )); … … 1359 1347 for( Int i = 1; i < pcVPS->getNumOutputLayerSets( ); i++ ) 1360 1348 { 1361 #if H_MV_HLS_8_SYN_39_191362 1349 if( i >= pcVPS->getNumLayerSets( ) ) 1363 #else1364 if( i > pcVPS->getVpsNumLayerSetsMinus1( ) )1365 #endif1366 1350 { 1367 1351 READ_UVLC( uiCode, "layer_set_idx_for_ols_minus1[i]" ); pcVPS->setLayerSetIdxForOlsMinus1( i, uiCode ); … … 1394 1378 } 1395 1379 1396 #if !H_MV_HLS_8_PMS_Q0195_201397 READ_FLAG( uiCode, "rep_format_idx_present_flag" ); pcVPS->setRepFormatIdxPresentFlag( uiCode == 1 );1398 if ( pcVPS->getRepFormatIdxPresentFlag() )1399 {1400 READ_UVLC( uiCode, "vps_num_rep_formats_minus1" ); pcVPS->setVpsNumRepFormatsMinus1( uiCode );1401 }1402 #else1403 1380 READ_UVLC( uiCode, "vps_num_rep_formats_minus1" ); pcVPS->setVpsNumRepFormatsMinus1( uiCode ); 1404 #endif1405 1381 1406 1382 for (Int i = 0; i <= pcVPS->getVpsNumRepFormatsMinus1(); i++ ) … … 1413 1389 } 1414 1390 1415 #if H_MV_HLS_8_PMS_Q0195_201416 1391 if ( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1417 1392 { 1418 1393 READ_FLAG( uiCode, "rep_format_idx_present_flag" ); pcVPS->setRepFormatIdxPresentFlag( uiCode == 1 ); 1419 1394 } 1420 #endif1421 1395 if( pcVPS->getRepFormatIdxPresentFlag() ) 1422 1396 { 1423 #if H_MV_HLS_8_SYN_Q0041_031424 1397 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1425 #else 1426 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1427 #endif 1428 { 1429 #if !H_MV_HLS_8_PMS_Q0195_20 1430 if( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1431 { 1432 #endif 1398 { 1433 1399 READ_CODE( pcVPS->getVpsRepFormatIdxLen(), uiCode, "vps_rep_format_idx[i]" ); pcVPS->setVpsRepFormatIdx( i, uiCode ); 1434 #if !H_MV_HLS_8_PMS_Q0195_20 1435 } 1436 #endif 1437 } 1438 } 1439 #if H_MV_HLS_8_PMS_Q0195_20 1400 } 1401 } 1440 1402 else 1441 1403 { 1442 #if H_MV_HLS_8_SYN_Q0041_031443 1404 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1444 #else1445 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1446 #endif1447 1405 { 1448 1406 pcVPS->setVpsRepFormatIdx( i, pcVPS->inferVpsRepFormatIdx( i ) ); … … 1474 1432 } 1475 1433 1476 #if H_MV_HLS_8_SYN_Q0041_031477 1434 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 2; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1478 1435 { 1479 1436 for( Int j = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; j < i; j++ ) 1480 #else1481 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1482 {1483 for( Int j = 0; j < i; j++ )1484 #endif1485 1437 { 1486 1438 if (pcVPS->getDirectDependencyFlag( i, j) ) … … 1568 1520 if( pcVPSVUI->getBitRatePresentVpsFlag( ) || pcVPSVUI->getPicRatePresentVpsFlag( ) ) 1569 1521 { 1570 #if H_MV_HLS_8_SYN_Q0041_031571 1522 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1572 #else 1573 for( Int i = 0; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1574 #endif 1575 { 1576 #if H_MV_HLS_8_MIS_Q0102_30 1523 { 1577 1524 for( Int j = 0; j <= pcVPS->getMaxSubLayersInLayerSetMinus1( i ); j++ ) 1578 #else1579 for( Int j = 0; j <= pcVPS->getMaxTLayers(); j++ )1580 #endif1581 1525 { 1582 1526 if( pcVPSVUI->getBitRatePresentVpsFlag( ) ) … … 1638 1582 if( !pcVPSVUI->getTilesNotInUseFlag() ) 1639 1583 { 1640 #if H_MV_HLS_8_SYN_Q0041_031641 1584 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1642 #else1643 for( Int i = 0; i <= pcVPS->getMaxLayersMinus1(); i++ )1644 #endif1645 1585 { 1646 1586 READ_FLAG( uiCode, "tiles_in_use_flag[i]" ); pcVPSVUI->setTilesInUseFlag( i, uiCode == 1 ); … … 1650 1590 } 1651 1591 } 1652 #if H_MV_HLS_8_SYN_Q0041_031653 1592 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 2; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1654 #else1655 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1656 #endif1657 1593 { 1658 1594 for( Int j = 0; j < pcVPS->getNumDirectRefLayers( pcVPS->getLayerIdInNuh( i ) ) ; j++ ) … … 1685 1621 for( Int j = 0; j < pcVPS->getNumDirectRefLayers( pcVPS->getLayerIdInNuh( i ) ); j++ ) 1686 1622 { 1687 #if H_MV_HLS_8_SYN_Q0041_031688 1623 if( pcVPS->getVpsBaseLayerInternalFlag() || pcVPS->getRefLayerId( pcVPS->getLayerIdInNuh( i ), j ) > 0 ) 1689 1624 { 1690 #endif1691 1625 READ_UVLC( uiCode, "min_spatial_segment_offset_plus1" ); pcVPSVUI->setMinSpatialSegmentOffsetPlus1( i, j, uiCode ); 1692 1626 if( pcVPSVUI->getMinSpatialSegmentOffsetPlus1( i, j ) > 0 ) … … 1698 1632 } 1699 1633 } 1700 #if H_MV_HLS_8_SYN_Q0041_03 1701 } 1702 #endif 1634 } 1703 1635 } 1704 1636 } … … 1747 1679 for( Int i = 0; i < vpsVuiBspHrdP->getNumBitstreamPartitions( h ); i++ ) 1748 1680 { 1749 #if H_MV_HLS_8_HRD_Q0101_041750 1681 for( Int j = 0; j < pcVPS->getNumLayersInIdList( h ); j++ ) 1751 1682 { 1752 1683 READ_FLAG( uiCode, "layer_in_bsp_flag" ); vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, uiCode == 1 ); 1753 #else1754 for( Int j = 0; j <= pcVPS->getMaxLayersMinus1(); j++ )1755 {1756 if( pcVPS->getLayerIdIncludedFlag( h ,j ) )1757 {1758 READ_FLAG( uiCode, "layer_in_bsp_flag" ); vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, uiCode == 1 );1759 }1760 else1761 {1762 vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, false ); // This inference seems to be missing in spec1763 }1764 #endif1765 1684 } 1766 1685 } … … 1770 1689 { 1771 1690 READ_UVLC( uiCode, "num_bsp_sched_combinations_minus1" ); vpsVuiBspHrdP->setNumBspSchedCombinationsMinus1( h, uiCode ); 1772 #if H_MV_HLS_8_HRD_Q0182_051773 1691 for( Int i = 0; i <= vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ); i++ ) 1774 #else1775 for( Int i = 0; i < vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ); i++ )1776 #endif1777 1692 { 1778 1693 for( Int j = 0; j < vpsVuiBspHrdP->getNumBitstreamPartitions( h ); j++ ) 1779 1694 { 1780 #if H_MV_HLS_8_HRD_Q0101_041781 1695 READ_CODE( vpsVuiBspHrdP->getBspCombHrdIdxLen(), uiCode, "bsp_comb_hrd_idx" ); vpsVuiBspHrdP->setBspCombHrdIdx( h, i, j, uiCode ); 1782 #else1783 READ_UVLC( uiCode, "bsp_comb_hrd_idx" ); vpsVuiBspHrdP->setBspCombHrdIdx( h, i, j, uiCode );1784 #endif1785 1696 READ_UVLC( uiCode, "bsp_comb_sched_idx" ); vpsVuiBspHrdP->setBspCombSchedIdx( h, i, j, uiCode ); 1786 #if H_MV_HLS_8_HRD_Q0101_041787 1697 vpsVuiBspHrdP->checkBspCombHrdAndShedIdx( pcVPS, h, i, j ); 1788 #endif1789 1698 } 1790 1699 } … … 1811 1720 for( Int i = 1; i < vps->getNumOutputLayerSets(); i++ ) 1812 1721 { 1813 #if H_MV_HLS_8_MIS_Q0102_301814 1722 Int currLsIdx = vps->olsIdxToLsIdx( i ); 1815 #endif1816 1723 READ_FLAG( uiCode, "sub_layer_flag_info_present_flag" ); dpbSize->setSubLayerFlagInfoPresentFlag( i, uiCode == 1 ); 1817 #if H_MV_HLS_8_MIS_Q0102_301818 1724 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( currLsIdx ); j++ ) 1819 #else1820 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( i ); j++ )1821 #endif1822 1725 { 1823 1726 if( j > 0 && dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) … … 1827 1730 if( dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) 1828 1731 { 1829 #if H_MV_HLS_8_MIS_Q0102_301830 1732 for( Int k = 0; k < vps->getNumLayersInIdList( currLsIdx ); k++ ) 1831 #else1832 for( Int k = 0; k < vps->getNumSubDpbs( vps->olsIdxToLsIdx( i )); k++ )1833 #endif1834 1733 { 1835 1734 READ_UVLC( uiCode, "max_vps_dec_pic_buffering_minus1" ); dpbSize->setMaxVpsDecPicBufferingMinus1( i, k, j, uiCode ); … … 1842 1741 if ( j > 0 ) 1843 1742 { 1844 #if H_MV_HLS_8_DBP_NODOC_421845 1743 for( Int k = 0; k < vps->getNumLayersInIdList( vps->olsIdxToLsIdx( i ) ); k++ ) 1846 #else1847 for( Int k = 0; k < vps->getNumSubDpbs( vps->olsIdxToLsIdx( i ) ); k++ )1848 #endif1849 1744 { 1850 1745 dpbSize->setMaxVpsDecPicBufferingMinus1( i, k, j, dpbSize->getMaxVpsDecPicBufferingMinus1( i,k, j - 1 ) ); … … 1857 1752 } 1858 1753 } 1859 #endif1860 1754 1861 1755 #if H_3D -
branches/HTM-11.1-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
r967 r972 277 277 pcPPS->getLayerId() != 1 ) 278 278 { 279 #if H_MV_HLS_8_SPS_NODOC_48280 279 pcPPS->setPps3dExtensionFlag( false ); 281 #else282 pcPPS->setPpsExtensionTypeFlag( PPS_EX_T_3D, false );283 #endif284 280 } 285 281 #endif … … 290 286 WRITE_FLAG( 1, "pps_extension_present_flag" ); 291 287 292 #if H_MV_HLS_8_SPS_NODOC_48293 288 WRITE_FLAG( pcPPS->getPpsRangeExtensionsFlag( ) ? 1 : 0 , "pps_range_extensions_flag" ); 294 289 WRITE_FLAG( pcPPS->getPpsMultilayerExtensionFlag( ) ? 1 : 0 , "pps_multilayer_extension_flag" ); … … 307 302 { 308 303 WRITE_FLAG( pcPPS->getPocResetInfoPresentFlag( ) ? 1 : 0 , "poc_reset_info_present_flag" ); 309 #if H_MV_HLS_8_PPS_NODOC_NN310 304 WRITE_FLAG( 0, "pps_extension_reserved_zero_flag" ); 311 #endif312 305 } 313 306 … … 318 311 } 319 312 #endif 320 #else321 for ( Int i = 0; i < PPS_EX_T_MAX_NUM; i++ )322 {323 WRITE_FLAG( pcPPS->getPpsExtensionTypeFlag( i ) ? 1 : 0 , "pps_extension_type_flag" );324 #if H_3D325 assert( !pcPPS->getPpsExtensionTypeFlag( i ) || i == PPS_EX_T_MV || i == PPS_EX_T_3D || i == PPS_EX_T_ESC );326 #else327 assert( !pcPPS->getPpsExtensionTypeFlag( i ) || i == PPS_EX_T_MV || i == PPS_EX_T_ESC );328 #endif329 }330 331 if( pcPPS->getPpsExtensionTypeFlag( PPS_EX_T_MV ) )332 {333 WRITE_FLAG( pcPPS->getPocResetInfoPresentFlag( ) ? 1 : 0 , "poc_reset_info_present_flag" );334 }335 336 #if H_3D337 if( pcPPS->getPpsExtensionTypeFlag( PPS_EX_T_3D ) ) // This probably needs to be aligned with Rext and SHVC338 {339 codePPSExtension( pcPPS );340 }341 #endif342 #endif343 344 313 #endif 345 314 … … 861 830 if ( pcSPS->getSpsExtensionPresentFlag() ) 862 831 { 863 #if H_MV_HLS_8_SPS_NODOC_48864 832 WRITE_FLAG( pcSPS->getSpsRangeExtensionsFlag( ) ? 1 : 0 , "sps_range_extensions_flag" ); 865 833 WRITE_FLAG( pcSPS->getSpsMultilayerExtensionFlag( ) ? 1 : 0 , "sps_multilayer_extension_flag" ); … … 869 837 WRITE_FLAG( pcSPS->getSps3dExtensionFlag( ) ? 1 : 0 , "sps_3d_extension_flag" ); 870 838 WRITE_CODE( pcSPS->getSpsExtension5bits( ), 5, "sps_extension_5bits" ); 871 #endif872 839 } 873 840 … … 889 856 890 857 #endif 891 #else892 for (Int i = 0; i < PS_EX_T_MAX_NUM; i++)893 {894 WRITE_FLAG( pcSPS->getSpsExtensionTypeFlag( i ) ? 1 : 0 , "sps_extension_type_flag" );895 #if H_3D896 assert( !pcSPS->getSpsExtensionTypeFlag( i ) || i == PS_EX_T_MV || i == PS_EX_T_3D );897 #else898 assert( !pcSPS->getSpsExtensionTypeFlag( i ) || i == PS_EX_T_MV );899 #endif900 }901 902 if( pcSPS->getSpsExtensionTypeFlag( PS_EX_T_MV ))903 {904 codeSPSExtension( pcSPS );905 }906 907 #if H_3D908 if( pcSPS->getSpsExtensionTypeFlag( PS_EX_T_3D ))909 {910 codeSPSExtension2( pcSPS, viewIndex, depthFlag );911 }912 #endif913 }914 858 #endif 915 859 #endif … … 955 899 { 956 900 WRITE_CODE( pcVPS->getVPSId(), 4, "vps_video_parameter_set_id" ); 957 #if H_MV _HLS_8_SYN_Q0041_03901 #if H_MV 958 902 WRITE_FLAG( pcVPS->getVpsBaseLayerInternalFlag( ) ? 1 : 0 , "vps_base_layer_internal_flag" ); 959 903 WRITE_FLAG( 1 , "vps_reserved_one_bit" ); … … 1042 986 } 1043 987 #if H_MV 1044 #if H_MV_HLS_8_RPS_Q0100_361045 988 WRITE_FLAG( pcVPS->getVpsExtensionFlag(), "vps_extension_flag" ); 1046 #else1047 WRITE_FLAG( 1, "vps_extension_flag" );1048 #endif1049 989 m_pcBitIf->writeAlignOne(); 1050 990 codeVPSExtension( pcVPS ); … … 1069 1009 #if H_MV 1070 1010 Void TEncCavlc::codeVPSExtension( TComVPS *pcVPS ) 1071 { 1072 1073 #if !H_MV_HLS_8_SYN_Q0041_03 1074 WRITE_FLAG( pcVPS->getAvcBaseLayerFlag() ? 1 : 0, "avc_base_layer_flag" ); 1075 #endif 1076 1011 { 1077 1012 WRITE_FLAG( pcVPS->getSplittingFlag() ? 1 : 0, "splitting_flag" ); 1078 1013 … … 1187 1122 } 1188 1123 1189 #if H_MV_HLS_8_SYN_39_191190 1124 if ( pcVPS->getNumIndependentLayers() > 1 ) 1191 1125 { … … 1204 1138 WRITE_CODE( pcVPS->getDefaultOutputLayerIdc( ), 2, "default_output_layer_idc" ); 1205 1139 } 1206 #else1207 WRITE_UVLC( pcVPS->getNumAddLayerSets( ), "num_add_layer_sets" );1208 1209 if( pcVPS->getNumOutputLayerSets() > 1)1210 {1211 WRITE_CODE( pcVPS->getDefaultOutputLayerIdc( ), 2, "default_output_layer_idc" );1212 }1213 #endif1214 1140 1215 1141 assert( pcVPS->getOutputLayerFlag(0, 0) == pcVPS->inferOutputLayerFlag( 0, 0 )); … … 1221 1147 for( Int i = 1; i < pcVPS->getNumOutputLayerSets( ); i++ ) 1222 1148 { 1223 #if H_MV_HLS_8_SYN_39_191224 1149 if( i >= pcVPS->getNumLayerSets( ) ) 1225 #else1226 if( i > pcVPS->getVpsNumLayerSetsMinus1( ) )1227 #endif1228 1150 { 1229 1151 WRITE_UVLC( pcVPS->getLayerSetIdxForOlsMinus1( i ), "layer_set_idx_for_ols_minus1[i]" ); … … 1256 1178 } 1257 1179 1258 #if !H_MV_HLS_8_PMS_Q0195_201259 WRITE_FLAG( pcVPS->getRepFormatIdxPresentFlag( ) ? 1 : 0 , "rep_format_idx_present_flag" );1260 if ( pcVPS->getRepFormatIdxPresentFlag() )1261 {1262 WRITE_UVLC( pcVPS->getVpsNumRepFormatsMinus1( ), "vps_num_rep_formats_minus1" );1263 }1264 #else1265 1180 WRITE_UVLC( pcVPS->getVpsNumRepFormatsMinus1( ), "vps_num_rep_formats_minus1" ); 1266 #endif1267 1181 1268 1182 for (Int i = 0; i <= pcVPS->getVpsNumRepFormatsMinus1(); i++ ) … … 1275 1189 } 1276 1190 1277 #if H_MV_HLS_8_PMS_Q0195_201278 1191 if ( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1279 1192 { 1280 1193 WRITE_FLAG( pcVPS->getRepFormatIdxPresentFlag( ) ? 1 : 0 , "rep_format_idx_present_flag" ); 1281 1194 } 1282 #endif 1195 1283 1196 if( pcVPS->getRepFormatIdxPresentFlag() ) 1284 1197 { 1285 #if H_MV_HLS_8_SYN_Q0041_031286 1198 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1287 #else 1288 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1289 #endif 1290 { 1291 #if !H_MV_HLS_8_PMS_Q0195_20 1292 if( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1293 { 1294 #endif 1199 { 1295 1200 WRITE_CODE( pcVPS->getVpsRepFormatIdx(i), pcVPS->getVpsRepFormatIdxLen(), "vps_rep_format_idx[i]" ); 1296 #if !H_MV_HLS_8_PMS_Q0195_20 1297 } 1298 #endif 1299 } 1300 } 1301 #if H_MV_HLS_8_PMS_Q0195_20 1201 } 1202 } 1302 1203 else 1303 1204 { 1304 #if H_MV_HLS_8_SYN_Q0041_031305 1205 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1306 #else1307 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1308 #endif1309 1206 { 1310 1207 assert( pcVPS->getVpsRepFormatIdx( i ) == pcVPS->inferVpsRepFormatIdx( i ) ); 1311 1208 } 1312 1209 } 1313 #endif1314 1315 1210 1316 1211 WRITE_FLAG( pcVPS->getMaxOneActiveRefLayerFlag( ) ? 1 : 0, "max_one_active_ref_layer_flag" ); … … 1337 1232 } 1338 1233 1339 #if H_MV_HLS_8_SYN_Q0041_031340 1234 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 2; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1341 1235 { 1342 1236 for( Int j = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; j < i; j++ ) 1343 #else1344 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1345 {1346 for( Int j = 0; j < i; j++ )1347 #endif1348 1237 { 1349 1238 if (pcVPS->getDirectDependencyFlag( i, j) ) … … 1366 1255 1367 1256 1368 WRITE_FLAG( pcVPS->getVpsVuiPresentFlag() ? 1 : 0 , "vps_vui_present_flag" );1257 WRITE_FLAG( pcVPS->getVpsVuiPresentFlag() ? 1 : 0 , "vps_vui_present_flag" ); 1369 1258 if( pcVPS->getVpsVuiPresentFlag() ) 1370 1259 { … … 1397 1286 for( Int i = 1; i < vps->getNumOutputLayerSets(); i++ ) 1398 1287 { 1399 #if H_MV_HLS_8_MIS_Q0102_301400 1288 Int currLsIdx = vps->olsIdxToLsIdx( i ); 1401 #endif1402 1289 WRITE_FLAG( dpbSize->getSubLayerFlagInfoPresentFlag( i ) ? 1 : 0 , "sub_layer_flag_info_present_flag" ); 1403 #if H_MV_HLS_8_MIS_Q0102_301404 1290 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( currLsIdx ); j++ ) 1405 #else1406 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( i ); j++ )1407 #endif1408 1291 { 1409 1292 if( j > 0 && dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) … … 1413 1296 if( dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) 1414 1297 { 1415 #if H_MV_HLS_8_MIS_Q0102_301416 1298 for( Int k = 0; k < vps->getNumLayersInIdList( currLsIdx ); k++ ) 1417 #else1418 for( Int k = 0; k < vps->getNumSubDpbs( vps->olsIdxToLsIdx( i )); k++ )1419 #endif1420 1299 { 1421 1300 WRITE_UVLC( dpbSize->getMaxVpsDecPicBufferingMinus1( i, k, j ), "max_vps_dec_pic_buffering_minus1" ); … … 1428 1307 if ( j > 0 ) 1429 1308 { 1430 #if H_MV_HLS_8_DBP_NODOC_421431 1309 for( Int k = 0; k < vps->getNumLayersInIdList( vps->olsIdxToLsIdx( i ) ); k++ ) 1432 #else1433 for( Int k = 0; k < vps->getNumSubDpbs( vps->olsIdxToLsIdx( i ) ); k++ )1434 #endif1435 1310 { 1436 1311 assert( dpbSize->getMaxVpsDecPicBufferingMinus1( i, k, j ) == dpbSize->getMaxVpsDecPicBufferingMinus1( i,k, j - 1 ) ); … … 1493 1368 if( pcVPSVUI->getBitRatePresentVpsFlag( ) || pcVPSVUI->getPicRatePresentVpsFlag( ) ) 1494 1369 { 1495 #if H_MV_HLS_8_SYN_Q0041_031496 1370 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1497 #else 1498 for( Int i = 0; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1499 #endif 1500 { 1501 #if H_MV_HLS_8_MIS_Q0102_30 1371 { 1502 1372 for( Int j = 0; j <= pcVPS->getMaxSubLayersInLayerSetMinus1( i ); j++ ) 1503 #else1504 for( Int j = 0; j <= pcVPS->getMaxTLayers(); j++ )1505 #endif1506 1373 { 1507 1374 if( pcVPSVUI->getBitRatePresentVpsFlag( ) ) … … 1563 1430 if( !pcVPSVUI->getTilesNotInUseFlag() ) 1564 1431 { 1565 #if H_MV_HLS_8_SYN_Q0041_031566 1432 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1567 #else1568 for( Int i = 0; i <= pcVPS->getMaxLayersMinus1(); i++ )1569 #endif1570 1433 { 1571 1434 WRITE_FLAG( pcVPSVUI->getTilesInUseFlag( i ) ? 1 : 0 , "tiles_in_use_flag[i]" ); … … 1575 1438 } 1576 1439 } 1577 #if H_MV_HLS_8_SYN_Q0041_031578 1440 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 2; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1579 #else1580 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1581 #endif1582 1441 { 1583 1442 for( Int j = 0; j < pcVPS->getNumDirectRefLayers( pcVPS->getLayerIdInNuh( i ) ) ; j++ ) … … 1610 1469 for( Int j = 0; j < pcVPS->getNumDirectRefLayers( pcVPS->getLayerIdInNuh( i ) ); j++ ) 1611 1470 { 1612 #if H_MV_HLS_8_SYN_Q0041_031613 1471 if( pcVPS->getVpsBaseLayerInternalFlag() || pcVPS->getRefLayerId( pcVPS->getLayerIdInNuh( i ), j ) > 0 ) 1614 1472 { 1615 #endif 1616 WRITE_UVLC( pcVPSVUI->getMinSpatialSegmentOffsetPlus1( i, j ), "min_spatial_segment_offset_plus1" ); 1617 if( pcVPSVUI->getMinSpatialSegmentOffsetPlus1( i, j ) > 0 ) 1618 { 1619 WRITE_FLAG( pcVPSVUI->getCtuBasedOffsetEnabledFlag( i, j ) ? 1 : 0 , "ctu_based_offset_enabled_flag" ); 1620 if( pcVPSVUI->getCtuBasedOffsetEnabledFlag( i, j ) ) 1473 WRITE_UVLC( pcVPSVUI->getMinSpatialSegmentOffsetPlus1( i, j ), "min_spatial_segment_offset_plus1" ); 1474 if( pcVPSVUI->getMinSpatialSegmentOffsetPlus1( i, j ) > 0 ) 1621 1475 { 1622 WRITE_UVLC( pcVPSVUI->getMinHorizontalCtuOffsetPlus1( i, j ), "min_horizontal_ctu_offset_plus1" ); 1476 WRITE_FLAG( pcVPSVUI->getCtuBasedOffsetEnabledFlag( i, j ) ? 1 : 0 , "ctu_based_offset_enabled_flag" ); 1477 if( pcVPSVUI->getCtuBasedOffsetEnabledFlag( i, j ) ) 1478 { 1479 WRITE_UVLC( pcVPSVUI->getMinHorizontalCtuOffsetPlus1( i, j ), "min_horizontal_ctu_offset_plus1" ); 1480 } 1623 1481 } 1624 1482 } 1625 #if H_MV_HLS_8_SYN_Q0041_031626 }1627 #endif1628 1483 } 1629 1484 } … … 1673 1528 for( Int i = 0; i < vpsVuiBspHrdP->getNumBitstreamPartitions( h ); i++ ) 1674 1529 { 1675 #if H_MV_HLS_8_HRD_Q0101_041676 1530 for( Int j = 0; j < pcVPS->getNumLayersInIdList( h ); j++ ) 1677 1531 { 1678 1532 WRITE_FLAG( vpsVuiBspHrdP->getLayerInBspFlag( h, i, j ) ? 1 : 0 , "layer_in_bsp_flag" ); 1679 #else1680 for( Int j = 0; j <= pcVPS->getMaxLayersMinus1(); j++ )1681 {1682 if( pcVPS->getLayerIdIncludedFlag( h ,j ) )1683 {1684 WRITE_FLAG( vpsVuiBspHrdP->getLayerInBspFlag( h, i, j ) ? 1 : 0 , "layer_in_bsp_flag" );1685 }1686 else1687 {1688 vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, false ); // This inference seems to be missing in spec1689 }1690 #endif1691 1533 } 1692 1534 } … … 1696 1538 { 1697 1539 WRITE_UVLC( vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ), "num_bsp_sched_combinations_minus1" ); 1698 #if H_MV_HLS_8_HRD_Q0182_051699 1540 for( Int i = 0; i <= vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ); i++ ) 1700 #else1701 for( Int i = 0; i < vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ); i++ )1702 #endif1703 1541 { 1704 1542 for( Int j = 0; j < vpsVuiBspHrdP->getNumBitstreamPartitions( h ); j++ ) 1705 1543 { 1706 #if H_MV_HLS_8_HRD_Q0101_041707 1544 WRITE_CODE( vpsVuiBspHrdP->getBspCombHrdIdx( h, i, j ), vpsVuiBspHrdP->getBspCombHrdIdxLen(), "bsp_comb_hrd_idx" ); 1708 #else1709 WRITE_UVLC( vpsVuiBspHrdP->getBspCombHrdIdx( h, i, j ), "bsp_comb_hrd_idx" );1710 #endif1711 1545 WRITE_UVLC( vpsVuiBspHrdP->getBspCombSchedIdx( h, i, j ), "bsp_comb_sched_idx" ); 1712 1546 1713 #if H_MV_HLS_8_HRD_Q0101_041714 1547 vpsVuiBspHrdP->checkBspCombHrdAndShedIdx( pcVPS, h, i, j ); 1715 #endif1716 1548 } 1717 1549 } … … 1907 1739 Int picOrderCntLSB = (pcSlice->getPOC()-pcSlice->getLastIDR()+(1<<pcSlice->getSPS()->getBitsForPOC())) & ((1<<pcSlice->getSPS()->getBitsForPOC())-1); 1908 1740 WRITE_CODE( picOrderCntLSB, pcSlice->getSPS()->getBitsForPOC(), "slice_pic_order_cnt_lsb"); 1909 #if H_MV_HLS_8_POC_Q0142_321910 1741 pcSlice->setSlicePicOrderCntLsb( picOrderCntLSB ); 1911 #endif1912 1742 } 1913 1743 … … 2341 2171 } 2342 2172 2343 #if H_MV_HLS_8_POC_Q0142_322344 2173 pcSlice->checkPocResetIdc(); 2345 #endif2346 2174 2347 2175 if( pcSlice->getPocResetIdc() != 0 ) … … 2355 2183 WRITE_CODE( pcSlice->getPocLsbVal( ), pcSlice->getPocLsbValLen() , "poc_lsb_val" ); 2356 2184 } 2357 #if H_MV_HLS_8_POC_Q0142_322358 2185 pcSlice->checkPocLsbVal(); 2359 #endif2360 2186 2361 2187 if( !pcSlice->getPocMsbValRequiredFlag() /* TODO && pcSlice->getVPS()->getVpsPocLsbAlignedFlag() */ ) … … 2363 2189 WRITE_FLAG( pcSlice->getPocMsbValPresentFlag( ) ? 1 : 0 , "poc_msb_val_present_flag" ); 2364 2190 } 2365 #if H_MV_HLS_8_POC_Q0146_152366 2191 else 2367 2192 { 2368 2193 assert( pcSlice->getPocMsbValPresentFlag() == pcSlice->inferPocMsbValPresentFlag( ) ); 2369 2194 } 2370 #endif2371 2195 2372 2196 if( pcSlice->getPocMsbValPresentFlag() )
Note: See TracChangeset for help on using the changeset viewer.