Ignore:
Timestamp:
9 Dec 2013, 17:16:03 (10 years ago)
Author:
tech
Message:

MV HEVC 6 HLS changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-9.0-dev0/source/App/TAppDecoder/TAppDecTop.cpp

    r655 r730  
    6161{
    6262#if H_MV
     63#if H_MV_LAYER_WISE_STARTUP
     64  for (Int i = 0; i < MAX_NUM_LAYER_IDS; i++)
     65  {
     66    m_layerIdToDecIdx[i] = -1;
     67    m_layerInitilizedFlags[i] = false;
     68  }
     69#else
    6370  for (Int i = 0; i < MAX_NUM_LAYER_IDS; i++) m_layerIdToDecIdx[i] = -1;
     71#endif
    6472#endif
    6573#if H_3D
     
    184192    Bool newSliceDiffPoc   = false;
    185193    Bool newSliceDiffLayer = false;
     194#if H_MV_FIX_SKIP_PICTURES
     195    Bool sliceSkippedFlag = false;
     196#endif
    186197#if H_3D
    187198    Bool allLayersDecoded  = false;     
     
    201212      read(nalu, nalUnit);
    202213#if H_MV     
    203       Int decIdx     = xGetDecoderIdx( nalu.m_layerId , true );
    204      
     214#if !H_MV_6_HRD_O0217_13
     215      Int decIdx     = xGetDecoderIdx( nalu.m_layerId , true );     
     216#endif
     217#if H_MV_6_LAYER_ID_32
     218      if( (m_iMaxTemporalLayer >= 0 && nalu.m_temporalId > m_iMaxTemporalLayer) || !isNaluWithinTargetDecLayerIdSet(&nalu) || nalu.m_layerId > MAX_NUM_LAYER_IDS-1 )
     219#else           
    205220      if( (m_iMaxTemporalLayer >= 0 && nalu.m_temporalId > m_iMaxTemporalLayer) || !isNaluWithinTargetDecLayerIdSet(&nalu) )
     221#endif
    206222      {
    207223        bNewPicture = false;
     224#if H_MV_6_LAYER_ID_32
     225        if ( !bitstreamFile )
     226        {
     227          decIdxLastPic     = decIdxCurrPic;
     228        }
     229#endif
    208230      }
    209231      else
    210       {
     232      {
     233#if H_MV_6_HRD_O0217_13
     234        Int decIdx     = xGetDecoderIdx( nalu.m_layerId , true );     
     235#endif
    211236        newSliceDiffLayer = nalu.isSlice() && ( nalu.m_layerId != layerIdCurrPic ) && !firstSlice;
     237#if H_MV_FIX_SKIP_PICTURES
     238        newSliceDiffPoc   = m_tDecTop[decIdx]->decode(nalu, m_iSkipFrame, m_pocLastDisplay[decIdx], newSliceDiffLayer, sliceSkippedFlag );
     239#else
    212240        newSliceDiffPoc   = m_tDecTop[decIdx]->decode(nalu, m_iSkipFrame, m_pocLastDisplay[decIdx], newSliceDiffLayer );
     241#endif
    213242        // decode function only returns true when all of the following conditions are true
    214243        // - poc in particular layer changes
    215244        // - nalu does not belong to first slice in layer
    216         // - nalu.isSlice() == true     
    217 
     245        // - nalu.isSlice() == true             
     246
     247#if H_MV_6_HRD_O0217_13
     248        // Update TargetDecLayerIdList only when not specified by layer id file, specification by file might actually out of conformance.
     249        if (nalu.m_nalUnitType == NAL_UNIT_VPS && m_targetDecLayerIdSetFileEmpty )
     250        {
     251          TComVPS* vps = m_tDecTop[decIdx]->getPrefetchedVPS();
     252          if ( m_targetOptLayerSetIdx == -1 )
     253          {
     254            // Not normative! Corresponds to specification by "External Means". (Should be set equal to 0, when no external means available. )
     255            m_targetOptLayerSetIdx = vps->getVpsNumLayerSetsMinus1();
     256          }
     257
     258          m_targetDecLayerIdSet = vps->getTargetDecLayerIdList( m_targetOptLayerSetIdx );
     259        }
     260#endif
     261#if H_MV_FIX_SKIP_PICTURES
     262        bNewPicture       = ( newSliceDiffLayer || newSliceDiffPoc ) && !sliceSkippedFlag;
     263        if ( nalu.isSlice() && firstSlice && !sliceSkippedFlag )       
     264#else
    218265        bNewPicture       = newSliceDiffLayer || newSliceDiffPoc;
    219 
    220266        if ( nalu.isSlice() && firstSlice )
     267#endif
    221268        {
    222269          layerIdCurrPic = nalu.m_layerId;
     
    832879{
    833880  Int decIdx = -1;
     881
     882#if H_MV_6_LAYER_ID_32
     883  if ( layerId > MAX_NUM_LAYER_IDS-1 ) 
     884  {
     885    return decIdx;
     886  }
     887#endif
     888
    834889  if ( m_layerIdToDecIdx[ layerId ] != -1 )
    835890  {     
     
    850905    m_tDecTop[ decIdx ]->setDecodedPictureHashSEIEnabled(m_decodedPictureHashSEIEnabled);
    851906    m_tDecTop[ decIdx ]->setIvPicLists( &m_ivPicLists );
     907#if H_MV_LAYER_WISE_STARTUP
     908    m_tDecTop[ decIdx ]->setLayerInitilizedFlags( m_layerInitilizedFlags );
     909#endif
     910
    852911#if H_3D
    853912   m_tDecTop[ decIdx ]->setCamParsCollector( &m_cCamParsCollector );
Note: See TracChangeset for help on using the changeset viewer.