Changeset 976 in 3DVCSoftware for trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp
- Timestamp:
- 7 Jul 2014, 17:27:51 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp
r964 r976 374 374 375 375 #if H_MV 376 #if H_MV_HLS_8_SPS_NODOC_48377 376 READ_FLAG( uiCode, "pps_range_extensions_flag" ); pcPPS->setPpsRangeExtensionsFlag( uiCode == 1 ); 378 377 READ_FLAG( uiCode, "pps_multilayer_extension_flag" ); pcPPS->setPpsMultilayerExtensionFlag( uiCode == 1 ); … … 390 389 if ( pcPPS->getPpsMultilayerExtensionFlag() ) 391 390 { 392 READ_FLAG( uiCode, "poc_reset_info_present_flag" ); pcPPS->setPocResetInfoPresentFlag( uiCode == 1 ); 393 #if H_MV_HLS_8_PPS_NODOC_NN 394 READ_FLAG( uiCode, "pps_extension_reserved_zero_flag" ); 395 #endif 391 READ_FLAG( uiCode, "poc_reset_info_present_flag" ); pcPPS->setPocResetInfoPresentFlag( uiCode == 1 ); 392 READ_FLAG( uiCode, "pps_extension_reserved_zero_flag" ); 396 393 } 397 394 #if !H_3D … … 406 403 { 407 404 #endif 408 #else 409 for ( Int i = 0; i < PPS_EX_T_MAX_NUM; i++ ) 410 { 411 READ_FLAG( uiCode, "pps_extension_type_flag" ); pcPPS->setPpsExtensionTypeFlag( i, uiCode == 1 ); 412 #if H_3D 413 assert( !pcPPS->getPpsExtensionTypeFlag( i ) || i == PPS_EX_T_MV || i == PPS_EX_T_3D || i == PPS_EX_T_ESC ); 414 #else 415 assert( !pcPPS->getPpsExtensionTypeFlag( i ) || i == PPS_EX_T_MV || i == PPS_EX_T_ESC ); 416 #endif 417 } 418 419 420 if( pcPPS->getPpsExtensionTypeFlag( PPS_EX_T_MV ) ) 421 { 422 READ_FLAG( uiCode, "poc_reset_info_present_flag" ); pcPPS->setPocResetInfoPresentFlag( uiCode == 1 ); 423 } 424 425 #if H_3D 426 if( pcPPS->getPpsExtensionTypeFlag( PPS_EX_T_3D ) ) // This probably needs to be aligned with Rext and SHVC 427 { 428 parsePPSExtension( pcPPS, pcVPS ); 429 } 430 #endif 431 432 if( pcPPS->getPpsExtensionTypeFlag( PPS_EX_T_ESC ) ) 433 { 434 #endif 405 435 406 #endif 436 407 … … 481 452 READ_FLAG(uiCode, "inter_view_dlt_pred_enable_flag[ i ]"); 482 453 483 #if MTK_DLT_CODING_FIX_H0091484 454 if( uiCode ) 485 455 { 486 456 assert( pcDLT->getUseDLTFlag( 1 )); 487 457 } 488 #endif489 490 458 pcDLT->setInterViewDltPredEnableFlag( i, (uiCode == 1) ? true : false ); 491 459 … … 795 763 { 796 764 #endif 797 READ_CODE( 3, uiCode, "sps_max_sub_layers_minus1" ); pcSPS->setMaxTLayers ( uiCode+1 );798 assert(uiCode <= 6);799 800 READ_FLAG( uiCode, "sps_temporal_id_nesting_flag" ); pcSPS->setTemporalIdNestingFlag ( uiCode > 0 ? true : false );801 if ( pcSPS->getMaxTLayers() == 1 )802 {803 // sps_temporal_id_nesting_flag must be 1 when sps_max_sub_layers_minus1 is 0804 assert( uiCode == 1 );805 }806 807 parsePTL(pcSPS->getPTL(), 1, pcSPS->getMaxTLayers() - 1);765 READ_CODE( 3, uiCode, "sps_max_sub_layers_minus1" ); pcSPS->setMaxTLayers ( uiCode+1 ); 766 assert(uiCode <= 6); 767 768 READ_FLAG( uiCode, "sps_temporal_id_nesting_flag" ); pcSPS->setTemporalIdNestingFlag ( uiCode > 0 ? true : false ); 769 if ( pcSPS->getMaxTLayers() == 1 ) 770 { 771 // sps_temporal_id_nesting_flag must be 1 when sps_max_sub_layers_minus1 is 0 772 assert( uiCode == 1 ); 773 } 774 775 parsePTL(pcSPS->getPTL(), 1, pcSPS->getMaxTLayers() - 1); 808 776 #if H_MV 809 777 } … … 823 791 { 824 792 #endif 825 READ_UVLC( uiCode, "chroma_format_idc" ); pcSPS->setChromaFormatIdc( uiCode );826 assert(uiCode <= 3);827 // in the first version we only support chroma_format_idc equal to 1 (4:2:0), so separate_colour_plane_flag cannot appear in the bitstream828 assert (uiCode == 1);829 if( uiCode == 3 )830 {831 READ_FLAG( uiCode, "separate_colour_plane_flag"); assert(uiCode == 0);832 }833 834 READ_UVLC ( uiCode, "pic_width_in_luma_samples" ); pcSPS->setPicWidthInLumaSamples ( uiCode );835 READ_UVLC ( uiCode, "pic_height_in_luma_samples" ); pcSPS->setPicHeightInLumaSamples( uiCode );793 READ_UVLC( uiCode, "chroma_format_idc" ); pcSPS->setChromaFormatIdc( uiCode ); 794 assert(uiCode <= 3); 795 // in the first version we only support chroma_format_idc equal to 1 (4:2:0), so separate_colour_plane_flag cannot appear in the bitstream 796 assert (uiCode == 1); 797 if( uiCode == 3 ) 798 { 799 READ_FLAG( uiCode, "separate_colour_plane_flag"); assert(uiCode == 0); 800 } 801 802 READ_UVLC ( uiCode, "pic_width_in_luma_samples" ); pcSPS->setPicWidthInLumaSamples ( uiCode ); 803 READ_UVLC ( uiCode, "pic_height_in_luma_samples" ); pcSPS->setPicHeightInLumaSamples( uiCode ); 836 804 #if H_MV 837 805 } … … 860 828 { 861 829 #endif 862 READ_UVLC( uiCode, "bit_depth_luma_minus8" );863 assert(uiCode <= 6);864 pcSPS->setBitDepthY( uiCode + 8 );865 pcSPS->setQpBDOffsetY( (Int) (6*uiCode) );866 867 READ_UVLC( uiCode, "bit_depth_chroma_minus8" );868 assert(uiCode <= 6);869 pcSPS->setBitDepthC( uiCode + 8 );870 pcSPS->setQpBDOffsetC( (Int) (6*uiCode) );830 READ_UVLC( uiCode, "bit_depth_luma_minus8" ); 831 assert(uiCode <= 6); 832 pcSPS->setBitDepthY( uiCode + 8 ); 833 pcSPS->setQpBDOffsetY( (Int) (6*uiCode) ); 834 835 READ_UVLC( uiCode, "bit_depth_chroma_minus8" ); 836 assert(uiCode <= 6); 837 pcSPS->setBitDepthC( uiCode + 8 ); 838 pcSPS->setQpBDOffsetC( (Int) (6*uiCode) ); 871 839 #if H_MV 872 840 } … … 880 848 { 881 849 #endif 882 UInt subLayerOrderingInfoPresentFlag;883 READ_FLAG(subLayerOrderingInfoPresentFlag, "sps_sub_layer_ordering_info_present_flag");884 885 for(UInt i=0; i <= pcSPS->getMaxTLayers()-1; i++)886 {887 READ_UVLC ( uiCode, "sps_max_dec_pic_buffering_minus1[i]");888 pcSPS->setMaxDecPicBuffering( uiCode + 1, i);889 READ_UVLC ( uiCode, "sps_num_reorder_pics[i]" );890 pcSPS->setNumReorderPics(uiCode, i);891 READ_UVLC ( uiCode, "sps_max_latency_increase_plus1[i]");892 pcSPS->setMaxLatencyIncrease( uiCode, i );893 894 if (!subLayerOrderingInfoPresentFlag)895 {896 for (i++; i <= pcSPS->getMaxTLayers()-1; i++)897 {898 pcSPS->setMaxDecPicBuffering(pcSPS->getMaxDecPicBuffering(0), i);899 pcSPS->setNumReorderPics(pcSPS->getNumReorderPics(0), i);900 pcSPS->setMaxLatencyIncrease(pcSPS->getMaxLatencyIncrease(0), i);901 }902 break;903 }904 }850 UInt subLayerOrderingInfoPresentFlag; 851 READ_FLAG(subLayerOrderingInfoPresentFlag, "sps_sub_layer_ordering_info_present_flag"); 852 853 for(UInt i=0; i <= pcSPS->getMaxTLayers()-1; i++) 854 { 855 READ_UVLC ( uiCode, "sps_max_dec_pic_buffering_minus1[i]"); 856 pcSPS->setMaxDecPicBuffering( uiCode + 1, i); 857 READ_UVLC ( uiCode, "sps_num_reorder_pics[i]" ); 858 pcSPS->setNumReorderPics(uiCode, i); 859 READ_UVLC ( uiCode, "sps_max_latency_increase_plus1[i]"); 860 pcSPS->setMaxLatencyIncrease( uiCode, i ); 861 862 if (!subLayerOrderingInfoPresentFlag) 863 { 864 for (i++; i <= pcSPS->getMaxTLayers()-1; i++) 865 { 866 pcSPS->setMaxDecPicBuffering(pcSPS->getMaxDecPicBuffering(0), i); 867 pcSPS->setNumReorderPics(pcSPS->getNumReorderPics(0), i); 868 pcSPS->setMaxLatencyIncrease(pcSPS->getMaxLatencyIncrease(0), i); 869 } 870 break; 871 } 872 } 905 873 #if H_MV 906 874 } … … 912 880 READ_UVLC( uiCode, "log2_diff_max_min_coding_block_size" ); 913 881 pcSPS->setLog2DiffMaxMinCodingBlockSize(uiCode); 914 882 915 883 if (pcSPS->getPTL()->getGeneralPTL()->getLevelIdc() >= Level::LEVEL5) 916 884 { 917 885 assert(log2MinCUSize + pcSPS->getLog2DiffMaxMinCodingBlockSize() >= 5); 918 886 } 919 887 920 888 Int maxCUDepthDelta = uiCode; 921 889 pcSPS->setMaxCUWidth ( 1<<(log2MinCUSize + maxCUDepthDelta) ); … … 948 916 { 949 917 #endif 950 READ_FLAG( uiCode, "sps_scaling_list_data_present_flag" ); pcSPS->setScalingListPresentFlag ( uiCode );951 if(pcSPS->getScalingListPresentFlag ())952 {953 parseScalingList( pcSPS->getScalingList() );954 }918 READ_FLAG( uiCode, "sps_scaling_list_data_present_flag" ); pcSPS->setScalingListPresentFlag ( uiCode ); 919 if(pcSPS->getScalingListPresentFlag ()) 920 { 921 parseScalingList( pcSPS->getScalingList() ); 922 } 955 923 #if H_MV 956 924 } … … 1017 985 { 1018 986 #if H_MV 1019 #if H_MV_HLS_8_SPS_NODOC_481020 987 READ_FLAG( uiCode, "sps_range_extensions_flag" ); pcSPS->setSpsRangeExtensionsFlag( uiCode == 1 ); 1021 988 READ_FLAG( uiCode, "sps_multilayer_extension_flag" ); pcSPS->setSpsMultilayerExtensionFlag( uiCode == 1 ); … … 1050 1017 { 1051 1018 #endif 1052 #else 1053 for (Int i = 0; i < PS_EX_T_MAX_NUM; i++) 1054 { 1055 READ_FLAG( uiCode, "sps_extension_type_flag" ); pcSPS->setSpsExtensionTypeFlag( i, uiCode ); 1056 #if H_3D 1057 assert( !pcSPS->getSpsExtensionTypeFlag( i ) || i == PS_EX_T_MV || i == PS_EX_T_3D || i == PS_EX_T_ESC ); 1058 #else 1059 assert( !pcSPS->getSpsExtensionTypeFlag( i ) || i == PS_EX_T_MV || i == PS_EX_T_ESC ); 1060 #endif 1061 } 1062 1063 if( pcSPS->getSpsExtensionTypeFlag( PS_EX_T_MV )) 1064 { 1065 parseSPSExtension( pcSPS ); 1066 } 1067 1068 #if H_3D 1069 if( pcSPS->getSpsExtensionTypeFlag( PS_EX_T_3D )) 1070 { 1071 parseSPSExtension2( pcSPS, viewIndex, depthFlag ); 1072 } 1073 #endif 1074 1075 if ( pcSPS->getSpsExtensionTypeFlag( PS_EX_T_ESC )) 1076 { 1077 #endif 1078 #endif 1079 while ( xMoreRbspData() ) 1080 { 1081 READ_FLAG( uiCode, "sps_extension_data_flag"); 1082 } 1083 #if H_MV && !H_MV_HLS_8_SPS_NODOC_48 1084 } 1085 #endif 1019 1020 #endif 1021 while ( xMoreRbspData() ) 1022 { 1023 READ_FLAG( uiCode, "sps_extension_data_flag"); 1024 } 1086 1025 } 1087 1026 } … … 1132 1071 1133 1072 READ_CODE( 4, uiCode, "vps_video_parameter_set_id" ); pcVPS->setVPSId( uiCode ); 1134 #if H_MV _HLS_8_SYN_Q0041_031073 #if H_MV 1135 1074 READ_FLAG( uiCode, "vps_base_layer_internal_flag" ); pcVPS->setVpsBaseLayerInternalFlag( uiCode == 1 ); 1136 1075 READ_FLAG( uiCode, "vps_reserved_one_bit" ); assert( uiCode == 1 ); … … 1221 1160 } 1222 1161 } 1223 #if H_MV _HLS_8_RPS_Q0100_361162 #if H_MV 1224 1163 READ_FLAG( uiCode, "vps_extension_flag" ); pcVPS->setVpsExtensionFlag( uiCode == 1 ? true : false ); 1225 1164 if ( pcVPS->getVpsExtensionFlag() ) … … 1262 1201 { 1263 1202 UInt uiCode; 1264 #if !H_MV_HLS_8_SYN_Q0041_031265 READ_FLAG( uiCode, "avc_base_layer_flag" ); pcVPS->setAvcBaseLayerFlag( uiCode == 1 ? true : false );1266 #endif1267 1203 1268 1204 READ_FLAG( uiCode, "splitting_flag" ); pcVPS->setSplittingFlag( uiCode == 1 ? true : false ); … … 1384 1320 } 1385 1321 1386 #if H_MV_HLS_8_SYN_39_191387 1322 if ( pcVPS->getNumIndependentLayers() > 1 ) 1388 1323 { … … 1404 1339 pcVPS->initTargetLayerIdLists( ); 1405 1340 1406 #else1407 READ_UVLC( uiCode, "num_add_layer_sets" ); pcVPS->setNumAddLayerSets( uiCode );1408 pcVPS->initTargetLayerIdLists( );1409 if( pcVPS->getNumOutputLayerSets() > 1)1410 {1411 READ_CODE( 2, uiCode, "default_output_layer_idc" ); pcVPS->setDefaultOutputLayerIdc( std::min( uiCode, (UInt) 2 ) );1412 }1413 #endif1414 1341 1415 1342 pcVPS->setOutputLayerFlag(0, 0, pcVPS->inferOutputLayerFlag( 0, 0 )); … … 1420 1347 for( Int i = 1; i < pcVPS->getNumOutputLayerSets( ); i++ ) 1421 1348 { 1422 #if H_MV_HLS_8_SYN_39_191423 1349 if( i >= pcVPS->getNumLayerSets( ) ) 1424 #else1425 if( i > pcVPS->getVpsNumLayerSetsMinus1( ) )1426 #endif1427 1350 { 1428 1351 READ_UVLC( uiCode, "layer_set_idx_for_ols_minus1[i]" ); pcVPS->setLayerSetIdxForOlsMinus1( i, uiCode ); … … 1455 1378 } 1456 1379 1457 #if !H_MV_HLS_8_PMS_Q0195_201458 READ_FLAG( uiCode, "rep_format_idx_present_flag" ); pcVPS->setRepFormatIdxPresentFlag( uiCode == 1 );1459 if ( pcVPS->getRepFormatIdxPresentFlag() )1460 {1461 READ_UVLC( uiCode, "vps_num_rep_formats_minus1" ); pcVPS->setVpsNumRepFormatsMinus1( uiCode );1462 }1463 #else1464 1380 READ_UVLC( uiCode, "vps_num_rep_formats_minus1" ); pcVPS->setVpsNumRepFormatsMinus1( uiCode ); 1465 #endif1466 1381 1467 1382 for (Int i = 0; i <= pcVPS->getVpsNumRepFormatsMinus1(); i++ ) … … 1474 1389 } 1475 1390 1476 #if H_MV_HLS_8_PMS_Q0195_201477 1391 if ( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1478 1392 { 1479 1393 READ_FLAG( uiCode, "rep_format_idx_present_flag" ); pcVPS->setRepFormatIdxPresentFlag( uiCode == 1 ); 1480 1394 } 1481 #endif1482 1395 if( pcVPS->getRepFormatIdxPresentFlag() ) 1483 1396 { 1484 #if H_MV_HLS_8_SYN_Q0041_031485 1397 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1486 #else 1487 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1488 #endif 1489 { 1490 #if !H_MV_HLS_8_PMS_Q0195_20 1491 if( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1492 { 1493 #endif 1398 { 1494 1399 READ_CODE( pcVPS->getVpsRepFormatIdxLen(), uiCode, "vps_rep_format_idx[i]" ); pcVPS->setVpsRepFormatIdx( i, uiCode ); 1495 #if !H_MV_HLS_8_PMS_Q0195_20 1496 } 1497 #endif 1498 } 1499 } 1500 #if H_MV_HLS_8_PMS_Q0195_20 1400 } 1401 } 1501 1402 else 1502 1403 { 1503 #if H_MV_HLS_8_SYN_Q0041_031504 1404 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1505 #else1506 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1507 #endif1508 1405 { 1509 1406 pcVPS->setVpsRepFormatIdx( i, pcVPS->inferVpsRepFormatIdx( i ) ); 1510 1407 } 1511 1408 } 1512 #endif1513 1409 1514 1410 READ_FLAG( uiCode, "max_one_active_ref_layer_flag" ); pcVPS->setMaxOneActiveRefLayerFlag ( uiCode == 1 ); … … 1535 1431 } 1536 1432 1537 #if H_MV_HLS_8_SYN_Q0041_031538 1433 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 2; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1539 1434 { 1540 1435 for( Int j = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; j < i; j++ ) 1541 #else1542 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1543 {1544 for( Int j = 0; j < i; j++ )1545 #endif1546 1436 { 1547 1437 if (pcVPS->getDirectDependencyFlag( i, j) ) … … 1629 1519 if( pcVPSVUI->getBitRatePresentVpsFlag( ) || pcVPSVUI->getPicRatePresentVpsFlag( ) ) 1630 1520 { 1631 #if H_MV_HLS_8_SYN_Q0041_031632 1521 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1633 #else 1634 for( Int i = 0; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1635 #endif 1636 { 1637 #if H_MV_HLS_8_MIS_Q0102_30 1522 { 1638 1523 for( Int j = 0; j <= pcVPS->getMaxSubLayersInLayerSetMinus1( i ); j++ ) 1639 #else1640 for( Int j = 0; j <= pcVPS->getMaxTLayers(); j++ )1641 #endif1642 1524 { 1643 1525 if( pcVPSVUI->getBitRatePresentVpsFlag( ) ) … … 1699 1581 if( !pcVPSVUI->getTilesNotInUseFlag() ) 1700 1582 { 1701 #if H_MV_HLS_8_SYN_Q0041_031702 1583 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1703 #else1704 for( Int i = 0; i <= pcVPS->getMaxLayersMinus1(); i++ )1705 #endif1706 1584 { 1707 1585 READ_FLAG( uiCode, "tiles_in_use_flag[i]" ); pcVPSVUI->setTilesInUseFlag( i, uiCode == 1 ); … … 1711 1589 } 1712 1590 } 1713 #if H_MV_HLS_8_SYN_Q0041_031714 1591 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 2; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1715 #else1716 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1717 #endif1718 1592 { 1719 1593 for( Int j = 0; j < pcVPS->getNumDirectRefLayers( pcVPS->getLayerIdInNuh( i ) ) ; j++ ) … … 1746 1620 for( Int j = 0; j < pcVPS->getNumDirectRefLayers( pcVPS->getLayerIdInNuh( i ) ); j++ ) 1747 1621 { 1748 #if H_MV_HLS_8_SYN_Q0041_031749 1622 if( pcVPS->getVpsBaseLayerInternalFlag() || pcVPS->getRefLayerId( pcVPS->getLayerIdInNuh( i ), j ) > 0 ) 1750 1623 { 1751 #endif1752 1624 READ_UVLC( uiCode, "min_spatial_segment_offset_plus1" ); pcVPSVUI->setMinSpatialSegmentOffsetPlus1( i, j, uiCode ); 1753 1625 if( pcVPSVUI->getMinSpatialSegmentOffsetPlus1( i, j ) > 0 ) … … 1759 1631 } 1760 1632 } 1761 #if H_MV_HLS_8_SYN_Q0041_03 1762 } 1763 #endif 1633 } 1764 1634 } 1765 1635 } … … 1808 1678 for( Int i = 0; i < vpsVuiBspHrdP->getNumBitstreamPartitions( h ); i++ ) 1809 1679 { 1810 #if H_MV_HLS_8_HRD_Q0101_041811 1680 for( Int j = 0; j < pcVPS->getNumLayersInIdList( h ); j++ ) 1812 1681 { 1813 1682 READ_FLAG( uiCode, "layer_in_bsp_flag" ); vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, uiCode == 1 ); 1814 #else1815 for( Int j = 0; j <= pcVPS->getMaxLayersMinus1(); j++ )1816 {1817 if( pcVPS->getLayerIdIncludedFlag( h ,j ) )1818 {1819 READ_FLAG( uiCode, "layer_in_bsp_flag" ); vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, uiCode == 1 );1820 }1821 else1822 {1823 vpsVuiBspHrdP->setLayerInBspFlag( h, i, j, false ); // This inference seems to be missing in spec1824 }1825 #endif1826 1683 } 1827 1684 } … … 1831 1688 { 1832 1689 READ_UVLC( uiCode, "num_bsp_sched_combinations_minus1" ); vpsVuiBspHrdP->setNumBspSchedCombinationsMinus1( h, uiCode ); 1833 #if H_MV_HLS_8_HRD_Q0182_051834 1690 for( Int i = 0; i <= vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ); i++ ) 1835 #else1836 for( Int i = 0; i < vpsVuiBspHrdP->getNumBspSchedCombinationsMinus1( h ); i++ )1837 #endif1838 1691 { 1839 1692 for( Int j = 0; j < vpsVuiBspHrdP->getNumBitstreamPartitions( h ); j++ ) 1840 1693 { 1841 #if H_MV_HLS_8_HRD_Q0101_041842 1694 READ_CODE( vpsVuiBspHrdP->getBspCombHrdIdxLen(), uiCode, "bsp_comb_hrd_idx" ); vpsVuiBspHrdP->setBspCombHrdIdx( h, i, j, uiCode ); 1843 #else1844 READ_UVLC( uiCode, "bsp_comb_hrd_idx" ); vpsVuiBspHrdP->setBspCombHrdIdx( h, i, j, uiCode );1845 #endif1846 1695 READ_UVLC( uiCode, "bsp_comb_sched_idx" ); vpsVuiBspHrdP->setBspCombSchedIdx( h, i, j, uiCode ); 1847 #if H_MV_HLS_8_HRD_Q0101_041848 1696 vpsVuiBspHrdP->checkBspCombHrdAndShedIdx( pcVPS, h, i, j ); 1849 #endif1850 1697 } 1851 1698 } … … 1872 1719 for( Int i = 1; i < vps->getNumOutputLayerSets(); i++ ) 1873 1720 { 1874 #if H_MV_HLS_8_MIS_Q0102_301875 1721 Int currLsIdx = vps->olsIdxToLsIdx( i ); 1876 #endif1877 1722 READ_FLAG( uiCode, "sub_layer_flag_info_present_flag" ); dpbSize->setSubLayerFlagInfoPresentFlag( i, uiCode == 1 ); 1878 #if H_MV_HLS_8_MIS_Q0102_301879 1723 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( currLsIdx ); j++ ) 1880 #else1881 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( i ); j++ )1882 #endif1883 1724 { 1884 1725 if( j > 0 && dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) … … 1888 1729 if( dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) 1889 1730 { 1890 #if H_MV_HLS_8_MIS_Q0102_301891 1731 for( Int k = 0; k < vps->getNumLayersInIdList( currLsIdx ); k++ ) 1892 #else1893 for( Int k = 0; k < vps->getNumSubDpbs( vps->olsIdxToLsIdx( i )); k++ )1894 #endif1895 1732 { 1896 1733 READ_UVLC( uiCode, "max_vps_dec_pic_buffering_minus1" ); dpbSize->setMaxVpsDecPicBufferingMinus1( i, k, j, uiCode ); … … 1903 1740 if ( j > 0 ) 1904 1741 { 1905 #if H_MV_HLS_8_DBP_NODOC_421906 1742 for( Int k = 0; k < vps->getNumLayersInIdList( vps->olsIdxToLsIdx( i ) ); k++ ) 1907 #else1908 for( Int k = 0; k < vps->getNumSubDpbs( vps->olsIdxToLsIdx( i ) ); k++ )1909 #endif1910 1743 { 1911 1744 dpbSize->setMaxVpsDecPicBufferingMinus1( i, k, j, dpbSize->getMaxVpsDecPicBufferingMinus1( i,k, j - 1 ) ); … … 1918 1751 } 1919 1752 } 1920 #endif1921 1753 1922 1754 #if H_3D … … 1939 1771 #if H_3D_IV_MERGE 1940 1772 READ_FLAG( uiCode, "iv_mv_pred_flag[i]"); pcVPS->setIvMvPredFlag ( i, uiCode == 1 ? true : false ); 1941 #if QC_IV_PRED_CONSTRAINT_H01371942 1773 if( !pcVPS->getNumDirectRefLayers(i) ) 1943 1774 { 1944 1775 assert( !uiCode ); 1945 1776 } 1946 #endif1947 1777 #if H_3D_SPIVMP 1948 1778 READ_UVLC (uiCode, "log2_sub_PU_size_minus3[i]"); pcVPS->setSubPULog2Size(i, uiCode+3); … … 1951 1781 #if H_3D_ARP 1952 1782 READ_FLAG( uiCode, "iv_res_pred_flag[i]" ); pcVPS->setUseAdvRP ( i, uiCode ); pcVPS->setARPStepNum( i, uiCode ? H_3D_ARP_WFNR : 1 ); 1953 #if QC_IV_PRED_CONSTRAINT_H01371954 1783 if( !pcVPS->getNumDirectRefLayers(i) ) 1955 1784 { 1956 1785 assert( !uiCode ); 1957 1786 } 1958 #endif1959 1787 #endif 1960 1788 #if H_3D_NBDV_REF … … 1963 1791 #if H_3D_VSP 1964 1792 READ_FLAG( uiCode, "view_synthesis_pred_flag[i]"); pcVPS->setViewSynthesisPredFlag( i, uiCode == 1 ? true : false ); 1965 #if QC_IV_PRED_CONSTRAINT_H01371966 1793 if( !pcVPS->getNumDirectRefLayers(i) ) 1967 1794 { 1968 1795 assert( !uiCode ); 1969 1796 } 1970 #endif1971 1797 #endif 1972 1798 #if H_3D_DBBP … … 1980 1806 { 1981 1807 READ_FLAG( uiCode, "iv_mv_pred_flag[i]"); pcVPS->setIvMvPredFlag ( i, uiCode == 1 ? true : false ); 1982 #if QC_IV_PRED_CONSTRAINT_H01371983 1808 if( !pcVPS->getNumDirectRefLayers(i) ) 1984 1809 { 1985 1810 assert( !uiCode ); 1986 1811 } 1987 #endif1988 1812 } 1989 1813 #endif … … 2037 1861 } 2038 1862 #endif 2039 2040 #if H_MV _HLS_8_HRD_Q0102_081863 #endif 1864 #if H_MV 2041 1865 Void TDecCavlc::parseSliceHeader (TComSlice*& rpcSlice, ParameterSetManagerDecoder *parameterSetManager, Int targetOlsIdx) 2042 1866 #else … … 2081 1905 sps->inferRepFormat ( vps , rpcSlice->getLayerId() ); 2082 1906 sps->inferScalingList( parameterSetManager->getActiveSPS( sps->getSpsScalingListRefLayerId() ) ); 2083 #if H_MV_HLS_8_HRD_Q0102_082084 1907 sps->inferSpsMaxDecPicBufferingMinus1( vps, targetOlsIdx, rpcSlice->getLayerId(), false ); 2085 #endif2086 #if H_MV_HLS_8_RPS_Q0100_362087 1908 vps->inferDbpSizeLayerSetZero( sps, false ); 2088 #endif2089 1909 2090 1910 if ( sps->getVuiParametersPresentFlag() ) … … 2141 1961 } 2142 1962 2143 #if H 0044_POC_LSB_NOT_PRESENT1963 #if H_MV 2144 1964 UInt slicePicOrderCntLsb = 0; 2145 1965 #endif … … 2195 2015 2196 2016 #if H_MV 2197 #if !H0044_POC_LSB_NOT_PRESENT2198 UInt slicePicOrderCntLsb = 0;2199 #endif2200 2017 Int iPOClsb = slicePicOrderCntLsb; // Needed later 2201 2018 if ( (rpcSlice->getLayerId() > 0 && !vps->getPocLsbNotPresentFlag( rpcSlice->getLayerIdInVps())) || !rpcSlice->getIdrPicFlag() ) … … 2203 2020 READ_CODE(sps->getBitsForPOC(), slicePicOrderCntLsb, "slice_pic_order_cnt_lsb"); 2204 2021 } 2205 #if H_MV_HLS_8_POC_Q0142_322206 2022 rpcSlice->setSlicePicOrderCntLsb( slicePicOrderCntLsb ); 2207 #endif2208 2023 2209 2024 Bool picOrderCntMSBZeroFlag = false; … … 2301 2116 { 2302 2117 parseShortTermRefPicSet(sps,rps, sps->getRPSList()->getNumberOfReferencePictureSets()); 2303 #if H_MV _HLS_8_RPS_Q0100_362118 #if H_MV 2304 2119 if ( !rps->getInterRPSPrediction( ) ) 2305 2120 { // check sum of num_positive_pics and num_negative_pics … … 2414 2229 rps->setNumberOfPictures(offset); 2415 2230 } 2416 #if H_MV _HLS_8_RPS_Q0100_362231 #if H_MV 2417 2232 if ( !rps->getInterRPSPrediction( ) ) 2418 2233 { // check sum of NumPositivePics, NumNegativePics, num_long_term_sps and num_long_term_pics … … 2804 2619 rpcSlice->setPocResetIdc( 0 ); 2805 2620 } 2806 #if H_MV_HLS_8_POC_Q0142_322807 2621 rpcSlice->checkPocResetIdc(); 2808 #endif 2809 2810 #if H0044_POC_LSB_NOT_PRESENT 2622 2811 2623 if ( rpcSlice->getVPS()->getPocLsbNotPresentFlag(rpcSlice->getLayerId()) && slicePicOrderCntLsb > 0 ) 2812 2624 { 2813 2625 assert( rpcSlice->getPocResetIdc() != 2 ); 2814 2626 } 2815 #endif 2627 2816 2628 if( rpcSlice->getPocResetIdc() != 0 ) 2817 2629 { … … 2828 2640 READ_FLAG( uiCode, "full_poc_reset_flag" ); rpcSlice->setFullPocResetFlag( uiCode == 1 ); 2829 2641 READ_CODE( rpcSlice->getPocLsbValLen() , uiCode, "poc_lsb_val" ); rpcSlice->setPocLsbVal( uiCode ); 2830 #if !H_MV_HLS_8_POC_Q0142_322831 #if H0044_POC_LSB_NOT_PRESENT2832 if ( rpcSlice->getVPS()->getPocLsbNotPresentFlag(rpcSlice->getLayerId()) && rpcSlice->getFullPocResetFlag() )2833 {2834 assert( rpcSlice->getPocLsbVal() == 0 );2835 }2836 #endif2837 #endif2838 2642 } 2839 #if H_MV_HLS_8_POC_Q0142_322840 2643 rpcSlice->checkPocLsbVal(); 2841 #endif2842 2644 2843 2645 // Derive the value of PocMs8bValRequiredFlag … … 2852 2654 else 2853 2655 { 2854 #if H_MV_HLS_8_POC_Q0146_152855 2656 rpcSlice->setPocMsbValPresentFlag( rpcSlice->inferPocMsbValPresentFlag( ) ); 2856 #else2857 if( rpcSlice->getPocMsbValRequiredFlag() )2858 {2859 rpcSlice->setPocMsbValPresentFlag( true );2860 }2861 else2862 {2863 rpcSlice->setPocMsbValPresentFlag( false );2864 }2865 #endif2866 2657 } 2867 2658
Note: See TracChangeset for help on using the changeset viewer.