Remove unused members of VP8_COMP

Various members that were either completely unreferenced or written
and not read.

Change-Id: Ie41ebac0ff0364a76f287586e4fe09a68907806e
This commit is contained in:
John Koleszar 2011-05-19 14:42:24 -04:00
parent c684d5e5f2
commit 048497720c
10 changed files with 0 additions and 91 deletions

View File

@ -79,7 +79,6 @@ typedef struct
int errorperbit;
int sadperbit16;
int sadperbit4;
int errthresh;
int rddiv;
int rdmult;
unsigned int * mb_activity_ptr;

View File

@ -562,9 +562,6 @@ void vp8_encode_frame(VP8_COMP *cpi)
x->vector_range = 32;
// Count of MBs using the alternate Q if any
cpi->alt_qcount = 0;
// Reset frame count of inter 0,0 motion vector useage.
cpi->inter_zz_count = 0;

View File

@ -302,7 +302,6 @@ static void setup_mbby_copy(MACROBLOCK *mbdst, MACROBLOCK *mbsrc)
z->sadperbit16 = x->sadperbit16;
z->sadperbit4 = x->sadperbit4;
z->errthresh = x->errthresh;
/*
z->mv_col_min = x->mv_col_min;

View File

@ -1241,12 +1241,6 @@ void vp8_init_second_pass(VP8_COMP *cpi)
reset_fpf_position(cpi, start_pos); // Reset file position
}
// Calculate the clip target modified bits per error
// The observed bpe starts as the same number.
cpi->clip_bpe = cpi->bits_left /
DOUBLE_DIVIDE_CHECK(cpi->modified_error_total);
cpi->observed_bpe = cpi->clip_bpe;
}
void vp8_end_second_pass(VP8_COMP *cpi)
@ -1978,13 +1972,6 @@ void vp8_second_pass(VP8_COMP *cpi)
this_frame_intra_error = this_frame.intra_error;
this_frame_coded_error = this_frame.coded_error;
// Store information regarding level of motion etc for use mode decisions.
cpi->motion_speed = (int)(fabs(this_frame.MVr) + fabs(this_frame.MVc));
cpi->motion_var = (int)(fabs(this_frame.MVrv) + fabs(this_frame.MVcv));
cpi->inter_lvl = (int)(this_frame.pcnt_inter * 100);
cpi->intra_lvl = (int)((1.0 - this_frame.pcnt_inter) * 100);
cpi->motion_lvl = (int)(this_frame.pcnt_motion * 100);
start_pos = cpi->stats_in;
// keyframe and section processing !
@ -2011,16 +1998,6 @@ void vp8_second_pass(VP8_COMP *cpi)
// Is this a GF / ARF (Note that a KF is always also a GF)
if (cpi->frames_till_gf_update_due == 0)
{
// Update monitor of the bits per error observed so far.
// Done once per gf group based on what has gone before
// so do nothing if this is the first frame.
if (cpi->common.current_video_frame > 0)
{
cpi->observed_bpe =
(double)(cpi->clip_bits_total - cpi->bits_left) /
cpi->modified_error_used;
}
// Define next gf group and assign bits to it
vpx_memcpy(&this_frame_copy, &this_frame, sizeof(this_frame));
define_gf_group(cpi, &this_frame_copy);

View File

@ -2093,8 +2093,6 @@ VP8_PTR vp8_create_compressor(VP8_CONFIG *oxcf)
cpi->diamond_search_sad = SEARCH_INVOKE(&cpi->rtcd.search, diamond_search);
cpi->refining_search_sad = SEARCH_INVOKE(&cpi->rtcd.search, refining_search);
cpi->ready_for_new_frame = 1;
// make sure frame 1 is okay
cpi->error_bins[0] = cpi->common.MBs;
@ -4818,8 +4816,6 @@ int vp8_get_compressed_data(VP8_PTR ptr, unsigned int *frame_flags, unsigned lon
}
cpi->ready_for_new_frame = 1;
vpx_usec_timer_mark(&cmptimer);
cpi->time_compress_data += vpx_usec_timer_elapsed(&cmptimer);

View File

@ -313,10 +313,6 @@ typedef struct VP8_COMP
int rd_thresh_mult[MAX_MODES];
int rd_baseline_thresh[MAX_MODES];
int rd_threshes[MAX_MODES];
int mvcostbase;
int mvcostmultiplier;
int subseqblockweight;
int errthresh;
int RDMULT;
int RDDIV ;
@ -329,16 +325,6 @@ typedef struct VP8_COMP
long long intra_error;
long long last_intra_error;
#if 0
// Experimental RD code
long long frame_distortion;
long long last_frame_distortion;
#endif
int last_mb_distortion;
int frames_since_auto_filter;
int this_frame_target;
int projected_frame_size;
int last_q[2]; // Separate values for Intra/Inter
@ -384,7 +370,6 @@ typedef struct VP8_COMP
int per_frame_bandwidth; // Current section per frame bandwidth target
int av_per_frame_bandwidth; // Average frame size target for clip
int min_frame_bandwidth; // Minimum allocation that should be used for any frame
int last_key_frame_size;
int inter_frame_target;
double output_frame_rate;
long long last_time_stamp_seen;
@ -443,11 +428,6 @@ typedef struct VP8_COMP
vp8_prob frame_coef_probs [BLOCK_TYPES] [COEF_BANDS] [PREV_COEF_CONTEXTS] [vp8_coef_tokens-1];
unsigned int frame_branch_ct [BLOCK_TYPES] [COEF_BANDS] [PREV_COEF_CONTEXTS] [vp8_coef_tokens-1][2];
/* Second compressed data partition contains coefficient data. */
unsigned char *output_partition2;
size_t output_partition2size;
int frames_to_key;
int gfu_boost;
int kf_boost;
@ -456,15 +436,12 @@ typedef struct VP8_COMP
double total_intra_error_left;
double total_coded_error_left;
double start_tot_err_left;
double min_error;
double kf_intra_err_min;
double gf_intra_err_min;
double modified_error_total;
double modified_error_used;
double modified_error_left;
double clip_bpe;
double observed_bpe;
double avg_iiratio;
@ -499,7 +476,6 @@ typedef struct VP8_COMP
int goldfreq;
int auto_worst_q;
int cpu_used;
int chroma_boost;
int horiz_scale;
int vert_scale;
int pass;
@ -517,30 +493,13 @@ typedef struct VP8_COMP
int this_frame_percent_intra;
int last_frame_percent_intra;
int last_key_frame_q;
int last_kffilt_lvl;
int ref_frame_flags;
SPEED_FEATURES sf;
int error_bins[1024];
int inter_lvl;
int intra_lvl;
int motion_lvl;
int motion_speed;
int motion_var;
unsigned int next_iiratio;
unsigned int this_iiratio;
int this_frame_modified_error;
double norm_intra_err_per_mb;
double norm_inter_err_per_mb;
double norm_iidiff_per_mb;
int last_best_mode_index; // Record of mode index chosen for previous macro block.
int last_auto_filt_val;
int last_auto_filt_q;
// Data used for real time conferencing mode to help determine if it would be good to update the gf
int inter_zz_count;
@ -549,10 +508,6 @@ typedef struct VP8_COMP
int skip_true_count;
int skip_false_count;
int alt_qcount;
int ready_for_new_frame;
unsigned char *segmentation_map;
signed char segment_feature_data[MB_LVL_MAX][MAX_MB_SEGMENTS]; // Segment data (can be deltas or absolute values)
int segment_encode_breakout[MAX_MB_SEGMENTS]; // segment threashold for encode breakout
@ -602,9 +557,6 @@ typedef struct VP8_COMP
unsigned int time_pick_lpf;
unsigned int time_encode_mb_row;
unsigned int tempdata1;
unsigned int tempdata2;
int base_skip_false_prob[128];
unsigned int section_intra_rating;

View File

@ -919,9 +919,6 @@ void vp8_pick_inter_mode(VP8_COMP *cpi, MACROBLOCK *x, int recon_yoffset, int re
cpi->rd_threshes[best_mode_index] = (cpi->rd_baseline_thresh[best_mode_index] >> 7) * cpi->rd_thresh_mult[best_mode_index];
}
// Keep a record of best mode index for use in next loop
cpi->last_best_mode_index = best_mode_index;
if (best_mbmode.mode <= B_PRED)
{
x->e_mbd.mode_info_context->mbmi.ref_frame = INTRA_FRAME;

View File

@ -474,8 +474,4 @@ void vp8cx_pick_filter_level(YV12_BUFFER_CONFIG *sd, VP8_COMP *cpi)
}
cm->filter_level = filt_best;
cpi->last_auto_filt_val = filt_best;
cpi->last_auto_filt_q = cm->base_qindex;
cpi->frames_since_auto_filter = 0;
}

View File

@ -1431,7 +1431,6 @@ void vp8_adjust_key_frame_context(VP8_COMP *cpi)
}
cpi->frames_since_key = 0;
cpi->last_key_frame_size = cpi->projected_frame_size;
cpi->key_frame_count++;
}

View File

@ -2374,9 +2374,6 @@ void vp8_rd_pick_inter_mode(VP8_COMP *cpi, MACROBLOCK *x, int recon_yoffset, int
}
// Keep a record of best mode index that we chose
cpi->last_best_mode_index = best_mode_index;
// Note how often each mode chosen as best
cpi->mode_chosen_counts[best_mode_index] ++;