Ignore:
Timestamp:
4 Sep 2015, 21:28:58 (9 years ago)
Author:
tech
Message:

Clean-ups. HLS.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-15.0-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp

    r1313 r1317  
    4040#include "SEIwrite.h"
    4141
    42 #if NH_3D
     42#if NH_MV
    4343#include "TEncTop.h"
    4444#endif
     
    5353{
    5454  fprintf( g_hTrace, "=========== Video Parameter Set     ===========\n" );
     55}
    5556
    5657Void  xTraceSPSHeader ()
     
    380381    WRITE_CODE((pcPPS->getDLT()->getDepthViewBitDepth() - 8), 4, "pps_bit_depth_for_depth_layers_minus8");
    381382   
    382 #if NH_3D_DLT_FIX
    383383    for( Int i = 0; i <= pcPPS->getDLT()->getNumDepthViews()-1; i++ )
    384 #else
    385     for( Int i = 0; i <= pcPPS->getDLT()->getNumDepthViews(); i++ )
    386 #endif
    387384    {
    388385      Int layerId = pcPPS->getDLT()->getDepthIdxToLayerId(i);
     
    748745    WRITE_UVLC( pcSPS->getMaxDecPicBuffering(i) - 1,       "sps_max_dec_pic_buffering_minus1[i]" );
    749746    WRITE_UVLC( pcSPS->getNumReorderPics(i),               "sps_max_num_reorder_pics[i]" );
     747#if NH_MV
     748    WRITE_UVLC( pcSPS->getSpsMaxLatencyIncreasePlus1(i),   "sps_max_latency_increase_plus1[i]" );
     749#else
    750750    WRITE_UVLC( pcSPS->getMaxLatencyIncrease(i),           "sps_max_latency_increase_plus1[i]" );
     751#endif
    751752    if (!subLayerOrderingInfoPresentFlag)
    752753    {
     
    814815    codeShortTermRefPicSet( rps,false, i);
    815816  }
     817#if NH_MV
     818  WRITE_FLAG( pcSPS->getLongTermRefPicsPresentFlag() ? 1 : 0,         "long_term_ref_pics_present_flag" );
     819  if (pcSPS->getLongTermRefPicsPresentFlag())
     820#else
    816821  WRITE_FLAG( pcSPS->getLongTermRefsPresent() ? 1 : 0,         "long_term_ref_pics_present_flag" );
    817822  if (pcSPS->getLongTermRefsPresent())
     823#endif
    818824  {
    819825    WRITE_UVLC(pcSPS->getNumLongTermRefPicSPS(), "num_long_term_ref_pics_sps" );
     
    17471753  //write slice address
    17481754  const Int sliceSegmentRsAddress = pcSlice->getPic()->getPicSym()->getCtuTsToRsAddrMap(ctuTsAddress);
    1749 
     1755#if NH_MV
     1756  // This should actually be done somewhere else and not in writing process.
     1757  pcSlice->setFirstSliceSegementInPicFlag( sliceSegmentRsAddress==0 );
     1758  WRITE_FLAG( pcSlice->getFirstSliceSegementInPicFlag() , "first_slice_segment_in_pic_flag" );
     1759#else
    17501760  WRITE_FLAG( sliceSegmentRsAddress==0, "first_slice_segment_in_pic_flag" );
     1761#endif
    17511762  if ( pcSlice->getRapPicFlag() )
    17521763  {
     
    17601771  else
    17611772#endif
    1762 
    17631773  WRITE_UVLC( pcSlice->getPPS()->getPPSId(), "slice_pic_parameter_set_id" );
    17641774  if ( pcSlice->getPPS()->getDependentSliceSegmentsEnabledFlag() && (sliceSegmentRsAddress!=0) )
     
    17721782  if ( !pcSlice->getDependentSliceSegmentFlag() )
    17731783  {
    1774 
    17751784#if NH_MV   
    17761785    Int esb = 0;  //Don't use i, otherwise will shadow something below
     
    18611870        }
    18621871      }
     1872#if NH_MV
     1873      if(pcSlice->getSPS()->getLongTermRefPicsPresentFlag())
     1874#else
    18631875      if(pcSlice->getSPS()->getLongTermRefsPresent())
     1876#endif
    18641877      {
    18651878        Int numLtrpInSH = rps->getNumberOfLongtermPictures();
     
    21962209    Bool isDBFEnabled = (!pcSlice->getDeblockingFilterDisable());
    21972210
    2198     if(pcSlice->getPPS()->getLoopFilterAcrossSlicesEnabledFlag() && ( isSAOEnabled || isDBFEnabled ))
     2211      if(pcSlice->getPPS()->getLoopFilterAcrossSlicesEnabledFlag() && ( isSAOEnabled || isDBFEnabled ))
    21992212    {
    22002213      WRITE_FLAG(pcSlice->getLFCrossSliceBoundaryFlag()?1:0, "slice_loop_filter_across_slices_enabled_flag");
     
    22042217    {
    22052218      Int voiInVps = vps->getVoiInVps( pcSlice->getViewIndex() );
    2206 #if NH_3D_FIX_TICKET_101
    22072219      if( vps->getCpInSliceSegmentHeaderFlag( voiInVps ) )
    2208 #else
    2209       if( vps->getCpInSliceSegmentHeaderFlag( voiInVps ) && !pcSlice->getIsDepth() )
    2210 #endif
    22112220      {
    22122221        for( Int m = 0; m < vps->getNumCp( voiInVps ); m++ )
     
    22572266      if( pcSlice->getPocMsbValRequiredFlag() )
    22582267      {
    2259         pcSlice->setPocMsbValPresentFlag( true );
     2268        pcSlice->setPocMsbCycleValPresentFlag( true );
    22602269      }
    22612270      else
    22622271      {
    2263         pcSlice->setPocMsbValPresentFlag( false );
    2264       }
    2265     }
    2266 
    2267     if( pcSlice->getPocMsbValPresentFlag() )
     2272        pcSlice->setPocMsbCycleValPresentFlag( false );
     2273      }
     2274    }
     2275
     2276    if( pcSlice->getPocMsbCycleValPresentFlag() )
    22682277    {
    22692278//      Int iMaxPOClsb = 1<< pcSlice->getSPS()->getBitsForPOC(); currently unused
    22702279
    22712280      UInt lengthVal = 1;
    2272       UInt tempVal = pcSlice->getPocMsbVal() + 1;
     2281      UInt tempVal = pcSlice->getPocMsbCycleVal() + 1;
    22732282      assert ( tempVal );
    22742283      while( 1 != tempVal )
     
    23142323    if( !pcSlice->getPocMsbValRequiredFlag() &&  pcSlice->getVPS()->getVpsPocLsbAlignedFlag()  )
    23152324    {
    2316       WRITE_FLAG( pcSlice->getPocMsbValPresentFlag( ) ? 1 : 0 , "poc_msb_val_present_flag" );
     2325      WRITE_FLAG( pcSlice->getPocMsbCycleValPresentFlag( ) ? 1 : 0 , "poc_msb_cycle_val_present_flag" );
    23172326    }
    23182327    else
    23192328    {
    2320       assert( pcSlice->getPocMsbValPresentFlag() ==  pcSlice->inferPocMsbValPresentFlag( ) );
     2329      assert( pcSlice->getPocMsbCycleValPresentFlag() ==  pcSlice->inferPocMsbCycleValPresentFlag( ) );
    23212330    }
    23222331   
    2323     if( pcSlice->getPocMsbValPresentFlag() )
    2324     {
    2325       WRITE_UVLC( pcSlice->getPocMsbVal( ), "poc_msb_val" );
     2332    if( pcSlice->getPocMsbCycleValPresentFlag() )
     2333    {
     2334      WRITE_UVLC( pcSlice->getPocMsbCycleVal( ), "poc_msb_cycle_val" );
    23262335    }
    23272336   
     
    23472356  for (Int i = 0; i < maxNumSubLayersMinus1; i++)
    23482357  {
    2349 #if !NH_MV
    2350 #endif
    23512358    WRITE_FLAG( pcPTL->getSubLayerProfilePresentFlag(i), "sub_layer_profile_present_flag[i]" );
    2352 #if !NH_MV
    2353 #endif
    23542359    WRITE_FLAG( pcPTL->getSubLayerLevelPresentFlag(i),   "sub_layer_level_present_flag[i]" );
    23552360  }
Note: See TracChangeset for help on using the changeset viewer.