[cvs] / xvidcore / src / decoder.c Repository:
ViewVC logotype

Diff of /xvidcore/src/decoder.c

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

revision 1.49.2.18, Wed Oct 22 09:47:52 2003 UTC revision 1.49.2.19, Thu Nov 13 22:35:30 2003 UTC
# Line 1164  Line 1164 
1164          const int64_t TRB = dec->time_pp - dec->time_bp, TRD = dec->time_pp;          const int64_t TRB = dec->time_pp - dec->time_bp, TRD = dec->time_pp;
1165          int i;          int i;
1166    
 #ifdef BFRAMES_DEC_DEBUG  
         FILE *fp;  
         static char first=0;  
 #define BFRAME_DEBUG  
         if (!first && fp) { \  
                 fprintf(fp,"Y=%3d   X=%3d   MB=%2d   CBP=%02X\n",y,x,mb->mode,mb->cbp); \  
         }  
 #endif  
   
1167          start_timer();          start_timer();
1168          image_setedges(&dec->refn[0], dec->edged_width, dec->edged_height,          image_setedges(&dec->refn[0], dec->edged_width, dec->edged_height,
1169                                          dec->width, dec->height);                                          dec->width, dec->height);
# Line 1180  Line 1171 
1171                                          dec->width, dec->height);                                          dec->width, dec->height);
1172          stop_edges_timer();          stop_edges_timer();
1173    
 #ifdef BFRAMES_DEC_DEBUG  
         if (!first){  
                 fp=fopen("C:\\XVIDDBG.TXT","w");  
         }  
 #endif  
   
1174          for (y = 0; y < dec->mb_height; y++) {          for (y = 0; y < dec->mb_height; y++) {
1175                  /* Initialize Pred Motion Vector */                  /* Initialize Pred Motion Vector */
1176                  dec->p_fmv = dec->p_bmv = zeromv;                  dec->p_fmv = dec->p_bmv = zeromv;
1177                  for (x = 0; x < dec->mb_width; x++) {                  for (x = 0; x < dec->mb_width; x++) {
1178                          MACROBLOCK *mb = &dec->mbs[y * dec->mb_width + x];                          MACROBLOCK *mb = &dec->mbs[y * dec->mb_width + x];
1179                          MACROBLOCK *last_mb = &dec->last_mbs[y * dec->mb_width + x];                          MACROBLOCK *last_mb = &dec->last_mbs[y * dec->mb_width + x];
1180                            const int fcode_max = (fcode_forward>fcode_backward) ? fcode_forward : fcode_backward;
1181                            uint32_t intra_dc_threshold; /* fake variable */
1182    
1183                            if (check_resync_marker(bs, fcode_max  - 1)) {
1184                                    int bound = read_video_packet_header(bs, dec, fcode_max - 1, &quant,
1185                                                                                                             &fcode_forward, &fcode_backward, &intra_dc_threshold);
1186                                    x = bound % dec->mb_width;
1187                                    y = bound / dec->mb_width;
1188                                    /* reset predicted macroblocks */
1189                                    dec->p_fmv = dec->p_bmv = zeromv;
1190                            }
1191    
1192                          mv =                          mv =
1193                          mb->b_mvs[0] = mb->b_mvs[1] = mb->b_mvs[2] = mb->b_mvs[3] =                          mb->b_mvs[0] = mb->b_mvs[1] = mb->b_mvs[2] = mb->b_mvs[3] =
# Line 1304  Line 1300 
1300                          }                          }
1301                  } /* End of for */                  } /* End of for */
1302          }          }
   
 #ifdef BFRAMES_DEC_DEBUG  
         if (!first){  
                 first=1;  
                 if (fp)  
                         fclose(fp);  
         }  
 #endif  
1303  }  }
1304    
1305  /* perform post processing if necessary, and output the image */  /* perform post processing if necessary, and output the image */

Legend:
Removed from v.1.49.2.18  
changed lines
  Added in v.1.49.2.19

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