[cvs] / xvidcore / src / prediction / mbprediction.h Repository:
ViewVC logotype

Diff of /xvidcore/src/prediction/mbprediction.h

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

revision 1.19, Sat Feb 15 15:22:19 2003 UTC revision 1.20, Wed Feb 19 21:02:11 2003 UTC
# Line 549  Line 549 
549      lpos = lx + ly * mb_width;      lpos = lx + ly * mb_width;
550      rpos = rx + ry * mb_width;      rpos = rx + ry * mb_width;
551      tpos = tx + ty * mb_width;      tpos = tx + ty * mb_width;
552      num_cand = 0;      last_cand = num_cand = 0;
553    
554      if (lpos >= bound && lx >= 0) {      if (lpos >= bound && lx >= 0) {
555          num_cand++;          num_cand++;
# Line 575  Line 575 
575          pmv[3] = zeroMV;          pmv[3] = zeroMV;
576      }      }
577    
578      /* if only one valid candidate predictor, the invalid candiates are set to the canidate */          /*
579             * If there're more than one candidate, we return the median vector
580             * edgomez : the special case "no candidates" is handled the same way
581             *           because all vectors are set to zero. So the median vector
582             *           is {0,0}, and this is exactly the vector we must return
583             *           according to the mpeg4 specs.
584             */
585          if (num_cand != 1) {          if (num_cand != 1) {
586                  /* set median */                  /* set median */
587    
# Line 649  Line 655 
655      lpos = lx + ly * mb_width;      lpos = lx + ly * mb_width;
656      rpos = rx + ry * mb_width;      rpos = rx + ry * mb_width;
657      tpos = tx + ty * mb_width;      tpos = tx + ty * mb_width;
658      num_cand = 0;      last_cand = num_cand = 0;
659    
660      if (lpos >= bound && lx >= 0) {      if (lpos >= bound && lx >= 0) {
661          num_cand++;          num_cand++;
# Line 675  Line 681 
681          pmv[3] = zeroMV;          pmv[3] = zeroMV;
682      }      }
683    
684      /* if only one valid candidate predictor, the invalid candiates are set to the canidate */          /*
685             * If there're more than one candidate, we return the median vector
686             * edgomez : the special case "no candidates" is handled the same way
687             *           because all vectors are set to zero. So the median vector
688             *           is {0,0}, and this is exactly the vector we must return
689             *           according to the mpeg4 specs.
690             */
691          if (num_cand != 1) {          if (num_cand != 1) {
692                  /* set median */                  /* set median */
693    
# Line 748  Line 760 
760      lpos = lx + ly * mb_width;      lpos = lx + ly * mb_width;
761      rpos = rx + ry * mb_width;      rpos = rx + ry * mb_width;
762      tpos = tx + ty * mb_width;      tpos = tx + ty * mb_width;
763      num_cand = 0;      last_cand = num_cand = 0;
764    
765      if (lpos >= bound && lx >= 0) {      if (lpos >= bound && lx >= 0) {
766          num_cand++;          num_cand++;

Legend:
Removed from v.1.19  
changed lines
  Added in v.1.20

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