Changeset 738 in 3DVCSoftware for trunk/source/App/TAppDecoder/TAppDecTop.cpp


Ignore:
Timestamp:
10 Dec 2013, 13:50:12 (11 years ago)
Author:
tech
Message:

Merged HTM-9.0-dev0@731. (MV-HEVC 6 HLS)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/App/TAppDecoder/TAppDecTop.cpp

    r655 r738  
    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     
     214#if !H_MV_6_HRD_O0217_13
    203215      Int decIdx     = xGetDecoderIdx( nalu.m_layerId , true );
    204      
     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
    210232      {
     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
     
    216245        // - nalu.isSlice() == true     
    217246
     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;
    219266
    220267        if ( nalu.isSlice() && firstSlice )
     268#endif
    221269        {
    222270          layerIdCurrPic = nalu.m_layerId;
     
    832880{
    833881  Int decIdx = -1;
     882
     883#if H_MV_6_LAYER_ID_32
     884  if ( layerId > MAX_NUM_LAYER_IDS-1 ) 
     885  {
     886    return decIdx;
     887  }
     888#endif
     889
    834890  if ( m_layerIdToDecIdx[ layerId ] != -1 )
    835891  {     
     
    850906    m_tDecTop[ decIdx ]->setDecodedPictureHashSEIEnabled(m_decodedPictureHashSEIEnabled);
    851907    m_tDecTop[ decIdx ]->setIvPicLists( &m_ivPicLists );
     908#if H_MV_LAYER_WISE_STARTUP
     909    m_tDecTop[ decIdx ]->setLayerInitilizedFlags( m_layerInitilizedFlags );
     910#endif
     911
    852912#if H_3D
    853913   m_tDecTop[ decIdx ]->setCamParsCollector( &m_cCamParsCollector );
Note: See TracChangeset for help on using the changeset viewer.