Index: branches/SHM-dev/source/Lib/TLibCommon/TComDataCU.cpp
===================================================================
--- branches/SHM-dev/source/Lib/TLibCommon/TComDataCU.cpp	(revision 900)
+++ branches/SHM-dev/source/Lib/TLibCommon/TComDataCU.cpp	(revision 901)
@@ -3546,15 +3546,15 @@
   if( motionMapping )
   {
-    // actually, motion field compression is performed in the Void TComPic::compressMotion() function, but with (+4) the rounding may have effect on the picture boundary check.
-    if( m_pcPic->isSpatialEnhLayer(refLayerIdc) )
-    {
+    if( m_pcPic->equalPictureSizeAndOffsetFlag(refLayerIdc) )
+    {
+      // copy motion field from the same sample position for the case of 1x scaling ratio and same offset value between the current and reference layers
+      iBX = pelX;
+      iBY = pelY;
+    }
+    else
+    {
+      // actually, motion field compression is performed in the Void TComPic::compressMotion() function, but with (+4) the rounding may have effect on the picture boundary check.
       iBX = ( ( iBX + 4 ) >> 4 ) << 4;
       iBY = ( ( iBY + 4 ) >> 4 ) << 4;
-    }
-    else
-    {
-      // copy motion field from the top left sample for 1x scaling ratio
-      iBX = pelX;
-      iBY = pelY;
     }
   }
Index: branches/SHM-dev/source/Lib/TLibCommon/TComPic.cpp
===================================================================
--- branches/SHM-dev/source/Lib/TLibCommon/TComPic.cpp	(revision 900)
+++ branches/SHM-dev/source/Lib/TLibCommon/TComPic.cpp	(revision 901)
@@ -64,4 +64,5 @@
   memset( m_pcFullPelBaseRec, 0, sizeof( m_pcFullPelBaseRec ) );
   memset( m_bSpatialEnhLayer, false, sizeof( m_bSpatialEnhLayer ) );
+  memset( m_equalPictureSizeAndOffsetFlag, false, sizeof( m_equalPictureSizeAndOffsetFlag ) );
 #endif
   m_apcPicYuv[0]      = NULL;
Index: branches/SHM-dev/source/Lib/TLibCommon/TComPic.h
===================================================================
--- branches/SHM-dev/source/Lib/TLibCommon/TComPic.h	(revision 900)
+++ branches/SHM-dev/source/Lib/TLibCommon/TComPic.h	(revision 901)
@@ -88,4 +88,7 @@
   Bool                  m_bSpatialEnhLayer[MAX_LAYERS];       // whether current layer is a spatial enhancement layer,
   TComPicYuv*           m_pcFullPelBaseRec[MAX_LAYERS];    // upsampled base layer recontruction for difference domain inter prediction
+#if REF_IDX_MFM
+  Bool                  m_equalPictureSizeAndOffsetFlag[MAX_LAYERS]; 
+#endif
 #endif
 #if Q0048_CGS_3D_ASYMLUT
@@ -203,4 +206,6 @@
 #endif
 #if REF_IDX_MFM
+  Bool          equalPictureSizeAndOffsetFlag(UInt refLayerIdc)             { return m_equalPictureSizeAndOffsetFlag[refLayerIdc]; }
+  Void          setEqualPictureSizeAndOffsetFlag(UInt refLayerIdc, Bool b)  { m_equalPictureSizeAndOffsetFlag[refLayerIdc] = b;    }
   Void          copyUpsampledMvField  ( UInt refLayerIdc, TComPic* pcPicBase );
   Void          initUpsampledMvField  ();
Index: branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp
===================================================================
--- branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 900)
+++ branches/SHM-dev/source/Lib/TLibDecoder/TDecTop.cpp	(revision 901)
@@ -407,4 +407,12 @@
         Bool sameBitDepths = ( g_bitDepthYLayer[m_layerId] == g_bitDepthYLayer[refLayerId] ) && ( g_bitDepthCLayer[m_layerId] == g_bitDepthCLayer[refLayerId] );
 
+#if REF_IDX_MFM
+        if( pcPicYuvRecBase->getWidth() == pcSlice->getPicWidthInLumaSamples() && pcPicYuvRecBase->getHeight() == pcSlice->getPicHeightInLumaSamples() && equalOffsets && zeroPhase )
+        {
+          rpcPic->setEqualPictureSizeAndOffsetFlag( i, true );
+        }
+
+        if( !rpcPic->equalPictureSizeAndOffsetFlag(i) || !sameBitDepths 
+#else
         if( pcPicYuvRecBase->getWidth() != pcSlice->getPicWidthInLumaSamples() || pcPicYuvRecBase->getHeight() != pcSlice->getPicHeightInLumaSamples() || !sameBitDepths
 #if REF_REGION_OFFSET && RESAMPLING_FIX
@@ -415,4 +423,5 @@
 #else
           || !zeroOffsets
+#endif
 #endif
 #if Q0048_CGS_3D_ASYMLUT
Index: branches/SHM-dev/source/Lib/TLibEncoder/TEncTop.cpp
===================================================================
--- branches/SHM-dev/source/Lib/TLibEncoder/TEncTop.cpp	(revision 900)
+++ branches/SHM-dev/source/Lib/TLibEncoder/TEncTop.cpp	(revision 901)
@@ -820,4 +820,12 @@
           Bool sameBitDepths = ( g_bitDepthYLayer[m_layerId] == g_bitDepthYLayer[refLayerId] ) && ( g_bitDepthCLayer[m_layerId] == g_bitDepthCLayer[refLayerId] );
 
+#if REF_IDX_MFM
+          if( m_iSourceWidth == pcEncTopBase->getSourceWidth() && m_iSourceHeight == pcEncTopBase->getSourceHeight() && equalOffsets && zeroPhase )
+          {
+            pcEPic->setEqualPictureSizeAndOffsetFlag( i, true );
+          }
+
+          if( !pcEPic->equalPictureSizeAndOffsetFlag(i) || !sameBitDepths 
+#else
           if( m_iSourceWidth != pcEncTopBase->getSourceWidth() || m_iSourceHeight != pcEncTopBase->getSourceHeight() || !sameBitDepths 
 #if REF_REGION_OFFSET && RESAMPLING_FIX
@@ -828,4 +836,5 @@
 #else
             || !zeroOffsets
+#endif
 #endif
 #if Q0048_CGS_3D_ASYMLUT
