[svn] / trunk / xvidcore / src / prediction / mbprediction.c Repository:
ViewVC logotype

Diff of /trunk/xvidcore/src/prediction/mbprediction.c

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

revision 195, Wed Jun 12 20:38:41 2002 UTC revision 248, Fri Jun 28 15:14:40 2002 UTC
# Line 42  Line 42 
42    *                                                                            *    *                                                                            *
43    *  Revision history:                                                         *    *  Revision history:                                                         *
44    *                                                                            *    *                                                                            *
45      *  29.06.2002 predict_acdc() bounding                                        *
46    *  12.12.2001 improved calc_acdc_prediction; removed need for memcpy         *    *  12.12.2001 improved calc_acdc_prediction; removed need for memcpy         *
47    *  15.12.2001 moved pmv displacement to motion estimation                    *    *  15.12.2001 moved pmv displacement to motion estimation                    *
48    *  30.11.2001 mmx cbp support                                                *    *  30.11.2001 mmx cbp support                                                *
# Line 90  Line 91 
91                           int16_t qcoeff[64],                           int16_t qcoeff[64],
92                           uint32_t current_quant,                           uint32_t current_quant,
93                           int32_t iDcScaler,                           int32_t iDcScaler,
94                           int16_t predictors[8])                           int16_t predictors[8],
95                            const unsigned int bound_x,
96                            const unsigned int bound_y)
97    
98  {  {
99            const unsigned bound = (bound_y * mb_width) + bound_x;
100            const unsigned mbpos = (y * mb_width) + x;
101          int16_t *left, *top, *diag, *current;          int16_t *left, *top, *diag, *current;
102    
103          int32_t left_quant = current_quant;          int32_t left_quant = current_quant;
# Line 111  Line 117 
117    
118          // left macroblock          // left macroblock
119    
120          if (x &&          if (x && mbpos >= bound + 1  &&
121                  (pMBs[index - 1].mode == MODE_INTRA ||                  (pMBs[index - 1].mode == MODE_INTRA ||
122                   pMBs[index - 1].mode == MODE_INTRA_Q)) {                   pMBs[index - 1].mode == MODE_INTRA_Q)) {
123    
# Line 121  Line 127 
127          }          }
128          // top macroblock          // top macroblock
129    
130          if (y &&          if (mbpos >= bound + mb_width &&
131                  (pMBs[index - mb_width].mode == MODE_INTRA ||                  (pMBs[index - mb_width].mode == MODE_INTRA ||
132                   pMBs[index - mb_width].mode == MODE_INTRA_Q)) {                   pMBs[index - mb_width].mode == MODE_INTRA_Q)) {
133    
# Line 130  Line 136 
136          }          }
137          // diag macroblock          // diag macroblock
138    
139          if (x && y &&          if (x && mbpos >= bound + mb_width + 1 &&
140                  (pMBs[index - 1 - mb_width].mode == MODE_INTRA ||                  (pMBs[index - 1 - mb_width].mode == MODE_INTRA ||
141                   pMBs[index - 1 - mb_width].mode == MODE_INTRA_Q)) {                   pMBs[index - 1 - mb_width].mode == MODE_INTRA_Q)) {
142    
# Line 379  Line 385 
385                          iDcScaler = get_dc_scaler(iQuant, (j < 4) ? 1 : 0);                          iDcScaler = get_dc_scaler(iQuant, (j < 4) ? 1 : 0);
386    
387                          predict_acdc(frame->mbs, x, y, mb_width, j, &qcoeff[j * 64],                          predict_acdc(frame->mbs, x, y, mb_width, j, &qcoeff[j * 64],
388                                                   iQuant, iDcScaler, predictors[j]);                                                   iQuant, iDcScaler, predictors[j], 0, 0);
389    
390                          S += calc_acdc(pMB, j, &qcoeff[j * 64], iDcScaler, predictors[j]);                          S += calc_acdc(pMB, j, &qcoeff[j * 64], iDcScaler, predictors[j]);
391    

Legend:
Removed from v.195  
changed lines
  Added in v.248

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