Index: branches/HTM-6.0-dev0/source/Lib/TLibCommon/TComRdCostWeightPrediction.cpp
===================================================================
--- branches/HTM-6.0-dev0/source/Lib/TLibCommon/TComRdCostWeightPrediction.cpp	(revision 310)
+++ branches/HTM-6.0-dev0/source/Lib/TLibCommon/TComRdCostWeightPrediction.cpp	(revision 311)
@@ -81,29 +81,28 @@
   wpScalingParam  *wpCur    = &(pcDtParam->wpCur[uiComp]);
   Int   w0      = wpCur->w,
-        offset  = wpCur->offset,
-        shift   = wpCur->shift,
-        round   = wpCur->round;
-  
+    offset  = wpCur->offset,
+    shift   = wpCur->shift,
+    round   = wpCur->round;
+
   UInt uiSum = 0;
-  #if HHI_INTERVIEW_SKIP
+#if HHI_INTERVIEW_SKIP
   if( pcDtParam->pUsed )
   {
     Pel*  piUsed      = pcDtParam->pUsed;
     Int   iStrideUsed = pcDtParam->iStrideUsed;
-  for( ; iRows != 0; iRows-- )
-  {
-    for (Int n = 0; n < iCols; n++ )
-    {
+    for( ; iRows != 0; iRows-- )
+    {
+      for (Int n = 0; n < iCols; n++ )
+      {
         if( piUsed[n])
         {
-      pred = ( (w0*piCur[n] + round) >> shift ) + offset ;
-      //uiSum += abs( piOrg[n] - piCur[n] );
-      uiSum += abs( piOrg[n] - pred );
-    }
-    }
-    piOrg += iStrideOrg;
-    piCur += iStrideCur;
+          pred = ( (w0*piCur[n] + round) >> shift ) + offset ;
+          uiSum += abs( piOrg[n] - pred );
+        }
+      }
+      piOrg += iStrideOrg;
+      piCur += iStrideCur;
       piUsed += iStrideUsed;
-  }
+    }
 #if FIX_LGE_WP_FOR_3D_C0223
   }
@@ -115,21 +114,20 @@
 #endif
 #endif
-  for( ; iRows != 0; iRows-- )
-  {
-    for (Int n = 0; n < iCols; n++ )
-    {
-      pred = ( (w0*piCur[n] + round) >> shift ) + offset ;
-  
-      uiSum += abs( piOrg[n] - pred );
-    }
-    piOrg += iStrideOrg;
-    piCur += iStrideCur;
-  }
+    for( ; iRows != 0; iRows-- )
+    {
+      for (Int n = 0; n < iCols; n++ )
+      {
+        pred = ( (w0*piCur[n] + round) >> shift ) + offset ;
+        uiSum += abs( piOrg[n] - pred );
+      }
+      piOrg += iStrideOrg;
+      piCur += iStrideCur;
+    }
 #if FIX_LGE_WP_FOR_3D_C0223 //comment of #endif
-  //#endif
+    //#endif
 #endif
-    #if HHI_INTERVIEW_SKIP
-      }
-    #endif
+#if HHI_INTERVIEW_SKIP
+  }
+#endif
   pcDtParam->uiComp = 255;  // reset for DEBUG (assert test)
 
Index: branches/HTM-6.0-dev0/source/Lib/TLibCommon/TComResidualGenerator.cpp
===================================================================
--- branches/HTM-6.0-dev0/source/Lib/TLibCommon/TComResidualGenerator.cpp	(revision 310)
+++ branches/HTM-6.0-dev0/source/Lib/TLibCommon/TComResidualGenerator.cpp	(revision 311)
@@ -614,8 +614,15 @@
   Int           iDesStrideC = pcYuv    ->getCStride();
 #if MTK_RELEASE_DV_CONSTRAINT_C0129
+#if FIX_CHROMA_RESIDUAL_C0129
+  Pel*          pSrcSamplesU0= pcBaseRes->getCbAddr ( 0 ) + iCRefPosY0 * iSrcStrideC;
+  Pel*          pSrcSamplesU1= pcBaseRes->getCbAddr ( 0 ) + iCRefPosY1 * iSrcStrideC;
+  Pel*          pSrcSamplesV0= pcBaseRes->getCrAddr ( 0 ) + iCRefPosY0 * iSrcStrideC;
+  Pel*          pSrcSamplesV1= pcBaseRes->getCrAddr ( 0 ) + iCRefPosY1 * iSrcStrideC;
+#else
   Pel*          pSrcSamplesU0= pcBaseRes->getCbAddr ( 0 ) + ( iCRefPosY0 >> 1 ) * iSrcStrideC;
   Pel*          pSrcSamplesU1= pcBaseRes->getCbAddr ( 0 ) + ( iCRefPosY1 >> 1 ) * iSrcStrideC;
   Pel*          pSrcSamplesV0= pcBaseRes->getCrAddr ( 0 ) + ( iCRefPosY0 >> 1 ) * iSrcStrideC;
   Pel*          pSrcSamplesV1= pcBaseRes->getCrAddr ( 0 ) + ( iCRefPosY1 >> 1 ) * iSrcStrideC;
+#endif
 #else
   Pel*          pSrcSamplesU= pcBaseRes->getCbAddr ( 0 ) + ( uiYPos >> 1 ) * iSrcStrideC;
Index: branches/HTM-6.0-dev0/source/Lib/TLibCommon/TypeDef.h
===================================================================
--- branches/HTM-6.0-dev0/source/Lib/TLibCommon/TypeDef.h	(revision 310)
+++ branches/HTM-6.0-dev0/source/Lib/TLibCommon/TypeDef.h	(revision 311)
@@ -121,4 +121,5 @@
 #define MTK_RELEASE_DV_CONSTRAINT_C0129   1   // JCT3V-C0129
 #define MTK_SIMPLIFY_DVTC_C0135           1   // JCT3V-C0135
+#define FIX_CHROMA_RESIDUAL_C0129         1 
 
 ///// ***** MOTION PARAMETER INHERITANCE  *********
