Ticket #1239: max_tlayer_cleanup.patch

File max_tlayer_cleanup.patch, 3.1 KB (added by adarsh, 10 years ago)
  • App/TAppEncoder/TAppEncCfg.cpp

     
    330330  ("LambdaModifier4,-LM4", m_adLambdaModifier[ 4 ], ( Double )1.0, "Lambda modifier for temporal layer 4")
    331331  ("LambdaModifier5,-LM5", m_adLambdaModifier[ 5 ], ( Double )1.0, "Lambda modifier for temporal layer 5")
    332332  ("LambdaModifier6,-LM6", m_adLambdaModifier[ 6 ], ( Double )1.0, "Lambda modifier for temporal layer 6")
    333   ("LambdaModifier7,-LM7", m_adLambdaModifier[ 7 ], ( Double )1.0, "Lambda modifier for temporal layer 7")
    334333
    335334  /* Quantization parameters */
    336335  ("QP,q",          m_fQP,             30.0, "Qp value, if value is float, QP is switched once during encoding")
  • Lib/TLibCommon/CommonDef.h

     
    163163#define DYN_REF_FREE                0           ///< dynamic free of reference memories
    164164
    165165// Explicit temporal layer QP offset
    166 #define MAX_TLAYER                  8           ///< max number of temporal layer
     166#define MAX_TLAYER                  7           ///< max number of temporal layer
    167167#define HB_LAMBDA_FOR_LDC           1           ///< use of B-style lambda for non-key pictures in low-delay mode
    168168
    169169// Fast estimation of generalized B in low-delay mode
  • Lib/TLibCommon/TComSlice.h

     
    223223class TComPTL
    224224{
    225225  ProfileTierLevel m_generalPTL;
    226   ProfileTierLevel m_subLayerPTL[6];      // max. value of max_sub_layers_minus1 is 6
    227   Bool m_subLayerProfilePresentFlag[6];
    228   Bool m_subLayerLevelPresentFlag[6];
     226  ProfileTierLevel m_subLayerPTL    [MAX_TLAYER-1];      // max. value of max_sub_layers_minus1 is MAX_TLAYER-1 (= 6)
     227  Bool m_subLayerProfilePresentFlag [MAX_TLAYER-1];
     228  Bool m_subLayerLevelPresentFlag   [MAX_TLAYER-1];
    229229
    230230public:
    231231  TComPTL();
  • Lib/TLibDecoder/TDecCAVLC.cpp

     
    661661  READ_CODE( 4,  uiCode,  "vps_video_parameter_set_id" );         pcVPS->setVPSId( uiCode );
    662662  READ_CODE( 2,  uiCode,  "vps_reserved_three_2bits" );           assert(uiCode == 3);
    663663  READ_CODE( 6,  uiCode,  "vps_reserved_zero_6bits" );            assert(uiCode == 0);
    664   READ_CODE( 3,  uiCode,  "vps_max_sub_layers_minus1" );          pcVPS->setMaxTLayers( uiCode + 1 );
     664  READ_CODE( 3,  uiCode,  "vps_max_sub_layers_minus1" );          pcVPS->setMaxTLayers( uiCode + 1 );    assert(uiCode <= 6);
    665665  READ_FLAG(     uiCode,  "vps_temporal_id_nesting_flag" );       pcVPS->setTemporalNestingFlag( uiCode ? true:false );
    666666  assert (pcVPS->getMaxTLayers()>1||pcVPS->getTemporalNestingFlag());
    667667  READ_CODE( 16, uiCode,  "vps_reserved_ffff_16bits" );           assert(uiCode == 0xffff);