Changeset 710 in SHVCSoftware for branches


Ignore:
Timestamp:
20 Apr 2014, 21:14:44 (11 years ago)
Author:
seregin
Message:

add referring the VPS rep_format for the AVC BL

Location:
branches/SHM-6-dev/source/Lib
Files:
2 edited

Legend:

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

    r689 r710  
    20862086  if( layerId == 0 )
    20872087  {
    2088     retVal = sps->getChromaFormatIdc();
     2088    if( vps->getAvcBaseLayerFlag() )
     2089    {
     2090      retVal = vps->getVpsRepFormat(layerId)->getChromaFormatVpsIdc();
     2091    }
     2092    else
     2093    {
     2094      retVal = sps->getChromaFormatIdc();
     2095    }
    20892096  }
    20902097  else
  • branches/SHM-6-dev/source/Lib/TLibDecoder/TDecTop.cpp

    r705 r710  
    779779#endif
    780780
     781#if AVC_BASE
     782  if( activeVPS->getAvcBaseLayerFlag() )
     783  {
     784    TComPic* pBLPic = (*m_ppcTDecTop[0]->getListPic()->begin());
     785    if( m_layerId == 1 && pBLPic->getPicYuvRec() == NULL )
     786    {
     787      UInt refLayerId = 0;
     788      RepFormat* repFormat = activeVPS->getVpsRepFormat( activeVPS->getVpsRepFormatIdx(refLayerId) );
     789
     790      Int  numReorderPics[MAX_TLAYER];
     791      Window conformanceWindow;
     792      Window defaultDisplayWindow;
     793
     794#if AUXILIARY_PICTURES
     795#if SVC_UPSAMPLING
     796#if AVC_SYNTAX
     797      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), repFormat->getChromaFormatVpsIdc(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, activeSPS, true);
     798#else
     799      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), repFormat->getChromaFormatVpsIdc(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, NULL, true);
     800#endif
     801#else
     802      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), repFormat->getChromaFormatVpsIdc(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, true);
     803#endif
     804#else
     805#if SVC_UPSAMPLING
     806#if AVC_SYNTAX
     807      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, activeSPS, true);
     808#else
     809      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, NULL, true);
     810#endif
     811#else
     812      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), onformanceWindow, defaultDisplayWindow, numReorderPics, true);
     813#endif
     814#endif
     815      // it is needed where the VPS is accessed through the slice
     816      pBLPic->getSlice(0)->setVPS( activeVPS );
     817
     818#if O0194_DIFFERENT_BITDEPTH_EL_BL
     819      g_bitDepthYLayer[0] = repFormat->getBitDepthVpsLuma();
     820      g_bitDepthCLayer[0] = repFormat->getBitDepthVpsChroma();
     821#endif
     822    }
     823  }
     824#endif
     825
    781826#if P0312_VERT_PHASE_ADJ
    782827  if( activeVPS->getVpsVuiVertPhaseInUseFlag() == 0 )
     
    19762021    case NAL_UNIT_SPS:
    19772022      xDecodeSPS();
    1978 #if AVC_BASE
    1979       if( m_parameterSetManagerDecoder.getPrefetchedVPS(0)->getAvcBaseLayerFlag() )
    1980       {
    1981         TComPic* pBLPic = (*m_ppcTDecTop[0]->getListPic()->begin());
    1982         if( nalu.m_layerId == 1 && pBLPic->getPicYuvRec() == NULL )
    1983         {
    1984           // using EL SPS with spsId = 1
    1985           TComSPS* sps = m_parameterSetManagerDecoder.getPrefetchedSPS(1);
    1986           Int  numReorderPics[MAX_TLAYER];
    1987           Window &conformanceWindow = sps->getConformanceWindow();
    1988           Window defaultDisplayWindow = sps->getVuiParametersPresentFlag() ? sps->getVuiParameters()->getDefaultDisplayWindow() : Window();
    1989 #if AUXILIARY_PICTURES
    1990 #if SVC_UPSAMPLING
    1991 #if AVC_SYNTAX
    1992           pBLPic->create( m_ppcTDecTop[0]->getBLWidth(), m_ppcTDecTop[0]->getBLHeight(), sps->getChromaFormatIdc(), sps->getMaxCUWidth(), sps->getMaxCUHeight(), sps->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, sps, true);
    1993 #else
    1994           pBLPic->create( m_ppcTDecTop[0]->getBLWidth(), m_ppcTDecTop[0]->getBLHeight(), sps->getChromaFormatIdc(), sps->getMaxCUWidth(), sps->getMaxCUHeight(), sps->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, NULL, true);
    1995 #endif
    1996 #else
    1997           pBLPic->create( m_ppcTDecTop[0]->getBLWidth(), m_ppcTDecTop[0]->getBLHeight(), sps->getChromaFormatIdc(), sps->getMaxCUWidth(), sps->getMaxCUHeight(), sps->getMaxCUDepth(), onformanceWindow, defaultDisplayWindow, numReorderPics, true);
    1998 #endif
    1999 #else
    2000 #if SVC_UPSAMPLING
    2001 #if AVC_SYNTAX
    2002           pBLPic->create( m_ppcTDecTop[0]->getBLWidth(), m_ppcTDecTop[0]->getBLHeight(), sps->getMaxCUWidth(), sps->getMaxCUHeight(), sps->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, sps, true);
    2003 #else
    2004           pBLPic->create( m_ppcTDecTop[0]->getBLWidth(), m_ppcTDecTop[0]->getBLHeight(), sps->getMaxCUWidth(), sps->getMaxCUHeight(), sps->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, NULL, true);
    2005 #endif
    2006 #else
    2007           pBLPic->create( m_ppcTDecTop[0]->getBLWidth(), m_ppcTDecTop[0]->getBLHeight(), sps->getMaxCUWidth(), sps->getMaxCUHeight(), sps->getMaxCUDepth(), onformanceWindow, defaultDisplayWindow, numReorderPics, true);
    2008 #endif
    2009 #endif
    2010 
    2011 #if O0194_DIFFERENT_BITDEPTH_EL_BL
    2012           // set AVC BL bit depth, can be an input parameter from the command line
    2013           g_bitDepthYLayer[0] = 8;
    2014           g_bitDepthCLayer[0] = 8;
    2015 #endif
    2016         }
    2017       }
    2018 #endif
    20192023      return false;
    20202024
Note: See TracChangeset for help on using the changeset viewer.