Ticket #1276: ticket1276_r4158_proposed.patch
File ticket1276_r4158_proposed.patch, 1.6 KB (added by karlsharman, 10 years ago) |
---|
-
source/Lib/TLibEncoder/TEncCu.cpp
681 681 } 682 682 } 683 683 684 m_pcRDGoOnSbacCoder->load(m_pppcRDSbacCoder[uiDepth][CI_NEXT_BEST]); 684 685 m_pcEntropyCoder->resetBits(); 685 686 m_pcEntropyCoder->encodeSplitFlag( rpcBestCU, 0, uiDepth, true ); 686 687 rpcBestCU->getTotalBits() += m_pcEntropyCoder->getNumberOfWrittenBits(); // split bits 687 688 rpcBestCU->getTotalBins() += ((TEncBinCABAC *)((TEncSbac*)m_pcEntropyCoder->m_pcEntropyCoderIf)->getEncBinIf())->getBinsCoded(); 688 689 rpcBestCU->getTotalCost() = m_pcRdCost->calcRdCost( rpcBestCU->getTotalBits(), rpcBestCU->getTotalDistortion() ); 690 m_pcRDGoOnSbacCoder->store(m_pppcRDSbacCoder[uiDepth][CI_NEXT_BEST]); 689 691 690 692 // Early CU determination 691 693 if( m_pcEncCfg->getUseEarlyCU() && rpcBestCU->isSkipped(0) ) … … 793 795 } 794 796 } 795 797 798 m_pcRDGoOnSbacCoder->load(m_pppcRDSbacCoder[uhNextDepth][CI_NEXT_BEST]); 796 799 if( !bBoundary ) 797 800 { 798 801 m_pcEntropyCoder->resetBits(); … … 838 841 } 839 842 } 840 843 841 m_p ppcRDSbacCoder[uhNextDepth][CI_NEXT_BEST]->store(m_pppcRDSbacCoder[uiDepth][CI_TEMP_BEST]);844 m_pcRDGoOnSbacCoder->store(m_pppcRDSbacCoder[uiDepth][CI_TEMP_BEST]); 842 845 843 846 // TODO: this does not account for the slice bytes already written. See other instances of FIXED_NUMBER_OF_BYTES 844 847 Bool isEndOfSlice = rpcBestCU->getSlice()->getSliceMode()==FIXED_NUMBER_OF_BYTES