Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/ContextTables.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/ContextTables.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/ContextTables.h	(revision 612)
@@ -112,5 +112,5 @@
 #if H_3D_DIM_DMM
 #define NUM_DMM1_DATA_CTX             1       ///< number of context models for DMM1 data
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 #define NUM_DMM2_DATA_CTX             1       ///< number of context models for DMM2 data
 #endif
@@ -429,5 +429,5 @@
   { CNU }, 
 };
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 static const UChar
 INIT_DMM2_DATA[3][NUM_DMM2_DATA_CTX] = 
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComDataCU.cpp
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComDataCU.cpp	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComDataCU.cpp	(revision 612)
@@ -120,5 +120,5 @@
     m_dmmWedgeTabIdx[i] = NULL;
   }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   m_dmm2DeltaEnd    = NULL;
 #endif
@@ -280,5 +280,5 @@
       m_dmmWedgeTabIdx[i]    = (UInt*)xMalloc(UInt, uiNumPartition);
     }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
     m_dmm2DeltaEnd    = (Int* )xMalloc(Int,  uiNumPartition);
 #endif
@@ -419,5 +419,5 @@
       if ( m_dmmWedgeTabIdx[i] ) { xFree( m_dmmWedgeTabIdx[i] ); m_dmmWedgeTabIdx[i] = NULL; }
     }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
     if ( m_dmm2DeltaEnd    ) { xFree( m_dmm2DeltaEnd    ); m_dmm2DeltaEnd    = NULL; }
 #endif
@@ -646,5 +646,5 @@
       memset( m_dmmWedgeTabIdx[i] + firstElement, 0,                      numElements * sizeof( *m_dmmWedgeTabIdx[i] ) );
     }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
     memset( m_dmm2DeltaEnd      + firstElement, 0,                        numElements * sizeof( *m_dmm2DeltaEnd    ) );
 #endif
@@ -829,5 +829,5 @@
         m_dmmWedgeTabIdx[i] [ui] = 0;
       }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
       m_dmm2DeltaEnd    [ui] = 0;
 #endif
@@ -946,5 +946,5 @@
     memset( m_dmmWedgeTabIdx[i], 0, sizeof(UInt) * m_uiNumPartition );
   }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   memset( m_dmm2DeltaEnd   , 0, sizeof(Int ) * m_uiNumPartition );
 #endif
@@ -1036,5 +1036,5 @@
         m_dmmWedgeTabIdx[i] [ui] = pcCU->m_dmmWedgeTabIdx[i] [uiPartOffset+ui];
       }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
       m_dmm2DeltaEnd    [ui] = pcCU->m_dmm2DeltaEnd   [uiPartOffset+ui];
 #endif
@@ -1196,5 +1196,5 @@
     m_dmmWedgeTabIdx[i] = pcCU->getDmmWedgeTabIdx( i ) + uiPart;
   }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   m_dmm2DeltaEnd    = pcCU->getDmm2DeltaEnd()    + uiPart;
 #endif
@@ -1404,5 +1404,5 @@
     memcpy( m_dmmWedgeTabIdx[i] + uiOffset, pcCU->getDmmWedgeTabIdx( i ), sizeof(UInt) * uiNumPartition );
   }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   memcpy( m_dmm2DeltaEnd    + uiOffset, pcCU->getDmm2DeltaEnd()   , sizeof(Int ) * uiNumPartition );
 #endif
@@ -1539,5 +1539,5 @@
     memcpy( rpcCU->getDmmWedgeTabIdx( i ) + m_uiAbsIdxInLCU, m_dmmWedgeTabIdx[i], sizeof(UInt) * m_uiNumPartition );
   }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   memcpy( rpcCU->getDmm2DeltaEnd()    + m_uiAbsIdxInLCU, m_dmm2DeltaEnd   , sizeof(Int ) * m_uiNumPartition );
 #endif
@@ -1658,5 +1658,5 @@
     memcpy( rpcCU->getDmmWedgeTabIdx( i ) + uiPartOffset, m_dmmWedgeTabIdx[i], sizeof(UInt) * uiQNumPart );
   }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   memcpy( rpcCU->getDmm2DeltaEnd()    + uiPartOffset, m_dmm2DeltaEnd   , sizeof(Int ) * uiQNumPart );
 #endif
@@ -6406,5 +6406,5 @@
   for( UInt ui = 0; ui < uiCurrPartNumb; ui++ ) { m_dmmWedgeTabIdx[dmmType][uiAbsPartIdx+ui] = tabIdx; }
 }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 Void  TComDataCU::setDmm2DeltaEndSubParts( Int iDelta, UInt uiAbsPartIdx, UInt uiDepth )
 {
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComDataCU.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComDataCU.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComDataCU.h	(revision 612)
@@ -211,5 +211,5 @@
 #if H_3D_DIM_DMM
   UInt*         m_dmmWedgeTabIdx[DMM_NUM_TYPE]; 
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   Int*          m_dmm2DeltaEnd;
 #endif
@@ -555,5 +555,5 @@
   Void  setDmmWedgeTabIdxSubParts     ( UInt tabIdx, UInt dmmType, UInt uiAbsPartIdx, UInt uiDepth );
 
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   Int*  getDmm2DeltaEnd               ()                      { return m_dmm2DeltaEnd;        }
   Int   getDmm2DeltaEnd               ( UInt uiIdx )          { return m_dmm2DeltaEnd[uiIdx]; }
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComPrediction.cpp
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComPrediction.cpp	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComPrediction.cpp	(revision 612)
@@ -456,5 +456,5 @@
         dmmSegmentation = &(g_dmmWedgeLists[ g_aucConvertToBit[iWidth] ][ pcCU->getDmmWedgeTabIdx( dimType, uiAbsPartIdx ) ]);
       } break;
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
     case( DMM2_IDX ):
       {
@@ -2773,4 +2773,5 @@
 
 #if H_3D_DIM_DMM
+#if !SEC_DMM2_E0146_HHIFIX
 UInt TComPrediction::xPredWedgeFromIntra( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, Int iDeltaEnd )
 {
@@ -2784,9 +2785,5 @@
   {
     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
@@ -2813,9 +2810,5 @@
   {
     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
@@ -2849,4 +2842,5 @@
   return 0;
 }
+#endif
 
 UInt TComPrediction::xPredWedgeFromTex( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, UInt intraTabIdx )
@@ -2914,4 +2908,5 @@
 }
 
+#if !SEC_DMM2_E0146_HHIFIX
 Void TComPrediction::xGetBlockOffset( TComDataCU* pcCU, UInt uiAbsPartIdx, TComDataCU* pcRefCU, UInt uiRefAbsPartIdx, UInt& ruiOffsetX, UInt& ruiOffsetY )
 {
@@ -3302,4 +3297,5 @@
 }
 #endif
+#endif
 #if H_3D_DIM_RBC
 Void TComPrediction::xDeltaDCQuantScaleUp( TComDataCU* pcCU, Pel& rDeltaDC )
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComPrediction.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComPrediction.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComPrediction.h	(revision 612)
@@ -154,5 +154,7 @@
   Void xAssignBiSegDCs          ( Pel* ptrDst, UInt dstStride, Bool* biSegPattern, Int patternStride, Pel   valDC1, Pel   valDC2 );
 #if H_3D_DIM_DMM
+#if !SEC_DMM2_E0146_HHIFIX
   UInt xPredWedgeFromIntra      ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, Int iDeltaEnd = 0 );
+#endif
   UInt xPredWedgeFromTex        ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, UInt intraTabIdx );
   Void xPredContourFromTex      ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiWidth, UInt uiHeight, TComWedgelet* pcContourWedge );
@@ -160,8 +162,10 @@
   Void xCopyTextureLumaBlock    ( TComDataCU* pcCU, UInt uiAbsPartIdx, Pel* piDestBlockY, UInt uiWidth, UInt uiHeight );
 
+#if !SEC_DMM2_E0146_HHIFIX
   Void xGetBlockOffset          ( TComDataCU* pcCU, UInt uiAbsPartIdx, TComDataCU* pcRefCU, UInt uiRefAbsPartIdx, UInt& ruiOffsetX, UInt& ruiOffsetY );
   Bool xGetWedgeIntraDirPredData( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiBlockSize, Int& riSlopeX, Int& riSlopeY, UInt& ruiStartPosX, UInt& ruiStartPosY );
   Void xGetWedgeIntraDirStartEnd( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiBlockSize, Int iDeltaX, Int iDeltaY, UInt uiPMSPosX, UInt uiPMSPosY, UChar& ruhXs, UChar& ruhYs, UChar& ruhXe, UChar& ruhYe, Int iDeltaEnd = 0 );
   UInt xGetWedgePatternIdx      ( UInt uiBlockSize, UChar uhXs, UChar uhYs, UChar uhXe, UChar uhYe );
+#endif
 #endif
 #if H_3D_DIM_RBC
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComWedgelet.cpp
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComWedgelet.cpp	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComWedgelet.cpp	(revision 612)
@@ -175,4 +175,5 @@
 }
 
+#if !SEC_DMM2_E0146_HHIFIX
 Bool TComWedgelet::checkPredDirAbovePossible( UInt uiPredDirBlockSize, UInt uiPredDirBlockOffset )
 {
@@ -642,4 +643,5 @@
   }
 }
+#endif
 
 Void TComWedgelet::xGenerateWedgePattern()
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComWedgelet.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComWedgelet.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TComWedgelet.h	(revision 612)
@@ -50,5 +50,5 @@
 enum DIM_IDX
 {
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
   DMM1_IDX = 0,
   DMM3_IDX = 1,
@@ -63,5 +63,5 @@
 #endif
 };
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
 #define DMM_NUM_TYPE   3
 #else
@@ -86,5 +86,5 @@
 #define DMM_NO_WEDGEINDEX       MAX_UINT
 #define DMM_NUM_WEDGE_REFINES   8
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 #define DMM2_DELTAEND_MAX       4
 #endif
@@ -151,4 +151,5 @@
   Bool  checkInvIdentical( Bool* pbRefPattern );
 
+#if !SEC_DMM2_E0146_HHIFIX
   // functions for DMM2 prediction
   Bool  checkPredDirAbovePossible( UInt uiPredDirBlockSize, UInt uiPredDirBlockOffsett );
@@ -156,4 +157,5 @@
   Void  getPredDirStartEndAbove( UChar& ruhXs, UChar& ruhYs, UChar& ruhXe, UChar& ruhYe, UInt uiPredDirBlockSize, UInt uiPredDirBlockOffset, Int iDeltaEnd );
   Void  getPredDirStartEndLeft ( UChar& ruhXs, UChar& ruhYs, UChar& ruhXe, UChar& ruhYe, UInt uiPredDirBlockSize, UInt uiPredDirBlockOffset, Int iDeltaEnd );
+#endif
 };  // END CLASS DEFINITION TComWedgelet
 
Index: branches/HTM-8.0-dev0/source/Lib/TLibCommon/TypeDef.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibCommon/TypeDef.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibCommon/TypeDef.h	(revision 612)
@@ -180,5 +180,5 @@
 
 #if H_3D_DIM
-#define SEC_DMM2_E0146                    1   // Removal of DMM2 from DMMs
+#define SEC_DMM2_E0146_HHIFIX             1   // Removal of DMM2 from DMMs
 #define ZJU_DEPTH_INTRA_MODE_E0204        1   // Simplified Binarization for depth_intra_mode
 #define KWU_SDC_SIMPLE_DC_E0117           1   // Simplified DC calculation for SDC
Index: branches/HTM-8.0-dev0/source/Lib/TLibDecoder/TDecSbac.cpp
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibDecoder/TDecSbac.cpp	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibDecoder/TDecSbac.cpp	(revision 612)
@@ -89,5 +89,5 @@
 #if H_3D_DIM_DMM
 , m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 , m_cDmm2DataSCModel          ( 1,             1,               NUM_DMM2_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
 #endif
@@ -179,5 +179,5 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM1_DATA );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   m_cDmm2DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM2_DATA );
 #endif
@@ -255,5 +255,5 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   m_cDmm2DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM2_DATA );
 #endif
@@ -444,5 +444,5 @@
   ruiTabIdx = uiIdx;
 }
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 Void TDecSbac::xParseDmm2Offset( Int& riOffset )
 {
@@ -1162,5 +1162,5 @@
       pcCU->setDmmWedgeTabIdxSubParts( uiTabIdx, dimType, absPartIdx, depth );
     } break;
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   case( DMM2_IDX ):
     {
@@ -1333,9 +1333,9 @@
         binNum = 0;
 #if LGE_SDC_REMOVE_DC_E0158
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
         while( symbol && binNum < 2 )
 #endif
 #else
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
         while( symbol && binNum < 2 )
 #else
@@ -1358,5 +1358,5 @@
     else if( modeCode == 6  ) { dir = (2*DMM3_IDX+DIM_OFFSET); sdcFlag = 0;}
 #if LGE_SDC_REMOVE_DC_E0158
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
     else if( modeCode == 7 )  { dir = (2* RBC_IDX+DIM_OFFSET); sdcFlag = 0;}
 #else
@@ -1366,5 +1366,5 @@
 #else
     else if( modeCode == 14 ) { dir =      DC_IDX;             sdcFlag = 1;}
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
     else if( modeCode == 15 ) { dir = (2* RBC_IDX+DIM_OFFSET); sdcFlag = 0;}
 #else
Index: branches/HTM-8.0-dev0/source/Lib/TLibDecoder/TDecSbac.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibDecoder/TDecSbac.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibDecoder/TDecSbac.h	(revision 612)
@@ -102,5 +102,5 @@
 #if H_3D_DIM_DMM
   Void  xParseDmm1WedgeIdx   ( UInt& ruiTabIdx, Int iNumBit );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   Void  xParseDmm2Offset     ( Int& riOffset );
 #endif
@@ -216,5 +216,5 @@
 #if H_3D_DIM_DMM
   ContextModel3DBuffer m_cDmm1DataSCModel;
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   ContextModel3DBuffer m_cDmm2DataSCModel;
 #endif
Index: branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSbac.cpp
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSbac.cpp	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSbac.cpp	(revision 612)
@@ -95,5 +95,5 @@
 #if H_3D_DIM_DMM
 , m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 , m_cDmm2DataSCModel          ( 1,             1,               NUM_DMM2_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
 #endif
@@ -177,5 +177,5 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   m_cDmm2DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM2_DATA );
 #endif
@@ -268,5 +268,5 @@
 #if H_3D_DIM_DMM
       curCost += m_cDmm1DataSCModel.calcCost          ( curSliceType, qp, (UChar*)INIT_DMM1_DATA );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
       curCost += m_cDmm2DataSCModel.calcCost          ( curSliceType, qp, (UChar*)INIT_DMM2_DATA );
 #endif
@@ -340,5 +340,5 @@
 #if H_3D_DIM_DMM
   m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   m_cDmm2DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM2_DATA );
 #endif
@@ -549,5 +549,5 @@
 }
 
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 Void TEncSbac::xCodeDmm2Offset( Int iOffset )
 {
@@ -1226,5 +1226,5 @@
       xCodeDmm1WedgeIdx( pcCU->getDmmWedgeTabIdx( dimType, absPartIdx ), g_dmm1TabIdxBits[pcCU->getIntraSizeIdx(absPartIdx)] );
     } break;
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   case( DMM2_IDX ):
     {
@@ -1285,5 +1285,5 @@
 #else
 #if LGE_SDC_REMOVE_DC_E0158
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
   UInt codeWordTable[3][7] =    {{0, 0, 0, 2, 0,6, 7},{0, 2, 3, 4, 5, 6, 7},{0, 1, 0, 0, 0, 0, 0}};
   UInt codeWordLenTable[3][7] = {{0, 1, 0, 2, 0,3, 3},{2, 3, 3, 3, 3, 3, 3},{1, 1, 0, 0, 0, 0, 0}};
@@ -1293,5 +1293,5 @@
 #endif
 #else
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
   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}};
@@ -1318,5 +1318,5 @@
     case DMM3_IDX: codeIdx = 5; break;
 #if LGE_SDC_REMOVE_DC_E0158
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
     case  RBC_IDX: codeIdx = 6; break;
 #else
@@ -1325,5 +1325,5 @@
 #endif
 #else
-#if SEC_DMM2_E0146
+#if SEC_DMM2_E0146_HHIFIX
     case  RBC_IDX: codeIdx = 7; break;
 #else
Index: branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSbac.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSbac.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSbac.h	(revision 612)
@@ -121,5 +121,5 @@
 #if H_3D_DIM_DMM
   Void  xCodeDmm1WedgeIdx    ( UInt uiTabIdx, Int iNumBit );
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   Void  xCodeDmm2Offset      ( Int iOffset );
 #endif
@@ -256,5 +256,5 @@
 #if H_3D_DIM_DMM
   ContextModel3DBuffer m_cDmm1DataSCModel;
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
   ContextModel3DBuffer m_cDmm2DataSCModel;
 #endif
Index: branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSearch.cpp
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 612)
@@ -2878,5 +2878,5 @@
               biSegmentation = &(g_dmmWedgeLists[(g_aucConvertToBit[uiWidth])][uiTabIdx]);
             } break;
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
           case( DMM2_IDX ):
             {
@@ -7361,5 +7361,5 @@
 }
 
-#if !SEC_DMM2_E0146
+#if !SEC_DMM2_E0146_HHIFIX
 Void TEncSearch::xSearchDmm2Wedge( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx, Int& riWedgeDeltaEnd )
 {
Index: branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSearch.h
===================================================================
--- branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSearch.h	(revision 611)
+++ branches/HTM-8.0-dev0/source/Lib/TLibEncoder/TEncSearch.h	(revision 612)
@@ -352,5 +352,5 @@
   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
+#if !SEC_DMM2_E0146_HHIFIX
   Void xSearchDmm2Wedge           ( TComDataCU* pcCU, UInt uiAbsPtIdx, Pel* piRef, UInt uiRefStride, UInt uiWidth, UInt uiHeight, UInt& ruiTabIdx, Int& riWedgeDeltaEnd );
 #endif
