Changeset 1086 in SHVCSoftware for branches/SHM-dev/source


Ignore:
Timestamp:
26 Mar 2015, 05:06:01 (10 years ago)
Author:
seregin
Message:

fix layerIdc derivation for OLS index

Location:
branches/SHM-dev/source/Lib
Files:
4 edited

Legend:

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

    r1085 r1086  
    35643564#endif
    35653565#if VPS_DPB_SIZE_TABLE
    3566 Int TComVPS::getLayerIdcInOls( Int olsIdx, Int layerId )
     3566Int TComVPS::getLayerIdcForOls( Int olsIdx, Int layerId )
    35673567{
    35683568  Int layerIdc = -1;
    3569 
    3570   std::vector<Int>::iterator it = std::find( m_layerSetLayerIdList[olsIdx].begin(), m_layerSetLayerIdList[olsIdx].end(), layerId );
    3571 
    3572   if( it != m_layerSetLayerIdList[olsIdx].end() )
    3573   {
    3574     layerIdc = (Int)std::distance( m_layerSetLayerIdList[olsIdx].begin(), it );
     3569  UInt lsIdx = m_outputLayerSetIdx[olsIdx];
     3570
     3571  std::vector<Int>::iterator it = std::find( m_layerSetLayerIdList[lsIdx].begin(), m_layerSetLayerIdList[lsIdx].end(), layerId );
     3572
     3573  if( it != m_layerSetLayerIdList[lsIdx].end() )
     3574  {
     3575    layerIdc = (Int)std::distance( m_layerSetLayerIdList[lsIdx].begin(), it );
    35753576  }
    35763577
  • branches/SHM-dev/source/Lib/TLibCommon/TComSlice.h

    r1085 r1086  
    14121412  Int    getMaxVpsDecPicBufferingMinus1(Int olsIdx, Int subDpbIdx, Int subLayerIdx)        { assert(olsIdx != 0); return m_maxVpsDecPicBufferingMinus1[olsIdx][subDpbIdx][subLayerIdx]; }
    14131413  Void   setMaxVpsDecPicBufferingMinus1(Int olsIdx, Int subDpbIdx, Int subLayerIdx, Int x) { m_maxVpsDecPicBufferingMinus1[olsIdx][subDpbIdx][subLayerIdx] = x;    }
    1414   Int    getLayerIdcInOls( Int olsIdx, Int layerId );
     1414  Int    getLayerIdcForOls( Int olsIdx, Int layerId );
    14151415
    14161416#if RESOLUTION_BASED_DPB
  • branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp

    r1085 r1086  
    15451545          if(chkAssert)
    15461546          {
    1547             UInt layerIdc = pcSlice->getVPS()->getLayerIdcInOls( ii, pcSlice->getLayerId() );
     1547            UInt layerIdc = pcSlice->getVPS()->getLayerIdcForOls( ii, pcSlice->getLayerId() );
    15481548            assert(rps->getNumberOfNegativePictures() <= pcSlice->getVPS()->getMaxVpsDecPicBufferingMinus1(ii, layerIdc, pcSlice->getVPS()->getMaxSLayersInLayerSetMinus1(ii)));
    15491549            assert(rps->getNumberOfPositivePictures() <= pcSlice->getVPS()->getMaxVpsDecPicBufferingMinus1(ii, layerIdc, pcSlice->getVPS()->getMaxSLayersInLayerSetMinus1(ii)) - rps->getNumberOfNegativePictures());
  • branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp

    r1085 r1086  
    285285    m_iMaxRefPicNum = pcSlice->getVPS()->getMaxVpsLayerDecPicBuffMinus1( getCommonDecoderParams()->getTargetOutputLayerSetIdx(), layerIdx, pcSlice->getTLayer() ) + 1; // m_uiMaxDecPicBuffering has the space for the picture currently being decoded
    286286#else
    287     m_iMaxRefPicNum = pcSlice->getVPS()->getMaxVpsDecPicBufferingMinus1( m_commonDecoderParams->getTargetOutputLayerSetIdx(), pcSlice->getVPS()->getLayerIdcInOls( pcSlice->getVPS()->getOutputLayerSetIdx( m_commonDecoderParams->getTargetOutputLayerSetIdx()), pcSlice->getLayerId() ), pcSlice->getTLayer() ) + 1; // m_uiMaxDecPicBuffering has the space for the picture currently being decoded
     287    m_iMaxRefPicNum = pcSlice->getVPS()->getMaxVpsDecPicBufferingMinus1( m_commonDecoderParams->getTargetOutputLayerSetIdx(), pcSlice->getVPS()->getLayerIdcForOls( pcSlice->getVPS()->getOutputLayerSetIdx( m_commonDecoderParams->getTargetOutputLayerSetIdx()), pcSlice->getLayerId() ), pcSlice->getTLayer() ) + 1; // m_uiMaxDecPicBuffering has the space for the picture currently being decoded
    288288#endif
    289289  }
     
    671671      if( sps->getMultiLayerExtSpsFlag() )
    672672      {
    673         sps->setMaxDecPicBuffering( activeVPS->getMaxVpsDecPicBufferingMinus1( m_commonDecoderParams->getTargetOutputLayerSetIdx(), activeVPS->getLayerIdcInOls( activeVPS->getOutputLayerSetIdx( m_commonDecoderParams->getTargetOutputLayerSetIdx() ), m_layerId ), i) + 1, i);
     673        sps->setMaxDecPicBuffering( activeVPS->getMaxVpsDecPicBufferingMinus1( m_commonDecoderParams->getTargetOutputLayerSetIdx(), activeVPS->getLayerIdcForOls( activeVPS->getOutputLayerSetIdx( m_commonDecoderParams->getTargetOutputLayerSetIdx() ), m_layerId ), i) + 1, i);
    674674      }
    675675
Note: See TracChangeset for help on using the changeset viewer.