Changeset 81 in 3DVCSoftware for trunk/source/Lib/TLibEncoder
- Timestamp:
- 21 Jun 2012, 21:01:20 (12 years ago)
- Location:
- trunk/source/Lib/TLibEncoder
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibEncoder/TEncCu.cpp
r77 r81 1156 1156 if( m_pcRdCost->getUseRenModel() ) 1157 1157 { 1158 #if HHI_FIX 1159 UInt uiWidth = m_ppcOrigYuv[uiDepth]->getWidth ( ); 1160 UInt uiHeight = m_ppcOrigYuv[uiDepth]->getHeight( ); 1161 Pel* piSrc = m_ppcOrigYuv[uiDepth]->getLumaAddr( 0 ); 1162 UInt uiSrcStride = m_ppcOrigYuv[uiDepth]->getStride(); 1163 m_pcRdCost->setRenModelData( m_ppcBestCU[uiDepth], 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1164 #else 1158 1165 UInt uiWidth = m_ppcBestCU[uiDepth]->getWidth ( 0 ); 1159 1166 UInt uiHeight = m_ppcBestCU[uiDepth]->getHeight( 0 ); … … 1161 1168 UInt uiSrcStride = m_ppcOrigYuv[uiDepth]->getStride(); 1162 1169 m_pcRdCost->setRenModelData( m_ppcBestCU[uiDepth], 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1170 #endif 1163 1171 } 1164 1172 #endif … … 1206 1214 if( m_pcRdCost->getUseRenModel() ) // necessary ?? 1207 1215 { 1216 #if HHI_FIX 1217 UInt uiWidth = m_ppcRecoYuvBest[uhNextDepth]->getWidth ( ); 1218 UInt uiHeight = m_ppcRecoYuvBest[uhNextDepth]->getHeight ( ); 1219 Pel* piSrc = m_ppcRecoYuvBest[uhNextDepth]->getLumaAddr( 0 ); 1220 UInt uiSrcStride = m_ppcRecoYuvBest[uhNextDepth]->getStride ( ); 1221 m_pcRdCost->setRenModelData( pcSubBestPartCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1222 #else 1208 1223 UInt uiWidth = pcSubBestPartCU->getWidth ( 0 ); 1209 1224 UInt uiHeight = pcSubBestPartCU->getHeight( 0 ); … … 1211 1226 UInt uiSrcStride = m_ppcRecoYuvBest[pcSubBestPartCU->getDepth(0)]->getStride(); 1212 1227 m_pcRdCost->setRenModelData( pcSubBestPartCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1228 #endif 1213 1229 } 1214 1230 #endif … … 1353 1369 if( m_pcRdCost->getUseRenModel() ) 1354 1370 { 1371 #if HHI_FIX 1372 UInt uiWidth = m_ppcRecoYuvBest[uiDepth]->getWidth ( ); 1373 UInt uiHeight = m_ppcRecoYuvBest[uiDepth]->getHeight ( ); 1374 Pel* piSrc = m_ppcRecoYuvBest[uiDepth]->getLumaAddr( 0 ); 1375 UInt uiSrcStride = m_ppcRecoYuvBest[uiDepth]->getStride ( ); 1376 m_pcRdCost->setRenModelData( rpcBestCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1377 #else 1355 1378 UInt uiWidth = rpcBestCU->getWidth ( 0 ); 1356 1379 UInt uiHeight = rpcBestCU->getHeight( 0 ); … … 1358 1381 UInt uiSrcStride = m_ppcRecoYuvBest[uiDepth]->getStride(); 1359 1382 m_pcRdCost->setRenModelData( rpcBestCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1383 #endif 1360 1384 } 1361 1385 #endif … … 1723 1747 if( m_pcRdCost->getUseRenModel() ) 1724 1748 { 1725 // reset 1749 #if HHI_FIX 1750 UInt uiWidth = m_ppcOrigYuv[uhDepth]->getWidth ( ); 1751 UInt uiHeight = m_ppcOrigYuv[uhDepth]->getHeight( ); 1752 Pel* piSrc = m_ppcOrigYuv[uhDepth]->getLumaAddr( ); 1753 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride(); 1754 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1755 #else 1726 1756 UInt uiWidth = rpcTempCU->getWidth ( 0 ); 1727 1757 UInt uiHeight = rpcTempCU->getHeight( 0 ); … … 1729 1759 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride(); 1730 1760 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1761 #endif 1731 1762 } 1732 1763 #endif … … 1820 1851 if( m_pcRdCost->getUseRenModel() ) 1821 1852 { //Reset 1853 #if HHI_FIX 1854 UInt uiWidth = m_ppcOrigYuv[uhDepth]->getWidth (); 1855 UInt uiHeight = m_ppcOrigYuv[uhDepth]->getHeight (); 1856 Pel* piSrc = m_ppcOrigYuv[uhDepth]->getLumaAddr (); 1857 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride (); 1858 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1859 #else 1822 1860 UInt uiWidth = rpcTempCU->getWidth ( 0 ); 1823 1861 UInt uiHeight = rpcTempCU->getHeight( 0 ); … … 1825 1863 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride(); 1826 1864 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1865 #endif 1827 1866 } 1828 1867 #endif … … 1888 1927 if( m_pcRdCost->getUseRenModel() ) 1889 1928 { 1929 #if HHI_FIX 1930 UInt uiWidth = m_ppcOrigYuv[uhDepth]->getWidth ( ); 1931 UInt uiHeight = m_ppcOrigYuv[uhDepth]->getHeight( ); 1932 Pel* piSrc = m_ppcOrigYuv[uhDepth]->getLumaAddr( ); 1933 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride(); 1934 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1935 #else 1890 1936 UInt uiWidth = rpcTempCU->getWidth ( 0 ); 1891 1937 UInt uiHeight = rpcTempCU->getHeight( 0 ); … … 1893 1939 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride(); 1894 1940 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 1941 #endif 1895 1942 } 1896 1943 #endif … … 1999 2046 if( m_pcRdCost->getUseRenModel() ) 2000 2047 { 2048 #if HHI_FIX 2049 UInt uiWidth = m_ppcOrigYuv[uiDepth]->getWidth (); 2050 UInt uiHeight = m_ppcOrigYuv[uiDepth]->getHeight (); 2051 Pel* piSrc = m_ppcOrigYuv[uiDepth]->getLumaAddr(); 2052 UInt uiSrcStride = m_ppcOrigYuv[uiDepth]->getStride (); 2053 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 2054 #else 2001 2055 UInt uiWidth = rpcTempCU->getWidth ( 0 ); 2002 2056 UInt uiHeight = rpcTempCU->getHeight( 0 ); … … 2004 2058 UInt uiSrcStride = m_ppcOrigYuv[uiDepth]->getStride(); 2005 2059 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 2060 #endif 2006 2061 } 2007 2062 #endif … … 2502 2557 if( m_pcRdCost->getUseRenModel() && !bRecursiveCall) 2503 2558 { 2559 #if HHI_FIX 2560 UInt uiWidth = m_ppcOrigYuv[uhDepth]->getWidth (); 2561 UInt uiHeight = m_ppcOrigYuv[uhDepth]->getHeight (); 2562 Pel* piSrc = m_ppcOrigYuv[uhDepth]->getLumaAddr(); 2563 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride (); 2564 m_pcRdCost->setRenModelData( rpcTempCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 2565 #else 2504 2566 UInt uiWidth = m_ppcTempCU [uhDepth]->getWidth ( 0 ); 2505 2567 UInt uiHeight = m_ppcTempCU [uhDepth]->getHeight( 0 ); … … 2507 2569 UInt uiSrcStride = m_ppcOrigYuv[uhDepth]->getStride(); 2508 2570 m_pcRdCost->setRenModelData( m_ppcTempCU[uhDepth], 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 2571 #endif 2509 2572 } 2510 2573 #endif … … 2654 2717 if( !bSplit && bRecursiveCall && m_pcRdCost->getUseRenModel() ) 2655 2718 { 2719 #if HHI_FIX 2720 UInt uiWidth = m_ppcRecoYuvBest[uhDepth]->getWidth ( ); 2721 UInt uiHeight = m_ppcRecoYuvBest[uhDepth]->getHeight ( ); 2722 UInt uiSrcStride = m_ppcRecoYuvBest[uhDepth]->getStride ( ); 2723 Pel* piSrc = m_ppcRecoYuvBest[uhDepth]->getLumaAddr( 0 ); 2724 m_pcRdCost->setRenModelData( rpcBestCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 2725 #else 2656 2726 UInt uiWidth = rpcBestCU->getWidth ( 0 ); 2657 2727 UInt uiHeight = rpcBestCU->getHeight( 0 ); … … 2659 2729 UInt uiSrcStride = m_ppcRecoYuvBest[uhDepth]->getStride(); 2660 2730 m_pcRdCost->setRenModelData( rpcBestCU, 0, piSrc, uiSrcStride, uiWidth, uiHeight ); 2731 #endif 2661 2732 } 2662 2733 #endif -
trunk/source/Lib/TLibEncoder/TEncSearch.cpp
r77 r81 304 304 // motion cost 305 305 uiSad += m_pcRdCost->getCost( iSearchX, iSearchY ); 306 306 #if HHI_FIX 307 // regularization cost 308 if( m_pcRdCost->useMultiviewReg() ) 309 { 310 uiSad += m_pcRdCost->getMultiviewRegCost( iSearchX, iSearchY ); 311 } 312 #endif 307 313 if( uiSad < rcStruct.uiBestSad ) 308 314 { … … 3865 3871 else 3866 3872 { 3873 #if HHI_FIX 3874 rcMv = ( m_pcRdCost->useMultiviewReg() ? m_pcRdCost->getMultiviewOrgMvPred() : *pcMvPred ); 3875 #else 3867 3876 rcMv = *pcMvPred; 3877 #endif 3868 3878 xPatternSearchFast ( pcCU, pcPatternKey, piRefY, iRefStride, &cMvSrchRngLT, &cMvSrchRngRB, rcMv, ruiCost ); 3869 3879 } … … 3967 3977 uiSad += m_pcRdCost->getCost( x, y ); 3968 3978 3979 #if HHI_FIX 3980 // regularization cost 3981 if( m_pcRdCost->useMultiviewReg() ) 3982 { 3983 uiSad += m_pcRdCost->getMultiviewRegCost( x, y ); 3984 } 3985 #endif 3986 3969 3987 if ( uiSad < uiSadBest ) 3970 3988 {
Note: See TracChangeset for help on using the changeset viewer.