Changeset 216 in SHVCSoftware for branches/SHM-2.1-dev/source/Lib/TLibCommon


Ignore:
Timestamp:
20 May 2013, 20:12:37 (12 years ago)
Author:
sharp
Message:

JCTVC-M0203 <hendry.hendry@…> and JCTVC-M0209 - Sachin Deshpande <sdeshpande@…>
Inter-layer prediction indication signaling and decoding

Location:
branches/SHM-2.1-dev/source/Lib/TLibCommon
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-2.1-dev/source/Lib/TLibCommon/TComSlice.cpp

    r196 r216  
    520520  //inter-layer reference picture
    521521#if REF_IDX_MFM
     522
     523#if ILR_RESTR
     524  Int maxSubLayerForILPPlus1 = (getLayerId() > 0)? getVPS()->getMaxSublayerForIlpPlus1(ilpPic[0]->getSlice(0)->getLayerId()) : 0;
     525#if ZERO_NUM_DIRECT_LAYERS
     526  if( getLayerId() > 0 && m_activeNumILRRefIdx > 0 && ( ( (Int)(ilpPic[0]->getSlice(0)->getTLayer())<=  maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[0]->getSlice(0)->getRapPicFlag()) )  )
     527#else
     528  if( getLayerId() && ( ( (Int)(ilpPic[0]->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[0]->getSlice(0)->getRapPicFlag()) )  )
     529#endif
     530
     531#else
    522532#if ZERO_NUM_DIRECT_LAYERS
    523533  if( m_layerId > 0 && m_activeNumILRRefIdx > 0 )
    524534#else
    525535  if (getLayerId())
     536#endif
    526537#endif
    527538  {
     
    542553  TComPic*  rpsCurrList1[MAX_NUM_REF+1];
    543554#if REF_IDX_FRAMEWORK
     555#if ILR_RESTR
     556  Int numInterLayerRPSPics = 0;
     557  if (getLayerId()>0)
     558  {
     559    for (i=0; i < getVPS()->getNumDirectRefLayers(getLayerId()); i++)
     560    {
     561      maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[i]->getSlice(0)->getLayerId());
     562      if( ((Int)(ilpPic[i]->getSlice(0)->getTLayer())<= maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[i]->getSlice(0)->getRapPicFlag() ) )
     563      {
     564        numInterLayerRPSPics++;
     565      }
     566    }
     567#if JCTVC_M0458_INTERLAYER_RPS_SIG
     568    if (numInterLayerRPSPics < m_activeNumILRRefIdx)
     569    {
     570      m_activeNumILRRefIdx = numInterLayerRPSPics;
     571    }
     572#else
     573    if (numInterLayerRPSPics < m_numILRRefIdx)
     574    {
     575      m_numILRRefIdx = numInterLayerRPSPics;
     576    }
     577#endif
     578  }
     579#endif
    544580#if JCTVC_M0458_INTERLAYER_RPS_SIG
    545581  Int numPocTotalCurr = NumPocStCurr0 + NumPocStCurr1 + NumPocLtCurr + m_activeNumILRRefIdx;
     
    604640#endif
    605641      {
     642#if ILR_RESTR
     643         maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[i]->getSlice(0)->getLayerId());
     644        if( ((Int)(ilpPic[i]->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[i]->getSlice(0)->getRapPicFlag()) )
     645#endif
    606646        rpsCurrList0[cIdx] = ilpPic[i];
    607647      }
     
    632672#endif
    633673      {
     674#if ILR_RESTR
     675        maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[i]->getSlice(0)->getLayerId());
     676        if( ((Int)(ilpPic[i]->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[i]->getSlice(0)->getRapPicFlag()) )
     677#endif
    634678        rpsCurrList1[cIdx] = ilpPic[i];
    635679      }
     
    16031647#if JCTVC_M0458_INTERLAYER_RPS_SIG
    16041648  m_maxOneActiveRefLayerFlag = true;
     1649#endif
     1650#if JCTVC_M0203_INTERLAYER_PRED_IDC
     1651  for( Int i = 0; i < MAX_VPS_LAYER_ID_PLUS1 - 1; i++)
     1652  {
     1653    m_maxSublayerForIlpPlus1[i] = m_uiMaxTLayers + 1;
     1654  }
    16051655#endif
    16061656}
  • branches/SHM-2.1-dev/source/Lib/TLibCommon/TComSlice.h

    r195 r216  
    560560  Bool       m_maxOneActiveRefLayerFlag;
    561561#endif
     562#if JCTVC_M0203_INTERLAYER_PRED_IDC
     563  UInt       m_maxSublayerForIlpPlus1[MAX_VPS_LAYER_ID_PLUS1 - 1];
     564#endif
    562565public:
    563566  TComVPS();
     
    712715  Void   setMaxOneActiveRefLayerFlag(Bool x)                                    { m_maxOneActiveRefLayerFlag = x;                         }
    713716#endif
     717#if JCTVC_M0203_INTERLAYER_PRED_IDC
     718  Bool   getMaxSublayerForIlpPlus1(Int layerId)                     { return m_maxSublayerForIlpPlus1[layerId];                   }
     719  Void   setMaxSublayerForIlpPlus1(Int layerId, UInt maxSublayer)   { m_maxSublayerForIlpPlus1[layerId] = maxSublayer;            }
     720#endif
    714721};
    715722
  • branches/SHM-2.1-dev/source/Lib/TLibCommon/TypeDef.h

    r212 r216  
    9595#define ZERO_NUM_DIRECT_LAYERS           1      ///< support of zero direct reference layers
    9696#endif
     97#define JCTVC_M0203_INTERLAYER_PRED_IDC  1      ///< implementation of JCTVC-M0203 Inter-layer Prediction Indication
     98#if JCTVC_M0203_INTERLAYER_PRED_IDC
     99#define ILR_RESTR                        1     ///< JCTVC-M0209 Inter-layer RPS and RPL
     100#endif
     101
    97102#else
    98103#define INTRA_BL                         1      ///< inter-layer texture prediction
Note: See TracChangeset for help on using the changeset viewer.