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: encoder.c,v 1.95.2.47 2003-11-05 16:15:47 edgomez Exp $ |
* $Id: encoder.c,v 1.95.2.50 2003-11-13 22:35:30 edgomez Exp $ |
25 |
* |
* |
26 |
****************************************************************************/ |
****************************************************************************/ |
27 |
|
|
648 |
data.mb_height = pEnc->mbParam.mb_height; |
data.mb_height = pEnc->mbParam.mb_height; |
649 |
data.fincr = frame->fincr; |
data.fincr = frame->fincr; |
650 |
data.fbase = pEnc->mbParam.fbase; |
data.fbase = pEnc->mbParam.fbase; |
651 |
|
data.bquant_ratio = pEnc->mbParam.bquant_ratio; |
652 |
|
data.bquant_offset = pEnc->mbParam.bquant_offset; |
653 |
|
|
654 |
for (i=0; i<3; i++) { |
for (i=0; i<3; i++) { |
655 |
data.min_quant[i] = pEnc->mbParam.min_quant[i]; |
data.min_quant[i] = pEnc->mbParam.min_quant[i]; |
1507 |
&pEnc->vInterH, |
&pEnc->vInterH, |
1508 |
&pEnc->vInterV, |
&pEnc->vInterV, |
1509 |
&pEnc->vInterHV); |
&pEnc->vInterHV); |
1510 |
gmcval += /*current->quant */ 2 * (int)(pParam->mb_width*pParam->mb_height); |
} else { |
|
} |
|
|
|
|
1511 |
gmcval = globalSAD(¤t->warp, pParam, current->mbs, |
gmcval = globalSAD(¤t->warp, pParam, current->mbs, |
1512 |
current, |
current, |
1513 |
&reference->image, |
&reference->image, |
1514 |
¤t->image, |
¤t->image, |
1515 |
pEnc->vGMC.y); |
pEnc->vGMC.y); |
1516 |
|
} |
1517 |
|
|
1518 |
gmcval += /*current->quant*/ 2 * (int)(pParam->mb_width*pParam->mb_height); |
gmcval += /*current->quant*/ 2 * (int)(pParam->mb_width*pParam->mb_height); |
1519 |
|
|
1520 |
/* 1st '3': 3 warpoints, 2nd '3': 16th pel res (2<<3) */ |
/* 1st '3': 3 warpoints, 2nd '3': 16th pel res (2<<3) */ |
1915 |
|
|
1916 |
/* decoder ignores mb when refence block is INTER(0,0), CBP=0 */ |
/* decoder ignores mb when refence block is INTER(0,0), CBP=0 */ |
1917 |
if (mb->mode == MODE_NOT_CODED) { |
if (mb->mode == MODE_NOT_CODED) { |
1918 |
/* mb->mvs[0].x = mb->mvs[0].y = mb->cbp = 0; */ |
if (pEnc->mbParam.plugin_flags & XVID_REQORIGINAL) { |
1919 |
|
MBMotionCompensation(mb, x, y, f_ref, NULL, f_ref, NULL, NULL, &frame->image, |
1920 |
|
NULL, 0, 0, pEnc->mbParam.edged_width, 0, 0, 0); |
1921 |
|
} |
1922 |
|
|
1923 |
continue; |
continue; |
1924 |
} |
} |
1925 |
|
|