Changeset 665 in SHVCSoftware for branches/SHM-6-dev/source/Lib/TLibEncoder


Ignore:
Timestamp:
10 Apr 2014, 18:06:20 (11 years ago)
Author:
seregin
Message:

add a check for num_add_output_layer_sets

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-6-dev/source/Lib/TLibEncoder/TEncCavlc.cpp

    r664 r665  
    996996  }
    997997#else
    998   Int numOutputLayerSets = vps->getNumOutputLayerSets() ;
    999   assert( numOutputLayerSets - (Int)vps->getNumLayerSets() >= 0 );
     998  Int numOutputLayerSets = vps->getNumOutputLayerSets();
     999  Int numAddOutputLayerSets = numOutputLayerSets - (Int)vps->getNumLayerSets();
     1000
     1001  // The value of num_add_output_layer_sets shall be in the range of 0 to 1023, inclusive.
     1002  assert( numAddOutputLayerSets >= 0 && numAddOutputLayerSets < 1024 );
    10001003
    10011004#if Q0165_NUM_ADD_OUTPUT_LAYER_SETS
    10021005  if( vps->getNumLayerSets() > 1 )
    10031006  {
    1004     WRITE_UVLC( numOutputLayerSets - vps->getNumLayerSets(), "num_add_output_layer_sets" );
     1007    WRITE_UVLC( numAddOutputLayerSets, "num_add_output_layer_sets" );
    10051008    WRITE_CODE( vps->getDefaultTargetOutputLayerIdc(), 2, "default_target_output_layer_idc" );
    10061009  }
     
    10081011  WRITE_UVLC( numOutputLayerSets - vps->getNumLayerSets(), "num_add_output_layer_sets" );
    10091012#endif
    1010 
    10111013#endif
    10121014
Note: See TracChangeset for help on using the changeset viewer.