Changeset 485 in 3DVCSoftware for branches/HTM-DEV-0.3-dev1
- Timestamp:
- 20 Jun 2013, 12:32:01 (11 years ago)
- Location:
- branches/HTM-DEV-0.3-dev1/source
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-DEV-0.3-dev1/source/App/TAppEncoder/TAppEncTop.cpp
r467 r485 1051 1051 } 1052 1052 1053 if( uiNumFrames == 0 || (Int)ceil(Log2(iNumDepthValues)) == (Int)ceil(Log2(((1 << g_bitDepthY)-1))))1053 if( uiNumFrames == 0 || numBitsForValue(iNumDepthValues) == g_bitDepthY ) 1054 1054 { 1055 1055 // don't use DLT -
branches/HTM-DEV-0.3-dev1/source/Lib/TLibCommon/TComRom.h
r459 r485 159 159 __inline Void mapDepthModeToIntraDir( Int& intraMode ) { if( isDimMode( intraMode ) ) intraMode = DC_IDX; } 160 160 161 #if H_3D_DIM_SDC || H_3D_DIM_DLT 162 __inline UInt numBitsForValue( UInt value ) { UInt bits = 0; while (value != 0) { value >>= 1; bits++; } return bits; }; 163 #endif 164 161 165 #if H_3D_DIM_DMM 162 166 extern const WedgeResolution g_dmmWedgeResolution [6]; -
branches/HTM-DEV-0.3-dev1/source/Lib/TLibCommon/TComSlice.cpp
r473 r485 1485 1485 // allocate some memory and initialize with default mapping 1486 1486 m_iNumDepthmapValues[i] = ((1 << g_bitDepthY)-1)+1; 1487 m_iBitsPerDepthValue[i] = (Int)ceil(Log2(m_iNumDepthmapValues[i]));1487 m_iBitsPerDepthValue[i] = numBitsForValue(m_iNumDepthmapValues[i]); 1488 1488 1489 1489 m_iDepthValue2Idx[i] = (Int*) xMalloc(Int, m_iNumDepthmapValues[i]); … … 1579 1579 // update DLT variables 1580 1580 m_iNumDepthmapValues[layerIdInVps] = iNumDepthValues; 1581 m_iBitsPerDepthValue[layerIdInVps] = (Int)ceil(Log2(m_iNumDepthmapValues[layerIdInVps]));1581 m_iBitsPerDepthValue[layerIdInVps] = numBitsForValue(m_iNumDepthmapValues[layerIdInVps]); 1582 1582 } 1583 1583 #endif -
branches/HTM-DEV-0.3-dev1/source/Lib/TLibCommon/TypeDef.h
r474 r485 119 119 // HHI_DEPTH_INTRA_SEARCH_RAU_C0160 120 120 // LG_ZEROINTRADEPTHRESI_A0087 121 #if H_3D_DIM_DLT || H_3D_DIM_SDC122 #define Log2( n ) ( log((double)n) / log(2.0) )123 #endif124 121 #endif 125 122 -
branches/HTM-DEV-0.3-dev1/source/Lib/TLibDecoder/TDecCAVLC.cpp
r467 r485 987 987 free(aiIdx2DepthValue); 988 988 } 989 else990 pcVPS->setDepthLUTs(i);991 989 } 992 else993 pcVPS->setDepthLUTs(i);994 990 #endif 995 991 } -
branches/HTM-DEV-0.3-dev1/source/Lib/TLibDecoder/TDecSbac.cpp
r467 r485 565 565 if ( uiCount == uiPrefixThreshold ) 566 566 { 567 for ( UInt ui = 0; ui < ( (UInt)ceil( Log2(uiNumDepthValues - uiPrefixThreshold) )); ui++ )567 for ( UInt ui = 0; ui < numBitsForValue(uiNumDepthValues - uiPrefixThreshold); ui++ ) 568 568 { 569 569 m_pcTDecBinIf->decodeBinEP( uiBit ); -
branches/HTM-DEV-0.3-dev1/source/Lib/TLibEncoder/TEncSbac.cpp
r467 r485 630 630 { 631 631 uiAbsIdx -= uiPrefixThreshold; 632 UInt uiSuffixLength = ( (UInt)ceil( Log2(uiNumDepthValues - uiPrefixThreshold) ));632 UInt uiSuffixLength = numBitsForValue(uiNumDepthValues - uiPrefixThreshold); 633 633 UInt uiBitInfo = 0; 634 634 for ( Int i = 0; i < uiSuffixLength; i++)
Note: See TracChangeset for help on using the changeset viewer.