Changeset 872 in 3DVCSoftware for trunk/source/Lib/TLibEncoder/SEIwrite.cpp


Ignore:
Timestamp:
27 Mar 2014, 10:11:29 (10 years ago)
Author:
tech
Message:

Merged HTM-10.0-dev0@871. (MV-HEVC 7 HLS)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/Lib/TLibEncoder/SEIwrite.cpp

    r608 r872  
    44 * granted under this license.
    55 *
    6  * Copyright (c) 2010-2013, ITU/ISO/IEC
     6* Copyright (c) 2010-2014, ITU/ISO/IEC
    77 * All rights reserved.
    88 *
     
    9393    fprintf( g_hTrace, "=========== Scalable Nesting SEI message ===========\n");
    9494    break;
     95#if H_MV_HLS_7_SEI_P0204_26
     96    case SEI::SUB_BITSTREAM_PROPERTY:
     97    fprintf( g_hTrace, "=========== Sub-bitstream property SEI message ===========\n");
     98    break;
     99#endif
    95100  default:
    96101    fprintf( g_hTrace, "=========== Unknown SEI message ===========\n");
     
    146151    xWriteSEIScalableNesting(bs, *static_cast<const SEIScalableNesting*>(&sei), sps);
    147152    break;
     153#if H_MV_HLS_7_SEI_P0204_26
     154   case SEI::SUB_BITSTREAM_PROPERTY:
     155   xWriteSEISubBitstreamProperty(*static_cast<const SEISubBitstreamProperty*>(&sei));
     156   break;
     157#endif
    148158  default:
    149159    assert(!"Unhandled SEI message");
     
    307317  if( !hrd->getSubPicCpbParamsPresentFlag() )
    308318  {
    309     WRITE_FLAG( sei.m_rapCpbParamsPresentFlag, "rap_cpb_params_present_flag" );
     319    WRITE_FLAG( sei.m_rapCpbParamsPresentFlag, "irap_cpb_params_present_flag" );
     320  }
     321  if( sei.m_rapCpbParamsPresentFlag )
     322  {
     323    WRITE_CODE( sei.m_cpbDelayOffset, hrd->getCpbRemovalDelayLengthMinus1() + 1, "cpb_delay_offset" );
     324    WRITE_CODE( sei.m_dpbDelayOffset, hrd->getDpbOutputDelayLengthMinus1()  + 1, "dpb_delay_offset" );
    310325  }
    311326  WRITE_FLAG( sei.m_concatenationFlag, "concatenation_flag");
    312327  WRITE_CODE( sei.m_auCpbRemovalDelayDelta - 1, ( hrd->getCpbRemovalDelayLengthMinus1() + 1 ), "au_cpb_removal_delay_delta_minus1" );
    313   if( sei.m_rapCpbParamsPresentFlag )
    314   {
    315     WRITE_CODE( sei.m_cpbDelayOffset, hrd->getCpbRemovalDelayLengthMinus1() + 1, "cpb_delay_offset" );
    316     WRITE_CODE( sei.m_dpbDelayOffset, hrd->getDpbOutputDelayLengthMinus1()  + 1, "dpb_delay_offset" );
    317   }
    318328  for( nalOrVcl = 0; nalOrVcl < 2; nalOrVcl ++ )
    319329  {
     
    579589}
    580590
     591#if H_MV_HLS_7_SEI_P0204_26
     592Void SEIWriter::xWriteSEISubBitstreamProperty(const SEISubBitstreamProperty &sei)
     593{
     594  WRITE_CODE( sei.m_activeVpsId, 4, "active_vps_id" );
     595  assert( sei.m_numAdditionalSubStreams >= 1 );
     596  WRITE_UVLC( sei.m_numAdditionalSubStreams - 1, "num_additional_sub_streams_minus1" );
     597
     598  for( Int i = 0; i < sei.m_numAdditionalSubStreams; i++ )
     599  {
     600    WRITE_CODE( sei.m_subBitstreamMode[i],       2, "sub_bitstream_mode[i]"           );
     601    WRITE_UVLC( sei.m_outputLayerSetIdxToVps[i],    "output_layer_set_idx_to_vps[i]"  );
     602    WRITE_CODE( sei.m_highestSublayerId[i],      3, "highest_sub_layer_id[i]"         );
     603    WRITE_CODE( sei.m_avgBitRate[i],            16, "avg_bit_rate[i]"                 );
     604    WRITE_CODE( sei.m_maxBitRate[i],            16, "max_bit_rate[i]"                 );
     605  }
     606  xWriteByteAlign();
     607}
     608#endif
     609
    581610Void SEIWriter::xWriteByteAlign()
    582611{
Note: See TracChangeset for help on using the changeset viewer.