Index: branches/SHM-3.1-dev/source/App/TAppEncoder/TAppEncTop.cpp
===================================================================
--- branches/SHM-3.1-dev/source/App/TAppEncoder/TAppEncTop.cpp	(revision 398)
+++ branches/SHM-3.1-dev/source/App/TAppEncoder/TAppEncTop.cpp	(revision 399)
@@ -941,7 +941,7 @@
     {
 #if N0120_MAX_TID_REF_CFG
-      vps->setMaxSublayerForIlpPlus1(i, m_acTEncTop[i].getMaxTidIlRefPicsPlus1()); 
+      vps->setMaxTidIlRefPicsPlus1(i, m_acTEncTop[i].getMaxTidIlRefPicsPlus1()); 
 #else 
-      vps->setMaxSublayerForIlpPlus1(i, vps->getMaxTLayers()+1);
+      vps->setMaxTidIlRefPicsPlus1(i, vps->getMaxTLayers()+1);
 #endif 
     }
@@ -951,5 +951,5 @@
     for( i = 0; i < MAX_VPS_LAYER_ID_PLUS1 - 1; i++ )
     {
-      vps->setMaxSublayerForIlpPlus1(i, 7);
+      vps->setMaxTidIlRefPicsPlus1(i, 7);
     }
   }
Index: branches/SHM-3.1-dev/source/Lib/TLibCommon/TComSlice.cpp
===================================================================
--- branches/SHM-3.1-dev/source/Lib/TLibCommon/TComSlice.cpp	(revision 398)
+++ branches/SHM-3.1-dev/source/Lib/TLibCommon/TComSlice.cpp	(revision 399)
@@ -446,6 +446,6 @@
 
 #if ILR_RESTR
-    Int maxSubLayerForILPPlus1 = ( m_layerId > 0 && m_activeNumILRRefIdx > 0)? m_pcVPS->getMaxSublayerForIlpPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId()) : 0;
-    if( m_layerId > 0 && m_activeNumILRRefIdx > 0 && ( ( (Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=  maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )  ) 
+    Int maxTidIlRefPicsPlus1 = ( m_layerId > 0 && m_activeNumILRRefIdx > 0)? m_pcVPS->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId()) : 0;
+    if( m_layerId > 0 && m_activeNumILRRefIdx > 0 && ( ( (Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=  maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )  ) 
 #else //#if ILR_RESTR
     if( m_layerId > 0 && m_activeNumILRRefIdx > 0 )
@@ -484,6 +484,6 @@
     for( i=0; i < m_pcVPS->getNumDirectRefLayers( m_layerId ); i++ )
     {
-      Int maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[i]->getSlice(0)->getLayerId());
-      if( ((Int)(ilpPic[i]->getSlice(0)->getTLayer())<= maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[i]->getSlice(0)->getRapPicFlag() ) )
+      Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[i]->getSlice(0)->getLayerId());
+      if( ((Int)(ilpPic[i]->getSlice(0)->getTLayer())<= maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[i]->getSlice(0)->getRapPicFlag() ) )
       {
         numInterLayerRPSPics++;
@@ -625,6 +625,6 @@
         Int refLayerIdc = m_interLayerPredLayerIdc[i];
 #if ILR_RESTR
-        Int maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId());
-        if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )
+        Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId());
+        if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )
 #endif
           rpsCurrList0[cIdx] = ilpPic[refLayerIdc];
@@ -653,6 +653,6 @@
         Int refLayerIdc = m_interLayerPredLayerIdc[i];
 #if ILR_RESTR
-         Int maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId());
-        if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )
+         Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId());
+        if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )
 #endif
         rpsCurrList0[cIdx] = ilpPic[refLayerIdc];
@@ -690,6 +690,6 @@
         Int refLayerIdc = m_interLayerPredLayerIdc[i];
 #if ILR_RESTR
-        Int maxSubLayerForILPPlus1 = getVPS()->getMaxSublayerForIlpPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId());
-        if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )
+        Int maxTidIlRefPicsPlus1 = getVPS()->getMaxTidIlRefPicsPlus1(ilpPic[refLayerIdc]->getSlice(0)->getLayerId());
+        if( ((Int)(ilpPic[refLayerIdc]->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && ilpPic[refLayerIdc]->getSlice(0)->getRapPicFlag()) )
 #endif
         rpsCurrList1[cIdx] = ilpPic[refLayerIdc];
@@ -1801,9 +1801,9 @@
 #if JCTVC_M0203_INTERLAYER_PRED_IDC
 #if N0120_MAX_TID_REF_PRESENT_FLAG
-  m_maxTidIlRefPicsPlus1PresentFlag = true;
+  m_maxTidRefPresentFlag = true;
 #endif 
   for( Int i = 0; i < MAX_VPS_LAYER_ID_PLUS1 - 1; i++)
   {
-    m_maxSublayerForIlpPlus1[i] = m_uiMaxTLayers + 1;
+    m_maxTidIlRefPicsPlus1[i] = m_uiMaxTLayers + 1;
   }
 #endif
Index: branches/SHM-3.1-dev/source/Lib/TLibCommon/TComSlice.h
===================================================================
--- branches/SHM-3.1-dev/source/Lib/TLibCommon/TComSlice.h	(revision 398)
+++ branches/SHM-3.1-dev/source/Lib/TLibCommon/TComSlice.h	(revision 399)
@@ -524,8 +524,8 @@
 #endif
 #if JCTVC_M0203_INTERLAYER_PRED_IDC
-  UInt       m_maxSublayerForIlpPlus1[MAX_VPS_LAYER_ID_PLUS1 - 1];
+  UInt       m_maxTidIlRefPicsPlus1[MAX_VPS_LAYER_ID_PLUS1 - 1];
 #endif
 #if N0120_MAX_TID_REF_PRESENT_FLAG
-  Bool       m_maxTidIlRefPicsPlus1PresentFlag;
+  Bool       m_maxTidRefPresentFlag;
 #endif 
 #if M0040_ADAPTIVE_RESOLUTION_CHANGE
@@ -717,10 +717,10 @@
 #endif 
 #if JCTVC_M0203_INTERLAYER_PRED_IDC
-  UInt   getMaxSublayerForIlpPlus1(Int layerId)                     { return m_maxSublayerForIlpPlus1[layerId];                   }
-  Void   setMaxSublayerForIlpPlus1(Int layerId, UInt maxSublayer)   { m_maxSublayerForIlpPlus1[layerId] = maxSublayer;            }
+  UInt   getMaxTidIlRefPicsPlus1(Int layerId)                     { return m_maxTidIlRefPicsPlus1[layerId];                   }
+  Void   setMaxTidIlRefPicsPlus1(Int layerId, UInt maxSublayer)   { m_maxTidIlRefPicsPlus1[layerId] = maxSublayer;            }
 #endif
 #if N0120_MAX_TID_REF_PRESENT_FLAG
-  Bool   getMaxTidRefPresentFlag()                                  { return m_maxTidIlRefPicsPlus1PresentFlag ;}
-  Void   setMaxTidRefPresentFlag(Bool x)                            { m_maxTidIlRefPicsPlus1PresentFlag = x;}
+  Bool   getMaxTidRefPresentFlag()                                  { return m_maxTidRefPresentFlag ;}
+  Void   setMaxTidRefPresentFlag(Bool x)                            { m_maxTidRefPresentFlag = x;}
 #endif 
 #if M0040_ADAPTIVE_RESOLUTION_CHANGE
Index: branches/SHM-3.1-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp
===================================================================
--- branches/SHM-3.1-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 398)
+++ branches/SHM-3.1-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 399)
@@ -1003,5 +1003,5 @@
     for(i = 0; i < vps->getMaxLayers() - 1; i++)
     {
-      READ_CODE( 3, uiCode, "max_sublayer_for_ilp_plus1[i]" ); vps->setMaxSublayerForIlpPlus1(i, uiCode);
+      READ_CODE( 3, uiCode, "max_tid_il_ref_pics_plus1[i]" ); vps->setMaxTidIlRefPicsPlus1(i, uiCode);
 #if N0120_MAX_TID_REF_CFG
       assert( uiCode <= vps->getMaxTLayers());
@@ -1015,5 +1015,5 @@
     for(i = 0; i < vps->getMaxLayers() - 1; i++)
     {
-      vps->setMaxSublayerForIlpPlus1(i, 7);
+      vps->setMaxTidIlRefPicsPlus1(i, 7);
     }
   }
@@ -1021,5 +1021,5 @@
   for(i = 0; i < vps->getMaxLayers() - 1; i++)
   {
-    READ_CODE( 3, uiCode, "max_sublayer_for_ilp_plus1[i]" ); vps->setMaxSublayerForIlpPlus1(i, uiCode);
+    READ_CODE( 3, uiCode, "max_tid_il_ref_pics_plus1[i]" ); vps->setMaxTidIlRefPicsPlus1(i, uiCode);
     assert( uiCode <= vps->getMaxTLayers() );
   }
Index: branches/SHM-3.1-dev/source/Lib/TLibDecoder/TDecTop.cpp
===================================================================
--- branches/SHM-3.1-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 398)
+++ branches/SHM-3.1-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 399)
@@ -467,5 +467,5 @@
 
   Int remainingInterLayerReferencesFlag = 0;
-  if ( currTid <= pcSlice->getVPS()->getMaxSublayerForIlpPlus1(latestDecLayerId) - 1 )
+  if ( currTid <= pcSlice->getVPS()->getMaxTidIlRefPicsPlus1(latestDecLayerId) - 1 )
   {
     for ( Int j = latestDecIdx + 1; j < numTargetDecLayers; j++ )
Index: branches/SHM-3.1-dev/source/Lib/TLibEncoder/TEncCavlc.cpp
===================================================================
--- branches/SHM-3.1-dev/source/Lib/TLibEncoder/TEncCavlc.cpp	(revision 398)
+++ branches/SHM-3.1-dev/source/Lib/TLibEncoder/TEncCavlc.cpp	(revision 399)
@@ -788,5 +788,5 @@
      for( i = 0; i < vps->getMaxLayers() - 1; i++)
      {
-       WRITE_CODE(vps->getMaxSublayerForIlpPlus1(i), 3, "max_sublayer_for_ilp_plus1[i]" );
+       WRITE_CODE(vps->getMaxTidIlRefPicsPlus1(i), 3, "max_tid_il_ref_pics_plus1[i]" );
      }
    }
@@ -794,5 +794,5 @@
   for( i = 0; i < vps->getMaxLayers() - 1; i++)
   {
-    WRITE_CODE(vps->getMaxSublayerForIlpPlus1(i), 3, "max_sublayer_for_ilp_plus1[i]" );
+    WRITE_CODE(vps->getMaxTidIlRefPicsPlus1(i), 3, "max_tid_il_ref_pics_plus1[i]" );
   }
 #endif
Index: branches/SHM-3.1-dev/source/Lib/TLibEncoder/TEncGOP.cpp
===================================================================
--- branches/SHM-3.1-dev/source/Lib/TLibEncoder/TEncGOP.cpp	(revision 398)
+++ branches/SHM-3.1-dev/source/Lib/TLibEncoder/TEncGOP.cpp	(revision 399)
@@ -594,6 +594,6 @@
 #if ILR_RESTR && ILR_RESTR_FIX
         // Apply temporal layer restriction to inter-layer prediction
-        Int maxSubLayerForILPPlus1 = m_pcEncTop->getVPS()->getMaxSublayerForIlpPlus1(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getLayerId());
-        if( ((Int)(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getTLayer())<=maxSubLayerForILPPlus1-1) || (maxSubLayerForILPPlus1==0 && pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getRapPicFlag()) )
+        Int maxTidIlRefPicsPlus1 = m_pcEncTop->getVPS()->getMaxTidIlRefPicsPlus1(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getLayerId());
+        if( ((Int)(pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getTLayer())<=maxTidIlRefPicsPlus1-1) || (maxTidIlRefPicsPlus1==0 && pcSlice->getBaseColPic(refLayerIdc)->getSlice(0)->getRapPicFlag()) )
         {
           interLayerPredLayerIdcTmp[activeNumILRRefIdxTmp++] = refLayerIdc; // add picture to the list of valid inter-layer pictures
