Changeset 884 in 3DVCSoftware for trunk/source/Lib/TLibDecoder
- Timestamp:
- 29 Mar 2014, 18:55:16 (11 years ago)
- Location:
- trunk/source/Lib/TLibDecoder
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibDecoder/SEIread.cpp
r872 r884 99 99 fprintf( g_hTrace, "=========== Scalable Nesting SEI message ===========\n"); 100 100 break; 101 #if H_MV _HLS_7_SEI_P0204_26101 #if H_MV 102 102 case SEI::SUB_BITSTREAM_PROPERTY: 103 103 fprintf( g_hTrace, "=========== Sub-bitstream property SEI message ===========\n"); … … 245 245 xParseSEIScalableNesting((SEIScalableNesting&) *sei, nalUnitType, payloadSize, sps); 246 246 break; 247 #if H_MV _HLS_7_SEI_P0204_26247 #if H_MV 248 248 case SEI::SUB_BITSTREAM_PROPERTY: 249 249 sei = new SEISubBitstreamProperty; … … 777 777 778 778 } 779 #if H_MV _HLS_7_SEI_P0204_26779 #if H_MV 780 780 Void SEIReader::xParseSEISubBitstreamProperty(SEISubBitstreamProperty &sei) 781 781 { -
trunk/source/Lib/TLibDecoder/SEIread.h
r872 r884 73 73 Void xParseSEISOPDescription (SEISOPDescription &sei, UInt payloadSize); 74 74 Void xParseSEIScalableNesting (SEIScalableNesting& sei, const NalUnitType nalUnitType, UInt payloadSize, TComSPS *sps); 75 #if H_MV _HLS_7_SEI_P0204_2675 #if H_MV 76 76 Void xParseSEISubBitstreamProperty (SEISubBitstreamProperty &sei); 77 77 Void xResizeSubBitstreamPropertySeiArrays(SEISubBitstreamProperty &sei); -
trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp
r872 r884 366 366 367 367 READ_FLAG( uiCode, "pps_extension_flag"); 368 #if H_MV_HLS_7_GEN_P0166_PPS_EXTENSION369 368 if (uiCode) 370 369 { … … 383 382 if( pcPPS->getPpsExtensionTypeFlag( PPS_EX_T_MV ) ) 384 383 { 385 #if H_MV_HLS_7_POC_P0041386 384 READ_FLAG( uiCode, "poc_reset_info_present_flag" ); pcPPS->setPocResetInfoPresentFlag( uiCode == 1 ); 387 #endif388 385 } 389 386 … … 406 403 #endif 407 404 } 408 #else409 if (uiCode)410 {411 #if H_3D412 parsePPSExtension( pcPPS, pcVPS );413 READ_FLAG( uiCode, "pps_extension2_flag");414 if ( uiCode )415 {416 #endif417 while ( xMoreRbspData() )418 {419 READ_FLAG( uiCode, "pps_extension_data_flag");420 }421 #if H_3D422 }423 #endif424 }425 #endif426 405 } 427 406 … … 849 828 assert(uiCode <= 12); 850 829 851 #if H_MV _HLS_7_SPS_P0155_16_32830 #if H_MV 852 831 if ( pcSPS->getLayerId() == 0 ) 853 832 { … … 888 867 } 889 868 } 890 #if H_MV _HLS_7_SPS_P0155_16_32869 #if H_MV 891 870 } 892 871 #endif … … 1053 1032 READ_SVLC( iCode, "scaled_ref_layer_right_offset" ); pcSPS->setScaledRefLayerRightOffset( j, iCode ); 1054 1033 READ_SVLC( iCode, "scaled_ref_layer_bottom_offset" ); pcSPS->setScaledRefLayerBottomOffset( j, iCode ); 1055 #if H_MV_HLS_7_RESERVED_FLAGS1056 1034 READ_FLAG( uiCode, "sps_multilayer_ext_reserved_zero_flag[ i ]" ); 1057 #endif1058 1035 } 1059 1036 } … … 1092 1069 assert (pcVPS->getMaxTLayers()>1||pcVPS->getTemporalNestingFlag()); 1093 1070 1094 #if H_MV_HLS_7_VPS_P0125_241095 1071 READ_CODE( 16, uiCode, "vps_reserved_ffff_16bits" ); assert(uiCode == 0xffff); 1096 #else1097 #if H_MV && !H_MV_HLS7_GEN1098 READ_CODE( 16, uiCode, "vps_extension_offset" );1099 #else1100 READ_CODE( 16, uiCode, "vps_reserved_ffff_16bits" ); assert(uiCode == 0xffff);1101 #endif1102 #endif1103 1072 parsePTL ( pcVPS->getPTL(), true, pcVPS->getMaxTLayers()-1); 1104 1073 UInt subLayerOrderingInfoPresentFlag; … … 1212 1181 READ_FLAG( uiCode, "avc_base_layer_flag" ); pcVPS->setAvcBaseLayerFlag( uiCode == 1 ? true : false ); 1213 1182 1214 #if !H_MV_HLS_7_VPS_P0307_231215 READ_FLAG( uiCode, "vps_vui_present_flag" ); pcVPS->setVpsVuiPresentFlag( uiCode == 1 );1216 if ( pcVPS->getVpsVuiPresentFlag() )1217 {1218 READ_CODE( 16, uiCode, "vps_vui_offset" ); pcVPS->setVpsVuiOffset( uiCode );1219 }1220 #endif1221 1222 1183 READ_FLAG( uiCode, "splitting_flag" ); pcVPS->setSplittingFlag( uiCode == 1 ? true : false ); 1223 1184 … … 1325 1286 1326 1287 READ_FLAG( uiCode, "all_ref_layers_active_flag" ); pcVPS->setAllRefLayersActiveFlag( uiCode == 1 ); 1327 #if !H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_27 1328 READ_CODE( 10, uiCode, "vps_number_layer_sets_minus1" ); pcVPS->setVpsNumberLayerSetsMinus1 ( uiCode ); 1329 #endif 1330 1331 #if !H_MV_HLS_7_VPS_P0306_22 1332 READ_CODE( 6, uiCode, "vps_num_profile_tier_level_minus1" ); pcVPS->setVpsNumProfileTierLevelMinus1( uiCode ); 1333 #else 1288 1334 1289 READ_UVLC( uiCode, "vps_num_profile_tier_level_minus1" ); pcVPS->setVpsNumProfileTierLevelMinus1( uiCode ); 1335 #endif 1290 1336 1291 for( Int i = 1; i <= pcVPS->getVpsNumProfileTierLevelMinus1(); i++ ) 1337 1292 { 1338 1293 READ_FLAG( uiCode, "vps_profile_present_flag[i]" ); pcVPS->setVpsProfilePresentFlag( i, uiCode == 1 ); 1339 #if !H_MV_HLS_7_VPS_P0048_141340 if( !pcVPS->getVpsProfilePresentFlag( i ) )1341 {1342 READ_CODE( 6, uiCode, "profile_ref_minus1[i]" ); pcVPS->setProfileRefMinus1( i, uiCode );1343 pcVPS->checkProfileRefMinus1( i );1344 }1345 #endif1346 1294 parsePTL ( pcVPS->getPTL( i ), pcVPS->getVpsProfilePresentFlag( i ), pcVPS->getMaxTLayers()-1); 1347 1295 if( !pcVPS->getVpsProfilePresentFlag( i ) ) 1348 1296 { 1349 1297 TComPTL temp = *pcVPS->getPTL( i ); 1350 #if H_MV_HLS_7_VPS_P0048_141351 1298 *pcVPS->getPTL( i ) = *pcVPS->getPTL( i - 1 ); 1352 #else1353 *pcVPS->getPTL( i ) = *pcVPS->getPTL( pcVPS->getProfileRefMinus1( i ) + 1 );1354 #endif1355 1299 pcVPS->getPTL( i )->copyLevelFrom( &temp ); 1356 1300 } 1357 1301 } 1358 1302 1359 #if H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271360 1303 READ_UVLC( uiCode, "num_add_output_layer_sets" ); pcVPS->setNumAddOutputLayerSets( uiCode ); 1361 1304 pcVPS->initTargetLayerIdLists( ); … … 1365 1308 } 1366 1309 1367 #else1368 Int numOutputLayerSets = pcVPS->getVpsNumberLayerSetsMinus1( ) + 1;1369 1370 READ_FLAG( uiCode, "more_output_layer_sets_than_default_flag" ); pcVPS->setMoreOutputLayerSetsThanDefaultFlag( uiCode == 1 );1371 1372 if ( pcVPS->getMoreOutputLayerSetsThanDefaultFlag( ) )1373 {1374 READ_CODE( 10, uiCode, "num_add_output_layer_sets_minus1" ); pcVPS->setNumAddOutputLayerSetsMinus1( uiCode );1375 numOutputLayerSets += ( pcVPS->getNumAddOutputLayerSetsMinus1( ) + 1);1376 }1377 1378 if( numOutputLayerSets > 1)1379 {1380 READ_CODE( 2, uiCode, "default_one_target_output_layer_idc" ); pcVPS->setDefaultOneTargetOutputLayerIdc( uiCode );1381 pcVPS->checkDefaultOneTargetOutputLayerIdc();1382 }1383 #endif1384 1385 1310 pcVPS->setOutputLayerFlag(0, 0, pcVPS->inferOutputLayerFlag( 0, 0 )); 1386 1311 pcVPS->setOutputLayerSetIdxMinus1(0, -1); 1387 1312 1388 #if H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271389 1313 pcVPS->deriveTargetLayerIdList( 0 ); 1390 1314 for( Int i = 1; i < pcVPS->getNumOutputLayerSets( ); i++ ) 1391 1315 { 1392 1316 if( i > pcVPS->getVpsNumLayerSetsMinus1( ) ) 1393 #else1394 for( Int i = 1; i < numOutputLayerSets; i++ )1395 {1396 if( i > pcVPS->getVpsNumberLayerSetsMinus1( ) )1397 #endif1398 1317 { 1399 1318 READ_UVLC( uiCode, "output_layer_set_idx_minus1[i]" ); pcVPS->setOutputLayerSetIdxMinus1( i, uiCode ); 1400 #if H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271401 1319 } 1402 1320 … … 1416 1334 } 1417 1335 pcVPS->deriveTargetLayerIdList( i ); 1418 #else 1419 for( Int j = 0; j < pcVPS->getNumLayersInIdList( j ) - 1; j++ ) 1420 { 1421 READ_FLAG( uiCode, "output_layer_flag" ); pcVPS->setOutputLayerFlag( i, j, uiCode == 1 ); 1422 } 1423 } 1424 else 1425 { // These inference rules would also be helpful in spec text 1426 pcVPS->setOutputLayerSetIdxMinus1(i, i - 1 ); 1427 for( Int j = 0; j < pcVPS->getNumLayersInIdList( j ) - 1; j++ ) 1428 { 1429 pcVPS->setOutputLayerFlag(i,j, pcVPS->inferOutputLayerFlag( i, j )); 1430 } 1431 } 1432 #endif 1336 1433 1337 if ( pcVPS->getProfileLevelTierIdxLen() > 0 ) 1434 1338 { … … 1436 1340 } 1437 1341 1438 #if H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271439 1342 if( pcVPS->getNumOutputLayersInOutputLayerSet( i ) == 1 && pcVPS->getNumDirectRefLayers( pcVPS->getOlsHighestOutputLayerId( i ) ) > 0 ) 1440 1343 { … … 1442 1345 } 1443 1346 } 1444 #else1445 }1446 if( pcVPS->getMaxLayersMinus1() > 0 )1447 {1448 READ_FLAG( uiCode, "alt_output_layer_flag" ); pcVPS->setAltOutputLayerFlag( uiCode == 1 );1449 }1450 #endif1451 1452 #if !H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271453 pcVPS->deriveTargetLayerIdLists();1454 #endif1455 1347 1456 1348 READ_FLAG( uiCode, "rep_format_idx_present_flag" ); pcVPS->setRepFormatIdxPresentFlag( uiCode == 1 ); 1457 1349 if ( pcVPS->getRepFormatIdxPresentFlag() ) 1458 1350 { 1459 #if H_MV_HLS_7_VPS_P0306_221460 1351 READ_UVLC( uiCode, "vps_num_rep_formats_minus1" ); pcVPS->setVpsNumRepFormatsMinus1( uiCode ); 1461 #else1462 READ_CODE( 4, uiCode, "vps_num_rep_formats_minus1" ); pcVPS->setVpsNumRepFormatsMinus1( uiCode );1463 #endif1464 1352 } 1465 1353 … … 1479 1367 if( pcVPS->getVpsNumRepFormatsMinus1() > 0 ) 1480 1368 { 1481 #if H_MV_HLS_7_VPS_P0306_221482 1369 READ_CODE( pcVPS->getVpsRepFormatIdxLen(), uiCode, "vps_rep_format_idx[i]" ); pcVPS->setVpsRepFormatIdx( i, uiCode ); 1483 #else1484 READ_CODE( 8, uiCode, "vps_rep_format_idx" ); pcVPS->setVpsRepFormatIdx( i, uiCode );1485 #endif1486 1370 } 1487 1371 } … … 1500 1384 } 1501 1385 1502 #if H_MV_HLS_7_RESERVED_FLAGS1503 1386 READ_FLAG( uiCode, "vps_reserved_zero_flag" ); 1504 #endif1505 1387 parseDpbSize( pcVPS ); 1506 1388 … … 1531 1413 } 1532 1414 1533 #if H_MV_HLS_7_VPS_P0307_231534 1415 READ_UVLC( uiCode, "vps_non_vui_extension_length" ); pcVPS->setVpsNonVuiExtensionLength( uiCode ); 1535 1416 for ( Int i = 1; i <= pcVPS->getVpsNonVuiExtensionLength(); i++ ) … … 1538 1419 } 1539 1420 READ_FLAG( uiCode, "vps_vui_present_flag" ); pcVPS->setVpsVuiPresentFlag( uiCode == 1 ); 1540 #endif1541 #if !H_MV_HLS_7_RESERVED_FLAGS1542 READ_FLAG( uiCode, "vps_shvc_reserved_zero_flag" );1543 #endif1544 1421 if( pcVPS->getVpsVuiPresentFlag() ) 1545 1422 { … … 1547 1424 parseVPSVUI( pcVPS ); 1548 1425 } 1549 #if H_MV_HLS_7_FIX_INFER_CROSS_LAYER_IRAP_ALIGNED_FLAG1550 1426 { 1551 1427 TComVPSVUI* pcVPSVUI = pcVPS->getVPSVUI( ); … … 1553 1429 pcVPSVUI->inferVpsVui( false ); 1554 1430 } 1555 #endif1556 1431 1557 1432 pcVPS->checkVPSExtensionSyntax(); … … 1601 1476 READ_FLAG( uiCode, "cross_layer_irap_aligned_flag" ); pcVPSVUI->setCrossLayerIrapAlignedFlag( uiCode == 1 ); 1602 1477 } 1603 #if H_MV_HLS_7_MISC_P0068_211604 1478 if( pcVPSVUI->getCrossLayerIrapAlignedFlag( ) ) 1605 1479 { 1606 1480 READ_FLAG( uiCode, "all_layers_idr_aligned_flag" ); pcVPSVUI->setAllLayersIdrAlignedFlag( uiCode == 1 ); 1607 1481 } 1608 #endif1609 1482 READ_FLAG( uiCode, "bit_rate_present_vps_flag" ); pcVPSVUI->setBitRatePresentVpsFlag( uiCode == 1 ); 1610 1483 READ_FLAG( uiCode, "pic_rate_present_vps_flag" ); pcVPSVUI->setPicRatePresentVpsFlag( uiCode == 1 ); 1611 1484 if( pcVPSVUI->getBitRatePresentVpsFlag( ) || pcVPSVUI->getPicRatePresentVpsFlag( ) ) 1612 1485 { 1613 #if H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271614 1486 for( Int i = 0; i <= pcVPS->getVpsNumLayerSetsMinus1(); i++ ) 1615 #else1616 for( Int i = 0; i <= pcVPS->getVpsNumberLayerSetsMinus1(); i++ )1617 #endif1618 1487 { 1619 1488 for( Int j = 0; j <= pcVPS->getMaxTLayers(); j++ ) … … 1641 1510 } 1642 1511 1643 #if H_MV_HLS_7_VPS_P0076_151644 1512 READ_FLAG( uiCode, "video_signal_info_idx_present_flag" ); pcVPSVUI->setVideoSignalInfoIdxPresentFlag( uiCode == 1 ); 1645 1513 if( pcVPSVUI->getVideoSignalInfoIdxPresentFlag() ) … … 1675 1543 } 1676 1544 } 1677 #endif1678 1545 1679 1546 READ_FLAG( uiCode, "tiles_not_in_use_flag" ); pcVPSVUI->setTilesNotInUseFlag( uiCode == 1 ); … … 1712 1579 } 1713 1580 1714 #if H_MV_HLS_7_RESERVED_FLAGS1715 1581 READ_CODE( 3, uiCode, "vps_vui_reserved_zero_3bits" ); 1716 #endif1717 1718 1582 READ_FLAG( uiCode, "ilp_restricted_ref_layers_flag" ); pcVPSVUI->setIlpRestrictedRefLayersFlag( uiCode == 1 ); 1719 1583 … … 1737 1601 } 1738 1602 1739 #if !H_MV_HLS_7_VPS_P0076_151740 READ_FLAG( uiCode, "video_signal_info_idx_present_flag" ); pcVPSVUI->setVideoSignalInfoIdxPresentFlag( uiCode == 1 );1741 if( pcVPSVUI->getVideoSignalInfoIdxPresentFlag() )1742 {1743 READ_CODE( 4, uiCode, "vps_num_video_signal_info_minus1" ); pcVPSVUI->setVpsNumVideoSignalInfoMinus1( uiCode );1744 }1745 else1746 {1747 pcVPSVUI->setVpsNumVideoSignalInfoMinus1( pcVPS->getMaxLayersMinus1() );1748 }1749 1750 for( Int i = 0; i <= pcVPSVUI->getVpsNumVideoSignalInfoMinus1(); i++ )1751 {1752 assert( pcVPSVUI->getVideoSignalInfo( i ) == NULL );1753 TComVideoSignalInfo* curVideoSignalInfo = new TComVideoSignalInfo();1754 parseVideoSignalInfo( curVideoSignalInfo );1755 pcVPSVUI->setVideoSignalInfo(i, curVideoSignalInfo );1756 }1757 1758 if( pcVPSVUI->getVideoSignalInfoIdxPresentFlag() && pcVPSVUI->getVpsNumVideoSignalInfoMinus1() > 0 )1759 {1760 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1761 {1762 READ_CODE( 4, uiCode, "vps_video_signal_info_idx" ); pcVPSVUI->setVpsVideoSignalInfoIdx( i, uiCode );1763 assert( pcVPSVUI->getVpsVideoSignalInfoIdx( i ) >= 0 && pcVPSVUI->getVpsVideoSignalInfoIdx( i ) <= pcVPSVUI->getVpsNumVideoSignalInfoMinus1() );1764 }1765 }1766 else1767 {1768 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ )1769 {1770 pcVPSVUI->setVpsVideoSignalInfoIdx( i, pcVPSVUI->getVideoSignalInfoIdxPresentFlag() ? 0 : i );1771 }1772 }1773 #endif1774 1603 READ_FLAG( uiCode, "vps_vui_bsp_hrd_present_flag" ); pcVPSVUI->setVpsVuiBspHrdPresentFlag( uiCode == 1 ); 1775 1604 if ( pcVPSVUI->getVpsVuiBspHrdPresentFlag( ) ) … … 1777 1606 parseVpsVuiBspHrdParameters( pcVPS ); 1778 1607 } 1779 #if H_MV_HLS_7_MISC_P0182_131780 1608 for( Int i = 1; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1781 1609 { … … 1785 1613 } 1786 1614 } 1787 #endif1788 1615 } 1789 1616 … … 1864 1691 { 1865 1692 READ_FLAG( uiCode, "sub_layer_flag_info_present_flag" ); dpbSize->setSubLayerFlagInfoPresentFlag( i, uiCode == 1 ); 1866 #if H_MV_HLS_7_HRD_P0156_71867 1693 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( i ); j++ ) 1868 #else1869 for( Int j = 0; j <= vps->getMaxTLayers() - 1 ; j++ )1870 #endif1871 1694 { 1872 1695 if( j > 0 && dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) … … 1876 1699 if( dpbSize->getSubLayerDpbInfoPresentFlag( i, j ) ) 1877 1700 { 1878 #if H_MV_HLS_7_OUTPUT_LAYERS_5_10_22_271879 1701 for( Int k = 0; k < vps->getNumSubDpbs( vps->getLayerSetIdxForOutputLayerSet( i )); k++ ) 1880 #else1881 for( Int k = 0; k < vps->getNumSubDpbs( vps->getOutputLayerSetIdxMinus1( i ) + 1 ); k++ )1882 #endif1883 1702 { 1884 1703 READ_UVLC( uiCode, "max_vps_dec_pic_buffering_minus1" ); dpbSize->setMaxVpsDecPicBufferingMinus1( i, k, j, uiCode ); … … 1933 1752 READ_FLAG( uiCode, "iv_mv_pred_flag[i]"); pcVPS->setIvMvPredFlag ( i, uiCode == 1 ? true : false ); 1934 1753 #if H_3D_SPIVMP 1935 #if SEC_SPIVMP_MCP_SIZE_G00771936 1754 READ_UVLC (uiCode, "log2_sub_PU_size_minus3[i]"); pcVPS->setSubPULog2Size(i, uiCode+3); 1937 #else1938 READ_UVLC (uiCode, "log2_sub_PU_size_minus2"); pcVPS->setSubPULog2Size(i, uiCode+2);1939 #endif1940 1755 #endif 1941 1756 #endif … … 1965 1780 if (i!=1) 1966 1781 { 1967 #if SEC_SPIVMP_MCP_SIZE_G00771968 1782 READ_UVLC (uiCode, "log2_sub_PU_size_minus3[i]"); pcVPS->setSubPULog2Size(i, uiCode+3); 1969 #else1970 READ_UVLC (uiCode, "log2_sub_PU_size_minus2[i]"); pcVPS->setSubPULog2Size(i, uiCode+2);1971 #endif1972 1783 } 1973 1784 #endif … … 1991 1802 for (UInt viewIndex=0; viewIndex<pcVPS->getNumViews(); viewIndex++) 1992 1803 { 1993 #if FIX_CAM_PARS_COLLECTOR1994 1804 pcVPS->setCamParPresent ( viewIndex, false ); 1995 1805 pcVPS->setHasCamParInSliceHeader( viewIndex, false ); 1996 #endif1997 1806 READ_FLAG( uiCode, "cp_present_flag[i]" ); bCamParPresentFlag = ( uiCode == 1); 1998 1807 if ( bCamParPresentFlag ) … … 2013 1822 } 2014 1823 } 2015 #if QC_SPIVMP_MPI_G01192016 1824 READ_UVLC (uiCode, "log2_sub_PU_MPI_size_minus3"); pcVPS->setSubPUMPILog2Size( uiCode + 3 ); 2017 #endif2018 1825 READ_FLAG( uiCode, "iv_mv_scaling_flag"); pcVPS->setIvMvScalingFlag( uiCode == 1 ? true : false ); 2019 1826 } … … 2728 2535 if(pps->getSliceHeaderExtensionPresentFlag()) 2729 2536 { 2730 #if !H_MV_HLS_7_POC_P00412731 READ_UVLC(uiCode,"slice_header_extension_length");2732 for(Int i=0; i<uiCode; i++)2733 {2734 UInt ignore;2735 READ_CODE(8,ignore,"slice_header_extension_data_byte");2736 }2737 }2738 #else2739 2537 #if H_MV 2740 2538 READ_UVLC( uiCode, "slice_segment_header_extension_length" ); rpcSlice->setSliceSegmentHeaderExtensionLength( uiCode ); … … 2806 2604 } 2807 2605 } 2808 #endif2809 2606 #endif 2810 2607 } … … 3103 2900 #endif 3104 2901 #if H_3D_INTER_SDC 3105 #if QC_SDC_UNIFY_G01303106 2902 Void TDecCavlc::parseDeltaDC( TComDataCU* /*pcCU*/, UInt /*uiAbsPartIdx*/, UInt /*uiDepth*/ ) 3107 2903 { … … 3113 2909 assert(0); 3114 2910 } 3115 #else 3116 Void TDecCavlc::parseInterSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 3117 { 3118 assert(0); 3119 } 3120 3121 Void TDecCavlc::parseInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPart ) 3122 { 3123 assert(0); 3124 } 3125 #endif 2911 3126 2912 #endif 3127 2913 #if H_3D_DBBP -
trunk/source/Lib/TLibDecoder/TDecCAVLC.h
r872 r884 124 124 #endif 125 125 #if H_3D_INTER_SDC 126 #if QC_SDC_UNIFY_G0130127 126 Void parseDeltaDC ( TComDataCU* pcCU, UInt absPartIdx, UInt depth ); 128 127 Void parseSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 129 #else130 Void parseInterSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth );131 Void parseInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPart );132 #endif133 128 #endif 134 129 #if H_3D_DBBP -
trunk/source/Lib/TLibDecoder/TDecCu.cpp
r872 r884 293 293 294 294 295 #if MTK_DDD_G0063295 #if H_3D_DDD 296 296 pcCU->setUseDDD( false, uiAbsPartIdx, uiDepth ); 297 297 #endif … … 339 339 if( pcCU->getSlice()->getIsDepth()) 340 340 { 341 #if SEC_DEPTH_DV_DERIVAITON_G0074342 341 DvInfo.bDV = m_ppcCU[uiDepth]->getDispforDepth(0, 0, &DvInfo); 343 #else344 DvInfo.bDV = m_ppcCU[uiDepth]->getDispNeighBlocks(0, 0, &DvInfo);345 #endif346 342 } 347 343 else … … 414 410 m_pcEntropyDecoder->decodeMergeIndex( pcCU, 0, uiAbsPartIdx, uiDepth ); 415 411 UInt uiMergeIndex = pcCU->getMergeIndex(uiAbsPartIdx); 416 417 #if !SEC_IC_ARP_SIG_G0072 412 #if H_3D_ARP 413 m_pcEntropyDecoder->decodeARPW( pcCU , uiAbsPartIdx , uiDepth ); 414 #endif 418 415 #if H_3D_IC 419 416 m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth ); 420 #endif421 #endif422 #if H_3D_ARP423 m_pcEntropyDecoder->decodeARPW( pcCU , uiAbsPartIdx , uiDepth );424 #endif425 #if SEC_IC_ARP_SIG_G0072426 #if H_3D_IC427 m_pcEntropyDecoder->decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );428 #endif429 417 #endif 430 418 … … 466 454 pcCU->setInterDirSubParts( uhInterDirNeighbours[uiMergeIndex], uiAbsPartIdx, 0, uiDepth ); 467 455 468 #if MTK_DDD_G0063456 #if H_3D_DDD 469 457 if( uiMergeIndex == m_ppcCU[uiDepth]->getUseDDDCandIdx() ) 470 458 { … … 484 472 pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvd( cTmpMv, SIZE_2Nx2N, uiAbsPartIdx, uiDepth ); 485 473 pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvField( cMvFieldNeighbours[ 2*uiMergeIndex + uiRefListIdx ], SIZE_2Nx2N, uiAbsPartIdx, uiDepth ); 486 #if NTT_STORE_SPDV_VSP_G0148474 #if H_3D_VSP 487 475 if( pcCU->getVSPFlag( uiAbsPartIdx ) != 0 ) 488 476 { … … 551 539 m_pcEntropyDecoder->decodePartSize( pcCU, uiAbsPartIdx, uiDepth ); 552 540 553 #if QC_SDC_UNIFY_G0130541 #if H_3D_DIM_SDC 554 542 m_pcEntropyDecoder->decodeSDCFlag( pcCU, uiAbsPartIdx, uiDepth ); 555 543 #endif … … 573 561 // prediction mode ( Intra : direction mode, Inter : Mv, reference idx ) 574 562 m_pcEntropyDecoder->decodePredInfo( pcCU, uiAbsPartIdx, uiDepth, m_ppcCU[uiDepth]); 575 #if H_3D_INTER_SDC && !QC_SDC_UNIFY_G0130576 m_pcEntropyDecoder->decodeInterSDCFlag( pcCU, uiAbsPartIdx, uiDepth );577 #endif578 563 // Coefficient decoding 579 564 Bool bCodeDQP = getdQPFlag(); … … 663 648 #endif 664 649 #if H_3D_INTER_SDC 665 #if QC_SDC_UNIFY_G0130666 650 if( m_ppcCU[uiDepth]->getSDCFlag( 0 ) ) 667 #else668 if( m_ppcCU[uiDepth]->getInterSDCFlag( 0 ) )669 #endif670 651 { 671 652 xReconInterSDC( m_ppcCU[uiDepth], uiAbsPartIdx, uiDepth ); … … 730 711 UInt uiWidth = pcCU->getWidth ( 0 ); 731 712 UInt uiHeight = pcCU->getHeight( 0 ); 732 #if !SEC_INTER_SDC_G0101733 UChar* pMask = pcCU->getInterSDCMask();734 735 memset( pMask, 0, uiWidth*uiHeight );736 pcCU->xSetInterSDCCUMask( pcCU, pMask );737 #endif738 713 739 714 Pel *pResi; … … 746 721 for( uiPelX = 0; uiPelX < uiWidth; uiPelX++ ) 747 722 { 748 #if SEC_INTER_SDC_G0101749 723 pResi[ uiPelX ] = pcCU->getSDCSegmentDCOffset( 0, 0 ); 750 #else751 UChar uiSeg = pMask[ uiPelX + uiPelY*uiWidth ];752 #if QC_SDC_UNIFY_G0130753 pResi[ uiPelX ] = pcCU->getSDCSegmentDCOffset( uiSeg, 0 );754 #else755 pResi[ uiPelX ] = pcCU->getInterSDCSegmentDCOffset( uiSeg, 0 );756 #endif757 #endif758 724 } 759 725 pResi += uiResiStride; … … 929 895 #endif 930 896 931 #if H_3D && UPDATE_HM13897 #if H_3D 932 898 Bool useDltFlag = (isDimMode( uiLumaPredMode ) || uiLumaPredMode == HOR_IDX || uiLumaPredMode == VER_IDX || uiLumaPredMode == DC_IDX) && pcCU->getSlice()->getIsDepth() && pcCU->getSlice()->getPPS()->getDLT()->getUseDLTFlag(pcCU->getSlice()->getLayerIdInVps()); 933 899 … … 955 921 { 956 922 #if H_3D 957 #if UPDATE_HM13958 923 if ( useDltFlag ) 959 #else960 if( (isDimMode( uiLumaPredMode ) || uiLumaPredMode == HOR_IDX || uiLumaPredMode == VER_IDX || uiLumaPredMode == DC_IDX) && pcCU->getSlice()->getIsDepth() && pcCU->getSlice()->getPPS()->getDLT()->getUseDLTFlag(pcCU->getSlice()->getLayerIdInVps()) )961 #endif962 924 { 963 925 pReco [ uiX ] = pcCU->getSlice()->getPPS()->getDLT()->idx2DepthValue( pcCU->getSlice()->getLayerIdInVps(), Clip3( 0, pcCU->getSlice()->getPPS()->getDLT()->getNumDepthValues( pcCU->getSlice()->getLayerIdInVps() ) - 1, pcCU->getSlice()->getPPS()->getDLT()->depthValue2idx( pcCU->getSlice()->getLayerIdInVps(), pPred[ uiX ] ) + pResi[ uiX ] ) ); … … 1151 1113 UInt uiWidth = pcCU->getWidth ( 0 ); 1152 1114 UInt uiHeight = pcCU->getHeight ( 0 ); 1153 #if QC_PKU_SDC_SPLIT_G01231154 #if HS_TSINGHUA_SDC_SPLIT_G01111155 #if QC_GENERIC_SDC_G01221156 1115 TComWedgelet* dmm4SegmentationOrg = new TComWedgelet( uiWidth, uiHeight ); 1157 #endif1158 #else1159 #if QC_GENERIC_SDC_G01221160 TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight );1161 #endif1162 #endif1163 #endif1164 #if QC_PKU_SDC_SPLIT_G01231165 1116 UInt numParts = 1; 1166 UInt i = 0;1167 1117 UInt sdcDepth = 0; 1168 1118 TComYuv* pcRecoYuv = m_ppcYuvReco[uiDepth]; … … 1181 1131 UInt uiLumaPredMode = 0; 1182 1132 1183 #if HS_TSINGHUA_SDC_SPLIT_G01111184 1133 if ((uiWidth >> pcCU->getSlice()->getSPS()->getQuadtreeTULog2MaxSize()) > 1) 1185 1134 { … … 1188 1137 uiWidth = uiHeight = (1 << pcCU->getSlice()->getSPS()->getQuadtreeTULog2MaxSize()); 1189 1138 } 1190 #else 1191 if (uiWidth == 64) 1192 { 1193 numParts = 4; 1194 sdcDepth = 1; 1195 uiWidth = uiHeight = 32; 1196 } 1197 #endif 1198 1199 for ( i = 0; i < numParts; i++ ) 1139 1140 for ( Int i = 0; i < numParts; i++ ) 1200 1141 { 1201 1142 uiStride = pcRecoYuv->getStride (); … … 1203 1144 piPred = pcPredYuv->getLumaAddr( uiAbsPartIdx ); 1204 1145 piResi = pcResiYuv->getLumaAddr( uiAbsPartIdx ); 1205 1146 1206 1147 uiZOrder = pcCU->getZorderIdxInCU() + uiAbsPartIdx; 1207 1148 piRecIPred = pcCU->getPic()->getPicYuvRec()->getLumaAddr( pcCU->getAddr(), uiZOrder ); … … 1211 1152 1212 1153 AOF( uiWidth == uiHeight ); 1213 #else 1214 TComYuv* pcRecoYuv = m_ppcYuvReco[uiDepth]; 1215 TComYuv* pcPredYuv = m_ppcYuvReco[uiDepth]; 1216 TComYuv* pcResiYuv = m_ppcYuvResi[uiDepth]; 1217 1218 UInt uiStride = pcRecoYuv->getStride (); 1219 Pel* piReco = pcRecoYuv->getLumaAddr( uiAbsPartIdx ); 1220 Pel* piPred = pcPredYuv->getLumaAddr( uiAbsPartIdx ); 1221 Pel* piResi = pcResiYuv->getLumaAddr( uiAbsPartIdx ); 1222 1223 UInt uiZOrder = pcCU->getZorderIdxInCU() + uiAbsPartIdx; 1224 Pel* piRecIPred = pcCU->getPic()->getPicYuvRec()->getLumaAddr( pcCU->getAddr(), uiZOrder ); 1225 UInt uiRecIPredStride = pcCU->getPic()->getPicYuvRec()->getStride (); 1226 1227 UInt uiLumaPredMode = pcCU->getLumaIntraDir ( uiAbsPartIdx ); 1228 1229 AOF( uiWidth == uiHeight ); 1230 AOF( uiAbsPartIdx == 0 ); 1231 AOF( pcCU->getSDCAvailable(uiAbsPartIdx) ); 1232 AOF( pcCU->getSDCFlag(uiAbsPartIdx) ); 1233 #endif 1234 1235 //===== init availability pattern ===== 1236 Bool bAboveAvail = false; 1237 Bool bLeftAvail = false; 1238 #if QC_PKU_SDC_SPLIT_G0123 1239 pcCU->getPattern()->initPattern ( pcCU, sdcDepth, uiAbsPartIdx ); 1240 pcCU->getPattern()->initAdiPattern( pcCU, uiAbsPartIdx, sdcDepth, m_pcPrediction->getPredicBuf(), m_pcPrediction->getPredicBufWidth(), m_pcPrediction->getPredicBufHeight(), bAboveAvail, bLeftAvail ); 1241 #else 1242 pcCU->getPattern()->initPattern ( pcCU, 0, uiAbsPartIdx ); 1243 pcCU->getPattern()->initAdiPattern( pcCU, uiAbsPartIdx, 0, m_pcPrediction->getPredicBuf(), m_pcPrediction->getPredicBufWidth(), m_pcPrediction->getPredicBufHeight(), bAboveAvail, bLeftAvail ); 1244 #endif 1245 #if !QC_PKU_SDC_SPLIT_G0123 1246 #if QC_GENERIC_SDC_G0122 1247 TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight ); 1248 #endif 1249 #endif 1250 #if HS_TSINGHUA_SDC_SPLIT_G0111 1251 TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight ); 1252 #endif 1253 //===== get prediction signal ===== 1254 #if H_3D_DIM 1255 if( isDimMode( uiLumaPredMode ) ) 1256 { 1257 m_pcPrediction->predIntraLumaDepth( pcCU, uiAbsPartIdx, uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight 1258 #if QC_GENERIC_SDC_G0122 1259 , false, dmm4Segmentation 1260 #endif 1261 ); 1262 #if HS_TSINGHUA_SDC_SPLIT_G0111 1263 Bool* dmm4PatternSplit = dmm4Segmentation->getPattern(); 1264 Bool* dmm4PatternOrg = dmm4SegmentationOrg->getPattern(); 1265 for( UInt k = 0; k < (uiWidth*uiHeight); k++ ) 1266 { 1267 dmm4PatternOrg[k+(uiAbsPartIdx<<4)] = dmm4PatternSplit[k]; 1268 } 1269 #endif 1270 } 1271 else 1272 { 1273 #endif 1274 m_pcPrediction->predIntraLumaAng( pcCU->getPattern(), uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight, bAboveAvail, bLeftAvail ); 1275 #if H_3D_DIM 1276 } 1277 #endif 1278 #if QC_PKU_SDC_SPLIT_G0123 1154 1155 //===== init availability pattern ===== 1156 Bool bAboveAvail = false; 1157 Bool bLeftAvail = false; 1158 1159 pcCU->getPattern()->initPattern ( pcCU, sdcDepth, uiAbsPartIdx ); 1160 pcCU->getPattern()->initAdiPattern( pcCU, uiAbsPartIdx, sdcDepth, m_pcPrediction->getPredicBuf(), m_pcPrediction->getPredicBufWidth(), m_pcPrediction->getPredicBufHeight(), bAboveAvail, bLeftAvail ); 1161 1162 TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight ); 1163 //===== get prediction signal ===== 1164 if( isDimMode( uiLumaPredMode ) ) 1165 { 1166 m_pcPrediction->predIntraLumaDepth( pcCU, uiAbsPartIdx, uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight, false, dmm4Segmentation ); 1167 Bool* dmm4PatternSplit = dmm4Segmentation->getPattern(); 1168 Bool* dmm4PatternOrg = dmm4SegmentationOrg->getPattern(); 1169 for( UInt k = 0; k < (uiWidth*uiHeight); k++ ) 1170 { 1171 dmm4PatternOrg[k+(uiAbsPartIdx<<4)] = dmm4PatternSplit[k]; 1172 } 1173 } 1174 else 1175 { 1176 m_pcPrediction->predIntraLumaAng( pcCU->getPattern(), uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight, bAboveAvail, bLeftAvail ); 1177 } 1178 1279 1179 if ( numParts > 1 ) 1280 1180 { … … 1292 1192 } 1293 1193 uiAbsPartIdx += ( (uiWidth * uiWidth) >> 4 ); 1294 #if HS_TSINGHUA_SDC_SPLIT_G01111295 1194 dmm4Segmentation->destroy(); delete dmm4Segmentation; 1296 #endif1297 1195 } 1298 1196 uiAbsPartIdx = 0; … … 1309 1207 piRecIPred = pcCU->getPic()->getPicYuvRec()->getLumaAddr( pcCU->getAddr(), uiZOrder ); 1310 1208 uiRecIPredStride = pcCU->getPic()->getPicYuvRec()->getStride (); 1311 #endif1312 1209 // number of segments depends on prediction mode 1313 1210 UInt uiNumSegments = 1; … … 1326 1223 uiMaskStride = pcWedgelet->getStride(); 1327 1224 } 1328 #if QC_GENERIC_SDC_G01221329 1225 if( getDimType( uiLumaPredMode ) == DMM4_IDX ) 1330 1226 { 1331 1227 uiNumSegments = 2; 1332 #if HS_TSINGHUA_SDC_SPLIT_G01111333 1228 pbMask = dmm4SegmentationOrg->getPattern(); 1334 1229 uiMaskStride = dmm4SegmentationOrg->getStride(); 1335 #else 1336 pbMask = dmm4Segmentation->getPattern(); 1337 uiMaskStride = dmm4Segmentation->getStride(); 1338 #endif 1339 } 1340 #endif 1230 } 1341 1231 // get DC prediction for each segment 1342 1232 Pel apDCPredValues[2]; … … 1400 1290 pRecCr += uiStrideC; 1401 1291 } 1402 #if QC_GENERIC_SDC_G01221403 #if HS_TSINGHUA_SDC_SPLIT_G01111404 1292 dmm4SegmentationOrg->destroy(); delete dmm4SegmentationOrg; 1405 #else1406 dmm4Segmentation->destroy(); delete dmm4Segmentation;1407 #endif1408 #endif1409 1293 } 1410 1294 #endif -
trunk/source/Lib/TLibDecoder/TDecEntropy.cpp
r872 r884 111 111 pcCU->setICFlagSubParts( false , uiAbsPartIdx, 0, uiDepth ); 112 112 113 #if SEC_IC_ARP_SIG_G0072114 113 if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() || pcCU->getARPW( uiAbsPartIdx ) > 0 ) 115 #else116 if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() )117 #endif118 114 { 119 115 return; … … 272 268 decodeMergeIndex( pcCU, uiPartIdx, uiSubPartIdx, uiDepth ); 273 269 UInt uiMergeIndex = pcCU->getMergeIndex(uiSubPartIdx); 274 #if !SEC_IC_ARP_SIG_G0072 270 #if H_3D_ARP 271 decodeARPW ( pcCU, uiAbsPartIdx, uiDepth ); 272 #endif 275 273 #if H_3D_IC 276 274 decodeICFlag( pcCU, uiAbsPartIdx, uiDepth ); 277 #endif278 #endif279 #if H_3D_ARP280 decodeARPW ( pcCU, uiAbsPartIdx, uiDepth );281 #endif282 #if SEC_IC_ARP_SIG_G0072283 #if H_3D_IC284 decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );285 #endif286 275 #endif 287 276 #if H_3D_DBBP … … 362 351 pcCU->setInterDirSubParts( uhInterDirNeighbours[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth ); 363 352 364 #if MTK_DDD_G0063353 #if H_3D_DDD 365 354 if( uiMergeIndex == pcSubCU->getUseDDDCandIdx() ) 366 355 { … … 384 373 pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvd( cTmpMv, ePartSize, uiSubPartIdx, uiDepth, uiPartIdx ); 385 374 pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvField( cMvFieldNeighbours[ 2*uiMergeIndex + uiRefListIdx ], ePartSize, uiSubPartIdx, uiDepth, uiPartIdx ); 386 #if NTT_STORE_SPDV_VSP_G0148375 #if H_3D_VSP 387 376 #if H_3D_DBBP 388 377 if( pcCU->getVSPFlag( uiSubPartIdx ) != 0 && !pcCU->getDBBPFlag( uiAbsPartIdx ) ) … … 440 429 } 441 430 } 442 #if !SEC_IC_ARP_SIG_G0072 431 #if H_3D_ARP 432 decodeARPW ( pcCU, uiAbsPartIdx, uiDepth ); 433 #endif 443 434 #if H_3D_IC 444 435 decodeICFlag( pcCU, uiAbsPartIdx, uiDepth ); 445 436 #endif 446 #endif447 #if H_3D_ARP448 decodeARPW ( pcCU, uiAbsPartIdx, uiDepth );449 #endif450 #if SEC_IC_ARP_SIG_G0072451 #if H_3D_IC452 decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );453 #endif454 #endif455 437 } 456 438 #if H_3D_VSP 457 #if NTT_STORE_SPDV_VSP_G0148458 439 if ( (pcCU->getInterDir(uiSubPartIdx) == 3) && pcSubCU->isBipredRestriction(uiPartIdx) && (pcCU->getVSPFlag(uiSubPartIdx) == 0)) 459 #else460 if ( (pcCU->getInterDir(uiSubPartIdx) == 3) && pcSubCU->isBipredRestriction(uiPartIdx) && (pcCU->getVSPFlag(uiSubPartIdx) == false))461 #endif462 440 #else 463 441 if ( (pcCU->getInterDir(uiSubPartIdx) == 3) && pcSubCU->isBipredRestriction(uiPartIdx) ) … … 797 775 UInt uiLumaOffset = uiMinCoeffSize*uiAbsPartIdx; 798 776 UInt uiChromaOffset = uiLumaOffset>>2; 799 #if QC_SDC_UNIFY_G0130800 777 #if H_3D_DIM_SDC 801 778 if( pcCU->getSDCFlag( uiAbsPartIdx ) && pcCU->isIntra( uiAbsPartIdx) ) … … 807 784 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 ); 808 785 } 809 #endif810 786 811 787 #if H_3D_INTER_SDC … … 817 793 } 818 794 #endif 819 #if QC_SDC_UNIFY_G0130_FIX820 795 if( pcCU->getSlice()->getIsDepth() && ( pcCU->getSDCFlag( uiAbsPartIdx ) || pcCU->isIntra( uiAbsPartIdx ) ) ) 821 #else822 if( pcCU->getSDCFlag( uiAbsPartIdx ) || pcCU->isIntra( uiAbsPartIdx ) )823 #endif824 796 { 825 797 Int iPartNum = ( pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_NxN ) ? 4 : 1; … … 842 814 } 843 815 } 844 #else845 #if H_3D_DIM_SDC846 if( pcCU->getSDCFlag( uiAbsPartIdx ) )847 {848 assert( pcCU->getPartitionSize(uiAbsPartIdx) == SIZE_2Nx2N );849 assert( pcCU->getTransformIdx(uiAbsPartIdx) == 0 );850 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_LUMA) == 1 );851 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 );852 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 );853 return;854 }855 #endif856 857 #if H_3D_INTER_SDC858 if( pcCU->getInterSDCFlag( uiAbsPartIdx ) )859 {860 assert( !pcCU->isSkipped( uiAbsPartIdx ) );861 assert( !pcCU->isIntra( uiAbsPartIdx) );862 assert( pcCU->getSlice()->getIsDepth() );863 864 decodeInterSDCResidualData( pcCU, uiAbsPartIdx, uiDepth );865 return;866 }867 #endif868 816 #endif 869 817 … … 893 841 894 842 #if H_3D_INTER_SDC 895 #if QC_SDC_UNIFY_G0130896 843 Void TDecEntropy::decodeSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 897 844 { … … 904 851 } 905 852 906 #if SEC_INTER_SDC_G0101907 853 if( !pcCU->getSlice()->getIsDepth() || pcCU->getPartitionSize( uiAbsPartIdx ) != SIZE_2Nx2N || pcCU->isSkipped( uiAbsPartIdx ) ) 908 #else909 if( !pcCU->getSlice()->getIsDepth() || ( pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) != SIZE_2Nx2N ) || pcCU->isSkipped( uiAbsPartIdx ) )910 #endif911 854 { 912 855 return; 913 856 } 914 857 915 #if SEC_INTER_SDC_G0101916 858 assert( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N || ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->isSkipped( uiAbsPartIdx ) ) ); 917 #else918 assert( ( pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N ) || ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->isSkipped( uiAbsPartIdx ) ) );919 #endif920 921 859 m_pcEntropyDecoderIf->parseSDCFlag( pcCU, uiAbsPartIdx, uiDepth ); 922 860 } 923 924 #else925 Void TDecEntropy::decodeInterSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )926 {927 pcCU->setInterSDCFlagSubParts( false, uiAbsPartIdx, 0, uiDepth);928 929 if( !pcCU->getSlice()->getVPS()->getInterSDCFlag( pcCU->getSlice()->getLayerIdInVps() ) )930 {931 return;932 }933 934 if( !pcCU->getSlice()->getIsDepth() || pcCU->isIntra( uiAbsPartIdx ) || pcCU->isSkipped( uiAbsPartIdx ) )935 {936 return;937 }938 939 m_pcEntropyDecoderIf->parseInterSDCFlag( pcCU, uiAbsPartIdx, uiDepth );940 }941 942 Void TDecEntropy::decodeInterSDCResidualData( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )943 {944 if( !pcCU->getSlice()->getVPS()->getInterSDCFlag( pcCU->getSlice()->getLayerIdInVps() ) )945 {946 return;947 }948 949 if( !pcCU->getSlice()->getIsDepth() || pcCU->isIntra( uiAbsPartIdx ) || !pcCU->getInterSDCFlag( uiAbsPartIdx ) )950 {951 return;952 }953 954 UInt uiNumSegments = ( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N ) ? 1 : ( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_NxN ? 4 : 2 );955 956 // decode residual data for each segment957 for( UInt uiSeg = 0; uiSeg < uiNumSegments; uiSeg++ )958 {959 m_pcEntropyDecoderIf->parseInterSDCResidualData( pcCU, uiAbsPartIdx, uiDepth, uiSeg );960 }961 }962 #endif963 861 #endif 964 862 #if H_3D_DBBP -
trunk/source/Lib/TLibDecoder/TDecEntropy.h
r872 r884 96 96 #endif 97 97 #if H_3D_INTER_SDC 98 #if QC_SDC_UNIFY_G013099 98 virtual Void parseDeltaDC ( TComDataCU* pcCU, UInt absPartIdx, UInt depth ) = 0; 100 99 virtual Void parseSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) = 0; 101 #else102 virtual Void parseInterSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) = 0;103 virtual Void parseInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPart ) = 0;104 #endif105 100 #endif 106 101 #if H_3D_DBBP … … 187 182 #endif 188 183 #if H_3D_INTER_SDC 189 #if QC_SDC_UNIFY_G0130190 184 Void decodeSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 191 #else192 Void decodeInterSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth );193 Void decodeInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth );194 #endif195 185 #endif 196 186 #if H_3D_DBBP -
trunk/source/Lib/TLibDecoder/TDecSbac.cpp
r872 r884 86 86 , m_cDdcFlagSCModel ( 1, 1, NUM_DDC_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 87 87 , m_cDdcDataSCModel ( 1, 1, NUM_DDC_DATA_CTX , m_contextModels + m_numContextModels, m_numContextModels) 88 #if QC_GENERIC_SDC_G012289 88 , m_cAngleFlagSCModel ( 1, 1, NUM_ANGLE_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 90 #if !QC_SDC_UNIFY_G013091 , m_cIntraSdcFlagSCModel ( 1, 1, NUM_INTRASDC_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels)92 #endif93 #endif94 89 #if H_3D_DIM_DMM 95 90 , m_cDmm1DataSCModel ( 1, 1, NUM_DMM1_DATA_CTX , m_contextModels + m_numContextModels, m_numContextModels) … … 100 95 #endif 101 96 #endif 102 #if H_3D_INTER_SDC && !QC_SDC_UNIFY_G0130 103 , m_cInterSDCFlagSCModel ( 1, 1, NUM_INTER_SDC_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 104 , m_cInterSDCResidualSCModel ( 1, 1, NUM_INTER_SDC_RESIDUAL_CTX , m_contextModels + m_numContextModels, m_numContextModels) 105 , m_cInterSDCResidualSignFlagSCModel ( 1, 1, NUM_INTER_SDC_SIGN_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 106 #endif 107 #if QC_SDC_UNIFY_G0130 97 #if H_3D_DIM_SDC 108 98 , m_cSDCFlagSCModel ( 1, 1, NUM_SDC_FLAG_CTX , m_contextModels + m_numContextModels, m_numContextModels) 109 99 #endif … … 180 170 m_cDdcFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_DDC_FLAG ); 181 171 m_cDdcDataSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_DDC_DATA ); 182 #if QC_GENERIC_SDC_G0122183 172 m_cAngleFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_ANGLE_FLAG ); 184 #if !QC_SDC_UNIFY_G0130185 m_cIntraSdcFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_INTRASDC_FLAG );186 #endif187 #endif188 173 #if H_3D_DIM_DMM 189 174 m_cDmm1DataSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_DMM1_DATA ); … … 194 179 #endif 195 180 #endif 196 #if H_3D_INTER_SDC && !QC_SDC_UNIFY_G0130 197 m_cInterSDCFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_INTER_SDC_FLAG ); 198 m_cInterSDCResidualSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_INTER_SDC_RESIDUAL ); 199 m_cInterSDCResidualSignFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_INTER_SDC_SIGN_FLAG ); 200 #endif 201 #if QC_SDC_UNIFY_G0130 181 #if H_3D_DIM_SDC 202 182 m_cSDCFlagSCModel.initBuffer ( sliceType, qp, (UChar*)INIT_SDC_FLAG ); 203 183 #endif … … 260 240 m_cDdcFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_DDC_FLAG ); 261 241 m_cDdcDataSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_DDC_DATA ); 262 #if QC_GENERIC_SDC_G0122263 242 m_cAngleFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_ANGLE_FLAG ); 264 #if !QC_SDC_UNIFY_G0130265 m_cIntraSdcFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_INTRASDC_FLAG );266 #endif267 #endif268 243 #if H_3D_DIM_DMM 269 244 m_cDmm1DataSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA ); … … 274 249 #endif 275 250 #endif 276 #if H_3D_INTER_SDC && !QC_SDC_UNIFY_G0130 277 m_cInterSDCFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_INTER_SDC_FLAG ); 278 m_cInterSDCResidualSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_INTER_SDC_RESIDUAL ); 279 m_cInterSDCResidualSignFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_INTER_SDC_SIGN_FLAG ); 280 #endif 281 #if QC_SDC_UNIFY_G0130 251 #if H_3D_DIM_SDC 282 252 m_cSDCFlagSCModel.initBuffer ( eSliceType, iQp, (UChar*)INIT_SDC_FLAG ); 283 253 #endif … … 817 787 Bool rapPic = (pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_W_RADL || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_N_LP || pcCU->getSlice()->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA); 818 788 819 #if MTK_TEX_DEP_PAR_G0055820 789 Bool depthDependent = false; 821 790 UInt uiTexturePart = uiMode; 822 #endif823 791 if(bDepthMapDetect && !bIntraSliceDetect && !rapPic && sps->getUseQTL() && sps->getUsePC()) 824 792 { 825 793 TComDataCU *pcTextureCU = pcTexture->getCU(pcCU->getAddr()); 826 794 assert(pcTextureCU->getDepth(uiAbsPartIdx) >= uiDepth); 827 #if !MTK_TEX_DEP_PAR_G0055828 if (pcTextureCU->getDepth(uiAbsPartIdx) == uiDepth && pcTextureCU->getPartitionSize( uiAbsPartIdx ) != SIZE_NxN)829 #else830 795 if(pcTextureCU->getDepth(uiAbsPartIdx) == uiDepth ) 831 796 { … … 834 799 } 835 800 if (pcTextureCU->getDepth(uiAbsPartIdx) == uiDepth && pcTextureCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N) 836 #endif837 801 { 838 802 bParsePartSize = false; … … 879 843 if(bParsePartSize) 880 844 { 881 #endif882 #if MTK_TEX_DEP_PAR_G0055883 845 if (depthDependent==false || uiTexturePart == SIZE_NxN|| uiTexturePart == SIZE_2Nx2N) 884 846 { … … 920 882 } 921 883 } 922 #if MTK_TEX_DEP_PAR_G0055884 #if H_3D_QTLPC 923 885 } 924 886 else if(uiTexturePart == SIZE_2NxN || uiTexturePart == SIZE_2NxnU || uiTexturePart == SIZE_2NxnD) … … 985 947 } 986 948 else 949 { 987 950 assert(0); 988 #endif 951 } 989 952 #if H_MV_ENC_DEC_TRAC 990 953 DTRACE_CU("part_mode", eMode ) 991 954 #endif 992 #if H_3D_QTLPC993 955 } 994 956 #endif … … 1041 1003 } 1042 1004 if( pcCU->getLumaIntraDir( absPartIdx+partOffset*j ) < NUM_INTRA_MODE ) 1043 #if H_3D_DIM_SDC1044 #if QC_GENERIC_SDC_G01221045 if( 1 ) // This should be cleaned up.1046 #else1047 if( !pcCU->getSDCFlag( absPartIdx+partOffset*j ) )1048 #endif1049 #endif1050 1005 { 1051 1006 #endif … … 1063 1018 #if H_3D_DIM 1064 1019 if( pcCU->getLumaIntraDir( absPartIdx+partOffset*j ) < NUM_INTRA_MODE ) 1065 #if H_3D_DIM_SDC1066 #if QC_GENERIC_SDC_G01221067 if( 1 ) // This should be cleaned up.1068 #else1069 if( !pcCU->getSDCFlag( absPartIdx+partOffset*j ) )1070 #endif1071 #endif1072 1020 { 1073 1021 #endif … … 1171 1119 } 1172 1120 1173 #if !QC_SDC_UNIFY_G01301174 if( dimType < DIM_NUM_TYPE || pcCU->getSDCFlag( absPartIdx ) )1175 {1176 UInt symbol;1177 #if QC_GENERIC_SDC_G01221178 UInt uiNumSegments = isDimMode( dir ) ? 2 : 1;1179 #else1180 UInt uiNumSegments = ( dir == PLANAR_IDX ) ? 1 : 2;1181 #endif1182 1183 if( pcCU->getSDCFlag( absPartIdx ) )1184 {1185 assert(pcCU->getPartitionSize(absPartIdx)==SIZE_2Nx2N);1186 pcCU->setTrIdxSubParts(0, absPartIdx, depth);1187 pcCU->setCbfSubParts(1, 1, 1, absPartIdx, depth);1188 }1189 1190 m_pcTDecBinIf->decodeBin( symbol, m_cDdcFlagSCModel.get(0, 0, uiNumSegments-1) );1191 1192 if( symbol )1193 {1194 if( !pcCU->getSDCFlag( absPartIdx ) )1195 {1196 dir += symbol;1197 }1198 }1199 for( UInt segment = 0; segment < uiNumSegments; segment++ )1200 {1201 Pel valDeltaDC = 0;1202 if( symbol )1203 {1204 xParseDimDeltaDC( valDeltaDC, uiNumSegments );1205 }1206 1207 if( pcCU->getSDCFlag( absPartIdx ) )1208 {1209 pcCU->setSDCSegmentDCOffset( valDeltaDC, segment, absPartIdx );1210 }1211 else1212 {1213 pcCU->setDimDeltaDC( dimType, segment, absPartIdx, valDeltaDC );1214 }1215 }1216 }1217 #endif1218 1121 pcCU->setLumaIntraDirSubParts( (UChar)dir, absPartIdx, depth ); 1219 1122 } 1220 1123 1221 #if QC_GENERIC_SDC_G01221222 1124 Void TDecSbac::parseIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx, UInt depth ) 1223 1125 { … … 1234 1136 uiIsDimMode = uiSymbol ? 0 : 1; 1235 1137 pcCU->setLumaIntraDirSubParts( 0, absPartIdx, depth ); 1236 #if !QC_SDC_UNIFY_G0130 1237 if( pcCU->getPartitionSize( absPartIdx ) == SIZE_2Nx2N ) //SDC is allowed only in this case 1238 { 1239 m_pcTDecBinIf->decodeBin( uiSymbol, m_cIntraSdcFlagSCModel.get( 0, 0, pcCU->getCtxSDCFlag( absPartIdx ) ) ); 1240 } 1241 else 1242 { 1243 uiSymbol = 0; 1244 } 1245 1246 pcCU->setSDCFlagSubParts( uiSymbol, absPartIdx, depth ); 1247 #endif 1138 1248 1139 //decode DMM index 1249 1140 if( uiIsDimMode ) … … 1260 1151 } 1261 1152 } 1262 #else1263 Void TDecSbac::parseIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx, UInt depth )1264 {1265 UInt puIdx = (pcCU->getWidth(absPartIdx) == 64) ? 2 : ( (pcCU->getPartitionSize(absPartIdx) == SIZE_NxN && pcCU->getWidth(absPartIdx) == 8) ? 0 : 1 );1266 UInt dir = 0;1267 Bool sdcFlag = 0;1268 UInt symbol = 1;1269 UInt modeCode = 0 ;1270 UInt binNum = 0;1271 UInt ctxDepthMode = 0;1272 1273 if( puIdx == 2 )1274 {1275 {1276 ctxDepthMode = puIdx*3 + binNum;1277 m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );1278 modeCode = (modeCode<<1) + symbol;1279 binNum++;1280 }1281 if( modeCode == 0 ) { dir = PLANAR_IDX; sdcFlag = 1;}1282 else if( modeCode == 1 ) { dir = 0; sdcFlag = 0;}1283 }1284 else if( puIdx == 0 )1285 {1286 while( binNum < 1 && symbol )1287 {1288 ctxDepthMode = puIdx*3 + ((binNum >= 2) ? 2 : binNum);1289 m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );1290 modeCode = (modeCode<<1) + symbol;1291 binNum++;1292 }1293 if( modeCode == 0 )1294 {1295 dir = 0;1296 sdcFlag = 0;1297 }1298 else if ( modeCode == 1 )1299 {1300 dir = (2*DMM1_IDX+DIM_OFFSET);1301 sdcFlag = 0;1302 }1303 }1304 else1305 {1306 while( binNum < 4 && symbol )1307 {1308 ctxDepthMode = puIdx*3 + ((binNum >= 2) ? 2 : binNum);1309 m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );1310 modeCode = (modeCode<<1) + symbol;1311 binNum++;1312 }1313 if ( modeCode == 0 ) { dir = PLANAR_IDX; sdcFlag = 1;}1314 else if ( modeCode == 2 ) { dir = 5; sdcFlag = 0;}1315 else if ( modeCode == 6 ) { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 1;}1316 else if ( modeCode == 14 ) { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 0;}1317 else if ( modeCode == 15 ) { dir = (2*DMM4_IDX+DIM_OFFSET); sdcFlag = 0;}1318 1319 }1320 pcCU->setLumaIntraDirSubParts( (UChar)dir, absPartIdx, depth );1321 #if H_3D_DIM_SDC1322 pcCU->setSDCFlagSubParts( sdcFlag, absPartIdx, depth );1323 #endif1324 }1325 #endif1326 1153 #endif 1327 1154 … … 2189 2016 if( 1 == uiW ) 2190 2017 { 2191 #if MTK_ARP_FLAG_CABAC_SIMP_G00612192 2018 m_pcTDecBinIf->decodeBin( uiCode , m_cCUPUARPWSCModel.get( 0, 0, 2 ) ); 2193 #else2194 m_pcTDecBinIf->decodeBin( uiCode , m_cCUPUARPWSCModel.get( 0, 0, 3 ) );2195 #endif2196 2019 uiW += ( 1 == uiCode ? 1 : 0 ); 2197 2020 } … … 2213 2036 { 2214 2037 UInt uiSymbol = 0; 2215 #if MTK_IC_FLAG_CABAC_SIMP_G00612216 2038 m_pcTDecBinIf->decodeBin( uiSymbol, m_cCUICFlagSCModel.get( 0, 0, 0 ) ); 2217 #else2218 UInt uiCtxIC = pcCU->getCtxICFlag( uiAbsPartIdx );2219 m_pcTDecBinIf->decodeBin( uiSymbol, m_cCUICFlagSCModel.get( 0, 0, uiCtxIC ) );2220 #endif2221 2039 #if !H_MV_ENC_DEC_TRAC 2222 2040 DTRACE_CABAC_VL( g_nSymbolCounter++ ); … … 2236 2054 2237 2055 #if H_3D_INTER_SDC 2238 #if QC_SDC_UNIFY_G01302239 2056 Void TDecSbac::parseDeltaDC( TComDataCU* pcCU, UInt absPartIdx, UInt depth ) 2240 2057 { … … 2267 2084 else 2268 2085 { 2269 #if SEC_INTER_SDC_G01012270 2086 uiNumSegments = 1; 2271 #else2272 PartSize cPartSize = pcCU->getPartitionSize( absPartIdx );2273 uiNumSegments = ( cPartSize == SIZE_2Nx2N ) ? 1 : ( cPartSize == SIZE_NxN ? 4 : 2 );2274 #endif2275 2087 symbol = 1; 2276 2088 } … … 2323 2135 } 2324 2136 } 2325 #else 2326 Void TDecSbac::parseInterSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 2327 { 2328 UInt uiSymbol = 0; 2329 UInt uiCtxInterSDCFlag = pcCU->getCtxInterSDCFlag( uiAbsPartIdx ); 2330 2331 m_pcTDecBinIf->decodeBin( uiSymbol, m_cInterSDCFlagSCModel.get( 0, 0, uiCtxInterSDCFlag ) ); 2332 2333 if( uiSymbol ) 2334 { 2335 pcCU->setInterSDCFlagSubParts( true, uiAbsPartIdx, 0, uiDepth ); 2336 pcCU->setTrIdxSubParts( 0, uiAbsPartIdx, uiDepth ); 2337 pcCU->setCbfSubParts( 1, 1, 1, uiAbsPartIdx, uiDepth ); 2338 } 2339 else 2340 { 2341 pcCU->setInterSDCFlagSubParts( false, uiAbsPartIdx, 0, uiDepth); 2342 } 2343 } 2344 2345 Void TDecSbac::parseInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiSegment ) 2346 { 2347 UInt uiAbsIdx = 0; 2348 UInt uiSign = 0; 2349 Int iIdx = 0; 2350 2351 xReadExGolombLevel( uiAbsIdx, m_cInterSDCResidualSCModel.get( 0, 0, 0 ) ); 2352 2353 uiAbsIdx++; 2354 m_pcTDecBinIf->decodeBin( uiSign, m_cInterSDCResidualSignFlagSCModel.get( 0, 0, 0 ) ); 2355 iIdx = (Int)( uiSign ? -1 : 1 ) * uiAbsIdx; 2356 2357 pcCU->setInterSDCSegmentDCOffset( iIdx, uiSegment, uiAbsPartIdx ); 2358 } 2359 #endif 2137 2360 2138 #endif 2361 2139 -
trunk/source/Lib/TLibDecoder/TDecSbac.h
r872 r884 112 112 #endif 113 113 #if H_3D_INTER_SDC 114 #if QC_SDC_UNIFY_G0130115 114 Void parseDeltaDC ( TComDataCU* pcCU, UInt absPartIdx, UInt depth ); 116 115 Void parseSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ); 117 #else118 Void parseInterSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth );119 Void parseInterSDCResidualData ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPart );120 #endif121 116 #endif 122 117 #if H_3D_DBBP … … 218 213 ContextModel3DBuffer m_cDdcFlagSCModel; 219 214 ContextModel3DBuffer m_cDdcDataSCModel; 220 #if QC_GENERIC_SDC_G0122221 215 ContextModel3DBuffer m_cAngleFlagSCModel; 222 #if !QC_SDC_UNIFY_G0130223 ContextModel3DBuffer m_cIntraSdcFlagSCModel;224 #endif225 #endif226 216 #if H_3D_DIM_DMM 227 217 ContextModel3DBuffer m_cDmm1DataSCModel; … … 232 222 #endif 233 223 #endif 234 #if H_3D_INTER_SDC && !QC_SDC_UNIFY_G0130 235 ContextModel3DBuffer m_cInterSDCFlagSCModel; 236 ContextModel3DBuffer m_cInterSDCResidualSCModel; 237 ContextModel3DBuffer m_cInterSDCResidualSignFlagSCModel; 238 #endif 239 #if QC_SDC_UNIFY_G0130 224 #if H_3D_DIM_SDC 240 225 ContextModel3DBuffer m_cSDCFlagSCModel; 241 226 #endif -
trunk/source/Lib/TLibDecoder/TDecTop.cpp
r872 r884 51 51 m_aaiCodedOffset = new Int* [ MAX_NUM_LAYERS ]; 52 52 m_aaiCodedScale = new Int* [ MAX_NUM_LAYERS ]; 53 #if !FIX_CAM_PARS_COLLECTOR54 m_aiViewId = new Int [ MAX_NUM_LAYERS ];55 56 m_bViewReceived = new Bool [ MAX_NUM_LAYERS ];57 #endif58 53 for( UInt uiId = 0; uiId < MAX_NUM_LAYERS; uiId++ ) 59 54 { … … 65 60 m_iLog2Precision = LOG2_DISP_PREC_LUT; 66 61 m_uiBitDepthForLUT = 8; // fixed 67 #if FIX_CAM_PARS_COLLECTOR68 62 m_receivedIdc = NULL; 69 63 m_vps = NULL; 70 #endif71 64 } 72 65 … … 80 73 delete [] m_aaiCodedOffset; 81 74 delete [] m_aaiCodedScale; 82 #if !FIX_CAM_PARS_COLLECTOR83 delete [] m_aiViewId;84 delete [] m_bViewReceived;85 #endif86 75 87 76 xDeleteArray( m_adBaseViewShiftLUT, MAX_NUM_LAYERS, MAX_NUM_LAYERS, 2 ); 88 77 xDeleteArray( m_aiBaseViewShiftLUT, MAX_NUM_LAYERS, MAX_NUM_LAYERS, 2 ); 89 #if FIX_CAM_PARS_COLLECTOR90 78 xDeleteArray( m_receivedIdc, m_uiMaxViewIndex + 1 ); 91 #endif 92 } 93 94 95 #if FIX_CAM_PARS_COLLECTOR 79 } 80 81 96 82 Void 97 83 CamParsCollector::init( FILE* pCodedScaleOffsetFile, TComVPS* vps) … … 159 145 } 160 146 } 161 #else162 Void163 CamParsCollector::init( FILE* pCodedScaleOffsetFile )164 {165 m_bInitialized = true;166 m_pCodedScaleOffsetFile = pCodedScaleOffsetFile;167 m_uiCamParsCodedPrecision = 0;168 m_bCamParsVaryOverTime = false;169 m_iLastViewIndex = -1;170 m_iLastPOC = -1;171 m_uiMaxViewIndex = 0;172 }173 #endif174 175 147 176 148 … … 206 178 CamParsCollector::xInitLUTs( UInt uiSourceView, UInt uiTargetView, Int iScale, Int iOffset, Double****& radLUT, Int****& raiLUT) 207 179 { 208 #if FIX_CAM_PARS_COLLECTOR209 180 Int iLog2DivLuma = m_uiBitDepthForLUT + m_vps->getCamParPrecision() + 1 - m_iLog2Precision; AOF( iLog2DivLuma > 0 ); 210 #else211 Int iLog2DivLuma = m_uiBitDepthForLUT + m_uiCamParsCodedPrecision + 1 - m_iLog2Precision; AOF( iLog2DivLuma > 0 );212 #endif213 181 Int iLog2DivChroma = iLog2DivLuma + 1; 214 182 … … 252 220 } 253 221 254 #if !FIX_CAM_PARS_COLLECTOR255 Void256 CamParsCollector::setSlice( TComSlice* pcSlice )257 {258 259 if( pcSlice == 0 )260 {261 AOF( xIsComplete() );262 if( m_bCamParsVaryOverTime || m_iLastPOC == 0 )263 {264 xOutput( m_iLastPOC );265 }266 return;267 }268 269 if ( pcSlice->getIsDepth())270 {271 return;272 }273 274 Bool bFirstAU = ( pcSlice->getPOC() == 0 );275 Bool bFirstSliceInAU = ( pcSlice->getPOC() != Int ( m_iLastPOC ) );276 Bool bFirstSliceInView = ( pcSlice->getViewIndex() != UInt( m_iLastViewIndex ) || bFirstSliceInAU );277 278 AOT( bFirstSliceInAU && pcSlice->getViewIndex() != 0 );279 AOT( !bFirstSliceInAU && pcSlice->getViewIndex() < UInt( m_iLastViewIndex ) );280 281 AOT( !bFirstSliceInAU && pcSlice->getViewIndex() > UInt( m_iLastViewIndex + 1 ) );282 283 AOT( !bFirstAU && pcSlice->getViewIndex() > m_uiMaxViewIndex );284 285 if ( !bFirstSliceInView )286 {287 if( m_bCamParsVaryOverTime ) // check consistency of slice parameters here288 {289 UInt uiViewIndex = pcSlice->getViewIndex();290 for( UInt uiBaseViewIndex = 0; uiBaseViewIndex < uiViewIndex; uiBaseViewIndex++ )291 {292 AOF( m_aaiCodedScale [ uiBaseViewIndex ][ uiViewIndex ] == pcSlice->getCodedScale () [ uiBaseViewIndex ] );293 AOF( m_aaiCodedOffset[ uiBaseViewIndex ][ uiViewIndex ] == pcSlice->getCodedOffset () [ uiBaseViewIndex ] );294 AOF( m_aaiCodedScale [ uiViewIndex ][ uiBaseViewIndex ] == pcSlice->getInvCodedScale () [ uiBaseViewIndex ] );295 AOF( m_aaiCodedOffset[ uiViewIndex ][ uiBaseViewIndex ] == pcSlice->getInvCodedOffset() [ uiBaseViewIndex ] );296 }297 }298 return;299 }300 301 if( bFirstSliceInAU )302 {303 if( !bFirstAU )304 {305 AOF( xIsComplete() );306 xOutput( m_iLastPOC );307 }308 ::memset( m_bViewReceived, false, MAX_NUM_LAYERS * sizeof( Bool ) );309 }310 311 UInt uiViewIndex = pcSlice->getViewIndex();312 m_bViewReceived[ uiViewIndex ] = true;313 if( bFirstAU )314 {315 m_uiMaxViewIndex = std::max( m_uiMaxViewIndex, uiViewIndex );316 m_aiViewId[ uiViewIndex ] = pcSlice->getViewId();317 318 if( uiViewIndex == 1 )319 {320 m_uiCamParsCodedPrecision = pcSlice->getVPS()->getCamParPrecision ();321 m_bCamParsVaryOverTime = pcSlice->getVPS()->hasCamParInSliceHeader ( uiViewIndex );322 }323 else if( uiViewIndex > 1 )324 {325 AOF( m_uiCamParsCodedPrecision == pcSlice->getVPS()->getCamParPrecision () );326 AOF( m_bCamParsVaryOverTime == pcSlice->getVPS()->hasCamParInSliceHeader ( uiViewIndex ) );327 }328 329 for( UInt uiBaseIndex = 0; uiBaseIndex < uiViewIndex; uiBaseIndex++ )330 {331 if( m_bCamParsVaryOverTime )332 {333 m_aaiCodedScale [ uiBaseIndex ][ uiViewIndex ] = pcSlice->getCodedScale () [ uiBaseIndex ];334 m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ] = pcSlice->getCodedOffset () [ uiBaseIndex ];335 m_aaiCodedScale [ uiViewIndex ][ uiBaseIndex ] = pcSlice->getInvCodedScale () [ uiBaseIndex ];336 m_aaiCodedOffset[ uiViewIndex ][ uiBaseIndex ] = pcSlice->getInvCodedOffset() [ uiBaseIndex ];337 xInitLUTs( uiBaseIndex, uiViewIndex, m_aaiCodedScale[ uiBaseIndex ][ uiViewIndex ], m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ], m_adBaseViewShiftLUT, m_aiBaseViewShiftLUT);338 xInitLUTs( uiViewIndex, uiBaseIndex, m_aaiCodedScale[ uiViewIndex ][ uiBaseIndex ], m_aaiCodedOffset[ uiViewIndex ][ uiBaseIndex ], m_adBaseViewShiftLUT, m_aiBaseViewShiftLUT);339 }340 else341 {342 m_aaiCodedScale [ uiBaseIndex ][ uiViewIndex ] = pcSlice->getVPS()->getCodedScale (uiViewIndex) [ uiBaseIndex ];343 m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ] = pcSlice->getVPS()->getCodedOffset (uiViewIndex) [ uiBaseIndex ];344 m_aaiCodedScale [ uiViewIndex ][ uiBaseIndex ] = pcSlice->getVPS()->getInvCodedScale (uiViewIndex) [ uiBaseIndex ];345 m_aaiCodedOffset[ uiViewIndex ][ uiBaseIndex ] = pcSlice->getVPS()->getInvCodedOffset(uiViewIndex) [ uiBaseIndex ];346 xInitLUTs( uiBaseIndex, uiViewIndex, m_aaiCodedScale[ uiBaseIndex ][ uiViewIndex ], m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ], m_adBaseViewShiftLUT, m_aiBaseViewShiftLUT );347 xInitLUTs( uiViewIndex, uiBaseIndex, m_aaiCodedScale[ uiViewIndex ][ uiBaseIndex ], m_aaiCodedOffset[ uiViewIndex ][ uiBaseIndex ], m_adBaseViewShiftLUT, m_aiBaseViewShiftLUT );348 }349 }350 }351 else352 {353 AOF( m_aiViewId[ uiViewIndex ] == pcSlice->getViewId() );354 if( m_bCamParsVaryOverTime )355 {356 for( UInt uiBaseIndex = 0; uiBaseIndex < uiViewIndex; uiBaseIndex++ )357 {358 m_aaiCodedScale [ uiBaseIndex ][ uiViewIndex ] = pcSlice->getCodedScale () [ uiBaseIndex ];359 m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ] = pcSlice->getCodedOffset () [ uiBaseIndex ];360 m_aaiCodedScale [ uiViewIndex ][ uiBaseIndex ] = pcSlice->getInvCodedScale () [ uiBaseIndex ];361 m_aaiCodedOffset[ uiViewIndex ][ uiBaseIndex ] = pcSlice->getInvCodedOffset() [ uiBaseIndex ];362 363 xInitLUTs( uiBaseIndex, uiViewIndex, m_aaiCodedScale[ uiBaseIndex ][ uiViewIndex ], m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ], m_adBaseViewShiftLUT, m_aiBaseViewShiftLUT );364 xInitLUTs( uiViewIndex, uiBaseIndex, m_aaiCodedScale[ uiViewIndex ][ uiBaseIndex ], m_aaiCodedOffset[ uiViewIndex ][ uiBaseIndex ], m_adBaseViewShiftLUT, m_aiBaseViewShiftLUT );365 }366 }367 }368 369 m_iLastViewIndex = (Int)pcSlice->getViewIndex();370 m_iLastPOC = (Int)pcSlice->getPOC();371 }372 373 #else374 222 Void 375 223 CamParsCollector::setSlice( TComSlice* pcSlice ) … … 440 288 } 441 289 } 442 #endif443 290 444 291 … … 454 301 #endif 455 302 456 #if !FIX_CAM_PARS_COLLECTOR457 Bool458 CamParsCollector::xIsComplete()459 {460 for( UInt uiView = 0; uiView <= m_uiMaxViewIndex; uiView++ )461 {462 if( m_bViewReceived[ uiView ] == 0 )463 {464 return false;465 }466 }467 return true;468 }469 #endif470 303 471 304 Void … … 474 307 if( m_pCodedScaleOffsetFile ) 475 308 { 476 #if FIX_CAM_PARS_COLLECTOR477 309 if( iPOC == m_firstReceivedPoc ) 478 #else479 if( iPOC == 0 )480 #endif481 310 { 482 311 fprintf( m_pCodedScaleOffsetFile, "# ViewIndex ViewId\n" ); 483 312 fprintf( m_pCodedScaleOffsetFile, "#----------- ------------\n" ); 484 #if FIX_CAM_PARS_COLLECTOR485 313 for( UInt uiViewIndex = 0; uiViewIndex <= m_uiMaxViewIndex; uiViewIndex++ ) 486 314 { 487 315 fprintf( m_pCodedScaleOffsetFile, "%12d %12d\n", uiViewIndex, m_vps->getViewIdVal( uiViewIndex ) ); 488 #else489 for( UInt uiViewIndex = 0; uiViewIndex <= m_uiMaxViewIndex; uiViewIndex++ )490 {491 fprintf( m_pCodedScaleOffsetFile, "%12d %12d\n", uiViewIndex, m_aiViewId[ uiViewIndex ] );492 #endif493 316 } 494 317 fprintf( m_pCodedScaleOffsetFile, "\n\n"); … … 496 319 fprintf( m_pCodedScaleOffsetFile, "#----------- ------------ ------------ ------------ ------------ ------------ ------------\n" ); 497 320 } 498 #if FIX_CAM_PARS_COLLECTOR499 321 if( iPOC == m_firstReceivedPoc || m_bCamParsVaryOverTime ) 500 #else501 if( iPOC == 0 || m_bCamParsVaryOverTime )502 #endif503 322 { 504 323 Int iS = iPOC; … … 510 329 if( uiViewIndex != uiBaseIndex ) 511 330 { 512 #if FIX_CAM_PARS_COLLECTOR513 331 if ( m_receivedIdc[uiBaseIndex][uiViewIndex] != 0 ) 514 332 { … … 516 334 iS, iE, uiViewIndex, uiBaseIndex, m_aaiCodedScale[ uiBaseIndex ][ uiViewIndex ], m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ], m_vps->getCamParPrecision() ); 517 335 } 518 #else519 fprintf( m_pCodedScaleOffsetFile, "%12d %12d %12d %12d %12d %12d %12d\n",520 iS, iE, uiViewIndex, uiBaseIndex, m_aaiCodedScale[ uiBaseIndex ][ uiViewIndex ], m_aaiCodedOffset[ uiBaseIndex ][ uiViewIndex ], m_uiCamParsCodedPrecision );521 #endif522 523 336 } 524 337 } … … 641 454 for( Int temporalLayer=0; temporalLayer < MAX_TLAYER; temporalLayer++) 642 455 { 643 #if H_MV _HLS_7_SPS_P0155_16_32456 #if H_MV 644 457 numReorderPics[temporalLayer] = ( getLayerId() == 0 ) ? pcSlice->getSPS()->getNumReorderPics(temporalLayer) : pcSlice->getVPS()->getNumReorderPics(temporalLayer); 645 458 #else … … 647 460 #endif 648 461 } 649 #if H_MV _HLS_7_SPS_P0155_16_32462 #if H_MV 650 463 if ( getLayerId() == 0 ) 651 464 { -
trunk/source/Lib/TLibDecoder/TDecTop.h
r872 r884 71 71 ~CamParsCollector (); 72 72 73 #if FIX_CAM_PARS_COLLECTOR74 73 Void init ( FILE* pCodedScaleOffsetFile, TComVPS* vps ); 75 #else76 Void init ( FILE* pCodedScaleOffsetFile );77 #endif78 74 79 75 Void uninit (); … … 87 83 #endif 88 84 89 #if MTK_DDD_G006385 #if H_3D_DDD 90 86 Int getCodedScale( Int iBaseView, Int iCureView){ return m_aaiCodedScale[ iBaseView ][ iCureView ];} 91 87 Int getCodedOffset( Int iBaseView, Int iCureView){ return m_aaiCodedOffset[ iBaseView ][ iCureView ];} … … 94 90 95 91 private: 96 #if FIX_CAM_PARS_COLLECTOR97 92 Void xResetReceivedIdc( Bool overWriteFlag ); 98 #else99 Bool xIsComplete ();100 #endif101 93 Void xOutput ( Int iPOC ); 102 94 … … 108 100 Int** m_aaiCodedScale; 109 101 110 #if !FIX_CAM_PARS_COLLECTOR111 Int* m_aiViewId;112 #else113 102 TComVPS* m_vps; 114 103 Int** m_receivedIdc; … … 116 105 Int m_lastPoc; 117 106 Int m_firstReceivedPoc; 118 #endif 119 120 121 #if !FIX_CAM_PARS_COLLECTOR 122 Bool* m_bViewReceived; 123 UInt m_uiCamParsCodedPrecision; 124 #endif 107 108 125 109 Bool m_bCamParsVaryOverTime; 126 #if !FIX_CAM_PARS_COLLECTOR127 Int m_iLastViewIndex;128 Int m_iLastPOC;129 UInt m_uiMaxViewIndex;130 #endif131 132 110 133 111 UInt m_uiBitDepthForLUT;
Note: See TracChangeset for help on using the changeset viewer.