Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/ContextTables.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/ContextTables.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/ContextTables.h	(revision 554)
@@ -112,5 +112,7 @@
 #if H_3D_DIM_DMM
 #define NUM_DMM1_DATA_CTX             1       ///< number of context models for DMM1 data
+#if !SEC_DMM2_E0146
 #define NUM_DMM2_DATA_CTX             1       ///< number of context models for DMM2 data
+#endif
 #define NUM_DMM3_DATA_CTX             1       ///< number of context models for DMM3 data
 #endif
@@ -411,4 +413,5 @@
   { CNU }, 
 };
+#if !SEC_DMM2_E0146
 static const UChar
 INIT_DMM2_DATA[3][NUM_DMM2_DATA_CTX] = 
@@ -418,4 +421,5 @@
   { CNU }, 
 };
+#endif
 static const UChar
 INIT_DMM3_DATA[3][NUM_DMM3_DATA_CTX] = 
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComDataCU.cpp
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComDataCU.cpp	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComDataCU.cpp	(revision 554)
@@ -120,5 +120,7 @@
     m_dmmWedgeTabIdx[i] = NULL;
   }
+#if !SEC_DMM2_E0146
   m_dmm2DeltaEnd    = NULL;
+#endif
   m_dmm3IntraTabIdx = NULL;
 #endif
@@ -264,5 +266,7 @@
       m_dmmWedgeTabIdx[i]    = (UInt*)xMalloc(UInt, uiNumPartition);
     }
+#if !SEC_DMM2_E0146
     m_dmm2DeltaEnd    = (Int* )xMalloc(Int,  uiNumPartition);
+#endif
     m_dmm3IntraTabIdx = (UInt*)xMalloc(UInt, uiNumPartition);
 #endif
@@ -389,5 +393,7 @@
       if ( m_dmmWedgeTabIdx[i] ) { xFree( m_dmmWedgeTabIdx[i] ); m_dmmWedgeTabIdx[i] = NULL; }
     }
+#if !SEC_DMM2_E0146
     if ( m_dmm2DeltaEnd    ) { xFree( m_dmm2DeltaEnd    ); m_dmm2DeltaEnd    = NULL; }
+#endif
     if ( m_dmm3IntraTabIdx ) { xFree( m_dmm3IntraTabIdx ); m_dmm3IntraTabIdx = NULL; }
 #endif
@@ -596,5 +602,7 @@
       memset( m_dmmWedgeTabIdx[i] + firstElement, 0,                      numElements * sizeof( *m_dmmWedgeTabIdx[i] ) );
     }
+#if !SEC_DMM2_E0146
     memset( m_dmm2DeltaEnd      + firstElement, 0,                        numElements * sizeof( *m_dmm2DeltaEnd    ) );
+#endif
     memset( m_dmm3IntraTabIdx   + firstElement, 0,                        numElements * sizeof( *m_dmm3IntraTabIdx ) );
 #endif
@@ -767,5 +775,7 @@
         m_dmmWedgeTabIdx[i] [ui] = 0;
       }
+#if !SEC_DMM2_E0146
       m_dmm2DeltaEnd    [ui] = 0;
+#endif
       m_dmm3IntraTabIdx [ui] = 0;
 #endif
@@ -872,5 +882,7 @@
     memset( m_dmmWedgeTabIdx[i], 0, sizeof(UInt) * m_uiNumPartition );
   }
+#if !SEC_DMM2_E0146
   memset( m_dmm2DeltaEnd   , 0, sizeof(Int ) * m_uiNumPartition );
+#endif
   memset( m_dmm3IntraTabIdx, 0, sizeof(UInt) * m_uiNumPartition );
 #endif
@@ -947,5 +959,7 @@
         m_dmmWedgeTabIdx[i] [ui] = pcCU->m_dmmWedgeTabIdx[i] [uiPartOffset+ui];
       }
+#if !SEC_DMM2_E0146
       m_dmm2DeltaEnd    [ui] = pcCU->m_dmm2DeltaEnd   [uiPartOffset+ui];
+#endif
       m_dmm3IntraTabIdx [ui] = pcCU->m_dmm3IntraTabIdx[uiPartOffset+ui];
 #endif
@@ -1095,5 +1109,7 @@
     m_dmmWedgeTabIdx[i] = pcCU->getDmmWedgeTabIdx( i ) + uiPart;
   }
+#if !SEC_DMM2_E0146
   m_dmm2DeltaEnd    = pcCU->getDmm2DeltaEnd()    + uiPart;
+#endif
   m_dmm3IntraTabIdx = pcCU->getDmm3IntraTabIdx() + uiPart;
 #endif
@@ -1282,5 +1298,7 @@
     memcpy( m_dmmWedgeTabIdx[i] + uiOffset, pcCU->getDmmWedgeTabIdx( i ), sizeof(UInt) * uiNumPartition );
   }
+#if !SEC_DMM2_E0146
   memcpy( m_dmm2DeltaEnd    + uiOffset, pcCU->getDmm2DeltaEnd()   , sizeof(Int ) * uiNumPartition );
+#endif
   memcpy( m_dmm3IntraTabIdx + uiOffset, pcCU->getDmm3IntraTabIdx(), sizeof(UInt) * uiNumPartition );
 #endif
@@ -1402,5 +1420,7 @@
     memcpy( rpcCU->getDmmWedgeTabIdx( i ) + m_uiAbsIdxInLCU, m_dmmWedgeTabIdx[i], sizeof(UInt) * m_uiNumPartition );
   }
+#if !SEC_DMM2_E0146
   memcpy( rpcCU->getDmm2DeltaEnd()    + m_uiAbsIdxInLCU, m_dmm2DeltaEnd   , sizeof(Int ) * m_uiNumPartition );
+#endif
   memcpy( rpcCU->getDmm3IntraTabIdx() + m_uiAbsIdxInLCU, m_dmm3IntraTabIdx, sizeof(UInt) * m_uiNumPartition );
 #endif
@@ -1509,5 +1529,7 @@
     memcpy( rpcCU->getDmmWedgeTabIdx( i ) + uiPartOffset, m_dmmWedgeTabIdx[i], sizeof(UInt) * uiQNumPart );
   }
+#if !SEC_DMM2_E0146
   memcpy( rpcCU->getDmm2DeltaEnd()    + uiPartOffset, m_dmm2DeltaEnd   , sizeof(Int ) * uiQNumPart );
+#endif
   memcpy( rpcCU->getDmm3IntraTabIdx() + uiPartOffset, m_dmm3IntraTabIdx, sizeof(UInt) * uiQNumPart );
 #endif
@@ -5434,4 +5456,5 @@
   for( UInt ui = 0; ui < uiCurrPartNumb; ui++ ) { m_dmmWedgeTabIdx[dmmType][uiAbsPartIdx+ui] = tabIdx; }
 }
+#if !SEC_DMM2_E0146
 Void  TComDataCU::setDmm2DeltaEndSubParts( Int iDelta, UInt uiAbsPartIdx, UInt uiDepth )
 {
@@ -5439,4 +5462,5 @@
   for( UInt ui = 0; ui < uiCurrPartNumb; ui++ ) { m_dmm2DeltaEnd[uiAbsPartIdx+ui] = iDelta; }
 }
+#endif
 Void  TComDataCU::setDmm3IntraTabIdxSubParts( UInt uiTIdx, UInt uiAbsPartIdx, UInt uiDepth )
 {
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComDataCU.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComDataCU.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComDataCU.h	(revision 554)
@@ -208,5 +208,7 @@
 #if H_3D_DIM_DMM
   UInt*         m_dmmWedgeTabIdx[DMM_NUM_TYPE]; 
+#if !SEC_DMM2_E0146
   Int*          m_dmm2DeltaEnd;
+#endif
   UInt*         m_dmm3IntraTabIdx;
 #endif
@@ -522,8 +524,10 @@
   Void  setDmmWedgeTabIdxSubParts     ( UInt tabIdx, UInt dmmType, UInt uiAbsPartIdx, UInt uiDepth );
 
+#if !SEC_DMM2_E0146
   Int*  getDmm2DeltaEnd               ()                      { return m_dmm2DeltaEnd;        }
   Int   getDmm2DeltaEnd               ( UInt uiIdx )          { return m_dmm2DeltaEnd[uiIdx]; }
   Void  setDmm2DeltaEnd               ( UInt uiIdx, Int iD )  { m_dmm2DeltaEnd[uiIdx] = iD;   }
   Void  setDmm2DeltaEndSubParts       ( Int iDelta, UInt uiAbsPartIdx, UInt uiDepth );
+#endif
 
   UInt* getDmm3IntraTabIdx            ()                      { return m_dmm3IntraTabIdx;        }
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComPrediction.cpp
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComPrediction.cpp	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComPrediction.cpp	(revision 554)
@@ -436,4 +436,5 @@
         dmmSegmentation = &(g_dmmWedgeLists[ g_aucConvertToBit[iWidth] ][ pcCU->getDmmWedgeTabIdx( dimType, uiAbsPartIdx ) ]);
       } break;
+#if !SEC_DMM2_E0146
     case( DMM2_IDX ):
       {
@@ -447,4 +448,5 @@
         dmmSegmentation = &(g_dmmWedgeLists[ g_aucConvertToBit[iWidth] ][ uiTabIdx ]);
       } break;
+#endif
     case( DMM3_IDX ): 
       {
@@ -2042,5 +2044,9 @@
   {
     UInt dimType =  getDimType( pcTempCU->getLumaIntraDir( uiTempPartIdx ) );
+#if SEC_DMM2_E0146
+    if( DMM1_IDX == dimType || DMM3_IDX == dimType )
+#else
     if( DMM1_IDX == dimType || DMM2_IDX == dimType || DMM3_IDX == dimType )
+#endif
     {
       // get offset between current and reference block
@@ -2067,5 +2073,9 @@
   {
     UInt dimType = getDimType( pcTempCU->getLumaIntraDir( uiTempPartIdx ) );
+#if SEC_DMM2_E0146
+    if( DMM1_IDX == dimType || DMM3_IDX == dimType )
+#else
     if( DMM1_IDX == dimType || DMM2_IDX == dimType || DMM3_IDX == dimType )
+#endif
     {
       // get offset between current and reference block
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComWedgelet.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComWedgelet.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TComWedgelet.h	(revision 554)
@@ -50,4 +50,10 @@
 enum DIM_IDX
 {
+#if SEC_DMM2_E0146
+  DMM1_IDX = 0,
+  DMM3_IDX = 1,
+  DMM4_IDX = 2,
+  RBC_IDX  = 3
+#else
   DMM1_IDX = 0,
   DMM2_IDX = 3,
@@ -55,6 +61,11 @@
   DMM4_IDX = 2,
   RBC_IDX  = 4
+#endif
 };
+#if SEC_DMM2_E0146
+#define DMM_NUM_TYPE   3
+#else
 #define DMM_NUM_TYPE   4
+#endif
 #define RBC_NUM_TYPE   1
 #define DIM_NUM_TYPE   (DMM_NUM_TYPE+RBC_NUM_TYPE)
@@ -75,5 +86,7 @@
 #define DMM_NO_WEDGEINDEX       MAX_UINT
 #define DMM_NUM_WEDGE_REFINES   8
+#if !SEC_DMM2_E0146
 #define DMM2_DELTAEND_MAX       4
+#endif
 #define DMM3_SIMPLIFY_TR        1
 
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TypeDef.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TypeDef.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibCommon/TypeDef.h	(revision 554)
@@ -170,4 +170,7 @@
 #if H_3D_DIM
 #define H_3D_DIM_DMM                      1   // Depth Modeling Modes
+#if H_3D_DIM
+#define SEC_DMM2_E0146                    1   // Removal of DMM2 from DMMs
+#endif
 #define H_3D_DIM_RBC                      1   // Region Boundary Chain mode
 #define H_3D_DIM_SDC                      1   // Simplified Depth Coding method
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibDecoder/TDecSbac.cpp
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibDecoder/TDecSbac.cpp	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibDecoder/TDecSbac.cpp	(revision 554)
@@ -89,5 +89,7 @@
 #if H_3D_DIM_DMM
 , m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
+#if !SEC_DMM2_E0146
 , m_cDmm2DataSCModel          ( 1,             1,               NUM_DMM2_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
+#endif
 , m_cDmm3DataSCModel          ( 1,             1,               NUM_DMM3_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
 #endif
@@ -172,5 +174,7 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM1_DATA );
+#if !SEC_DMM2_E0146
   m_cDmm2DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM2_DATA );
+#endif
   m_cDmm3DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM3_DATA );
 #endif
@@ -241,5 +245,7 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
+#if !SEC_DMM2_E0146
   m_cDmm2DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM2_DATA );
+#endif
   m_cDmm3DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM3_DATA );
 #endif
@@ -423,4 +429,5 @@
   ruiTabIdx = uiIdx;
 }
+#if !SEC_DMM2_E0146
 Void TDecSbac::xParseDmm2Offset( Int& riOffset )
 {
@@ -448,4 +455,5 @@
   riOffset = iDeltaEnd;
 }
+#endif
 Void TDecSbac::xParseDmm3WedgeIdx( UInt& ruiIntraIdx, Int iNumBit )
 {
@@ -1139,4 +1147,5 @@
       pcCU->setDmmWedgeTabIdxSubParts( uiTabIdx, dimType, absPartIdx, depth );
     } break;
+#if !SEC_DMM2_E0146
   case( DMM2_IDX ):
     {
@@ -1145,4 +1154,5 @@
       pcCU->setDmm2DeltaEndSubParts( iOffset, absPartIdx, depth );
     } break;
+#endif
   case( DMM3_IDX ):
     {
@@ -1268,5 +1278,9 @@
       {
         binNum = 0;
+#if SEC_DMM2_E0146
+        while( symbol && binNum < 2 )
+#else
         while( symbol && binNum < 3 )
+#endif
         {
           ctxDepthMode = puIdx*3 + 2;
@@ -1284,6 +1298,10 @@
     else if( modeCode == 6  ) { dir = (2*DMM3_IDX+DIM_OFFSET); sdcFlag = 0;}
     else if( modeCode == 14 ) { dir =      DC_IDX;             sdcFlag = 1;}
+#if SEC_DMM2_E0146
+    else if( modeCode == 15 ) { dir = (2* RBC_IDX+DIM_OFFSET); sdcFlag = 0;}
+#else
     else if( modeCode == 30 ) { dir = (2* RBC_IDX+DIM_OFFSET); sdcFlag = 0;}
     else if( modeCode == 31 ) { dir = (2*DMM2_IDX+DIM_OFFSET); sdcFlag = 0;}
+#endif
   }
   pcCU->setLumaIntraDirSubParts( (UChar)dir, absPartIdx, depth );
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibDecoder/TDecSbac.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibDecoder/TDecSbac.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibDecoder/TDecSbac.h	(revision 554)
@@ -102,5 +102,7 @@
 #if H_3D_DIM_DMM
   Void  xParseDmm1WedgeIdx   ( UInt& ruiTabIdx, Int iNumBit );
+#if !SEC_DMM2_E0146
   Void  xParseDmm2Offset     ( Int& riOffset );
+#endif
   Void  xParseDmm3WedgeIdx   ( UInt& ruiIntraIdx, Int iNumBit );
 #endif
@@ -210,5 +212,7 @@
 #if H_3D_DIM_DMM
   ContextModel3DBuffer m_cDmm1DataSCModel;
+#if !SEC_DMM2_E0146
   ContextModel3DBuffer m_cDmm2DataSCModel;
+#endif
   ContextModel3DBuffer m_cDmm3DataSCModel;
 #endif
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSbac.cpp
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSbac.cpp	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSbac.cpp	(revision 554)
@@ -95,5 +95,7 @@
 #if H_3D_DIM_DMM
 , m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
+#if !SEC_DMM2_E0146
 , m_cDmm2DataSCModel          ( 1,             1,               NUM_DMM2_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
+#endif
 , m_cDmm3DataSCModel          ( 1,             1,               NUM_DMM3_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
 #endif
@@ -170,5 +172,7 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
+#if !SEC_DMM2_E0146
   m_cDmm2DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM2_DATA );
+#endif
   m_cDmm3DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM3_DATA );
 #endif
@@ -249,5 +253,7 @@
 #if H_3D_DIM_DMM
       curCost += m_cDmm1DataSCModel.calcCost          ( curSliceType, qp, (UChar*)INIT_DMM1_DATA );
+#if !SEC_DMM2_E0146
       curCost += m_cDmm2DataSCModel.calcCost          ( curSliceType, qp, (UChar*)INIT_DMM2_DATA );
+#endif
       curCost += m_cDmm3DataSCModel.calcCost          ( curSliceType, qp, (UChar*)INIT_DMM3_DATA );
 #endif
@@ -319,5 +325,7 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
+#if !SEC_DMM2_E0146
   m_cDmm2DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM2_DATA );
+#endif
   m_cDmm3DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM3_DATA );
 #endif
@@ -521,4 +529,5 @@
 }
 
+#if !SEC_DMM2_E0146
 Void TEncSbac::xCodeDmm2Offset( Int iOffset )
 {
@@ -537,4 +546,5 @@
   }
 }
+#endif
 
 Void TEncSbac::xCodeDmm3WedgeIdx( UInt uiIntraIdx, Int iNumBit )
@@ -615,4 +625,5 @@
   UInt uiMaxResidualBits = g_bitDepthY;
 #endif
+
   assert( uiMaxResidualBits <= g_bitDepthY );
   
@@ -1196,8 +1207,10 @@
       xCodeDmm1WedgeIdx( pcCU->getDmmWedgeTabIdx( dimType, absPartIdx ), g_dmm1TabIdxBits[pcCU->getIntraSizeIdx(absPartIdx)] );
     } break;
+#if !SEC_DMM2_E0146
   case( DMM2_IDX ):
     {
       xCodeDmm2Offset( pcCU->getDmm2DeltaEnd( absPartIdx ) );
     } break;
+#endif
   case( DMM3_IDX ):
     {
@@ -1248,6 +1261,11 @@
 Void TEncSbac::codeIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx )
 {
+#if SEC_DMM2_E0146
+  UInt codeWordTable[3][8] =    {{0, 0, 0, 2, 0,6, 0, 7},{0, 2, 3, 4, 5, 6, 14, 15},{0, 2, 0, 0, 0, 0, 3, 0}};
+  UInt codeWordLenTable[3][8] = {{0, 1, 0, 2, 0,3, 0, 3},{2, 3, 3, 3, 3, 3,  4,  4},{1, 2, 0, 0, 0, 0, 2, 0}};
+#else
   UInt codeWordTable[3][9] =    {{0, 0, 0, 2, 0,6, 0, 0, 7},{0, 2, 3, 4, 5, 6, 14, 31, 30},{0, 2, 0, 0, 0, 0, 3, 0, 0}};
   UInt codeWordLenTable[3][9] = {{0, 1, 0, 2, 0,3, 0, 0, 3},{2, 3, 3, 3, 3, 3,  4,  5,  5},{1, 2, 0, 0, 0, 0, 2, 0, 0}};
+#endif
   UInt dir = pcCU->getLumaIntraDir( absPartIdx );
   UInt puIdx = (pcCU->getWidth(absPartIdx) == 64) ? 2 : ( (pcCU->getPartitionSize(absPartIdx) == SIZE_NxN && pcCU->getWidth(absPartIdx) == 8) ? 0 : 1 );
@@ -1265,6 +1283,10 @@
     case DMM4_IDX: codeIdx = 4; break;
     case DMM3_IDX: codeIdx = 5; break;
+#if SEC_DMM2_E0146
+    case  RBC_IDX: codeIdx = 7; break;
+#else
     case DMM2_IDX: codeIdx = 7; break;
     case  RBC_IDX: codeIdx = 8; break;
+#endif
     default:                    break;
     }
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSbac.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSbac.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSbac.h	(revision 554)
@@ -121,5 +121,7 @@
 #if H_3D_DIM_DMM
   Void  xCodeDmm1WedgeIdx    ( UInt uiTabIdx, Int iNumBit );
+#if !SEC_DMM2_E0146
   Void  xCodeDmm2Offset      ( Int iOffset );
+#endif
   Void  xCodeDmm3WedgeIdx    ( UInt uiIntraIdx, Int iNumBit );
 #endif
@@ -250,5 +252,7 @@
 #if H_3D_DIM_DMM
   ContextModel3DBuffer m_cDmm1DataSCModel;
+#if !SEC_DMM2_E0146
   ContextModel3DBuffer m_cDmm2DataSCModel;
+#endif
   ContextModel3DBuffer m_cDmm3DataSCModel;
 #endif
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSearch.cpp
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 554)
@@ -2849,4 +2849,5 @@
               biSegmentation = &(g_dmmWedgeLists[(g_aucConvertToBit[uiWidth])][uiTabIdx]);
             } break;
+#if !SEC_DMM2_E0146
           case( DMM2_IDX ):
             {
@@ -2860,4 +2861,5 @@
               }
             } break;
+#endif
           case( DMM3_IDX ):
             {
@@ -7060,4 +7062,5 @@
 }
 
+#if !SEC_DMM2_E0146
 Void TEncSearch::xSearchDmm2Wedge( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx, Int& riWedgeDeltaEnd )
 {
@@ -7125,4 +7128,5 @@
   return;
 }
+#endif
 
 Void TEncSearch::xSearchDmm3Wedge( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx, UInt& ruiIntraTabIdx )
Index: branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSearch.h
===================================================================
--- branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSearch.h	(revision 551)
+++ branches/HTM-DEV-2.0-dev3-Samsung/source/Lib/TLibEncoder/TEncSearch.h	(revision 554)
@@ -342,5 +342,7 @@
   Void xSearchDmmDeltaDCs         ( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piOrig, Pel* piPredic, UInt uiStride, Bool* biSegPattern, Int patternStride, UInt uiWidth, UInt uiHeight, Pel& rDeltaDC1, Pel& rDeltaDC2 );
   Void xSearchDmm1Wedge           ( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx );
+#if !SEC_DMM2_E0146
   Void xSearchDmm2Wedge           ( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx, Int& riWedgeDeltaEnd );
+#endif
   Void xSearchDmm3Wedge           ( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx, UInt& ruiIntraTabIdx );
 #endif
