[svn] / branches / dev-api-4 / xvidcore / src / motion / motion_est.c Repository:
ViewVC logotype

Diff of /branches/dev-api-4/xvidcore/src/motion/motion_est.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1137, Fri Sep 5 10:01:50 2003 UTC revision 1138, Sat Sep 6 11:24:50 2003 UTC
# Line 21  Line 21 
21   *  along with this program ; if not, write to the Free Software   *  along with this program ; if not, write to the Free Software
22   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
23   *   *
24   * $Id: motion_est.c,v 1.58.2.34 2003-09-05 10:01:50 Isibaar Exp $   * $Id: motion_est.c,v 1.58.2.35 2003-09-06 11:24:50 Isibaar Exp $
25   *   *
26   ****************************************************************************/   ****************************************************************************/
27    
# Line 1159  Line 1159 
1159          pMB->mcsel = 0;          pMB->mcsel = 0;
1160    
1161          /* INTER <-> INTER4V decision */          /* INTER <-> INTER4V decision */
1162          if ((Data->iMinSAD[0] + 50 < Data->iMinSAD[1] +          if ((Data->iMinSAD[0] + 75 < Data->iMinSAD[1] +
1163                  Data->iMinSAD[2] + Data->iMinSAD[3] + Data->iMinSAD[4])) { /* normal, fast, SAD-based mode decision */                  Data->iMinSAD[2] + Data->iMinSAD[3] + Data->iMinSAD[4])) { /* normal, fast, SAD-based mode decision */
1164                  if (inter4v == 0 || Data->iMinSAD[0] < Data->iMinSAD[1] + Data->iMinSAD[2] +                  if (inter4v == 0 || Data->iMinSAD[0] < Data->iMinSAD[1] + Data->iMinSAD[2] +
1165                          Data->iMinSAD[3] + Data->iMinSAD[4] + IMV16X16 * (int32_t)iQuant) {                          Data->iMinSAD[3] + Data->iMinSAD[4] + IMV16X16 * (int32_t)iQuant) {
# Line 1258  Line 1258 
1258          left = top = top_right = -1;          left = top = top_right = -1;
1259          thresh = 0;          thresh = 0;
1260    
1261          if(x > 0 && y > 0 && x < pParam->mb_width) {          if((x > 0) && (y > 0) && (x < (int32_t) pParam->mb_width)) {
1262                  left = (&pMBs[(x-1) + y * pParam->mb_width])->sad16; // left                  left = (&pMBs[(x-1) + y * pParam->mb_width])->sad16; // left
1263                  top = (&pMBs[x + (y-1) * pParam->mb_width])->sad16; // top                  top = (&pMBs[x + (y-1) * pParam->mb_width])->sad16; // top
1264                  top_right = (&pMBs[(x+1) + (y-1) * pParam->mb_width])->sad16; // top right                  top_right = (&pMBs[(x+1) + (y-1) * pParam->mb_width])->sad16; // top right
1265    
1266                  if(((&pMBs[(x-1) + y * pParam->mb_width])->mode != MODE_INTRA) &&                  if(((&pMBs[(x-1) + y * pParam->mb_width])->mode != MODE_INTRA) &&
1267                     ((&pMBs[x + (y-1) * pParam->mb_width])->mode != MODE_INTRA) &&                     ((&pMBs[x + (y-1) * pParam->mb_width])->mode != MODE_INTRA) &&
1268                     ((&pMBs[(x+1) + (y-1) * pParam->mb_width])->mode != MODE_INTRA))                     ((&pMBs[(x+1) + (y-1) * pParam->mb_width])->mode != MODE_INTRA)) {
1269                          thresh = MAX(MAX(top, left), top_right);                          thresh = MAX(MAX(top, left), top_right);
1270                    }
1271                  else                  else
1272                          thresh = MIN(MIN(top, left), top_right);                          thresh = MIN(MIN(top, left), top_right);
1273          }          }

Legend:
Removed from v.1137  
changed lines
  Added in v.1138

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4