Ignore:
Timestamp:
13 Jul 2015, 20:38:11 (9 years ago)
Author:
seregin
Message:

port rev 4219 and rev 4246

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/Lib/TLibDecoder/SEIread.cpp

    r1218 r1235  
    106106 */
    107107#if LAYERS_NOT_PRESENT_SEI
    108 Void SEIReader::parseSEImessage(TComInputBitstream* bs, SEIMessages& seis, const NalUnitType nalUnitType, TComVPS *vps, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    109 #else
    110 Void SEIReader::parseSEImessage(TComInputBitstream* bs, SEIMessages& seis, const NalUnitType nalUnitType, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     108Void SEIReader::parseSEImessage(TComInputBitstream* bs, SEIMessages& seis, const NalUnitType nalUnitType, const TComVPS *vps, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     109#else
     110Void SEIReader::parseSEImessage(TComInputBitstream* bs, SEIMessages& seis, const NalUnitType nalUnitType, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    111111#endif
    112112{
     
    133133#if O0164_MULTI_LAYER_HRD
    134134#if LAYERS_NOT_PRESENT_SEI
    135 Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, TComVPS *vps, TComSPS *sps, std::ostream *pDecodedMessageOutputStream, const SEIScalableNesting *nestingSei, const SEIBspNesting *bspNestingSei)
    136 #else
    137 Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, TComSPS *sps, std::ostream *pDecodedMessageOutputStream, const SEIScalableNesting *nestingSei)
     135Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, const TComVPS *vps, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream, const SEIScalableNesting *nestingSei, const SEIBspNesting *bspNestingSei)
     136#else
     137Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream, const SEIScalableNesting *nestingSei)
    138138#endif
    139139#else
    140140#if LAYERS_NOT_PRESENT_SEI
    141 Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, TComVPS *vps, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    142 #else
    143 Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     141Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, const TComVPS *vps, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     142#else
     143Void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    144144#endif
    145145#endif
     
    557557
    558558#if SVC_EXTENSION
    559 Void SEIReader::xParseSEIDecodingUnitInfo(SEIDecodingUnitInfo& sei, UInt payloadSize, TComSPS *sps, const SEIScalableNesting* nestingSei, const SEIBspNesting* bspNestingSei, TComVPS *vps,std::ostream *pDecodedMessageOutputStream)
    560 #else
    561 Void SEIReader::xParseSEIDecodingUnitInfo(SEIDecodingUnitInfo& sei, UInt payloadSize, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     559Void SEIReader::xParseSEIDecodingUnitInfo(SEIDecodingUnitInfo& sei, UInt payloadSize, const TComSPS *sps, const SEIScalableNesting* nestingSei, const SEIBspNesting* bspNestingSei, const TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
     560#else
     561Void SEIReader::xParseSEIDecodingUnitInfo(SEIDecodingUnitInfo& sei, UInt payloadSize, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    562562#endif
    563563{
     
    568568
    569569#if SVC_EXTENSION
    570   TComHRD *hrd;
     570  const TComHRD *hrd;
    571571  if( bspNestingSei )   // If DU info SEI contained inside a BSP nesting SEI message
    572572  {
     
    577577    Int maxValues = vps->getNumBspSchedulesMinus1(seiOlsIdx, psIdx, maxTemporalId) + 1;
    578578    std::vector<Int> hrdIdx(maxValues, 0);
    579     std::vector<TComHRD *> hrdVec;
     579    std::vector<const TComHRD*> hrdVec;
    580580    std::vector<Int> syntaxElemLen(maxValues, 0);
    581581    for(Int i = 0; i < maxValues; i++)
     
    601601  else
    602602  {
    603     TComVUI *vui = sps->getVuiParameters();
     603    const TComVUI *vui = sps->getVuiParameters();
    604604    hrd = vui->getHrdParameters();
    605605  }
     
    621621  }
    622622#else
    623   TComVUI *vui = sps->getVuiParameters();
     623  const TComVUI *vui = sps->getVuiParameters();
    624624
    625625  if(vui->getHrdParameters()->getSubPicCpbParamsInPicTimingSEIFlag())
     
    642642
    643643#if SVC_EXTENSION
    644 Void SEIReader::xParseSEIBufferingPeriod(SEIBufferingPeriod& sei, UInt payloadSize, TComSPS *sps, const SEIScalableNesting* nestingSei, const SEIBspNesting* bspNestingSei, TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
    645 #else
    646 Void SEIReader::xParseSEIBufferingPeriod(SEIBufferingPeriod& sei, UInt payloadSize, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     644Void SEIReader::xParseSEIBufferingPeriod(SEIBufferingPeriod& sei, UInt payloadSize, const TComSPS *sps, const SEIScalableNesting* nestingSei, const SEIBspNesting* bspNestingSei, const TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
     645#else
     646Void SEIReader::xParseSEIBufferingPeriod(SEIBufferingPeriod& sei, UInt payloadSize, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    647647#endif
    648648{
     
    651651
    652652#if SVC_EXTENSION
    653   TComHRD *pHRD;
     653  const TComHRD *pHRD;
    654654  if( bspNestingSei )   // If BP SEI contained inside a BSP nesting SEI message
    655655  {
     
    660660    Int maxValues = vps->getNumBspSchedulesMinus1(seiOlsIdx, psIdx, maxTemporalId) + 1;
    661661    std::vector<Int> hrdIdx(maxValues, 0);
    662     std::vector<TComHRD *> hrdVec;
     662    std::vector<const TComHRD*> hrdVec;
    663663    std::vector<Int> syntaxElemLen(maxValues, 0);
    664664    for(i = 0; i < maxValues; i++)
     
    683683  else
    684684  {
    685     TComVUI *vui = sps->getVuiParameters();
     685    const TComVUI *vui = sps->getVuiParameters();
    686686    pHRD = vui->getHrdParameters();
    687687  }
    688688  // To be done: When contained in an BSP HRD SEI message, the hrd structure is to be chosen differently.
    689689#else
    690   TComVUI *pVUI = sps->getVuiParameters();
    691   TComHRD *pHRD = pVUI->getHrdParameters();
     690  const TComVUI *pVUI = sps->getVuiParameters();
     691  const TComHRD *pHRD = pVUI->getHrdParameters();
    692692#endif
    693693
     
    746746
    747747#if SVC_EXTENSION
    748 Void SEIReader::xParseSEIPictureTiming(SEIPictureTiming& sei, UInt payloadSize, TComSPS *sps, const SEIScalableNesting* nestingSei, const SEIBspNesting* bspNestingSei, TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
    749 #else
    750 Void SEIReader::xParseSEIPictureTiming(SEIPictureTiming& sei, UInt payloadSize, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     748Void SEIReader::xParseSEIPictureTiming(SEIPictureTiming& sei, UInt payloadSize, const TComSPS *sps, const SEIScalableNesting* nestingSei, const SEIBspNesting* bspNestingSei, const TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
     749#else
     750Void SEIReader::xParseSEIPictureTiming(SEIPictureTiming& sei, UInt payloadSize, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    751751#endif
    752752{
     
    755755
    756756#if SVC_EXTENSION
    757   TComHRD *hrd;   
    758   TComVUI *vui = sps->getVuiParameters();
     757  const TComHRD *hrd;   
     758  const TComVUI *vui = sps->getVuiParameters();
    759759  if( bspNestingSei )   // If BP SEI contained inside a BSP nesting SEI message
    760760  {
     
    765765    Int maxValues = vps->getNumBspSchedulesMinus1(seiOlsIdx, psIdx, maxTemporalId) + 1;
    766766    std::vector<Int> hrdIdx(maxValues, 0);
    767     std::vector<TComHRD *> hrdVec;
     767    std::vector<const TComHRD*> hrdVec;
    768768    std::vector<Int> syntaxElemLen(maxValues, 0);
    769769    for(i = 0; i < maxValues; i++)
     
    796796  // To be done: When contained in an BSP HRD SEI message, the hrd structure is to be chosen differently.
    797797#else
    798   TComVUI *vui = sps->getVuiParameters();
    799   TComHRD *hrd = vui->getHrdParameters();
     798  const TComVUI *vui = sps->getVuiParameters();
     799  const TComHRD *hrd = vui->getHrdParameters();
    800800#endif
    801801  output_sei_message_header(sei, pDecodedMessageOutputStream, payloadSize);
     
    10611061
    10621062#if LAYERS_NOT_PRESENT_SEI
    1063 Void SEIReader::xParseSEIScalableNesting(SEIScalableNesting& sei, const NalUnitType nalUnitType, UInt payloadSize, TComVPS *vps, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    1064 #else
    1065 Void SEIReader::xParseSEIScalableNesting(SEIScalableNesting& sei, const NalUnitType nalUnitType, UInt payloadSize, TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     1063Void SEIReader::xParseSEIScalableNesting(SEIScalableNesting& sei, const NalUnitType nalUnitType, UInt payloadSize, const TComVPS *vps, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
     1064#else
     1065Void SEIReader::xParseSEIScalableNesting(SEIScalableNesting& sei, const NalUnitType nalUnitType, UInt payloadSize, const TComSPS *sps, std::ostream *pDecodedMessageOutputStream)
    10661066#endif
    10671067{
     
    14231423#if SVC_EXTENSION
    14241424#if LAYERS_NOT_PRESENT_SEI
    1425 Void SEIReader::xParseSEILayersNotPresent(SEILayersNotPresent &sei, UInt payloadSize, TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
     1425Void SEIReader::xParseSEILayersNotPresent(SEILayersNotPresent &sei, UInt payloadSize, const TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
    14261426{
    14271427  UInt uiCode;
     
    14851485
    14861486#if SUB_BITSTREAM_PROPERTY_SEI
    1487 Void SEIReader::xParseSEISubBitstreamProperty(SEISubBitstreamProperty &sei, TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
     1487Void SEIReader::xParseSEISubBitstreamProperty(SEISubBitstreamProperty &sei, const TComVPS *vps, std::ostream *pDecodedMessageOutputStream)
    14881488{
    14891489  UInt uiCode;
     
    15101510#if O0164_MULTI_LAYER_HRD
    15111511#if LAYERS_NOT_PRESENT_SEI
    1512 Void SEIReader::xParseSEIBspNesting(SEIBspNesting &sei, const NalUnitType nalUnitType, TComVPS *vps, TComSPS *sps, const SEIScalableNesting &nestingSei, std::ostream *pDecodedMessageOutputStream)
    1513 #else
    1514 Void SEIReader::xParseSEIBspNesting(SEIBspNesting &sei, const NalUnitType nalUnitType, TComSPS *sps, const SEIScalableNesting &nestingSei, std::ostream *pDecodedMessageOutputStream)
     1512Void SEIReader::xParseSEIBspNesting(SEIBspNesting &sei, const NalUnitType nalUnitType, const TComVPS *vps, const TComSPS *sps, const SEIScalableNesting &nestingSei, std::ostream *pDecodedMessageOutputStream)
     1513#else
     1514Void SEIReader::xParseSEIBspNesting(SEIBspNesting &sei, const NalUnitType nalUnitType, const TComSPS *sps, const SEIScalableNesting &nestingSei, std::ostream *pDecodedMessageOutputStream)
    15151515#endif
    15161516{
     
    15371537}
    15381538
    1539 Void SEIReader::xParseSEIBspInitialArrivalTime(SEIBspInitialArrivalTime &sei, TComVPS *vps, TComSPS *sps, const SEIScalableNesting &nestingSei, const SEIBspNesting &bspNestingSei, std::ostream *pDecodedMessageOutputStream)
     1539Void SEIReader::xParseSEIBspInitialArrivalTime(SEIBspInitialArrivalTime &sei, const TComVPS *vps, const TComSPS *sps, const SEIScalableNesting &nestingSei, const SEIBspNesting &bspNestingSei, std::ostream *pDecodedMessageOutputStream)
    15401540{
    15411541  assert(vps->getVpsVuiPresentFlag());
    15421542
    1543 #if SVC_EXTENSION
    15441543  UInt uiCode;
    15451544  Int psIdx         = bspNestingSei.m_seiPartitioningSchemeIdx;
     
    15481547  Int maxValues     = vps->getNumBspSchedulesMinus1(seiOlsIdx, psIdx, maxTemporalId) + 1;
    15491548  std::vector<Int> hrdIdx(0, maxValues);
    1550   std::vector<TComHRD *> hrdVec;
     1549  std::vector<const TComHRD*> hrdVec;
    15511550  std::vector<Int> syntaxElemLen;
    15521551  for(Int i = 0; i < maxValues; i++)
     
    15801579    }
    15811580  }
    1582 #else
    1583   UInt schedCombCnt = vps->getNumBspSchedCombinations(nestingSei.m_nestingOpIdx[0]);
    1584   UInt len;
    1585   UInt hrdIdx;
    1586   UInt uiCode;
    1587 
    1588   if (schedCombCnt > 0)
    1589   {
    1590     hrdIdx = vps->getBspCombHrdIdx(nestingSei.m_nestingOpIdx[0], 0, bspNestingSei.m_bspIdx);
    1591   }
    1592   else
    1593   {
    1594     hrdIdx = 0;
    1595   }
    1596 
    1597   TComHRD *hrd = vps->getBspHrd(hrdIdx);
    1598 
    1599   if (hrd->getNalHrdParametersPresentFlag() || hrd->getVclHrdParametersPresentFlag())
    1600   {
    1601     len = hrd->getInitialCpbRemovalDelayLengthMinus1() + 1;
    1602   }
    1603   else
    1604   {
    1605     len = 23 + 1;
    1606   }
    1607 
    1608   if (hrd->getNalHrdParametersPresentFlag())
    1609   {
    1610     for(UInt i = 0; i < schedCombCnt; i++)
    1611     {
    1612       sei_read_code( pDecodedMessageOutputStream, len, uiCode, "nal_initial_arrival_delay" ); sei.m_nalInitialArrivalDelay[i] = uiCode;
    1613     }
    1614   }
    1615 #if BSP_INIT_ARRIVAL_SEI
    1616   if( hrd->getVclHrdParametersPresentFlag() )
    1617 #else
    1618   else
    1619 #endif
    1620   {
    1621     for(UInt i = 0; i < schedCombCnt; i++)
    1622     {
    1623       sei_read_code( pDecodedMessageOutputStream, len, uiCode, "vcl_initial_arrival_delay" ); sei.m_vclInitialArrivalDelay[i] = uiCode;
    1624     }
    1625   }
    1626 #endif
    16271581}
    16281582
Note: See TracChangeset for help on using the changeset viewer.