Index: /branches/SHM-6-dev/source/App/TAppEncoder/TAppEncTop.cpp
===================================================================
--- /branches/SHM-6-dev/source/App/TAppEncoder/TAppEncTop.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/App/TAppEncoder/TAppEncTop.cpp	(revision 754)
@@ -1535,5 +1535,5 @@
     if( m_isField )
     {
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #if LAYER_CTB
 #if AUXILIARY_PICTURES
@@ -1555,5 +1555,5 @@
     else
     {
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #if LAYER_CTB
 #if AUXILIARY_PICTURES
@@ -1994,5 +1994,5 @@
     rpcPicYuvRec = new TComPicYuv;
 
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #if LAYER_CTB
 #if AUXILIARY_PICTURES
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComPic.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComPic.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComPic.cpp	(revision 754)
@@ -72,5 +72,5 @@
 {
 }
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
 Void TComPic::create( Int iWidth, Int iHeight, ChromaFormat chromaFormatIDC, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, Window &conformanceWindow, Window &defaultDisplayWindow,
@@ -184,5 +184,5 @@
   
   deleteSEIs(m_SEIs);
-#if SVC_EXTENSION && SVC_UPSAMPLING
+#if SVC_EXTENSION
   for( Int i = 0; i < MAX_LAYERS; i++ )
   {
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComPic.h
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComPic.h	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComPic.h	(revision 754)
@@ -97,21 +97,17 @@
   virtual ~TComPic();
   
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
   Void          create( Int iWidth, Int iHeight, ChromaFormat chromaFormatIDC, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, Window &conformanceWindow, Window &defaultDisplayWindow, 
                         Int *numReorderPics, TComSPS* pcSps = NULL, Bool bIsVirtual = false );
 #else
-  Void          create( Int iWidth, Int iHeight, ChromaFormat chromaFormatIDC, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, Window &conformanceWindow, Window &defaultDisplayWindow, 
-                        Int *numReorderPics, Bool bIsVirtual = false );                        
-#endif
-#else
-#if SVC_UPSAMPLING
   Void          create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, Window &conformanceWindow, Window &defaultDisplayWindow, 
                         Int *numReorderPics, TComSPS* pcSps = NULL, Bool bIsVirtual = false );
+#endif
 #else
   Void          create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, Window &conformanceWindow, Window &defaultDisplayWindow, 
-                        Int *numReorderPics, Bool bIsVirtual = false );                        
-#endif
-#endif
+                        Int *numReorderPics, Bool bIsVirtual = false ); 
+#endif //SVC_EXTENSION 
+
   virtual Void  destroy();
   
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComPicYuv.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComPicYuv.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComPicYuv.cpp	(revision 754)
@@ -67,22 +67,19 @@
 {
 }
+
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
 Void TComPicYuv::create( Int iPicWidth, Int iPicHeight, ChromaFormat chromaFormatIDC, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth, TComSPS* pcSps )
 #else
-Void TComPicYuv::create( Int iPicWidth, Int iPicHeight, ChromaFormat chromaFormatIDC, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth )
-#endif
-#else
-#if SVC_UPSAMPLING
 Void TComPicYuv::create( Int iPicWidth, Int iPicHeight, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth, TComSPS* pcSps )
+#endif
 #else
 Void TComPicYuv::create( Int iPicWidth, Int iPicHeight, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth )
 #endif
-#endif
 {
   m_iPicWidth       = iPicWidth;
   m_iPicHeight      = iPicHeight;
   
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
   if(pcSps != NULL)
   {
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComPicYuv.h
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComPicYuv.h	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComPicYuv.h	(revision 754)
@@ -42,5 +42,5 @@
 #include "CommonDef.h"
 #include "TComRom.h"
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #include "TComSlice.h"
 #endif
@@ -94,7 +94,5 @@
   ChromaFormat m_chromaFormatIDC; ////< Chroma Format
 #endif
-#if SVC_UPSAMPLING
   Window  m_conformanceWindow;
-#endif
 #if M0040_ADAPTIVE_RESOLUTION_CHANGE
   Bool    m_isReconstructed;
@@ -112,17 +110,13 @@
   //  Memory management
   // ------------------------------------------------------------------------------------------------
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
   Void  create      ( Int iPicWidth, Int iPicHeight, ChromaFormat chromaFormatIDC, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth, TComSPS* pcSps = NULL);
 #else
-  Void  create      ( Int iPicWidth, Int iPicHeight, ChromaFormat chromaFormatIDC, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth );
-#endif  
-#else
-#if SVC_UPSAMPLING
   Void  create      ( Int iPicWidth, Int iPicHeight, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth, TComSPS* pcSps = NULL);
+#endif
 #else
   Void  create      ( Int iPicWidth, Int iPicHeight, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth );
-#endif  
-#endif
+#endif //SVC_EXTENSION
   
   Void  destroy     ();
@@ -187,8 +181,6 @@
 #if SVC_EXTENSION
   Void   setHeight   ( Int iPicHeight )     { m_iPicHeight = iPicHeight; }
-#if SVC_UPSAMPLING
   Window& getConformanceWindow()                           { return  m_conformanceWindow;             }
   Void    setConformanceWindow(Window& conformanceWindow ) { m_conformanceWindow = conformanceWindow; }
-#endif
 #if M0040_ADAPTIVE_RESOLUTION_CHANGE
   Void  setReconstructed(Bool x) { m_isReconstructed = x;    }
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComPrediction.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComPrediction.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComPrediction.cpp	(revision 754)
@@ -781,5 +781,5 @@
 }
 
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #if O0215_PHASE_ALIGNMENT
 #if O0194_JOINT_US_BITSHIFT
@@ -807,4 +807,4 @@
 #endif
 #endif
-#endif
+#endif //SVC_EXTENSION
 //! \}
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComPrediction.h
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComPrediction.h	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComPrediction.h	(revision 754)
@@ -48,5 +48,5 @@
 #include "TComWeightPrediction.h"
 
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #include "TComUpsampleFilter.h"
 #endif
@@ -72,8 +72,4 @@
   
   TComInterpolationFilter m_if;
-  
-#if SVC_UPSAMPLING
-  TComUpsampleFilter      m_cUsf;
-#endif
 
   Pel*   m_pLumaRecBuffer;       ///< array for downsampled reconstructed luma sample 
@@ -94,4 +90,8 @@
   Void xDCPredFiltering( Int* pSrc, Int iSrcStride, Pel*& rpDst, Int iDstStride, Int iWidth, Int iHeight );
   Bool xCheckIdenticalMotion    ( TComDataCU* pcCU, UInt PartAddr);
+  
+#if SVC_EXTENSION
+  TComUpsampleFilter      m_cUsf;
+#endif
 
 public:
@@ -118,5 +118,4 @@
 
 #if SVC_EXTENSION
-#if SVC_UPSAMPLING
 #if O0215_PHASE_ALIGNMENT
 #if O0194_JOINT_US_BITSHIFT
@@ -132,5 +131,4 @@
 #endif
 #endif
-#endif
 #endif //SVC_EXTENSION
 };
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TComUpsampleFilter.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TComUpsampleFilter.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TComUpsampleFilter.cpp	(revision 754)
@@ -1,7 +1,6 @@
-
+#include "TypeDef.h"
+#if SVC_EXTENSION
 #include "TComUpsampleFilter.h"
-#include "TypeDef.h"
-
-#if SVC_UPSAMPLING
+
 #define CNU -1 ///< Coefficients Not Used
 
Index: /branches/SHM-6-dev/source/Lib/TLibCommon/TypeDef.h
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibCommon/TypeDef.h	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibCommon/TypeDef.h	(revision 754)
@@ -179,5 +179,4 @@
 #define DERIVE_LAYER_ID_LIST_VARIABLES   1      ///< Derived variables based on the variables in VPS - for use in syntax table parsing
 
-#define SVC_UPSAMPLING                   1      ///< upsampling filters
 #define ROUNDING_OFFSET                  1      ///< JCTVC-N0111: upsampling rounding offset using scalling factors
 #define N0214_INTERMEDIATE_BUFFER_16BITS 1      ///< JCTVC-N0214: support base layer input more than 8 bits
Index: /branches/SHM-6-dev/source/Lib/TLibDecoder/TDecTop.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 754)
@@ -228,31 +228,16 @@
 
         m_cIlpPic[j] = new  TComPic;
+
 #if AUXILIARY_PICTURES
 #if REPN_FORMAT_IN_VPS
-#if SVC_UPSAMPLING
         m_cIlpPic[j]->create(picWidth, picHeight, slice->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, pcSPS, true);
 #else
-        m_cIlpPic[j]->create(picWidth, picHeight, slice->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
         m_cIlpPic[j]->create(pcSPS->getPicWidthInLumaSamples(), pcSPS->getPicHeightInLumaSamples(), pcSPS->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, pcSPS, true);
-#else
-        m_cIlpPic[j]->create(pcSPS->getPicWidthInLumaSamples(), pcSPS->getPicHeightInLumaSamples(), pcSPS->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
 #endif
 #else
 #if REPN_FORMAT_IN_VPS
-#if SVC_UPSAMPLING
         m_cIlpPic[j]->create(picWidth, picHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, pcSPS, true);
 #else
-        m_cIlpPic[j]->create(picWidth, picHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
         m_cIlpPic[j]->create(pcSPS->getPicWidthInLumaSamples(), pcSPS->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, pcSPS, true);
-#else
-        m_cIlpPic[j]->create(pcSPS->getPicWidthInLumaSamples(), pcSPS->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
 #endif
 #endif
@@ -404,43 +389,28 @@
       }
     }
-#endif
-    
+
 #if AUXILIARY_PICTURES
 #if REPN_FORMAT_IN_VPS
-#if SVC_UPSAMPLING
     rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), pcSlice->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                      conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
 #else
-    rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), pcSlice->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
-                     conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
     rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), pcSlice->getSPS()->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                      conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
-#else
-    rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), pcSlice->getSPS()->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
-                     conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
 #endif
 #else
 #if REPN_FORMAT_IN_VPS
-#if SVC_UPSAMPLING
     rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                      conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
 #else
-    rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
-                     conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
     rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                      conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
-#else
+#endif
+#endif
+
+#else //SVC_EXTENSION
     rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                      conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#endif
-#endif
+#endif //SVC_EXTENSION
+    
     m_cListPic.pushBack( rpcPic );
     
@@ -481,45 +451,27 @@
   rpcPic->destroy();
 
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
 #if REPN_FORMAT_IN_VPS
-#if SVC_UPSAMPLING
   rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), pcSlice->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
                    conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
-
-#else
-  rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), pcSlice->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
-                   conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
+#else
   rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), pcSlice->getSPS()->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
                    conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
-
-#else
-  rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), pcSlice->getSPS()->getChromaFormatIdc(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
-                   conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
 #endif
 #else
 #if REPN_FORMAT_IN_VPS
-#if SVC_UPSAMPLING
   rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
                    conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
 
 #else
-  rpcPic->create ( pcSlice->getPicWidthInLumaSamples(), pcSlice->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
-                   conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
   rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
                    conformanceWindow, defaultDisplayWindow, numReorderPics, pcSlice->getSPS(), true);
-
-#else
+#endif
+#endif
+#else  //SVC_EXTENSION
   rpcPic->create ( pcSlice->getSPS()->getPicWidthInLumaSamples(), pcSlice->getSPS()->getPicHeightInLumaSamples(), g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth,
                    conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#endif
-#endif
+#endif //SVC_EXTENSION
 }
 
@@ -796,5 +748,4 @@
 
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
 #if AVC_SYNTAX
       pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), repFormat->getChromaFormatVpsIdc(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, activeSPS, true);
@@ -803,15 +754,8 @@
 #endif
 #else
-      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), repFormat->getChromaFormatVpsIdc(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, true);
-#endif
-#else
-#if SVC_UPSAMPLING
 #if AVC_SYNTAX
       pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, activeSPS, true);
 #else
       pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), conformanceWindow, defaultDisplayWindow, numReorderPics, NULL, true);
-#endif
-#else
-      pBLPic->create( repFormat->getPicWidthVpsInLumaSamples(), repFormat->getPicHeightVpsInLumaSamples(), activeSPS->getMaxCUWidth(), activeSPS->getMaxCUHeight(), activeSPS->getMaxCUDepth(), onformanceWindow, defaultDisplayWindow, numReorderPics, true);
 #endif
 #endif
@@ -1695,5 +1639,5 @@
         }
 #endif
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
         if( pcPic->isSpatialEnhLayer(refLayerIdc) )
         {
@@ -1737,5 +1681,5 @@
         }
         pcSlice->setFullPelBaseRec ( refLayerIdc, pcPic->getFullPelBaseRec(refLayerIdc) );
-#endif
+#endif //SVC_EXTENSION
       }
     }
Index: /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncGOP.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncGOP.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncGOP.cpp	(revision 754)
@@ -103,11 +103,11 @@
   m_associatedIRAPPOC  = 0;
 #endif
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
   m_pcPredSearch        = NULL;
-#endif
 #if Q0048_CGS_3D_ASYMLUT
   m_temp = NULL;
   m_pColorMappedPic = NULL;
 #endif
+#endif //SVC_EXTENSION
   return;
 }
@@ -173,8 +173,5 @@
 #if SVC_EXTENSION
   m_ppcTEncTop           = pcTEncTop->getLayerEnc();
-#endif
-#if SVC_UPSAMPLING
   m_pcPredSearch         = pcTEncTop->getPredSearch();                       ///< encoder search class
-#endif
 #if Q0048_CGS_3D_ASYMLUT
   if( pcTEncTop->getLayerId() )
@@ -189,4 +186,5 @@
   }
 #endif
+#endif //SVC_EXTENSION
 }
 
@@ -1089,5 +1087,5 @@
         }
 #endif
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
         if( pcPic->isSpatialEnhLayer(refLayerIdc) )
         {
@@ -1142,5 +1140,5 @@
         }
         pcSlice->setFullPelBaseRec ( refLayerIdc, pcPic->getFullPelBaseRec(refLayerIdc) );
-#endif
+#endif //SVC_EXTENSION
       }
 
Index: /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncGOP.h
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncGOP.h	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncGOP.h	(revision 754)
@@ -135,7 +135,5 @@
   UInt                    m_layerId;      
   TEncTop**               m_ppcTEncTop;
-#if SVC_UPSAMPLING
   TEncSearch*             m_pcPredSearch;                       ///< encoder search class
-#endif  
 #if Q0048_CGS_3D_ASYMLUT
   TEnc3DAsymLUT           m_Enc3DAsymLUTPicUpdate;
Index: /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncPic.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncPic.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncPic.cpp	(revision 754)
@@ -126,20 +126,17 @@
  * \return Void
  */
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
 Void TEncPic::create( Int iWidth, Int iHeight, ChromaFormat chromaFormat, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,  
                       Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, TComSPS* pcSps, Bool bIsVirtual )
-
-#else
-
-Void TEncPic::create( Int iWidth, Int iHeight, ChromaFormat chromaFormat, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,
-                      Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, Bool bIsVirtual )
-#endif
 {
-#if SVC_UPSAMPLING
   TComPic::create( iWidth, iHeight, chromaFormat, uiMaxWidth, uiMaxHeight, uiMaxDepth,  
                    conformanceWindow, defaultDisplayWindow, numReorderPics, pcSps, bIsVirtual );
 #else
-  TComPic::create( iWidth, iHeight, chromaFormat, uiMaxWidth, uiMaxHeight, uiMaxDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, bIsVirtual );
+Void TEncPic::create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,  
+                      Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, TComSPS* pcSps, Bool bIsVirtual )
+{
+  TComPic::create( iWidth, iHeight, uiMaxWidth, uiMaxHeight, uiMaxDepth,  
+                   conformanceWindow, defaultDisplayWindow, numReorderPics, pcSps, bIsVirtual );
 #endif
   m_uiMaxAQDepth = uiMaxAQDepth;
@@ -153,21 +150,10 @@
   }
 }
-#else
-#if SVC_UPSAMPLING
-Void TEncPic::create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,  
-                      Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, TComSPS* pcSps, Bool bIsVirtual )
-
-#else
+#else  //SVC_EXTENSION
 Void TEncPic::create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,  
                       Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, Bool bIsVirtual )
-#endif
 {
-#if SVC_UPSAMPLING
-  TComPic::create( iWidth, iHeight, uiMaxWidth, uiMaxHeight, uiMaxDepth,  
-                   conformanceWindow, defaultDisplayWindow, numReorderPics, pcSps, bIsVirtual );
-#else
   TComPic::create( iWidth, iHeight, uiMaxWidth, uiMaxHeight, uiMaxDepth,  
                    conformanceWindow, defaultDisplayWindow, numReorderPics, bIsVirtual );
-#endif
   m_uiMaxAQDepth = uiMaxAQDepth;
   if ( uiMaxAQDepth > 0 )
@@ -180,5 +166,5 @@
   }
 }
-#endif
+#endif //SVC_EXTENSION
 
 /** Clean up
Index: /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncPic.h
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncPic.h	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncPic.h	(revision 754)
@@ -41,5 +41,5 @@
 #include "TLibCommon/CommonDef.h"
 #include "TLibCommon/TComPic.h"
-#if SVC_UPSAMPLING
+#if SVC_EXTENSION
 #include "TLibCommon/TComSlice.h"
 #endif
@@ -105,22 +105,17 @@
   virtual ~TEncPic();
 
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
   Void          create( Int iWidth, Int iHeight, ChromaFormat chromaFormat, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,  
                       Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, TComSPS* pcSps, Bool bIsVirtual=false );
 #else
-  Void          create( Int iWidth, Int iHeight, ChromaFormat chromaFormat, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,
-                          Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, Bool bIsVirtual = false );
-
-#endif
-#else
-#if SVC_UPSAMPLING
   Void          create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,   
                         Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, TComSPS* pcSps, Bool bIsVirtual = false );
-#else
+#endif
+#else  //SVC_EXTENSION
   Void          create( Int iWidth, Int iHeight, UInt uiMaxWidth, UInt uiMaxHeight, UInt uiMaxDepth, UInt uiMaxAQDepth,   
                         Window &conformanceWindow, Window &defaultDisplayWindow, Int *numReorderPics, Bool bIsVirtual = false );
-#endif
-#endif
+#endif //SVC_EXTENSION
+
   virtual Void  destroy();
 
Index: /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncTop.cpp
===================================================================
--- /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncTop.cpp	(revision 753)
+++ /branches/SHM-6-dev/source/Lib/TLibEncoder/TEncTop.cpp	(revision 754)
@@ -820,21 +820,16 @@
 #endif
 
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
       pcEPic->create( m_iSourceWidth, m_iSourceHeight, m_chromaFormatIDC, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, m_cPPS.getMaxCuDQPDepth()+1 ,
                       m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics, &m_cSPS);
 #else
-      pcEPic->create( m_iSourceWidth, m_iSourceHeight, m_chromaFormatIDC, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, m_cPPS.getMaxCuDQPDepth()+1 ,
-                      m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics);
-#endif
-#else
-#if SVC_UPSAMPLING
       pcEPic->create( m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, m_cPPS.getMaxCuDQPDepth()+1 ,
                       m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics, &m_cSPS);
-#else
+#endif
+#else  //SVC_EXTENSION
       pcEPic->create( m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, m_cPPS.getMaxCuDQPDepth()+1 ,
                       m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics);
-#endif
-#endif
+#endif //SVC_EXTENSION
       rpcPic = pcEPic;
     }
@@ -889,21 +884,16 @@
 #endif
 
+#if SVC_EXTENSION
 #if AUXILIARY_PICTURES
-#if SVC_UPSAMPLING
       rpcPic->create( m_iSourceWidth, m_iSourceHeight, m_chromaFormatIDC, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                       m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics, &m_cSPS);
 #else
-      rpcPic->create( m_iSourceWidth, m_iSourceHeight, m_chromaFormatIDC, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
-                      m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics);
-#endif
-#else
-#if SVC_UPSAMPLING
       rpcPic->create( m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                       m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics, &m_cSPS);
-#else
+#endif
+#else  //SVC_EXTENSION
       rpcPic->create( m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, 
                       m_conformanceWindow, m_defaultDisplayWindow, m_numReorderPics);
-#endif
-#endif
+#endif //SVC_EXTENSION
     }
     m_cListPic.pushBack( rpcPic );
@@ -1582,12 +1572,8 @@
       {
         m_cIlpPic[j] = new  TComPic;
-#if SVC_UPSAMPLING
 #if AUXILIARY_PICTURES
         m_cIlpPic[j]->create(m_iSourceWidth, m_iSourceHeight, m_chromaFormatIDC, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, &m_cSPS, true);
 #else
         m_cIlpPic[j]->create(m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, &m_cSPS, true);
-#endif
-#else
-        m_cIlpPic[j]->create(m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, true);
 #endif
         for (Int i=0; i<m_cIlpPic[j]->getPicSym()->getNumberOfCUsInFrame(); i++)
@@ -1649,12 +1635,8 @@
       {
         m_cIlpPic[j] = new  TComPic;
-#if SVC_UPSAMPLING
 #if AUXILIARY_PICTURES
         m_cIlpPic[j]->create(picWidth, picHeight, m_chromaFormatIDC, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, &m_cSPS, true);
 #else
         m_cIlpPic[j]->create(picWidth, picHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, &m_cSPS, true);
-#endif
-#else
-        m_cIlpPic[j]->create(m_iSourceWidth, m_iSourceHeight, g_uiMaxCUWidth, g_uiMaxCUHeight, g_uiMaxCUDepth, conformanceWindow, defaultDisplayWindow, numReorderPics, true);
 #endif
         for (Int i=0; i<m_cIlpPic[j]->getPicSym()->getNumberOfCUsInFrame(); i++)
