Ignore:
Timestamp:
25 Sep 2014, 02:15:29 (10 years ago)
Author:
qualcomm
Message:

Implementation of adoptions in:
G0131, G0031, H0042, I0044, I0045

submitted by Hendry (fhendry@…)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-12.0-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp

    r1039 r1053  
    392392      READ_FLAG( uiCode, "pps_extension_reserved_zero_flag" );
    393393    }
     394#if INFERENCE_POC_RESET_INFO_PRESENT
     395    pcPPS->setPocResetInfoPresentFlag( false );
     396#endif
    394397#if !H_3D
    395398    if ( pcPPS->getPpsExtension6bits() )
     
    414417#endif
    415418  }
     419#if INFERENCE_POC_RESET_INFO_PRESENT
     420  else
     421  {
     422    pcPPS->setPpsRangeExtensionsFlag( false );
     423    pcPPS->setPpsMultilayerExtensionFlag( false );
     424    pcPPS->setPps3dExtensionFlag( false );
     425    pcPPS->setPocResetInfoPresentFlag( false );
     426  }
     427#endif
    416428}
    417429
     
    12741286    }
    12751287  }
     1288
     1289#if VPS_MISC_UPDATES   //These codes are moved from below
     1290  if ( pcVPS->getNumIndependentLayers() > 1 )
     1291  {
     1292   READ_UVLC( uiCode, "num_add_layer_sets"      ); pcVPS->setNumAddLayerSets( uiCode );
     1293  }
     1294  for (Int i = 0; i < pcVPS->getNumAddLayerSets(); i++)
     1295  {
     1296    for (Int j = 0; j < pcVPS->getNumIndependentLayers(); j++)
     1297    {
     1298      READ_CODE( pcVPS->getHighestLayerIdxPlus1Len( j ) , uiCode, "highest_layer_idx_plus1" ); pcVPS->setHighestLayerIdxPlus1( i, j, uiCode );
     1299    }
     1300  }
     1301#endif
     1302
    12761303  pcVPS->setRefLayers();
    12771304  READ_FLAG( uiCode, "vps_sub_layers_max_minus1_present_flag" ); pcVPS->setVpsSubLayersMaxMinus1PresentFlag( uiCode == 1 );
     
    13221349  }
    13231350
     1351#if !VPS_MISC_UPDATES   //These codes are moved to earlier position.
    13241352  if ( pcVPS->getNumIndependentLayers() > 1 )
    13251353  {
     
    13331361    }
    13341362  }
     1363#endif
     1364
    13351365  if (pcVPS->getNumLayerSets() > 1)
    13361366  {
     
    13511381    if( i >= pcVPS->getNumLayerSets( ) )   
    13521382    {       
     1383#if !VPS_MISC_UPDATES
    13531384      READ_UVLC( uiCode,      "layer_set_idx_for_ols_minus1[i]" ); pcVPS->setLayerSetIdxForOlsMinus1( i, uiCode );
    1354     }
    1355 
     1385#else
     1386      READ_CODE( pcVPS->getLayerSetIdxForOlsMinus1Len( i ), uiCode, "layer_set_idx_for_ols_minus1[i]" ); pcVPS->setLayerSetIdxForOlsMinus1( i, uiCode );
     1387#endif
     1388    }
     1389
     1390#if !VPS_MISC_UPDATES
    13561391    if ( i > pcVPS->getVpsNumLayerSetsMinus1() || pcVPS->getDefaultOutputLayerIdc() == 2 )
     1392#else
     1393    if ( i > pcVPS->getVpsNumLayerSetsMinus1() || pcVPS->getDefaultOutputLayerIdc() >= 2 )  //According to the spec, value 3 shall be treated as 2
     1394#endif
    13571395    {       
    13581396      for( Int j = 0; j < pcVPS->getNumLayersInIdList( pcVPS->olsIdxToLsIdx( i ) ); j++ )
     
    15211559  if( pcVPSVUI->getBitRatePresentVpsFlag( )  ||  pcVPSVUI->getPicRatePresentVpsFlag( ) )
    15221560  {
     1561#if I0045_BR_PR_ADD_LAYER_SET
     1562    for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i  <  pcVPS->getNumLayerSets(); i++ )
     1563#else
    15231564    for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i  <=  pcVPS->getVpsNumLayerSetsMinus1(); i++ )
     1565#endif
    15241566    {
    15251567      for( Int j = 0; j  <=  pcVPS->getMaxSubLayersInLayerSetMinus1( i ); j++ )
     
    15541596  else
    15551597  {
     1598#if I0045_VPS_VUI_VST_PARAMS
     1599    pcVPSVUI->setVpsNumVideoSignalInfoMinus1( pcVPS->getMaxLayersMinus1() - pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1);
     1600#else
    15561601    pcVPSVUI->setVpsNumVideoSignalInfoMinus1( pcVPS->getMaxLayersMinus1() );
     1602#endif
    15571603  }
    15581604
     
    15651611  }
    15661612
     1613#if I0045_VPS_VUI_VST_PARAMS
     1614  if( pcVPSVUI->getVideoSignalInfoIdxPresentFlag() && pcVPSVUI->getVpsNumVideoSignalInfoMinus1() > 0 )
     1615  {
     1616    for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <=  pcVPS->getMaxLayersMinus1(); i++ )
     1617    {
     1618      READ_CODE( 4, uiCode, "vps_video_signal_info_idx" ); pcVPSVUI->setVpsVideoSignalInfoIdx( i, uiCode );
     1619    }
     1620  }
     1621  else if ( !pcVPSVUI->getVideoSignalInfoIdxPresentFlag() )
     1622  {
     1623    for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <=  pcVPS->getMaxLayersMinus1(); i++ )
     1624    {
     1625      pcVPSVUI->setVpsVideoSignalInfoIdx( i, i );
     1626    }
     1627  }
     1628  else
     1629  {
     1630    for( Int i = pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1; i <=  pcVPS->getMaxLayersMinus1(); i++ )
     1631    {
     1632      pcVPSVUI->setVpsVideoSignalInfoIdx( i, 0 );
     1633    }
     1634  }
     1635#else
    15671636  if( pcVPSVUI->getVideoSignalInfoIdxPresentFlag() && pcVPSVUI->getVpsNumVideoSignalInfoMinus1() > 0 )
    15681637  {
     
    15801649    }
    15811650  }
     1651#endif
    15821652  READ_FLAG( uiCode, "tiles_not_in_use_flag" ); pcVPSVUI->setTilesNotInUseFlag( uiCode == 1 );
    15831653  if( !pcVPSVUI->getTilesNotInUseFlag() )
     
    16411711  if ( pcVPSVUI->getVpsVuiBspHrdPresentFlag( ) )
    16421712  {
     1713#if VPS_MISC_UPDATES
     1714    assert(pcVPS->getTimingInfo()->getTimingInfoPresentFlag() == 1);
     1715#endif
    16431716    parseVpsVuiBspHrdParameters( pcVPS );
    16441717  }
     
    20082081      esb++;
    20092082      READ_FLAG( uiCode, "discardable_flag" ); rpcSlice->setDiscardableFlag( uiCode == 1 );
     2083#if NON_REF_NAL_TYPE_DISCARDABLE
     2084      if ( uiCode == 1 )
     2085      {
     2086        assert(rpcSlice->getNalUnitType() != NAL_UNIT_CODED_SLICE_TRAIL_R &&
     2087          rpcSlice->getNalUnitType() != NAL_UNIT_CODED_SLICE_TSA_R &&
     2088          rpcSlice->getNalUnitType() != NAL_UNIT_CODED_SLICE_STSA_R &&
     2089          rpcSlice->getNalUnitType() != NAL_UNIT_CODED_SLICE_RADL_R &&
     2090          rpcSlice->getNalUnitType() != NAL_UNIT_CODED_SLICE_RASL_R);
     2091      }
     2092#endif
    20102093    }
    20112094
     
    22872370      if (rpcSlice->getSPS()->getTMVPFlagsPresent())
    22882371      {
     2372#if I0044_SLICE_TMVP
     2373        READ_FLAG( uiCode, "slice_temporal_mvp_enabled_flag" );
     2374#else
    22892375        READ_FLAG( uiCode, "slice_temporal_mvp_enable_flag" );
     2376#endif
    22902377        rpcSlice->setEnableTMVPFlag( uiCode == 1 ? true : false );
    22912378      }
     
    27232810#endif
    27242811  }
     2812#if INFERENCE_POC_MSB_VAL_PRESENT
     2813  else
     2814  {
     2815    rpcSlice->setSliceSegmentHeaderExtensionLength( 0 );
     2816    rpcSlice->setPocMsbValPresentFlag( false );
     2817  }
     2818#endif
    27252819
    27262820
Note: See TracChangeset for help on using the changeset viewer.