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

Diff of /branches/dev-api-4/xvidcore/src/plugins/plugin_2pass2.c

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

revision 1032, Sat May 17 13:37:49 2003 UTC revision 1036, Tue May 20 17:28:25 2003 UTC
# Line 22  Line 22 
22   * along with this program; if not, write to the Free Software   * along with this program; if not, write to the Free Software
23   * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA   * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
24   *   *
25   * $Id: plugin_2pass2.c,v 1.1.2.5 2003-05-17 13:36:38 suxen_drol Exp $   * $Id: plugin_2pass2.c,v 1.1.2.6 2003-05-20 17:28:25 edgomez Exp $
26   *   *
27   *****************************************************************************/   *****************************************************************************/
28    
# Line 186  Line 186 
186    
187    
188    
189    #if 0
190  static void print_stats(rc_2pass2_t * rc)  static void print_stats(rc_2pass2_t * rc)
191  {  {
192      int i;      int i;
193      for (i = 0; i < rc->num_frames; i++) {      for (i = 0; i < rc->num_frames; i++) {
194          stat_t * s = &rc->stats[i];          stat_t * s = &rc->stats[i];
195          DPRINTF(XVID_DEBUG_RC, "%i %i %i %i\n", s->type, s->quant, s->length, s->scaled_length);          DPRINTF(XVID_DEBUG_RC, "%i %i %i %i\n", s->type, s->quant, s->length, s->scaled_length);
   
196      }      }
197  }  }
198    #endif
199    
200  /* pre-process the statistics data  /* pre-process the statistics data
201      - for each type, count, tot_length, min_length, max_length      - for each type, count, tot_length, min_length, max_length
# Line 328  Line 328 
328              s->scaled_length = s->length;              s->scaled_length = s->length;
329          }else {          }else {
330                      len = (int)((double)s->length * scaler * s->weight / rc->avg_weight);                      len = (int)((double)s->length * scaler * s->weight / rc->avg_weight);
331                      if (len < min_size[s->type]) {              /* force frame size */                      if (len < min_size[s->type-1]) {            /* force frame size */
332                              s->scaled_length = min_size[s->type];                              s->scaled_length = min_size[s->type-1];
333                              target -= s->scaled_length;                              target -= s->scaled_length;
334                              pass1_length -= s->length;                              pass1_length -= s->length;
335                      }else{                      }else{
# Line 668  Line 668 
668    
669    
670          pre_process0(rc);          pre_process0(rc);
671    
672          if (rc->param.bitrate) {          if (rc->param.bitrate) {
673          zone_process(rc, create);          zone_process(rc, create);
674                  internal_scale(rc);                  internal_scale(rc);

Legend:
Removed from v.1032  
changed lines
  Added in v.1036

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