Ignore:
Timestamp:
15 Apr 2015, 11:36:33 (10 years ago)
Author:
tech
Message:

Removed 3D-HEVC.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-14.0-MV-draft-3/source/Lib/TLibCommon/TComPic.cpp

    r1179 r1191  
    6363, m_layerId                               (0)
    6464, m_viewId                                (0)
    65 #if H_3D
    66 , m_viewIndex                             (0)
    67 , m_isDepth                               (false)
    68 , m_aaiCodedScale                         (0)
    69 , m_aaiCodedOffset                        (0)
    70 #endif
    7165#endif
    7266{
    7367  m_apcPicYuv[0]      = NULL;
    7468  m_apcPicYuv[1]      = NULL;
    75 #if H_3D_QTLPC
    76   m_bReduceBitsQTL    = 0;
    77 #endif
    78 #if H_3D_NBDV
    79   m_iNumDdvCandPics   = 0;
    80   m_eRapRefList       = REF_PIC_LIST_0;
    81   m_uiRapRefIdx       = 0;
    82 #endif
    8369}
    8470
     
    114100  memcpy(m_numReorderPics, numReorderPics, MAX_TLAYER*sizeof(Int));
    115101
    116 #if H_3D_FCO
    117 /* initialize the texture to depth reference status */
    118   for (int j=0; j<2; j++)
    119   {
    120       for (int i=0; i<MAX_NUM_REF; i++)
    121       {
    122           m_aiTexToDepRef[j][i] = -1;
    123       }
    124   }
    125 #endif
    126102
    127103  return;
     
    153129  deleteSEIs(m_SEIs);
    154130}
    155 #if H_3D
    156 Void TComPic::compressMotion(Int scale)
    157 #else
    158131Void TComPic::compressMotion()
    159 #endif
    160132{
    161133  TComPicSym* pPicSym = getPicSym();
     
    163135  {
    164136    TComDataCU* pcCU = pPicSym->getCU(uiCUAddr);
    165 #if H_3D
    166     pcCU->compressMV(scale);
    167 #else
    168137    pcCU->compressMV();
    169 #endif
    170138  }
    171139}
     
    204172}
    205173
    206 #if H_3D
    207 TComPic* TComPicLists::getPic( Int viewIndex, Bool depthFlag, Int poc )
    208 {
    209   return getPic   ( m_vps->getLayerIdInNuh( viewIndex, depthFlag ), poc );
    210 }
    211 #endif
    212174Void TComPicLists::print()
    213175{
     
    250212}
    251213
    252 #if H_3D
    253 TComPicYuv* TComPicLists::getPicYuv( Int viewIndex, Bool depthFlag, Int poc, Bool recon )
    254 
    255   Int layerIdInNuh = m_vps->getLayerIdInNuh( viewIndex, depthFlag );
    256   return getPicYuv( layerIdInNuh, poc, recon );
    257 }
    258 #if H_3D_ARP
    259 TComList<TComPic*>* TComPicLists::getPicList( Int layerIdInNuh )
    260 {
    261   TComList<TComList<TComPic*>*>::iterator itL = m_lists.begin();
    262   Int iLayer = 0;
    263 
    264   assert( layerIdInNuh < m_lists.size() );
    265 
    266   while( iLayer != layerIdInNuh )
    267   {
    268     itL++;
    269     iLayer++;
    270   }
    271 
    272   return *itL;
    273 }
    274 #endif
    275 #endif
    276214#endif // H_MV
    277215
    278 #if H_3D_NBDV
    279 Int TComPic::getDisCandRefPictures( Int iColPOC )
    280 {
    281   UInt       uiTempLayerCurr = 7;
    282   TComSlice* currSlice       = getSlice(getCurrSliceIdx());
    283   UInt       numDdvCandPics  = 0;
    284 
    285   if ( !currSlice->getEnableTMVPFlag() )
    286     return numDdvCandPics;
    287 
    288   numDdvCandPics += 1;
    289 
    290   UInt pocCurr = currSlice->getPOC();
    291   UInt pocDiff = 255;
    292 
    293   for(UInt lpNr = 0; lpNr < (currSlice->isInterB() ? 2: 1); lpNr ++)
    294   {
    295     UInt x = lpNr ? currSlice->getColFromL0Flag() : 1 - currSlice->getColFromL0Flag();
    296 
    297     for (UInt i = 0; i < currSlice->getNumRefIdx(RefPicList(x)); i++)
    298     {
    299       if(currSlice->getViewIndex() == currSlice->getRefPic((RefPicList)x, i)->getViewIndex()
    300         && (x == currSlice->getColFromL0Flag()||currSlice->getRefPOC((RefPicList)x, i)!= iColPOC) && numDdvCandPics!=2)
    301       {
    302         TComSlice* refSlice    = currSlice->getRefPic((RefPicList)x, i)->getSlice(getCurrSliceIdx());
    303         Bool       bRAP        = (refSlice->getViewIndex() && refSlice->isIRAP())? 1: 0;
    304         UInt       uiTempLayer = currSlice->getRefPic((RefPicList)x, i)->getSlice(getCurrSliceIdx())->getTLayer();
    305        
    306         if( bRAP )
    307         {
    308           this->setRapRefIdx(i);
    309           this->setRapRefList((RefPicList)x);
    310           numDdvCandPics = 2;
    311 
    312           return numDdvCandPics;
    313         }
    314         else if (uiTempLayerCurr > uiTempLayer)
    315         {
    316            uiTempLayerCurr = uiTempLayer;
    317         }
    318       }
    319     }
    320   }
    321 
    322   UInt z   = -1; // GT: Added to make code compile needs to be checked!
    323   UInt idx = 0;
    324  
    325   for(UInt lpNr = 0; lpNr < (currSlice->isInterB() ? 2: 1); lpNr ++)
    326   {
    327     UInt x = lpNr? currSlice->getColFromL0Flag() : 1-currSlice->getColFromL0Flag();
    328    
    329     for (UInt i = 0; i < currSlice->getNumRefIdx(RefPicList(x)); i++)
    330     {
    331       Int iTempPoc = currSlice->getRefPic((RefPicList)x, i)->getPOC();
    332       Int iTempDiff = (iTempPoc > pocCurr) ? (iTempPoc - pocCurr): (pocCurr - iTempPoc);
    333      
    334       if(currSlice->getViewIndex() == currSlice->getRefPic((RefPicList)x, i)->getViewIndex() &&  (x == currSlice->getColFromL0Flag()||currSlice->getRefPOC((RefPicList)x, i)!= iColPOC)
    335         && currSlice->getRefPic((RefPicList)x, i)->getSlice(getCurrSliceIdx())->getTLayer() == uiTempLayerCurr && pocDiff > iTempDiff)
    336       {
    337         pocDiff = iTempDiff;
    338         z       = x;
    339         idx     = i;
    340       }
    341     }
    342   }
    343 
    344   if( pocDiff < 255 )
    345   {
    346     this->setRapRefIdx(idx);
    347     this->setRapRefList((RefPicList) z );
    348     numDdvCandPics = 2;
    349   }
    350 
    351   return numDdvCandPics;
    352 }
    353 
    354 Void TComPic::checkTemporalIVRef()
    355 {
    356   TComSlice* currSlice = getSlice(getCurrSliceIdx());
    357   const Int numCandPics = this->getNumDdvCandPics();
    358   for(Int curCandPic = 0; curCandPic < numCandPics; curCandPic++)
    359   {
    360     RefPicList eCurRefPicList   = REF_PIC_LIST_0 ;
    361     Int        curCandPicRefIdx = 0;
    362     if( curCandPic == 0 )
    363     {
    364       eCurRefPicList   = RefPicList(currSlice->isInterB() ? 1-currSlice->getColFromL0Flag() : 0);
    365       curCandPicRefIdx = currSlice->getColRefIdx();
    366     }
    367     else                 
    368     {
    369       eCurRefPicList   = this->getRapRefList();
    370       curCandPicRefIdx = this->getRapRefIdx();
    371     }
    372     TComPic* pcCandColPic = currSlice->getRefPic( eCurRefPicList, curCandPicRefIdx);
    373     TComSlice* pcCandColSlice = pcCandColPic->getSlice(0);// currently only support single slice
    374 
    375     if(!pcCandColSlice->isIntra())
    376     {
    377       for( Int iColRefDir = 0; iColRefDir < (pcCandColSlice->isInterB() ? 2: 1); iColRefDir ++ )
    378       {
    379         for( Int iColRefIdx =0; iColRefIdx < pcCandColSlice->getNumRefIdx(( RefPicList )iColRefDir ); iColRefIdx++)
    380         {
    381           m_abTIVRINCurrRL[curCandPic][iColRefDir][iColRefIdx] = false;
    382           Int iColViewIdx    = pcCandColSlice->getViewIndex();
    383           Int iColRefViewIdx = pcCandColSlice->getRefPic( ( RefPicList )iColRefDir, iColRefIdx)->getViewIndex();
    384           if(iColViewIdx == iColRefViewIdx)
    385             continue;
    386 
    387           for(Int iCurrRefDir = 0;(iCurrRefDir < (currSlice->isInterB() ? 2: 1)) && (m_abTIVRINCurrRL[curCandPic][iColRefDir][iColRefIdx] == false ); iCurrRefDir++)
    388           {
    389             for( Int iCurrRefIdx =0; iCurrRefIdx < currSlice->getNumRefIdx(( RefPicList )iCurrRefDir ); iCurrRefIdx++)
    390             {
    391               if( currSlice->getRefPic( ( RefPicList )iCurrRefDir, iCurrRefIdx )->getViewIndex() == iColRefViewIdx )
    392               { 
    393                 m_abTIVRINCurrRL[curCandPic][iColRefDir][iColRefIdx] = true;
    394                 break;
    395               }
    396             }
    397           }
    398         }
    399       }
    400     }
    401   }
    402 }
    403 Bool TComPic::isTempIVRefValid(Int currCandPic, Int iColRefDir, Int iColRefIdx)
    404 {
    405   return m_abTIVRINCurrRL[currCandPic][iColRefDir][iColRefIdx];
    406 }
    407 
    408 Void TComPic::checkTextureRef(  )
    409 {
    410   TComSlice* pcCurrSlice = getSlice(getCurrSliceIdx());
    411   TComPic* pcTextPic = pcCurrSlice->getTexturePic();
    412 #if H_3D_FCO
    413   if ( pcTextPic )
    414   {
    415 #endif
    416 
    417   TComSlice* pcTextSlice = pcTextPic->getSlice(0); // currently only support single slice
    418 
    419   for( Int iTextRefDir = 0; (iTextRefDir < (pcTextSlice->isInterB()? 2:1) ) && !pcTextSlice->isIntra(); iTextRefDir ++ )
    420   {
    421     for( Int iTextRefIdx =0; iTextRefIdx<pcTextSlice->getNumRefIdx(( RefPicList )iTextRefDir ); iTextRefIdx++)
    422     {
    423       Int iTextRefPOC    = pcTextSlice->getRefPOC( ( RefPicList )iTextRefDir, iTextRefIdx);
    424       Int iTextRefViewId = pcTextSlice->getRefPic( ( RefPicList )iTextRefDir, iTextRefIdx)->getViewIndex();
    425       m_aiTexToDepRef[iTextRefDir][iTextRefIdx] = -1;
    426       Int iCurrRefDir = iTextRefDir;
    427       for( Int iCurrRefIdx =0; ( iCurrRefIdx<pcCurrSlice->getNumRefIdx(( RefPicList )iCurrRefDir ) ) && ( m_aiTexToDepRef[iTextRefDir][iTextRefIdx] < 0 ) ; iCurrRefIdx++)
    428       {
    429         if( pcCurrSlice->getRefPOC( ( RefPicList )iCurrRefDir, iCurrRefIdx ) == iTextRefPOC &&
    430           pcCurrSlice->getRefPic( ( RefPicList )iCurrRefDir, iCurrRefIdx)->getViewIndex() == iTextRefViewId )
    431         { 
    432           m_aiTexToDepRef[iTextRefDir][iTextRefIdx] = iCurrRefIdx;
    433         }
    434       }
    435     }
    436 
    437   }
    438 #if H_3D_FCO
    439   }
    440 #endif
    441 
    442 }
    443 
    444 Int TComPic::isTextRefValid(Int iTextRefDir, Int iTextRefIdx)
    445 {
    446   return m_aiTexToDepRef[iTextRefDir][iTextRefIdx];
    447 }
    448 #endif
    449216//! \}
Note: See TracChangeset for help on using the changeset viewer.