Changeset 1169 in 3DVCSoftware
- Timestamp:
- 5 Apr 2015, 22:37:43 (10 years ago)
- Location:
- branches/HTM-13.1-dev0
- Files:
-
- 1 added
- 19 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-13.1-dev0/source/App/TAppEncoder/TAppEncTop.cpp
r1164 r1169 1681 1681 Void TAppEncTop::xSetRepFormat( TComVPS& vps ) 1682 1682 { 1683 1684 #if H_3D_DISABLE_CHROMA 1685 Bool anyDepth = false; 1686 for ( Int i = 0; i < m_numberOfLayers; i++ ) 1687 { 1688 vps.setVpsRepFormatIdx( i, m_depthFlag[ i ] ? 1 : 0 ); 1689 anyDepth = anyDepth || m_depthFlag[ i ]; 1690 } 1691 1692 vps.setRepFormatIdxPresentFlag( anyDepth ); 1693 vps.setVpsNumRepFormatsMinus1 ( anyDepth ? 1 : 0 ); 1694 1695 for ( Int j = 0; j <= vps.getVpsNumRepFormatsMinus1(); j++ ) 1696 { 1697 TComRepFormat* repFormat = new TComRepFormat; 1698 1699 repFormat->setBitDepthVpsChromaMinus8 ( g_bitDepthC - 8 ); 1700 repFormat->setBitDepthVpsLumaMinus8 ( g_bitDepthY - 8 ); 1701 repFormat->setChromaFormatVpsIdc ( j == 1 ? CHROMA_400 : CHROMA_420 ); 1702 repFormat->setPicHeightVpsInLumaSamples ( m_iSourceHeight ); 1703 repFormat->setPicWidthVpsInLumaSamples ( m_iSourceWidth ); 1704 repFormat->setChromaAndBitDepthVpsPresentFlag( true ); 1705 // ToDo not supported yet. 1706 //repFormat->setSeparateColourPlaneVpsFlag( ); 1707 #if H_MV_FIX_CONF_WINDOW 1708 Bool conformanceWindowVpsFlag = ( m_confWinBottom != 0 ) || ( m_confWinRight != 0 ) || ( m_confWinTop != 0 ) || ( m_confWinBottom != 0 ); 1709 repFormat->setConformanceWindowVpsFlag( conformanceWindowVpsFlag ); 1710 if ( conformanceWindowVpsFlag ) 1711 { 1712 repFormat->setConfWinVpsLeftOffset ( m_confWinLeft / TComSPS::getWinUnitX( repFormat->getChromaFormatVpsIdc() ) ); 1713 repFormat->setConfWinVpsRightOffset ( m_confWinRight / TComSPS::getWinUnitX( repFormat->getChromaFormatVpsIdc() ) ); 1714 repFormat->setConfWinVpsTopOffset ( m_confWinTop / TComSPS::getWinUnitY( repFormat->getChromaFormatVpsIdc() ) ); 1715 repFormat->setConfWinVpsBottomOffset ( m_confWinBottom / TComSPS::getWinUnitY( repFormat->getChromaFormatVpsIdc() ) ); 1716 } 1717 #else 1718 repFormat->setConformanceWindowVpsFlag( true ); 1719 repFormat->setConfWinVpsLeftOffset ( m_confWinLeft / TComSPS::getWinUnitX( repFormat->getChromaFormatVpsIdc() ) ); 1720 repFormat->setConfWinVpsRightOffset ( m_confWinRight / TComSPS::getWinUnitX( repFormat->getChromaFormatVpsIdc() ) ); 1721 repFormat->setConfWinVpsTopOffset ( m_confWinTop / TComSPS::getWinUnitY( repFormat->getChromaFormatVpsIdc() ) ); 1722 repFormat->setConfWinVpsBottomOffset ( m_confWinBottom / TComSPS::getWinUnitY( repFormat->getChromaFormatVpsIdc() ) ); 1723 #endif 1724 assert( vps.getRepFormat( j ) == NULL ); 1725 vps.setRepFormat( j , repFormat ); 1726 }; 1727 1728 1729 #else 1683 1730 vps.setRepFormatIdxPresentFlag( false ); 1684 1731 vps.setVpsNumRepFormatsMinus1 ( 0 ); … … 1709 1756 assert( vps.getRepFormat( 0 ) == NULL ); 1710 1757 vps.setRepFormat( 0 , repFormat ); 1758 #endif 1711 1759 } 1712 1760 -
branches/HTM-13.1-dev0/source/Lib/TLibCommon/TComDataCU.cpp
r1164 r1169 2446 2446 Void TComDataCU::setCbfSubParts( UInt uiCbfY, UInt uiCbfU, UInt uiCbfV, UInt uiAbsPartIdx, UInt uiDepth ) 2447 2447 { 2448 #if H_3D_DISABLE_CHROMA 2449 if( this->getSlice()->getIsDepth() ) 2450 { 2451 uiCbfU = 0; 2452 uiCbfV = 0; 2453 } 2454 #endif 2448 2455 UInt uiCurrPartNumb = m_pcPic->getNumPartInCU() >> (uiDepth << 1); 2449 2456 memset( m_puhCbf[0] + uiAbsPartIdx, uiCbfY, sizeof( UChar ) * uiCurrPartNumb ); … … 2454 2461 Void TComDataCU::setCbfSubParts( UInt uiCbf, TextType eTType, UInt uiAbsPartIdx, UInt uiDepth ) 2455 2462 { 2463 #if H_3D_DISABLE_CHROMA 2464 assert( getSlice() != NULL ); 2465 if( this->getSlice()->getIsDepth() && g_aucConvertTxtTypeToIdx[eTType] > 0 ) 2466 { 2467 uiCbf = 0; 2468 } 2469 #endif 2470 2456 2471 UInt uiCurrPartNumb = m_pcPic->getNumPartInCU() >> (uiDepth << 1); 2457 2472 memset( m_puhCbf[g_aucConvertTxtTypeToIdx[eTType]] + uiAbsPartIdx, uiCbf, sizeof( UChar ) * uiCurrPartNumb ); … … 2468 2483 Void TComDataCU::setCbfSubParts ( UInt uiCbf, TextType eTType, UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth ) 2469 2484 { 2485 #if H_3D_DISABLE_CHROMA 2486 assert( getSlice() != NULL ); 2487 if( this->getSlice()->getIsDepth() && g_aucConvertTxtTypeToIdx[eTType] > 0 ) 2488 { 2489 uiCbf = 0; 2490 } 2491 #endif 2470 2492 setSubPart<UChar>( uiCbf, m_puhCbf[g_aucConvertTxtTypeToIdx[eTType]], uiAbsPartIdx, uiDepth, uiPartIdx ); 2471 2493 } -
branches/HTM-13.1-dev0/source/Lib/TLibCommon/TComDataCU.h
r1164 r1169 313 313 TComPic* getPic () { return m_pcPic; } 314 314 TComSlice* getSlice () { return m_pcSlice; } 315 #if H_3D_DISABLE_CHROMA 316 Void setSlice ( TComSlice* pcSlice) { m_pcSlice = pcSlice; } 317 #endif 315 318 UInt& getAddr () { return m_uiCUAddr; } 316 319 UInt& getZorderIdxInCU () { return m_uiAbsIdxInLCU; } … … 433 436 Pel*& getPCMSampleCr () { return m_pcIPCMSampleCr; } 434 437 438 #if H_3D_DISABLE_CHROMA 439 UChar getCbf ( UInt uiIdx, TextType eType ) { assert( getSlice() != NULL ); assert( g_aucConvertTxtTypeToIdx[eType] == 0 || !getSlice()->getIsDepth() || m_puhCbf[g_aucConvertTxtTypeToIdx[eType]][uiIdx] == 0 ); return m_puhCbf[g_aucConvertTxtTypeToIdx[eType]][uiIdx]; } 440 UChar* getCbf ( TextType eType ) { assert( getSlice() != NULL ); assert( g_aucConvertTxtTypeToIdx[eType] == 0 || !getSlice()->getIsDepth() || m_puhCbf[g_aucConvertTxtTypeToIdx[eType]] ); return m_puhCbf[g_aucConvertTxtTypeToIdx[eType]]; } 441 #else 435 442 UChar getCbf ( UInt uiIdx, TextType eType ) { return m_puhCbf[g_aucConvertTxtTypeToIdx[eType]][uiIdx]; } 436 443 UChar* getCbf ( TextType eType ) { return m_puhCbf[g_aucConvertTxtTypeToIdx[eType]]; } 444 #endif 437 445 UChar getCbf ( UInt uiIdx, TextType eType, UInt uiTrDepth ) { return ( ( getCbf( uiIdx, eType ) >> uiTrDepth ) & 0x1 ); } 446 #if H_3D_DISABLE_CHROMA 447 Void setCbf ( UInt uiIdx, TextType eType, UChar uh ) { assert( getSlice() != NULL ); m_puhCbf[g_aucConvertTxtTypeToIdx[eType]][uiIdx] = ( g_aucConvertTxtTypeToIdx[eType] > 0 && getSlice()->getIsDepth() ) ? 0 : uh ; } 448 #else 438 449 Void setCbf ( UInt uiIdx, TextType eType, UChar uh ) { m_puhCbf[g_aucConvertTxtTypeToIdx[eType]][uiIdx] = uh; } 450 #endif 439 451 Void clearCbf ( UInt uiIdx, TextType eType, UInt uiNumParts ); 440 452 UChar getQtRootCbf ( UInt uiIdx ) { return getCbf( uiIdx, TEXT_LUMA, 0 ) || getCbf( uiIdx, TEXT_CHROMA_U, 0 ) || getCbf( uiIdx, TEXT_CHROMA_V, 0 ); } -
branches/HTM-13.1-dev0/source/Lib/TLibCommon/TComRom.cpp
r1164 r1169 391 391 Bool g_tracePU = false; 392 392 Bool g_traceTU = false; 393 Bool g_disableNumbering = true; 393 394 Bool g_disableHLSTrace = false; 394 395 UInt64 g_stopAtCounter = 0; … … 633 634 std::cout << "Break point here." << std::endl; 634 635 } 635 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 636 if ( !g_disableNumbering ) 637 { 638 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 639 } 636 640 fprintf( g_hTrace, "%-50s : %d\n", symbolName, val ); 637 641 fflush ( g_hTrace ); … … 770 774 771 775 #if SHARP_DMM_CLEAN_K0042 772 posEnd = racWedgeList.size();776 posEnd = (Int) racWedgeList.size(); 773 777 if (uiOri == 0 || uiOri == 4) 774 778 { -
branches/HTM-13.1-dev0/source/Lib/TLibCommon/TComRom.h
r1084 r1169 257 257 extern Bool g_traceTU; 258 258 extern Bool g_disableHLSTrace; // USE g_HLSTraceEnable to toggle HLS trace. Not this one! 259 extern Bool g_disableNumbering; // Don't print numbers to trace file 259 260 extern UInt64 g_stopAtCounter; // Counter to set breakpoint. 260 261 extern Bool g_traceCopyBack; // Output samples on copy back -
branches/HTM-13.1-dev0/source/Lib/TLibCommon/TComSlice.h
r1163 r1169 1772 1772 Void setChromaFormatIdc (Int i) { m_chromaFormatIdc = i; } 1773 1773 1774 #if H_3D_DISABLE_CHROMA 1775 static Int getWinUnitX (Int chromaFormatIdc) { assert (chromaFormatIdc >= 0 && chromaFormatIdc <= MAX_CHROMA_FORMAT_IDC); return m_winUnitX[chromaFormatIdc]; } 1776 static Int getWinUnitY (Int chromaFormatIdc) { assert (chromaFormatIdc >= 0 && chromaFormatIdc <= MAX_CHROMA_FORMAT_IDC); return m_winUnitY[chromaFormatIdc]; } 1777 #else 1774 1778 static Int getWinUnitX (Int chromaFormatIdc) { assert (chromaFormatIdc > 0 && chromaFormatIdc <= MAX_CHROMA_FORMAT_IDC); return m_winUnitX[chromaFormatIdc]; } 1775 1779 static Int getWinUnitY (Int chromaFormatIdc) { assert (chromaFormatIdc > 0 && chromaFormatIdc <= MAX_CHROMA_FORMAT_IDC); return m_winUnitY[chromaFormatIdc]; } 1780 #endif 1776 1781 1777 1782 // structure -
branches/HTM-13.1-dev0/source/Lib/TLibCommon/TypeDef.h
r1167 r1169 67 67 #if H_MV 68 68 #define SONY_MV_V_CONST_C0078 1 // Control disparity vector search range via configuration file 69 #define H_MV_FIX_CONF_WINDOW 1 69 70 #endif 70 71 … … 80 81 81 82 #if H_MV 82 #define H_MV_ENC_DEC_TRAC 1//< CU/PU level tracking83 #define H_MV_ENC_DEC_TRAC 0 //< CU/PU level tracking 83 84 #endif 84 85 … … 326 327 327 328 #define FIX_TICKET_95 1 // pps_scaling_list_ref_layer_id parsing 329 #define H_3D_DISABLE_CHROMA 1 328 330 329 331 #if H_3D -
branches/HTM-13.1-dev0/source/Lib/TLibDecoder/SyntaxElementParser.cpp
r872 r1169 54 54 return; 55 55 } 56 #endif 57 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 56 if ( !g_disableNumbering ) 57 { 58 #endif 59 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 60 #if H_MV_ENC_DEC_TRAC 61 } 62 #endif 63 58 64 if (length < 10) 59 65 { … … 75 81 return; 76 82 } 77 #endif 78 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 83 if ( !g_disableNumbering ) 84 { 85 #endif 86 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 87 #if H_MV_ENC_DEC_TRAC 88 } 89 #endif 79 90 fprintf( g_hTrace, "%-50s ue(v) : %u\n", pSymbolName, rValue ); 80 91 fflush ( g_hTrace ); … … 89 100 return; 90 101 } 91 #endif 92 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 102 if ( !g_disableNumbering ) 103 { 104 #endif 105 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 106 #if H_MV_ENC_DEC_TRAC 107 } 108 #endif 109 93 110 fprintf( g_hTrace, "%-50s se(v) : %d\n", pSymbolName, rValue ); 94 111 fflush ( g_hTrace ); … … 103 120 return; 104 121 } 105 #endif 106 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 122 if ( !g_disableNumbering ) 123 { 124 #endif 125 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 126 #if H_MV_ENC_DEC_TRAC 127 } 128 #endif 107 129 fprintf( g_hTrace, "%-50s u(1) : %d\n", pSymbolName, rValue ); 108 130 fflush ( g_hTrace ); -
branches/HTM-13.1-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp
r1167 r1169 777 777 assert(uiCode <= 3); 778 778 // 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 779 #if !H_3D_DISABLE_CHROMA 779 780 assert (uiCode == 1); 781 #endif 780 782 if( uiCode == 3 ) 781 783 { … … 1477 1479 for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 1 : 0; i <= pcVPS->getMaxLayersMinus1(); i++ ) 1478 1480 { 1479 1481 READ_CODE( pcVPS->getVpsRepFormatIdxLen(), uiCode, "vps_rep_format_idx[i]" ); pcVPS->setVpsRepFormatIdx( i, uiCode ); 1480 1482 } 1481 1483 } … … 2119 2121 } 2120 2122 // in the first version chroma_format_idc is equal to one, thus colour_plane_id will not be present 2123 2124 #if H_3D_DISABLE_CHROMA 2125 assert (sps->getChromaFormatIdc() == 1 || rpcSlice->getIsDepth() ); 2126 assert (sps->getChromaFormatIdc() == 0 || !rpcSlice->getIsDepth() ); 2127 #else 2121 2128 assert (sps->getChromaFormatIdc() == 1 ); 2129 #endif 2122 2130 // if( separate_colour_plane_flag == 1 ) 2123 2131 // colour_plane_id u(2) … … 2420 2428 { 2421 2429 READ_FLAG(uiCode, "slice_sao_luma_flag"); rpcSlice->setSaoEnabledFlag((Bool)uiCode); 2430 #if H_3D_DISABLE_CHROMA 2431 if( !rpcSlice->getIsDepth() ) 2432 { 2422 2433 READ_FLAG(uiCode, "slice_sao_chroma_flag"); rpcSlice->setSaoEnabledFlagChroma((Bool)uiCode); 2434 } 2435 else 2436 { 2437 rpcSlice->setSaoEnabledFlagChroma( false ); 2438 } 2439 2440 #else 2441 READ_FLAG(uiCode, "slice_sao_chroma_flag"); rpcSlice->setSaoEnabledFlagChroma((Bool)uiCode); 2442 #endif 2423 2443 } 2424 2444 … … 3165 3185 { 3166 3186 wpScalingParam *wp; 3187 #if H_3D_DISABLE_CHROMA 3188 Bool bChroma = !pcSlice->getIsDepth(); 3189 #else 3167 3190 Bool bChroma = true; // color always present in HEVC ? 3191 #endif 3168 3192 SliceType eSliceType = pcSlice->getSliceType(); 3169 3193 Int iNbRef = (eSliceType == B_SLICE ) ? (2) : (1); 3170 3194 UInt uiLog2WeightDenomLuma, uiLog2WeightDenomChroma; 3171 3195 UInt uiTotalSignalledWeightFlags = 0; 3172 3196 3173 3197 Int iDeltaDenom; 3174 3198 // decode delta_luma_log2_weight_denom : … … 3182 3206 uiLog2WeightDenomChroma = (UInt)(iDeltaDenom + uiLog2WeightDenomLuma); 3183 3207 } 3208 else 3209 #if H_3D_DISABLE_CHROMA 3210 { 3211 uiLog2WeightDenomChroma = 0; 3212 } 3213 #endif 3214 3184 3215 3185 3216 for ( Int iNumRef=0 ; iNumRef<iNbRef ; iNumRef++ ) -
branches/HTM-13.1-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp
r1163 r1169 176 176 decodeIntraDirModeLuma ( pcCU, uiAbsPartIdx, uiDepth ); 177 177 #if H_3D_DIM_SDC 178 #if H_3D_DISABLE_CHROMA 179 if(!pcCU->getSDCFlag(uiAbsPartIdx) && !pcCU->getSlice()->getIsDepth() ) 180 #else 178 181 if(!pcCU->getSDCFlag(uiAbsPartIdx)) 182 #endif 179 183 #endif 180 184 decodeIntraDirModeChroma( pcCU, uiAbsPartIdx, uiDepth ); … … 541 545 Void TDecEntropy::xDecodeTransform( TComDataCU* pcCU, UInt offsetLuma, UInt offsetChroma, UInt uiAbsPartIdx, UInt uiDepth, UInt width, UInt height, UInt uiTrIdx, Bool& bCodeDQP, Int quadtreeTULog2MinSizeInCU) 542 546 { 547 548 #if H_MV_ENC_DEC_TRAC 549 UInt uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiAbsPartIdx] ]; 550 UInt uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiAbsPartIdx] ]; 551 552 DTRACE_TU_S("=========== transform_tree ===========\n") 553 DTRACE_TU("x0", uiLPelX) 554 DTRACE_TU("x1", uiTPelY) 555 DTRACE_TU("log2TrafoSize", g_uiMaxCUWidth>>uiDepth) 556 DTRACE_TU("trafoDepth" , uiDepth) 557 #endif 558 543 559 UInt uiSubdiv; 544 560 const UInt uiLog2TrafoSize = g_aucConvertToBit[pcCU->getSlice()->getSPS()->getMaxCUWidth()]+2 - uiDepth; … … 593 609 if( bFirstCbfOfCU || uiLog2TrafoSize > 2 ) 594 610 { 611 #if H_3D_DISABLE_CHROMA 612 if (!pcCU->getSlice()->getIsDepth() ) 613 { 595 614 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth - 1 ) ) 596 615 { … … 601 620 m_pcEntropyDecoderIf->parseQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth, uiDepth ); 602 621 } 622 } 623 else 624 { 625 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth - 1 ) ) 626 { 627 pcCU->setCbfSubParts( 0, TEXT_CHROMA_U, uiAbsPartIdx, uiTrDepth - 1 ); 628 } 629 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth - 1 ) ) 630 { 631 pcCU->setCbfSubParts( 0, TEXT_CHROMA_V, uiAbsPartIdx, uiTrDepth - 1 ); 632 } 633 } 634 #else 635 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth - 1 ) ) 636 { 637 m_pcEntropyDecoderIf->parseQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth, uiDepth ); 638 } 639 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth - 1 ) ) 640 { 641 m_pcEntropyDecoderIf->parseQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth, uiDepth ); 642 } 643 #endif 603 644 } 604 645 else … … 762 803 assert( pcCU->getTransformIdx(uiAbsPartIdx) == 0 ); 763 804 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_LUMA) == 1 ); 805 #if H_3D_DISABLE_CHROMA 806 if (!pcCU->getSlice()->getIsDepth() ) 807 { 808 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 ); 809 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 ); 810 } 811 #else 764 812 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 ); 765 813 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 ); 814 #endif 766 815 } 767 816 -
branches/HTM-13.1-dev0/source/Lib/TLibDecoder/TDecSbac.cpp
r1163 r1169 501 501 } 502 502 503 504 #if H_3D_DISABLE_CHROMA 505 if( !pcCU->getSlice()->getIsDepth() ) 506 { 507 #endif 503 508 piPCMSample = pcCU->getPCMSampleCb() + uiChromaOffset; 504 509 uiWidth = pcCU->getWidth(uiAbsPartIdx)/2; … … 532 537 piPCMSample += uiWidth; 533 538 } 539 #if H_3D_DISABLE_CHROMA 540 } 541 #endif 542 534 543 535 544 m_pcTDecBinIf->start(); … … 1366 1375 DTRACE_CABAC_V( uiLog2TransformBlockSize ) 1367 1376 DTRACE_CABAC_T( "\n" ) 1377 #else 1378 DTRACE_TU("split_transform_flag", ruiSubdivFlag ) 1368 1379 #endif 1369 1380 } … … 1444 1455 DTRACE_CABAC_V( uiAbsPartIdx ) 1445 1456 DTRACE_CABAC_T( "\n" ) 1457 #else 1458 if ( eType == TEXT_CHROMA_U ) 1459 { 1460 DTRACE_TU("cbf_cb", uiSymbol ) 1461 } 1462 else if ( eType == TEXT_CHROMA_V ) 1463 { 1464 DTRACE_TU("cbf_cr", uiSymbol ) 1465 } 1466 else 1467 { 1468 DTRACE_TU("cbf_luma", uiSymbol ) 1469 } 1446 1470 #endif 1447 1471 -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/SyntaxElementWriter.cpp
r872 r1169 49 49 if( g_HLSTraceEnable ) 50 50 { 51 #if H_MV_ENC_DEC_TRAC 52 if ( !g_disableNumbering ) 53 { 54 #endif 51 55 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 56 #if H_MV_ENC_DEC_TRAC 57 } 58 #endif 59 52 60 if( length<10 ) 53 61 { … … 66 74 if( g_HLSTraceEnable ) 67 75 { 76 #if H_MV_ENC_DEC_TRAC 77 if ( !g_disableNumbering ) 78 { 79 #endif 68 80 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 81 #if H_MV_ENC_DEC_TRAC 82 } 83 #endif 84 69 85 fprintf( g_hTrace, "%-50s ue(v) : %d\n", pSymbolName, value ); 70 86 } … … 76 92 if( g_HLSTraceEnable ) 77 93 { 94 #if H_MV_ENC_DEC_TRAC 95 if ( !g_disableNumbering ) 96 { 97 #endif 78 98 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 99 #if H_MV_ENC_DEC_TRAC 100 } 101 #endif 102 79 103 fprintf( g_hTrace, "%-50s se(v) : %d\n", pSymbolName, value ); 80 104 } … … 86 110 if( g_HLSTraceEnable ) 87 111 { 112 #if H_MV_ENC_DEC_TRAC 113 if ( !g_disableNumbering ) 114 { 115 #endif 88 116 fprintf( g_hTrace, "%8lld ", g_nSymbolCounter++ ); 117 #if H_MV_ENC_DEC_TRAC 118 } 119 #endif 89 120 fprintf( g_hTrace, "%-50s u(1) : %d\n", pSymbolName, value ); 90 121 } -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
r1167 r1169 678 678 #endif 679 679 WRITE_UVLC( pcSPS->getChromaFormatIdc (), "chroma_format_idc" ); 680 #if !H_3D_DISABLE_CHROMA 680 681 assert(pcSPS->getChromaFormatIdc () == 1); 682 #endif 681 683 // in the first version chroma_format_idc can only be equal to 1 (4:2:0) 682 684 if( pcSPS->getChromaFormatIdc () == 3 ) … … 1376 1378 if ( pcRepFormat->getChromaAndBitDepthVpsPresentFlag() ) 1377 1379 { 1378 WRITE_CODE( pcRepFormat->getChromaFormatVpsIdc( ), 2, "chroma_format_vps_idc" );1379 1380 if ( pcRepFormat->getChromaFormatVpsIdc() == 3 )1381 {1382 WRITE_FLAG( pcRepFormat->getSeparateColourPlaneVpsFlag( ) ? 1 : 0 , "separate_colour_plane_vps_flag" );1383 }1384 WRITE_CODE( pcRepFormat->getBitDepthVpsLumaMinus8( ), 4, "bit_depth_vps_luma_minus8" );1385 WRITE_CODE( pcRepFormat->getBitDepthVpsChromaMinus8( ), 4, "bit_depth_vps_chroma_minus8" );1380 WRITE_CODE( pcRepFormat->getChromaFormatVpsIdc( ), 2, "chroma_format_vps_idc" ); 1381 1382 if ( pcRepFormat->getChromaFormatVpsIdc() == 3 ) 1383 { 1384 WRITE_FLAG( pcRepFormat->getSeparateColourPlaneVpsFlag( ) ? 1 : 0 , "separate_colour_plane_vps_flag" ); 1385 } 1386 WRITE_CODE( pcRepFormat->getBitDepthVpsLumaMinus8( ), 4, "bit_depth_vps_luma_minus8" ); 1387 WRITE_CODE( pcRepFormat->getBitDepthVpsChromaMinus8( ), 4, "bit_depth_vps_chroma_minus8" ); 1386 1388 } 1387 1389 else … … 1732 1734 1733 1735 // in the first version chroma_format_idc is equal to one, thus colour_plane_id will not be present 1736 #if H_3D_DISABLE_CHROMA 1737 assert (pcSlice->getSPS()->getChromaFormatIdc() == 1 || pcSlice->getIsDepth() ); 1738 assert (pcSlice->getSPS()->getChromaFormatIdc() == 0 || !pcSlice->getIsDepth() ); 1739 #else 1734 1740 assert (pcSlice->getSPS()->getChromaFormatIdc() == 1 ); 1741 #endif 1735 1742 // if( separate_colour_plane_flag == 1 ) 1736 1743 // colour_plane_id u(2) … … 1911 1918 { 1912 1919 WRITE_FLAG( pcSlice->getSaoEnabledFlag(), "slice_sao_luma_flag" ); 1920 #if H_3D_DISABLE_CHROMA 1921 if ( !pcSlice->getIsDepth() ) 1922 { 1913 1923 WRITE_FLAG( pcSlice->getSaoEnabledFlagChroma(), "slice_sao_chroma_flag" ); 1924 } 1925 #else 1926 WRITE_FLAG( pcSlice->getSaoEnabledFlagChroma(), "slice_sao_chroma_flag" ); 1927 #endif 1914 1928 } 1915 1929 } … … 2564 2578 { 2565 2579 wpScalingParam *wp; 2580 #if H_3D_DISABLE_CHROMA 2581 Bool bChroma = !pcSlice->getIsDepth(); // color always present in HEVC ? 2582 #else 2566 2583 Bool bChroma = true; // color always present in HEVC ? 2584 #endif 2567 2585 Int iNbRef = (pcSlice->getSliceType() == B_SLICE ) ? (2) : (1); 2568 2586 Bool bDenomCoded = false; -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncCu.cpp
r1164 r1169 275 275 m_ppcTempCU[0]->initCU( rpcCU->getPic(), rpcCU->getAddr() ); 276 276 277 #if H_3D_DISABLE_CHROMA 278 m_ppcWeightedTempCU[0]->initCU( rpcCU->getPic(), rpcCU->getAddr() ); 279 #endif 280 277 281 #if KWU_RC_MADPRED_E0227 278 282 m_LCUPredictionSAD = 0; … … 1249 1253 TComDataCU* pcSubTempPartCU = m_ppcTempCU[uhNextDepth]; 1250 1254 1255 #if H_3D_DISABLE_CHROMA 1256 m_ppcWeightedTempCU[uhNextDepth]->setSlice( m_ppcWeightedTempCU[ uiDepth]->getSlice()); 1257 #endif 1251 1258 for ( UInt uiPartUnitIdx = 0; uiPartUnitIdx < 4; uiPartUnitIdx++ ) 1252 1259 { … … 2792 2799 2793 2800 #if H_3D_DIM_SDC 2801 #if 0 // H_3D_DISABLE_CHROMA 2802 if( !rpcTempCU->getSDCFlag( 0 ) && !rpcTempCU->getSlice()->getIsDepth() ) 2803 #else 2794 2804 if( !rpcTempCU->getSDCFlag( 0 ) ) 2805 #endif 2795 2806 #endif 2796 2807 m_pcPredSearch ->estIntraPredChromaQT( rpcTempCU, m_ppcOrigYuv[uiDepth], m_ppcPredYuvTemp[uiDepth], m_ppcResiYuvTemp[uiDepth], m_ppcRecoYuvTemp[uiDepth], uiPreCalcDistC ); -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp
r1163 r1169 304 304 Void TEncEntropy::xEncodeTransform( TComDataCU* pcCU,UInt offsetLuma, UInt offsetChroma, UInt uiAbsPartIdx, UInt uiDepth, UInt width, UInt height, UInt uiTrIdx, Bool& bCodeDQP ) 305 305 { 306 307 #if H_MV_ENC_DEC_TRAC 308 UInt uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiAbsPartIdx] ]; 309 UInt uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiAbsPartIdx] ]; 310 311 DTRACE_TU_S("=========== transform_tree ===========\n") 312 DTRACE_TU("x0", uiLPelX) 313 DTRACE_TU("x1", uiTPelY) 314 DTRACE_TU("log2TrafoSize", g_uiMaxCUWidth>>uiDepth) 315 DTRACE_TU("trafoDepth" , uiDepth) 316 #endif 317 306 318 const UInt uiSubdiv = pcCU->getTransformIdx( uiAbsPartIdx ) + pcCU->getDepth( uiAbsPartIdx ) > uiDepth; 307 319 const UInt uiLog2TrafoSize = g_aucConvertToBit[pcCU->getSlice()->getSPS()->getMaxCUWidth()]+2 - uiDepth; … … 366 378 if( bFirstCbfOfCU || uiLog2TrafoSize > 2 ) 367 379 { 380 #if H_3D_DISABLE_CHROMA 381 if (!pcCU->getSlice()->getIsDepth() ) 382 { 383 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepthCurr - 1 ) ) 384 { 385 m_pcEntropyCoderIf->codeQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepthCurr ); 386 } 387 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepthCurr - 1 ) ) 388 { 389 m_pcEntropyCoderIf->codeQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepthCurr ); 390 } 391 } 392 else 393 { 394 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepthCurr - 1 ) ) 395 { 396 assert( pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepthCurr ) == 0 ); 397 } 398 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepthCurr - 1 ) ) 399 { 400 assert( pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepthCurr ) == 0 ); 401 } 402 } 403 #else 368 404 if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepthCurr - 1 ) ) 369 405 { … … 374 410 m_pcEntropyCoderIf->codeQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepthCurr ); 375 411 } 412 #endif 376 413 } 377 414 else if( uiLog2TrafoSize == 2 ) … … 506 543 encodeIntraDirModeLuma ( pcCU, uiAbsPartIdx,true ); 507 544 #if H_3D_DIM_SDC 545 #if H_3D_DISABLE_CHROMA 546 if(!pcCU->getSDCFlag(uiAbsPartIdx) && !pcCU->getSlice()->getIsDepth() ) 547 #else 508 548 if(!pcCU->getSDCFlag(uiAbsPartIdx)) 549 #endif 509 550 #endif 510 551 encodeIntraDirModeChroma( pcCU, uiAbsPartIdx, bRD ); … … 685 726 assert( pcCU->getTransformIdx(uiAbsPartIdx) == 0 ); 686 727 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_LUMA) == 1 ); 728 #if H_3D_DISABLE_CHROMA 729 if (!pcCU->getSlice()->getIsDepth() ) 730 { 731 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 ); 732 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 ); 733 } 734 #else 687 735 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 ); 688 736 assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 ); 689 } 737 #endif 738 } 739 690 740 691 741 if( pcCU->getSDCFlag( uiAbsPartIdx ) && !pcCU->isIntra( uiAbsPartIdx ) ) -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncGOP.cpp
r1133 r1169 1950 1950 m_pcSAO->PCMLFDisableProcess(pcPic); 1951 1951 1952 #if H_3D_DISABLE_CHROMA 1953 if (pcSlice->getIsDepth()) 1954 { 1955 sliceEnabled[SAO_Cb] = false; 1956 sliceEnabled[SAO_Cr] = false; 1957 } 1958 #endif 1952 1959 //assign SAO slice header 1953 1960 for(Int s=0; s< uiNumSlices; s++) -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncSbac.cpp
r1163 r1169 1095 1095 DTRACE_CABAC_V( uiCtx ) 1096 1096 DTRACE_CABAC_T( "\n" ) 1097 #endif 1097 #else 1098 DTRACE_TU("split_transform_flag", uiSymbol ) 1099 #endif 1100 1098 1101 } 1099 1102 … … 1426 1429 DTRACE_CABAC_V( uiAbsPartIdx ) 1427 1430 DTRACE_CABAC_T( "\n" ) 1431 #else 1432 if ( eType == TEXT_CHROMA_U ) 1433 { 1434 DTRACE_TU("cbf_cb", uiCbf ) 1435 } 1436 else if ( eType == TEXT_CHROMA_V ) 1437 { 1438 DTRACE_TU("cbf_cr", uiCbf ) 1439 } 1440 else 1441 { 1442 DTRACE_TU("cbf_luma", uiCbf ) 1443 } 1428 1444 #endif 1429 1445 } … … 1501 1517 } 1502 1518 1519 #if H_3D_DISABLE_CHROMA 1520 if( !pcCU->getSlice()->getIsDepth() ) 1521 { 1522 #endif 1503 1523 piPCMSample = pcCU->getPCMSampleCb() + uiChromaOffset; 1504 1524 uiWidth = pcCU->getWidth(uiAbsPartIdx)/2; … … 1532 1552 piPCMSample += uiWidth; 1533 1553 } 1554 #if H_3D_DISABLE_CHROMA 1555 } 1556 #endif 1534 1557 m_pcBinIf->resetBac(); 1535 1558 } -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncSearch.cpp
r1166 r1169 7335 7335 const UInt uiQTTempAccessLayer = pcCU->getSlice()->getSPS()->getQuadtreeTULog2MaxSize() - uiLog2TrSize; 7336 7336 7337 #if 0 //H_3D_DISABLE_CHROMA 7338 Bool bCodeChroma = !pcCU->getSlice()->getIsDepth(); 7339 #else 7337 7340 Bool bCodeChroma = true; 7341 #endif 7338 7342 UInt uiTrModeC = uiTrMode; 7339 7343 UInt uiLog2TrSizeC = uiLog2TrSize-1; -
branches/HTM-13.1-dev0/source/Lib/TLibEncoder/TEncTop.cpp
r1164 r1169 766 766 } 767 767 #endif 768 } 768 } 769 769 m_cSPS.setSpsExtensionPresentFlag ( true ); 770 770 m_cSPS.setSpsMultilayerExtensionFlag ( true ); … … 779 779 m_cSPS.setMaxCUHeight ( g_uiMaxCUHeight ); 780 780 m_cSPS.setMaxCUDepth ( g_uiMaxCUDepth ); 781 #if H_3D_DISABLE_CHROMA 782 m_cSPS.setChromaFormatIdc( getIsDepth() ? CHROMA_400 : CHROMA_420 ); 783 #endif 781 784 782 785 Int minCUSize = m_cSPS.getMaxCUWidth() >> ( m_cSPS.getMaxCUDepth()-g_uiAddCUDepth );
Note: See TracChangeset for help on using the changeset viewer.