Changeset 416 in 3DVCSoftware for branches/HTM-6.2-dev2-MERL/source
- Timestamp:
- 18 May 2013, 16:21:18 (12 years ago)
- Location:
- branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TComDataCU.cpp
r412 r416 5522 5522 { 5523 5523 Bool isFound = false; 5524 RefPicList privateRefPicList = REF_PIC_LIST_0 5524 RefPicList privateRefPicList = REF_PIC_LIST_0; 5525 5525 5526 5526 refFrmIdx = 0; … … 5648 5648 Int currPoc = getSlice()->getPOC(); 5649 5649 picDepth = getSlice()->getDepthRefPic(iTargetViewIdx, currPoc); 5650 assert(picDepth !=NULL);5650 assert(picDepth != NULL); 5651 5651 #else 5652 5652 picDepth = getSlice()->getRefPicBaseDepth(); -
branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TComPrediction.cpp
r412 r416 882 882 // Find the other interview reference in order to do VSP 883 883 RefPicList otherRefPicList = privateRefPicList == REF_PIC_LIST_0 ? REF_PIC_LIST_1 : REF_PIC_LIST_0; 884 Bool IsFound = false;885 for (Int i refIdx = 0; irefIdx <pcCU->getSlice()->getNumRefIdx(otherRefPicList); irefIdx ++ )886 { 887 Int refViewIdx = pcCU->getSlice()->getRefViewId( otherRefPicList, i refIdx);884 Bool isFound = false; 885 for (Int iRefIdx = 0; iRefIdx <pcCU->getSlice()->getNumRefIdx(otherRefPicList); iRefIdx ++ ) 886 { 887 Int refViewIdx = pcCU->getSlice()->getRefViewId( otherRefPicList, iRefIdx); 888 888 if ( (refViewIdx != pcCU->getSlice()->getViewId()) && (refViewIdx != viewId ) ) 889 889 { 890 refPic = pcCU->getSlice()->getRefPic(otherRefPicList, i refIdx);891 IsFound = true;890 refPic = pcCU->getSlice()->getRefPic(otherRefPicList, iRefIdx); 891 isFound = true; 892 892 break; 893 893 } 894 894 } 895 895 896 if ( IsFound == false)897 { 898 Int refIdx txt = -1-pcCU->getCUMvField( privateRefPicList )->getRefIdx( uiPartAddr );899 assert(refIdx txt >= 0);900 refPic = pcCU->getSlice()->getRefPic(privateRefPicList, refIdx txt);901 } 902 assert( IsFound);896 if (isFound == false) 897 { 898 Int refIdxTxt = -1-pcCU->getCUMvField( privateRefPicList )->getRefIdx( uiPartAddr ); 899 assert(refIdxTxt >= 0); 900 refPic = pcCU->getSlice()->getRefPic(privateRefPicList, refIdxTxt); 901 } 902 assert(isFound); 903 903 } 904 904 assert(refPic != NULL); … … 951 951 if( 952 952 #if MERL_VSP_C0152 953 vspIdx == 0 && // TODO: Maybe logically redundant, but easier to read 953 vspIdx == 0 && // TODO: Maybe logically redundant, but easier to read. Need verification before being removed 954 954 #endif 955 955 pcCU->getSlice()->getSPS()->isDepth() == false … … 1169 1169 if (pcCU->getVSPIndex(uiPartAddr) != 0) // is VSP 1170 1170 { 1171 Int Bi_VSP_Avail = 0;1171 Int biVSPAvail = 0; 1172 1172 //test whether VSP is Bi or Uni 1173 1173 //Step1. Get derived DV view id … … 1189 1189 (pcCU->getSlice()->getNumRefIdx(REF_PIC_LIST_0) > 0 ? 1 : 2)); 1190 1190 //Step 3. Check the availability of Bi VSP by checking the interview reference availability in the other reference list 1191 if(iInterDir ==3)1192 { 1193 for (Int i refIdx = 0; irefIdx <pcCU->getSlice()->getNumRefIdx(otherRefPicList); irefIdx ++ )1194 { 1195 Int refViewIdx = pcCU->getSlice()->getRefViewId( otherRefPicList, i refIdx);1191 if(iInterDir == 3) 1192 { 1193 for (Int iRefIdx = 0; iRefIdx <pcCU->getSlice()->getNumRefIdx(otherRefPicList); iRefIdx ++ ) 1194 { 1195 Int refViewIdx = pcCU->getSlice()->getRefViewId( otherRefPicList, iRefIdx); 1196 1196 if ( (refViewIdx != pcCU->getSlice()->getViewId()) && (refViewIdx != viewId ) ) 1197 1197 { 1198 Bi_VSP_Avail = 1;1198 biVSPAvail = 1; 1199 1199 break; 1200 1200 } … … 1202 1202 } 1203 1203 //Step 4. Update the Bi VSP prediction direction 1204 if ( iInterDir == 3 && Bi_VSP_Avail == 1)1204 if ( iInterDir == 3 && biVSPAvail == 1) 1205 1205 { 1206 1206 biDecision = 1; … … 1242 1242 1243 1243 #if !MERL_Bi_VSP_D0166 //both lists should go 1244 if ( iRefList == REF_PIC_LIST_1 && iRefIdx[iRefList] < 0 ) // iRefIdx[iRefList] ==NOT_VALID1244 if ( iRefList == REF_PIC_LIST_1 && iRefIdx[iRefList] < 0 ) // iRefIdx[iRefList] ==NOT_VALID 1245 1245 { 1246 1246 continue; … … 1268 1268 1269 1269 #if MERL_Bi_VSP_D0166 1270 if(biDecision ==1)1270 if(biDecision == 1) 1271 1271 #else 1272 1272 if( pcCU->getCUMvField( REF_PIC_LIST_0 )->getRefIdx( uiPartAddr ) >= 0 && pcCU->getCUMvField( REF_PIC_LIST_1 )->getRefIdx( uiPartAddr ) >= 0 ) … … 1681 1681 // refPic: Ref picture. Full picture, with padding 1682 1682 // posX, posY: PU position, texture 1683 // size _x, size_y: PU size1683 // sizeX, sizeY: PU size 1684 1684 // partAddr: z-order index 1685 1685 // mv: disparity vector. derived from neighboring blocks 1686 1686 // 1687 1687 // Output: dstPic, PU predictor 64x64 1688 Void TComPrediction::xPredInterLumaBlkFromDM( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv* mv, UInt partAddr,Int posX, Int posY, Int size _x, Int size_y, Bool isDepth, TComYuv *&dstPic1688 Void TComPrediction::xPredInterLumaBlkFromDM( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv* mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, TComYuv *&dstPic 1689 1689 #if MERL_Bi_VSP_D0166 1690 1690 , Bool bi … … 1722 1722 Int dstStride = dstPic->getStride(); 1723 1723 Int depStride = pPicBaseDepth->getStride(); 1724 Int depthPosX = Clip3(0, widthLuma - size _x, (posX/nTxtPerDepthX) + (mv->getHor()>>2));1725 Int depthPosY = Clip3(0, heightLuma- size _y, (posY/nTxtPerDepthY) + (mv->getVer()>>2));1724 Int depthPosX = Clip3(0, widthLuma - sizeX, (posX/nTxtPerDepthX) + (mv->getHor()>>2)); 1725 Int depthPosY = Clip3(0, heightLuma- sizeY, (posY/nTxtPerDepthY) + (mv->getVer()>>2)); 1726 1726 Pel *ref = refPic->getLumaAddr() + posX + posY * refStride; 1727 1727 Pel *dst = dstPic->getLumaAddr(partAddr); … … 1730 1730 #if MERL_VSP_BLOCKSIZE_C0152 != 1 1731 1731 #if MERL_VSP_BLOCKSIZE_C0152 == 2 1732 Int dW = size _x>>1;1733 Int dH = size _y>>1;1732 Int dW = sizeX>>1; 1733 Int dH = sizeY>>1; 1734 1734 #endif 1735 1735 #if MERL_VSP_BLOCKSIZE_C0152 == 4 1736 Int dW = size _x>>2;1737 Int dH = size _y>>2;1736 Int dW = sizeX>>2; 1737 Int dH = sizeY>>2; 1738 1738 #endif 1739 1739 { … … 1808 1808 //get LUT based horizontal reference range 1809 1809 Int range = 0; 1810 if( size _x == 4 && size_y== 8 )1810 if( sizeX == 4 && sizeY == 8 ) 1811 1811 range = m_iRangeLuma[0]; 1812 else if( size _x == 8 && size_y== 4 )1812 else if( sizeX == 8 && sizeY == 4 ) 1813 1813 range = m_iRangeLuma[1]; 1814 else if( size _x == 8 && size_y== 8 )1814 else if( sizeX == 8 && sizeY == 8 ) 1815 1815 range = m_iRangeLuma[2]; 1816 else if( size _x == 8 && size_y== 16 )1816 else if( sizeX == 8 && sizeY == 16 ) 1817 1817 range = m_iRangeLuma[3]; 1818 else if( size _x == 16 && size_y== 8 )1818 else if( sizeX == 16 && sizeY == 8 ) 1819 1819 range = m_iRangeLuma[4]; 1820 else if( size _x == 16 && size_y== 16 )1820 else if( sizeX == 16 && sizeY == 16 ) 1821 1821 range = m_iRangeLuma[5]; 1822 else if( size _x == 16 && size_y== 32 )1822 else if( sizeX == 16 && sizeY == 32 ) 1823 1823 range = m_iRangeLuma[6]; 1824 else if( size _x == 32 && size_y== 16 )1824 else if( sizeX == 32 && sizeY == 16 ) 1825 1825 range = m_iRangeLuma[7]; 1826 else if( size _x == 32 && size_y== 32 )1826 else if( sizeX == 32 && sizeY == 32 ) 1827 1827 range = m_iRangeLuma[8]; 1828 else if( size _x == 32 && size_y== 64 )1828 else if( sizeX == 32 && sizeY == 64 ) 1829 1829 range = m_iRangeLuma[9]; 1830 else if( size _x == 64 && size_y== 32 )1830 else if( sizeX == 64 && sizeY == 32 ) 1831 1831 range = m_iRangeLuma[10]; 1832 else if( size _x == 64 && size_y== 64 )1832 else if( sizeX == 64 && sizeY == 64 ) 1833 1833 range = m_iRangeLuma[11]; 1834 1834 else … … 1836 1836 1837 1837 // The minimum depth value 1838 Int min _relative_pos = 5000;1839 Int max _relative_pos = -5000;1840 1841 Pel* depth _temp, *depth_initial=depth;1842 for (Int yTxt =0; yTxt<size _y; yTxt++)1843 { 1844 for (Int xTxt =0; xTxt<size _x; xTxt++)1838 Int minRelativePos = 5000; 1839 Int maxRelativePos = -5000; 1840 1841 Pel* depthTemp, *depthInitial=depth; 1842 for (Int yTxt =0; yTxt<sizeY; yTxt++) 1843 { 1844 for (Int xTxt =0; xTxt<sizeX; xTxt++) 1845 1845 { 1846 1846 if (depthPosX+xTxt < widthDepth) 1847 depth _temp = depth_initial + xTxt;1847 depthTemp = depthInitial + xTxt; 1848 1848 else 1849 depth _temp = depth_initial + (widthDepth - depthPosX - 1);1850 1851 Int disparity = pShiftLUT[ *depth _temp ] << iShiftPrec;1852 Int disparity _int = disparity >> 2;1849 depthTemp = depthInitial + (widthDepth - depthPosX - 1); 1850 1851 Int disparity = pShiftLUT[ *depthTemp ] << iShiftPrec; 1852 Int disparityInt = disparity >> 2; 1853 1853 1854 1854 if( disparity <= 0) 1855 1855 { 1856 if (min _relative_pos > disparity_int+xTxt)1857 min _relative_pos = disparity_int+xTxt;1856 if (minRelativePos > disparityInt+xTxt) 1857 minRelativePos = disparityInt+xTxt; 1858 1858 } 1859 1859 else 1860 1860 { 1861 if (max _relative_pos < disparity_int+xTxt)1862 max _relative_pos = disparity_int+xTxt;1861 if (maxRelativePos < disparityInt+xTxt) 1862 maxRelativePos = disparityInt+xTxt; 1863 1863 } 1864 1864 } 1865 1865 if (depthPosY+yTxt < heightDepth) 1866 depth _initial = depth_initial + depStride;1866 depthInitial = depthInitial + depStride; 1867 1867 } 1868 1868 1869 1869 Int disparity_tmp = pShiftLUT[ *depth ] << iShiftPrec; 1870 1870 if (disparity_tmp <= 0) 1871 max _relative_pos = min_relative_pos + range -1 ;1871 maxRelativePos = minRelativePos + range -1 ; 1872 1872 else 1873 min _relative_pos = max_relative_pos - range +1 ;1873 minRelativePos = maxRelativePos - range +1 ; 1874 1874 #endif 1875 1875 #endif … … 1878 1878 Int yDepth = 0; 1879 1879 #endif 1880 for ( Int yTxt = 0; yTxt < size _y; yTxt += nTxtPerDepthY )1881 { 1882 for ( Int xTxt = 0, xDepth = 0; xTxt < size _x; xTxt += nTxtPerDepthX, xDepth++ )1883 { 1884 Pel rep _depth = 0; // to store the depth value used for warping1880 for ( Int yTxt = 0; yTxt < sizeY; yTxt += nTxtPerDepthY ) 1881 { 1882 for ( Int xTxt = 0, xDepth = 0; xTxt < sizeX; xTxt += nTxtPerDepthX, xDepth++ ) 1883 { 1884 Pel repDepth = 0; // to store the depth value used for warping 1885 1885 #if MERL_VSP_BLOCKSIZE_C0152 == 1 1886 rep _depth = depth[xDepth];1886 repDepth = depth[xDepth]; 1887 1887 #endif 1888 1888 #if MERL_VSP_BLOCKSIZE_C0152 == 2 1889 rep _depth = m_pDepth[(xTxt>>1) + (yTxt>>1)*dW];1889 repDepth = m_pDepth[(xTxt>>1) + (yTxt>>1)*dW]; 1890 1890 #endif 1891 1891 #if MERL_VSP_BLOCKSIZE_C0152 == 4 1892 rep _depth = m_pDepth[(xTxt>>2) + (yTxt>>2)*dW];1893 #endif 1894 1895 assert( rep _depth >= 0 && rep_depth <= 255 );1896 Int disparity = pShiftLUT[ rep _depth ] << iShiftPrec;1892 repDepth = m_pDepth[(xTxt>>2) + (yTxt>>2)*dW]; 1893 #endif 1894 1895 assert( repDepth >= 0 && repDepth <= 255 ); 1896 Int disparity = pShiftLUT[ repDepth ] << iShiftPrec; 1897 1897 Int refOffset = xTxt + (disparity >> 2); 1898 1898 Int xFrac = disparity & 0x3; 1899 1899 #if MERL_CVSP_D0165 1900 if(refOffset<min _relative_pos || refOffset>max_relative_pos)1900 if(refOffset<minRelativePos || refOffset>maxRelativePos) 1901 1901 xFrac = 0; 1902 refOffset = Clip3(min _relative_pos, max_relative_pos, refOffset);1902 refOffset = Clip3(minRelativePos, maxRelativePos, refOffset); 1903 1903 #endif 1904 1904 Int absX = posX + refOffset; … … 1929 1929 } 1930 1930 1931 Void TComPrediction::xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv*mv, UInt partAddr, Int posX, Int posY, Int size _x, Int size_y, Bool isDepth, TComYuv *&dstPic1931 Void TComPrediction::xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv*mv, UInt partAddr, Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, TComYuv *&dstPic 1932 1932 #if MERL_Bi_VSP_D0166 1933 1933 , Bool bi … … 1974 1974 depthPosX = posX * nDepthPerTxtX + (mv->getHor()>>2); //mv denotes the disparity for VSP 1975 1975 } 1976 depthPosX = Clip3(0, widthDepth - (size _x<<1), depthPosX);1976 depthPosX = Clip3(0, widthDepth - (sizeX<<1), depthPosX); 1977 1977 if ( heightChroma > heightDepth ) 1978 1978 { … … 1987 1987 depthPosY = posY * nDepthPerTxtY + (mv->getVer()>>2); //mv denotes the disparity for VSP 1988 1988 } 1989 depthPosY = Clip3(0, heightDepth - (size _y<<1), depthPosY);1989 depthPosY = Clip3(0, heightDepth - (sizeY<<1), depthPosY); 1990 1990 1991 1991 Pel *refCb = refPic->getCbAddr() + posX + posY * refStride; … … 2008 2008 { 2009 2009 #if MERL_VSP_BLOCKSIZE_C0152 == 1 2010 Int dW = size _x;2011 Int dH = size _y;2010 Int dW = sizeX; 2011 Int dH = sizeY; 2012 2012 Int sW = 2; // search window size 2013 2013 Int sH = 2; 2014 2014 #endif 2015 2015 #if MERL_VSP_BLOCKSIZE_C0152 == 2 2016 Int dW = size _x;2017 Int dH = size _y;2016 Int dW = sizeX; 2017 Int dH = sizeY; 2018 2018 Int sW = 2; // search window size 2019 2019 Int sH = 2; 2020 2020 #endif 2021 2021 #if MERL_VSP_BLOCKSIZE_C0152 == 4 2022 Int dW = size _x>>1;2023 Int dH = size _y>>1;2022 Int dW = sizeX>>1; 2023 Int dH = sizeY>>1; 2024 2024 Int sW = 4; // search window size 2025 2025 Int sH = 4; … … 2090 2090 //get LUT based horizontal reference range 2091 2091 Int range=0; 2092 if( size _x == 2 && size_y== 4 )2092 if( sizeX == 2 && sizeY == 4 ) 2093 2093 range = m_iRangeChroma[0]; 2094 else if( size _x == 4 && size_y== 2 )2094 else if( sizeX == 4 && sizeY == 2 ) 2095 2095 range = m_iRangeChroma[1]; 2096 else if( size _x == 4 && size_y== 4 )2096 else if( sizeX == 4 && sizeY == 4 ) 2097 2097 range = m_iRangeChroma[2]; 2098 else if( size _x == 4 && size_y== 8 )2098 else if( sizeX == 4 && sizeY == 8 ) 2099 2099 range = m_iRangeChroma[3]; 2100 else if( size _x == 8 && size_y== 4 )2100 else if( sizeX == 8 && sizeY == 4 ) 2101 2101 range = m_iRangeChroma[4]; 2102 else if( size _x == 8 && size_y== 8 )2102 else if( sizeX == 8 && sizeY == 8 ) 2103 2103 range = m_iRangeChroma[5]; 2104 else if( size _x == 8 && size_y== 16 )2104 else if( sizeX == 8 && sizeY == 16 ) 2105 2105 range = m_iRangeChroma[6]; 2106 else if( size _x == 16 && size_y== 8 )2106 else if( sizeX == 16 && sizeY == 8 ) 2107 2107 range = m_iRangeChroma[7]; 2108 else if( size _x == 16 && size_y== 16 )2108 else if( sizeX == 16 && sizeY == 16 ) 2109 2109 range = m_iRangeChroma[8]; 2110 else if( size _x == 16 && size_y== 32 )2110 else if( sizeX == 16 && sizeY == 32 ) 2111 2111 range = m_iRangeChroma[9]; 2112 else if( size _x == 32 && size_y== 16 )2112 else if( sizeX == 32 && sizeY == 16 ) 2113 2113 range = m_iRangeChroma[10]; 2114 else if( size _x == 32 && size_y== 32 )2114 else if( sizeX == 32 && sizeY == 32 ) 2115 2115 range = m_iRangeChroma[11]; 2116 2116 else … … 2118 2118 2119 2119 // The minimum depth value 2120 Int min _relative_pos = 5000;2121 Int max _relative_pos = -5000;2122 2123 Int depth _tmp;2124 for (Int yTxt=0; yTxt<size _y; yTxt++)2125 { 2126 for (Int xTxt=0; xTxt<size _x; xTxt++)2127 { 2128 depth _tmp = m_pDepth[xTxt+yTxt*dW];2129 Int disparity = pShiftLUT[ depth _tmp ] << iShiftPrec;2130 Int disparity _int = disparity >> 3;//in chroma resolution2131 2132 if (disparity _int < 0)2133 { 2134 if (min _relative_pos > disparity_int+xTxt)2135 min _relative_pos = disparity_int+xTxt;2120 Int minRelativePos = 5000; 2121 Int maxRelativePos = -5000; 2122 2123 Int depthTmp; 2124 for (Int yTxt=0; yTxt<sizeY; yTxt++) 2125 { 2126 for (Int xTxt=0; xTxt<sizeX; xTxt++) 2127 { 2128 depthTmp = m_pDepth[xTxt+yTxt*dW]; 2129 Int disparity = pShiftLUT[ depthTmp ] << iShiftPrec; 2130 Int disparityInt = disparity >> 3;//in chroma resolution 2131 2132 if (disparityInt < 0) 2133 { 2134 if (minRelativePos > disparityInt+xTxt) 2135 minRelativePos = disparityInt+xTxt; 2136 2136 } 2137 2137 else 2138 2138 { 2139 if (max _relative_pos < disparity_int+xTxt)2140 max _relative_pos = disparity_int+xTxt;2141 } 2142 } 2143 } 2144 2145 depth _tmp = m_pDepth[0];2146 Int disparity_tmp = pShiftLUT[ depth _tmp ] << iShiftPrec;2139 if (maxRelativePos < disparityInt+xTxt) 2140 maxRelativePos = disparityInt+xTxt; 2141 } 2142 } 2143 } 2144 2145 depthTmp = m_pDepth[0]; 2146 Int disparity_tmp = pShiftLUT[ depthTmp ] << iShiftPrec; 2147 2147 if ( disparity_tmp < 0 ) 2148 max _relative_pos = min_relative_pos + range - 1;2148 maxRelativePos = minRelativePos + range - 1; 2149 2149 else 2150 min _relative_pos = max_relative_pos - range + 1;2151 2152 #endif 2153 #endif 2154 2155 // (size _x, size_y) is Chroma block size2156 for ( Int yTxt = 0, yDepth = 0; yTxt < size _y; yTxt += nTxtPerDepthY, yDepth += nDepthPerTxtY )2157 { 2158 for ( Int xTxt = 0, xDepth = 0; xTxt < size _x; xTxt += nTxtPerDepthX, xDepth += nDepthPerTxtX )2159 { 2160 Pel rep _depth = 0; // to store the depth value used for warping2150 minRelativePos = maxRelativePos - range + 1; 2151 2152 #endif 2153 #endif 2154 2155 // (sizeX, sizeY) is Chroma block size 2156 for ( Int yTxt = 0, yDepth = 0; yTxt < sizeY; yTxt += nTxtPerDepthY, yDepth += nDepthPerTxtY ) 2157 { 2158 for ( Int xTxt = 0, xDepth = 0; xTxt < sizeX; xTxt += nTxtPerDepthX, xDepth += nDepthPerTxtX ) 2159 { 2160 Pel repDepth = 0; // to store the depth value used for warping 2161 2161 #if MERL_VSP_BLOCKSIZE_C0152 == 1 2162 rep _depth = m_pDepth[(xTxt) + (yTxt)*dW];2162 repDepth = m_pDepth[(xTxt) + (yTxt)*dW]; 2163 2163 #endif 2164 2164 #if MERL_VSP_BLOCKSIZE_C0152 == 2 2165 rep _depth = m_pDepth[(xTxt) + (yTxt)*dW];2165 repDepth = m_pDepth[(xTxt) + (yTxt)*dW]; 2166 2166 #endif 2167 2167 #if MERL_VSP_BLOCKSIZE_C0152 == 4 2168 rep _depth = m_pDepth[(xTxt>>1) + (yTxt>>1)*dW];2168 repDepth = m_pDepth[(xTxt>>1) + (yTxt>>1)*dW]; 2169 2169 #endif 2170 2170 2171 2171 // calculate the offset in the reference picture 2172 Int disparity = pShiftLUT[ rep _depth ] << iShiftPrec;2172 Int disparity = pShiftLUT[ repDepth ] << iShiftPrec; 2173 2173 Int refOffset = xTxt + (disparity >> 3); // in integer pixel in chroma image 2174 2174 Int xFrac = disparity & 0x7; 2175 2175 #if MERL_CVSP_D0165 2176 if(refOffset < min _relative_pos || refOffset > max_relative_pos)2176 if(refOffset < minRelativePos || refOffset > maxRelativePos) 2177 2177 xFrac = 0; 2178 refOffset = Clip3(min _relative_pos, max_relative_pos, refOffset);2178 refOffset = Clip3(minRelativePos, maxRelativePos, refOffset); 2179 2179 #endif 2180 2180 Int absX = posX + refOffset; -
branches/HTM-6.2-dev2-MERL/source/Lib/TLibCommon/TComPrediction.h
r412 r416 156 156 #if MERL_Bi_VSP_D0166 157 157 TComPic* xGetVspRefTxt(TComDataCU* pcCU, UInt uiPartAddr, RefPicList eRefPicList); 158 Void xPredInterLumaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int size _x, Int size_y, Bool isDepth,158 Void xPredInterLumaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, 159 159 TComYuv *&dstPic, Bool bi); 160 Void xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int size _x, Int size_y, Bool isDepth,160 Void xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, 161 161 TComYuv *&dstPic, Bool bi); 162 162 #else 163 Void xPredInterLumaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int size _x, Int size_y, Bool isDepth,163 Void xPredInterLumaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, 164 164 TComYuv *&dstPic ); 165 Void xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int size _x, Int size_y, Bool isDepth,165 Void xPredInterChromaBlkFromDM ( TComPicYuv *refPic, TComPicYuv *pPicBaseDepth, Int* pShiftLUT, Int iShiftPrec, TComMv *mv, UInt partAddr,Int posX, Int posY, Int sizeX, Int sizeY, Bool isDepth, 166 166 TComYuv *&dstPic ); 167 167 #endif
Note: See TracChangeset for help on using the changeset viewer.