Changeset 840 in 3DVCSoftware for branches/HTM-10.0rc1-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp
- Timestamp:
- 8 Feb 2014, 15:29:19 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-10.0rc1-dev0/source/Lib/TLibEncoder/TEncEntropy.cpp
r837 r840 798 798 } 799 799 800 #if H_3D_INTER_SDC 801 #if QC_SDC_UNIFY_G0130 802 Void TEncEntropy::encodeDeltaDC ( TComDataCU* pcCU, UInt absPartIdx ) 803 { 804 m_pcEntropyCoderIf->codeDeltaDC( pcCU, absPartIdx ); 805 } 806 807 Void TEncEntropy::encodeSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD ) 808 { 809 if( ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->getSlice()->getVPS()->getInterSDCFlag( pcCU->getSlice()->getLayerIdInVps() ) ) || 810 ( pcCU->isIntra( uiAbsPartIdx ) && !pcCU->getSlice()->getVPS()->getVpsDepthModesFlag( pcCU->getSlice()->getLayerIdInVps() ) ) ) 811 { 812 return; 813 } 814 815 #if SEC_INTER_SDC_G0101 816 if( !pcCU->getSlice()->getIsDepth() || pcCU->getPartitionSize( uiAbsPartIdx ) != SIZE_2Nx2N || pcCU->isSkipped( uiAbsPartIdx ) ) 817 #else 818 if( !pcCU->getSlice()->getIsDepth() || ( pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) != SIZE_2Nx2N ) || pcCU->isSkipped( uiAbsPartIdx ) ) 819 #endif 820 { 821 return; 822 } 823 824 #if SEC_INTER_SDC_G0101 825 assert( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N || ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->isSkipped( uiAbsPartIdx ) ) ); 826 #else 827 assert( ( pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N ) || ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->isSkipped( uiAbsPartIdx ) ) ); 828 #endif 829 830 if( bRD ) 831 { 832 uiAbsPartIdx = 0; 833 } 834 835 m_pcEntropyCoderIf->codeSDCFlag( pcCU, uiAbsPartIdx ); 836 } 837 #else 838 Void TEncEntropy::encodeInterSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD ) 839 { 840 if( !pcCU->getSlice()->getVPS()->getInterSDCFlag( pcCU->getSlice()->getLayerIdInVps() ) ) 841 { 842 return; 843 } 844 845 if( !pcCU->getSlice()->getIsDepth() || pcCU->isIntra( uiAbsPartIdx ) || pcCU->isSkipped( uiAbsPartIdx ) ) 846 { 847 return; 848 } 849 850 if( bRD ) 851 { 852 uiAbsPartIdx = 0; 853 } 854 855 m_pcEntropyCoderIf->codeInterSDCFlag( pcCU, uiAbsPartIdx ); 856 } 857 858 Void TEncEntropy::encodeInterSDCResidualData( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD ) 859 { 860 if( !pcCU->getSlice()->getVPS()->getInterSDCFlag( pcCU->getSlice()->getLayerIdInVps() ) ) 861 { 862 return; 863 } 864 865 if( !pcCU->getSlice()->getIsDepth() || pcCU->isIntra( uiAbsPartIdx ) || !pcCU->getInterSDCFlag( uiAbsPartIdx ) ) 866 { 867 return; 868 } 869 870 if( bRD ) 871 { 872 uiAbsPartIdx = 0; 873 } 874 875 // number of segments depends on prediction mode for INTRA 876 UInt uiNumSegments = ( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N ) ? 1 : ( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_NxN ? 4 : 2 ); 877 878 // encode residual data for each segment 879 for( UInt uiSeg = 0; uiSeg < uiNumSegments; uiSeg++ ) 880 { 881 m_pcEntropyCoderIf->codeInterSDCResidualData( pcCU, uiAbsPartIdx, uiSeg ); 882 } 883 } 884 #endif 885 #endif 886 #if H_3D_DBBP 887 Void TEncEntropy::encodeDBBPFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, Bool bRD ) 888 { 889 if( bRD ) 890 { 891 uiAbsPartIdx = 0; 892 } 893 m_pcEntropyCoderIf->codeDBBPFlag( pcCU, uiAbsPartIdx ); 894 } 895 #endif 800 896 //! \}
Note: See TracChangeset for help on using the changeset viewer.