Index: branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h
===================================================================
--- branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h	(revision 1404)
+++ branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h	(revision 1405)
@@ -181,4 +181,5 @@
   Bool      m_bFastMEAssumingSmootherMVEnabled;
   Int       m_minSearchWindow;
+  Bool      m_bRestrictMESampling;
 
   //====== Quality control ========
@@ -568,4 +569,5 @@
   Void      setFastMEAssumingSmootherMVEnabled ( Bool b )    { m_bFastMEAssumingSmootherMVEnabled = b; }
   Void      setMinSearchWindow              ( Int   i )      { m_minSearchWindow = i; }
+  Void      setRestrictMESampling           ( Bool  b )      { m_bRestrictMESampling = b; }
 
   //====== Quality control ========
@@ -641,4 +643,5 @@
   Bool      getFastMEAssumingSmootherMVEnabled () const { return m_bFastMEAssumingSmootherMVEnabled; }
   Int       getMinSearchWindow                 () const { return m_minSearchWindow; }
+  Bool      getRestrictMESampling              () const { return m_bRestrictMESampling; }
 
   //==== Quality control ========
Index: branches/SHM-dev/source/Lib/TLibEncoder/TEncSearch.cpp
===================================================================
--- branches/SHM-dev/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 1404)
+++ branches/SHM-dev/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 1405)
@@ -340,5 +340,5 @@
   m_cDistParam.m_maximumDistortionForEarlyExit = rcStruct.uiBestSad;
 
-  if(m_pcEncCfg->getFastSearch() == SELECTIVE)
+  if((m_pcEncCfg->getRestrictMESampling() == false) && m_pcEncCfg->getFastSearch() == SELECTIVE)
   {
     Int isubShift = 0;
