Changeset 1440 in SHVCSoftware
- Timestamp:
- 12 Aug 2015, 20:19:52 (9 years ago)
- Location:
- branches/SHM-dev/source/Lib
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-dev/source/Lib/TLibCommon/TCom3DAsymLUT.h
r1335 r1440 63 63 TCom3DAsymLUT(); 64 64 virtual ~TCom3DAsymLUT(); 65 66 virtualVoid create( Int nMaxOctantDepth, Int nInputBitDepth, Int nInputBitDepthC, Int nOutputBitDepth, Int nOutputBitDepthC, Int nMaxYPartNumLog2, Int nAdaptCThresholdU, Int nAdaptCThresholdV );65 66 Void create( Int nMaxOctantDepth, Int nInputBitDepth, Int nInputBitDepthC, Int nOutputBitDepth, Int nOutputBitDepthC, Int nMaxYPartNumLog2, Int nAdaptCThresholdU, Int nAdaptCThresholdV ); 67 67 virtual Void destroy(); 68 68 -
branches/SHM-dev/source/Lib/TLibEncoder/TEnc3DAsymLUT.cpp
r1437 r1440 90 90 } 91 91 92 Void TEnc3DAsymLUT::create( Int nMaxOctantDepth , Int nInputBitDepth , Int nInputBitDepthC , Int nOutputBitDepth , Int nOutputBitDepthC, Int nMaxYPartNumLog2 )92 Void TEnc3DAsymLUT::create( Int nMaxOctantDepth, Int nInputBitDepth, Int nInputBitDepthC, Int nOutputBitDepth, Int nOutputBitDepthC, Int nMaxYPartNumLog2 ) 93 93 { 94 94 if( m_pColorInfo != NULL ) … … 97 97 } 98 98 99 TCom3DAsymLUT::create( nMaxOctantDepth , nInputBitDepth , nInputBitDepthC, nOutputBitDepth , nOutputBitDepthC, nMaxYPartNumLog2, 1 << ( nInputBitDepthC - 1 ), 1 << ( nInputBitDepthC - 1 ) );99 TCom3DAsymLUT::create( nMaxOctantDepth, nInputBitDepth, nInputBitDepthC, nOutputBitDepth, nOutputBitDepthC, nMaxYPartNumLog2, 1 << ( nInputBitDepthC - 1 ), 1 << ( nInputBitDepthC - 1 ) ); 100 100 101 101 xAllocate3DArray( m_pColorInfo , xGetYSize() , xGetUSize() , xGetVSize() ); … … 138 138 } 139 139 140 Double TEnc3DAsymLUT::xDeriveVertexPerColor( Double N , Double Ys , Double Yy , Double Yu , Double Yv , Double ys , Double us , Double vs , Double yy , Double yu , Double yv , Double uu , Double uv , Double vv , Double YY,141 Pel & rP0 , Pel & rP1 , Pel & rP3 , Pel & rP7, Int nResQuantBit )140 Double TEnc3DAsymLUT::xDeriveVertexPerColor( Double N, Double Ys, Double Yy, Double Yu, Double Yv, Double ys, Double us, Double vs, Double yy, Double yu, Double yv, Double uu, Double uv, Double vv, Double YY, 141 Pel & rP0, Pel & rP1, Pel & rP3, Pel & rP7, Int nResQuantBit ) 142 142 { 143 143 Int nInitP0 = rP0; … … 200 200 } 201 201 202 Double TEnc3DAsymLUT::estimateDistWithCur3DAsymLUT( TComPic * pCurPic 202 Double TEnc3DAsymLUT::estimateDistWithCur3DAsymLUT( TComPic * pCurPic, UInt refLayerIdc ) 203 203 { 204 204 xCollectData( pCurPic , refLayerIdc ); … … 236 236 237 237 #if R0179_ENC_OPT_3DLUT_SIZE 238 Double TEnc3DAsymLUT::derive3DAsymLUT( TComSlice * pSlice , TComPic * pCurPic , UInt refLayerIdc , TEncCfg * pCfg , Bool bSignalPPS, Bool bElRapSliceTypeB, Double dFrameLambda )238 Double TEnc3DAsymLUT::derive3DAsymLUT( TComSlice * pSlice, TComPic * pCurPic, UInt refLayerIdc, TEncCfg * pCfg, Bool bSignalPPS, Bool bElRapSliceTypeB, Double dFrameLambda ) 239 239 { 240 240 m_nLUTBitDepth = pCfg->getCGSLUTBit(); … … 355 355 356 356 // check res_quant_bits only for the best table size and best U/V threshold 357 if( !bUseNewColorInfo ) 357 if( !bUseNewColorInfo ) 358 { 358 359 xConsolidateData( &m_sLutSizes[iBestLUTSizeIdx], &sMaxLutSize ); 360 } 359 361 360 362 // xCollectData( pCurPic , refLayerIdc ); … … 403 405 #endif 404 406 405 Double TEnc3DAsymLUT::derive3DAsymLUT( TComSlice * pSlice , TComPic * pCurPic , UInt refLayerIdc , TEncCfg * pCfg , Bool bSignalPPS, Bool bElRapSliceTypeB )407 Double TEnc3DAsymLUT::derive3DAsymLUT( TComSlice * pSlice, TComPic * pCurPic, UInt refLayerIdc, TEncCfg * pCfg, Bool bSignalPPS, Bool bElRapSliceTypeB ) 406 408 { 407 409 m_nLUTBitDepth = pCfg->getCGSLUTBit(); … … 459 461 460 462 setResQuantBit( nBestResQuanBit ); 461 xUpdatePartitioning( nBestOctantDepth , nBestYPartNumLog2 , nBestAdaptCThresholdU, nBestAdaptCThresholdV );463 xUpdatePartitioning( nBestOctantDepth, nBestYPartNumLog2, nBestAdaptCThresholdU, nBestAdaptCThresholdV ); 462 464 463 465 xSaveCuboids( m_pBestEncCuboid ); … … 465 467 } 466 468 467 Double TEnc3DAsymLUT::xDeriveVertexes( Int nResQuanBit 469 Double TEnc3DAsymLUT::xDeriveVertexes( Int nResQuanBit, SCuboid *** pCurCuboid ) 468 470 { 469 471 Double dErrorLuma = 0 , dErrorChroma = 0; … … 519 521 } 520 522 521 Void TEnc3DAsymLUT::xCollectData( TComPic * pCurPic 523 Void TEnc3DAsymLUT::xCollectData( TComPic * pCurPic, UInt refLayerIdc ) 522 524 { 523 525 Pel * pSrcY = m_pDsOrigPic->getAddr(COMPONENT_Y); … … 659 661 } 660 662 661 Void TEnc3DAsymLUT::xDerivePartNumLog2( TComSlice * pSlice , TEncCfg * pcCfg , Int & rOctantDepth , Int & rYPartNumLog2 , Bool bSignalPPS, Bool bElRapSliceTypeB )663 Void TEnc3DAsymLUT::xDerivePartNumLog2( TComSlice * pSlice, TEncCfg * pcCfg, Int & rOctantDepth, Int & rYPartNumLog2, Bool bSignalPPS, Bool bElRapSliceTypeB ) 662 664 { 663 665 Int nPartNumLog2 = 4; … … 687 689 } 688 690 689 Void TEnc3DAsymLUT::xMapPartNum2DepthYPart( Int nPartNumLog2 , Int & rOctantDepth, Int & rYPartNumLog2 )691 Void TEnc3DAsymLUT::xMapPartNum2DepthYPart( Int nPartNumLog2, Int & rOctantDepth, Int & rYPartNumLog2 ) 690 692 { 691 693 for( Int y = getMaxYPartNumLog2() ; y >= 0 ; y-- ) … … 705 707 } 706 708 707 Void TEnc3DAsymLUT::updatePicCGSBits( TComSlice * pcSlice 709 Void TEnc3DAsymLUT::updatePicCGSBits( TComSlice * pcSlice, Int nPPSBit ) 708 710 { 709 711 for( Int i = 0; i < pcSlice->getActiveNumILRRefIdx(); i++ ) … … 735 737 Int iNumELFrameBits = m_nPrevELFrameBit[pSlice->getSliceType()][pSlice->getDepth()]; 736 738 737 xMapPartNum2DepthYPart( xGetMaxPartNumLog2() , iMaxCPartNumLog2, iMaxYPartNumLog2 );739 xMapPartNum2DepthYPart( xGetMaxPartNumLog2(), iMaxCPartNumLog2, iMaxYPartNumLog2 ); 738 740 iMaxAddYPartNumLog2 = iMaxYPartNumLog2; 739 741 iMaxYPartNumLog2 += iMaxCPartNumLog2; … … 762 764 } 763 765 764 Void TEnc3DAsymLUT::xCopyColorInfo( SColorInfo *** dst, SColorInfo *** src 766 Void TEnc3DAsymLUT::xCopyColorInfo( SColorInfo *** dst, SColorInfo *** src, SColorInfo *** dstC, SColorInfo *** srcC ) 765 767 { 766 768 Int yIdx, uIdx, vIdx; … … 815 817 } 816 818 817 xReset3DArray( m_pColorInfo ,1<<pMaxLUTSize->iYPartNumLog2, 1<<pMaxLUTSize->iCPartNumLog2, 1<<pMaxLUTSize->iCPartNumLog2 );818 xReset3DArray( m_pColorInfoC 819 xReset3DArray( m_pColorInfo, 1<<pMaxLUTSize->iYPartNumLog2, 1<<pMaxLUTSize->iCPartNumLog2, 1<<pMaxLUTSize->iCPartNumLog2 ); 820 xReset3DArray( m_pColorInfoC, 1<<pMaxLUTSize->iYPartNumLog2, 1<<pMaxLUTSize->iCPartNumLog2, 1<<pMaxLUTSize->iCPartNumLog2 ); 819 821 820 822 for(yIdx = 0; yIdx < nYSize; yIdx++) -
branches/SHM-dev/source/Lib/TLibEncoder/TEnc3DAsymLUT.h
r1432 r1440 111 111 virtual ~TEnc3DAsymLUT(); 112 112 113 virtual Void create( Int nMaxOctantDepth , Int nInputBitDepth , Int nInputBitDepthC , Int nOutputBitDepth , Int nOutputBitDepthC, Int nMaxYPartNumLog2 );114 virtual Void 115 Double derive3DAsymLUT( TComSlice * pSlice , TComPic * pCurPic , UInt refLayerIdc , TEncCfg * pCfg , Bool bSignalPPS, Bool bElRapSliceTypeB );113 Void create( Int nMaxOctantDepth, Int nInputBitDepth, Int nInputBitDepthC, Int nOutputBitDepth, Int nOutputBitDepthC, Int nMaxYPartNumLog2 ); 114 virtual Void destroy(); 115 Double derive3DAsymLUT( TComSlice * pSlice, TComPic * pCurPic, UInt refLayerIdc, TEncCfg * pCfg, Bool bSignalPPS, Bool bElRapSliceTypeB ); 116 116 Double estimateDistWithCur3DAsymLUT( TComPic * pCurPic , UInt refLayerIdc ); 117 117 #if R0179_ENC_OPT_3DLUT_SIZE
Note: See TracChangeset for help on using the changeset viewer.