Index: /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibCommon/TComDataCU.cpp
===================================================================
--- /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibCommon/TComDataCU.cpp	(revision 347)
+++ /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibCommon/TComDataCU.cpp	(revision 348)
@@ -5322,6 +5322,13 @@
  */
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
 Void TComDataCU::fillMvpCand ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo, Int iMVPIdx)
 {
+    fillMvpCandBase(uiPartIdx, uiPartAddr, eRefPicList, iRefIdx, pInfo);
+}
+#else
+Void TComDataCU::fillMvpCand ( UInt uiPartIdx, UInt uiPartAddr, RefPicList eRefPicList, Int iRefIdx, AMVPInfo* pInfo, Int iMVPIdx)
+{
+
   if (!m_pcSlice->getSPS()->getViewId() || !m_pcSlice->getSPS()->getMultiviewMvPredMode())
   {
@@ -5402,4 +5409,5 @@
   }
 }
+#endif
 
 
Index: /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibCommon/TypeDef.h
===================================================================
--- /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibCommon/TypeDef.h	(revision 347)
+++ /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibCommon/TypeDef.h	(revision 348)
@@ -84,4 +84,5 @@
                                               // QC_C0051_FIXED_BY_MTK             1   // Bug fix for C0051 implementation
                                               // QC_AMVP_MRG_UNIFY_IVCAN_C0051     1
+#define SEC_TWO_CANDIDATES_FOR_AMVP_D0122 1   // SEC_TWO_CANDIDATES_FOR_AMVP_D0122, fixing # of AMVP candidates 3 to 2
 
 
Index: /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibDecoder/TDecEntropy.cpp
===================================================================
--- /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibDecoder/TDecEntropy.cpp	(revision 347)
+++ /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibDecoder/TDecEntropy.cpp	(revision 348)
@@ -479,5 +479,9 @@
   {
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+    const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS;
+#else
     const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcSubCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
+#endif
     m_pcEntropyDecoderIf->parseMVPIdx( iMVPIdx, iNumAMVPCands );
 #else
Index: /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibEncoder/TEncEntropy.cpp
===================================================================
--- /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibEncoder/TEncEntropy.cpp	(revision 347)
+++ /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibEncoder/TEncEntropy.cpp	(revision 348)
@@ -1351,5 +1351,9 @@
   {
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+    const Int iNumCands = AMVP_MAX_NUM_CANDS;
+#else
     const Int iNumCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
+#endif
     m_pcEntropyCoderIf->codeMVPIdx( pcCU, uiAbsPartIdx, eRefList, iNumCands );
 #else
Index: /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibEncoder/TEncSearch.cpp
===================================================================
--- /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 347)
+++ /branches/HTM-6.2-dev1-Samsung/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 348)
@@ -206,5 +206,9 @@
   
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+  const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS;
+#else
   const Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + 1;
+#endif
   for( Int iNum = 0; iNum < iNumAMVPCands+1; iNum++)
     for( Int iIdx = 0; iIdx < iNumAMVPCands; iIdx++)
@@ -3109,5 +3113,9 @@
 
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+  Int iNumAMVPCands = AMVP_MAX_NUM_CANDS;
+#else
   Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
+#endif
 #endif
 
@@ -3799,5 +3807,9 @@
     {
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+      Int iNumAMVPCands = AMVP_MAX_NUM_CANDS;
+#else
       Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
+#endif
 #if ZERO_MVD_EST
       (*puiDistBiP) = xGetTemplateCost( pcCU, uiPartIdx, uiPartAddr, pcOrgYuv, &m_cYuvPredTemp, rcMvPred, 0, iNumAMVPCands, eRefPicList, iRefIdx, iRoiWidth, iRoiHeight, uiDist );
@@ -3834,5 +3846,9 @@
       UInt uiTmpCost;
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+      Int iNumAMVPCands = AMVP_MAX_NUM_CANDS;
+#else
       Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
+#endif
 #if ZERO_MVD_EST
       uiTmpCost = xGetTemplateCost( pcCU, uiPartIdx, uiPartAddr, pcOrgYuv, &m_cYuvPredTemp, pcAMVPInfo->m_acMvCand[i], i, iNumAMVPCands, eRefPicList, iRefIdx, iRoiWidth, iRoiHeight, uiDist );
@@ -3967,5 +3983,9 @@
   
 #if H3D_IVMP
+#if SEC_TWO_CANDIDATES_FOR_AMVP_D0122
+  Int iNumAMVPCands = AMVP_MAX_NUM_CANDS;
+#else
   Int iNumAMVPCands = AMVP_MAX_NUM_CANDS + ( pcCU->getSlice()->getSPS()->getMultiviewMvPredMode() ? 1 : 0 );
+#endif
 #endif
   
