Index: /branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.cpp
===================================================================
--- /branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.cpp	(revision 1115)
+++ /branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.cpp	(revision 1116)
@@ -1482,9 +1482,5 @@
 
       // pcPic is statically created for the external (AVC) base layer, no need to delete it
-#if VPS_AVC_BL_FLAG_REMOVAL
       if( !m_acTDecTop[layerIdx].getParameterSetManager()->getActiveVPS()->getNonHEVCBaseLayerFlag() || layerIdx )
-#else
-      if( !m_acTDecTop[layerIdx].getParameterSetManager()->getActiveVPS()->getAvcBaseLayerFlag() || layerIdx )
-#endif
       {
         delete pcPic;
Index: /branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.cpp
===================================================================
--- /branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.cpp	(revision 1115)
+++ /branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.cpp	(revision 1116)
@@ -108,9 +108,5 @@
 : m_pBitstreamFile()
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
 , m_nonHEVCBaseLayerFlag(0)
-#else
-, m_avcBaseLayerFlag(0)
-#endif
 #endif
 , m_maxTidRefPresentFlag(1)
@@ -1182,9 +1178,5 @@
 #endif
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
   ("NonHEVCBase,-nonhevc",                            m_nonHEVCBaseLayerFlag,                                0, "BL is available but not internal")
-#else
-  ("AvcBase,-avc",                                    m_avcBaseLayerFlag,                                    0, "avc_base_layer_flag")
-#endif
   ("InputBLFile,-ibl",                                cfg_BLInputFile,                              string(""), "Base layer rec YUV input file name")
 #endif
@@ -1793,9 +1785,5 @@
 #if SVC_EXTENSION
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
   if( m_nonHEVCBaseLayerFlag )
-#else
-  if( m_avcBaseLayerFlag )
-#endif
   {
     *cfg_InputFile[0] = cfg_BLInputFile;
@@ -3499,9 +3487,5 @@
   
   // it can be updated after AVC BL support will be added to the WD
-#if VPS_AVC_BL_FLAG_REMOVAL
   if( m_nonHEVCBaseLayerFlag )
-#else
-  if( m_avcBaseLayerFlag )
-#endif
   {
     m_crossLayerIrapAlignFlag = false;
@@ -4514,9 +4498,5 @@
   printf("Scalable                          : %d\n", m_scalabilityMask[SCALABILITY_ID] );
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
   printf("Base layer                        : %s\n", m_nonHEVCBaseLayerFlag ? "Non-HEVC" : "HEVC");
-#else
-  printf("Base layer                        : %s\n", m_avcBaseLayerFlag ? "AVC" : "HEVC");
-#endif
 #endif
 #if AUXILIARY_PICTURES
Index: /branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.h
===================================================================
--- /branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.h	(revision 1115)
+++ /branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.h	(revision 1116)
@@ -70,9 +70,5 @@
   Int       m_framesToBeEncoded;                              ///< number of encoded frames
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
   Int       m_nonHEVCBaseLayerFlag;                           ///< non HEVC BL
-#else
-  Int       m_avcBaseLayerFlag;                               ///< avc_baselayer_flag
-#endif
 #endif
   Bool      m_maxTidRefPresentFlag; 
Index: /branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp
===================================================================
--- /branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp	(revision 1115)
+++ /branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp	(revision 1116)
@@ -291,9 +291,5 @@
 #if REF_IDX_MFM
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
     m_acTEncTop[layer].setMFMEnabledFlag                                  (layer == 0 ? false : ( m_nonHEVCBaseLayerFlag ? false : true ) && m_acLayerCfg[layer].getNumMotionPredRefLayers());
-#else
-    m_acTEncTop[layer].setMFMEnabledFlag                                  (layer == 0 ? false : ( m_avcBaseLayerFlag ? false : true ) && m_acLayerCfg[layer].getNumMotionPredRefLayers());
-#endif
 #else
     m_acTEncTop[layer].setMFMEnabledFlag                                  (layer == 0 ? false : ( m_acLayerCfg[layer].getNumMotionPredRefLayers() > 0 ) );
@@ -1371,5 +1367,4 @@
 #if VPS_EXTN_MASK_AND_DIM_INFO
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
   vps->setNonHEVCBaseLayerFlag( m_nonHEVCBaseLayerFlag );
   if ( m_nonHEVCBaseLayerFlag )
@@ -1377,7 +1372,4 @@
     vps->setBaseLayerInternalFlag (false);
   }
-#else
-  vps->setAvcBaseLayerFlag(m_avcBaseLayerFlag);
-#endif
 #else
   vps->setAvcBaseLayerFlag(false);
Index: /branches/SHM-dev/source/Lib/TLibCommon/TComSlice.cpp
===================================================================
--- /branches/SHM-dev/source/Lib/TLibCommon/TComSlice.cpp	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibCommon/TComSlice.cpp	(revision 1116)
@@ -2022,9 +2022,5 @@
 
 #if VPS_EXTN_MASK_AND_DIM_INFO
-#if VPS_AVC_BL_FLAG_REMOVAL
   m_nonHEVCBaseLayerFlag = false;
-#else
-  m_avcBaseLayerFlag = false;
-#endif
   m_splittingFlag = false;
   ::memset(m_scalabilityMask, 0, sizeof(m_scalabilityMask));
@@ -3712,9 +3708,5 @@
   if ( layerId == 0 || sps->getV1CompatibleSPSFlag() == 1 )
   {
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( layerId == 0 && vps->getNonHEVCBaseLayerFlag() )
-#else
-    if( layerId == 0 && vps->getAvcBaseLayerFlag() )
-#endif
 #else
   if ( layerId == 0 )
@@ -3755,9 +3747,5 @@
   if ( layerId == 0 || sps->getV1CompatibleSPSFlag() == 1 )
   {
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( layerId == 0 && vps->getNonHEVCBaseLayerFlag() )
-#else
-    if( layerId == 0 && vps->getAvcBaseLayerFlag() )
-#endif
 #else
   if ( layerId == 0 )
@@ -3807,9 +3795,5 @@
   if ( layerId == 0 || sps->getV1CompatibleSPSFlag() == 1 )
   {
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( layerId == 0 && vps->getNonHEVCBaseLayerFlag() )
-#else
-    if( layerId == 0 && vps->getAvcBaseLayerFlag() )
-#endif
 #else
   if ( layerId == 0 )
@@ -3854,9 +3838,5 @@
   {
 #endif
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( layerId == 0 && vps->getNonHEVCBaseLayerFlag() )
-#else
-    if( layerId == 0 && vps->getAvcBaseLayerFlag() )
-#endif
     {
       retVal = vps->getVpsRepFormat(layerId)->getBitDepthVpsLuma();
@@ -3896,9 +3876,5 @@
   {
 #endif
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( layerId == 0 && vps->getNonHEVCBaseLayerFlag() )
-#else
-    if( layerId == 0 && vps->getAvcBaseLayerFlag() )
-#endif
     {
       retVal = vps->getVpsRepFormat(layerId)->getBitDepthVpsChroma();
@@ -3944,9 +3920,5 @@
   if ( layerId == 0 || sps->getV1CompatibleSPSFlag() == 1 )
   {
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( layerId == 0 && vps->getNonHEVCBaseLayerFlag() )
-#else
-    if( layerId == 0 && vps->getAvcBaseLayerFlag() )
-#endif
 #else
   if ( layerId == 0 )
Index: /branches/SHM-dev/source/Lib/TLibCommon/TComSlice.h
===================================================================
--- /branches/SHM-dev/source/Lib/TLibCommon/TComSlice.h	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibCommon/TComSlice.h	(revision 1116)
@@ -631,9 +631,5 @@
   // ------------------------------------------
 #if VPS_EXTN_MASK_AND_DIM_INFO
-#if VPS_AVC_BL_FLAG_REMOVAL
   Bool       m_nonHEVCBaseLayerFlag; 
-#else
-  Bool       m_avcBaseLayerFlag;                                // For now, always set to true.
-#endif
   Bool       m_splittingFlag;
   Bool       m_scalabilityMask[MAX_VPS_NUM_SCALABILITY_TYPES];
@@ -1010,11 +1006,6 @@
   Void    setNumLayerSets(UInt v)                               { m_numLayerSets = v;    }
 #if VPS_EXTN_MASK_AND_DIM_INFO
-#if VPS_AVC_BL_FLAG_REMOVAL
   Bool   getNonHEVCBaseLayerFlag()                              { return m_nonHEVCBaseLayerFlag;   }
   Void   setNonHEVCBaseLayerFlag(Bool x)                        { m_nonHEVCBaseLayerFlag = x;      }
-#else
-  Bool   getAvcBaseLayerFlag()                                  { return m_avcBaseLayerFlag;       }
-  Void   setAvcBaseLayerFlag(Bool x)                            { m_avcBaseLayerFlag = x;          }
-#endif
 
   Bool   getSplittingFlag()                                     { return m_splittingFlag;          }
Index: /branches/SHM-dev/source/Lib/TLibCommon/TypeDef.h
===================================================================
--- /branches/SHM-dev/source/Lib/TLibCommon/TypeDef.h	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibCommon/TypeDef.h	(revision 1116)
@@ -48,5 +48,4 @@
 #define INFERENCE_POC_MSB_VAL_PRESENT    1      ///< JCTVC-Q0146 -- poc_msb_val_present_flag shall be equal to 0 when slice_header_extension_length is (inferred to be ) equal to 0
 #define NON_REF_NAL_TYPE_DISCARDABLE     1      ///< JCTVC-P0041 -- If discardable picture is a non-IRAP, it must be a non-referenced sub-layer picture
-#define VPS_AVC_BL_FLAG_REMOVAL          1      ///< remove avc_base_layer_flag and direct the function its offer to vps_base_layer_internal_flag and vps_base_layer_available_flag
 #define VPS_RESERVED_FLAGS               1      ///< vps_base_layer_internal_flag and vps_base_layer_available_flag
 #define VPS_VUI_VST_PARAMS               1      ///< JCTVC-R0227: Related to signalling of VST parameters of the base layer.
Index: /branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp
===================================================================
--- /branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 1116)
@@ -1003,7 +1003,5 @@
   READ_FLAG( uiCode, "vps_base_layer_internal_flag");             pcVPS->setBaseLayerInternalFlag( uiCode ? true : false );
   READ_FLAG( uiCode, "vps_base_layer_available_flag");            pcVPS->setBaseLayerAvailableFlag( uiCode ? true : false );
-#if VPS_AVC_BL_FLAG_REMOVAL
   pcVPS->setNonHEVCBaseLayerFlag( (pcVPS->getBaseLayerAvailableFlag() && !pcVPS->getBaseLayerInternalFlag()) ? true : false);
-#endif
 #else
   READ_CODE( 2,  uiCode,  "vps_reserved_three_2bits" );           assert(uiCode == 3);
@@ -2722,8 +2720,4 @@
   UInt numScalabilityTypes = 0, i = 0, j = 0;
 
-#if !VPS_AVC_BL_FLAG_REMOVAL
-  READ_FLAG( uiCode, "avc_base_layer_flag" ); vps->setAvcBaseLayerFlag(uiCode ? true : false);
-#endif
-
   READ_FLAG( uiCode, "splitting_flag" ); vps->setSplittingFlag(uiCode ? true : false);
 
Index: /branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp
===================================================================
--- /branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 1116)
@@ -498,9 +498,5 @@
 
     // When avc_base_layer_flag is equal to 1, it is a requirement of bitstream conformance that the value of sps_scaling_list_ref_layer_id shall be greater than 0
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( activeVPS->getNonHEVCBaseLayerFlag() )
-#else
-    if( activeVPS->getAvcBaseLayerFlag() )
-#endif
     {
       assert( refLayerId > 0 );
@@ -531,9 +527,5 @@
 
     // When avc_base_layer_flag is equal to 1, it is a requirement of bitstream conformance that the value of sps_scaling_list_ref_layer_id shall be greater than 0
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( activeVPS->getNonHEVCBaseLayerFlag() )
-#else
-    if( activeVPS->getAvcBaseLayerFlag() )
-#endif
     {
       assert( refLayerId > 0 );
@@ -561,9 +553,5 @@
 
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
   if( activeVPS->getNonHEVCBaseLayerFlag() )
-#else
-  if( activeVPS->getAvcBaseLayerFlag() )
-#endif
   {
     TComPic* pBLPic = (*m_ppcTDecTop[0]->getListPic()->begin());
@@ -1389,9 +1377,5 @@
   {
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( m_layerId > 0 && m_parameterSetManagerDecoder.getPrefetchedVPS(0)->getNonHEVCBaseLayerFlag() )
-#else
-    if( m_layerId > 0 && m_parameterSetManagerDecoder.getPrefetchedVPS(0)->getAvcBaseLayerFlag() )
-#endif
     {
       TComPic* pBLPic = (*m_ppcTDecTop[0]->getListPic()->begin());
@@ -1748,9 +1732,5 @@
         UInt refLayerId = pcSlice->getVPS()->getRefLayerId(m_layerId, refLayerIdc);
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
         if( refLayerId == 0 && m_parameterSetManagerDecoder.getActiveVPS()->getNonHEVCBaseLayerFlag() )
-#else
-        if( refLayerId == 0 && m_parameterSetManagerDecoder.getActiveVPS()->getAvcBaseLayerFlag() )
-#endif
         {          
           TComPic* pic = *m_ppcTDecTop[0]->getListPic()->begin();
@@ -1864,9 +1844,5 @@
         UInt refLayerIdc = pcSlice->getInterLayerPredLayerIdc(i);
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
         if( pcSlice->getVPS()->getRefLayerId( m_layerId, refLayerIdc ) == 0 && m_parameterSetManagerDecoder.getActiveVPS()->getNonHEVCBaseLayerFlag() )
-#else
-        if( pcSlice->getVPS()->getRefLayerId( m_layerId, refLayerIdc ) == 0 && m_parameterSetManagerDecoder.getActiveVPS()->getAvcBaseLayerFlag() )
-#endif
         {
           pcSlice->setBaseColPic ( refLayerIdc, *m_ppcTDecTop[0]->getListPic()->begin() );
@@ -2233,9 +2209,5 @@
 #endif
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
       if( m_parameterSetManagerDecoder.getPrefetchedVPS(0)->getNonHEVCBaseLayerFlag() )
-#else
-      if( m_parameterSetManagerDecoder.getPrefetchedVPS(0)->getAvcBaseLayerFlag() )
-#endif
       {
         if( !m_ppcTDecTop[0]->getBLReconFile()->good() )
Index: /branches/SHM-dev/source/Lib/TLibEncoder/TEncCavlc.cpp
===================================================================
--- /branches/SHM-dev/source/Lib/TLibEncoder/TEncCavlc.cpp	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibEncoder/TEncCavlc.cpp	(revision 1116)
@@ -2005,7 +2005,4 @@
 #if VPS_EXTN_MASK_AND_DIM_INFO
   UInt i = 0, j = 0;
-#if !VPS_AVC_BL_FLAG_REMOVAL
-  WRITE_FLAG( vps->getAvcBaseLayerFlag(),              "avc_base_layer_flag" );
-#endif
 
   WRITE_FLAG( vps->getSplittingFlag(),                 "splitting_flag" );
Index: /branches/SHM-dev/source/Lib/TLibEncoder/TEncGOP.cpp
===================================================================
--- /branches/SHM-dev/source/Lib/TLibEncoder/TEncGOP.cpp	(revision 1115)
+++ /branches/SHM-dev/source/Lib/TLibEncoder/TEncGOP.cpp	(revision 1116)
@@ -1290,9 +1290,5 @@
       // inferring of the scaling list can be moved to the config file
       UInt refLayerId = 0;
-#if VPS_AVC_BL_FLAG_REMOVAL
       if( m_layerId > 0 && !m_pcEncTop->getVPS()->getNonHEVCBaseLayerFlag() && m_pcEncTop->getVPS()->getRecursiveRefLayerFlag( m_layerId, refLayerId ) )
-#else
-      if( m_layerId > 0 && !m_pcEncTop->getVPS()->getAvcBaseLayerFlag() && m_pcEncTop->getVPS()->getRecursiveRefLayerFlag( m_layerId, refLayerId ) )
-#endif
       {
         m_pcEncTop->getSPS()->setInferScalingListFlag( true );
@@ -1324,9 +1320,5 @@
       // inferring of the scaling list can be moved to the config file
       UInt refLayerId = 0;
-#if VPS_AVC_BL_FLAG_REMOVAL
       if( m_layerId > 0 && !m_pcEncTop->getVPS()->getNonHEVCBaseLayerFlag() && m_pcEncTop->getVPS()->getRecursiveRefLayerFlag( m_layerId, refLayerId ) )
-#else
-      if( m_layerId > 0 && !m_pcEncTop->getVPS()->getAvcBaseLayerFlag() && m_pcEncTop->getVPS()->getRecursiveRefLayerFlag( m_layerId, refLayerId ) )
-#endif
       {
         m_pcEncTop->getSPS()->setInferScalingListFlag( true );
@@ -2292,9 +2284,5 @@
 
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
     if( m_layerId == 0 && m_pcEncTop->getVPS()->getNonHEVCBaseLayerFlag() )
-#else
-    if( m_layerId == 0 && m_pcEncTop->getVPS()->getAvcBaseLayerFlag() )
-#endif
     {
       pcPic->getPicYuvOrg()->copyToPic( pcPic->getPicYuvRec() );
@@ -2388,9 +2376,5 @@
       OutputNALUnit nalu( NAL_UNIT_VPS, 0, 0 ); // The value of nuh_layer_id of VPS NAL unit shall be equal to 0.
 #if AVC_BASE
-#if VPS_AVC_BL_FLAG_REMOVAL
       if( ( m_layerId > 0 && m_pcEncTop->getVPS()->getNonHEVCBaseLayerFlag() ) || ( m_layerId == 0 && !m_pcEncTop->getVPS()->getNonHEVCBaseLayerFlag() ) )
-#else
-      if( ( m_layerId > 0 && m_pcEncTop->getVPS()->getAvcBaseLayerFlag() ) || ( m_layerId == 0 && !m_pcEncTop->getVPS()->getAvcBaseLayerFlag() ) )
-#endif
 #else
       if( m_layerId == 0 )
