Removed several unused functions.

Change-Id: Ib9e27298c575afc02a98b593bc6ad60762064d9b
This commit is contained in:
Yaowu Xu 2014-03-17 14:09:29 -07:00
parent aec5e1ed65
commit 5511968f21
7 changed files with 3 additions and 43 deletions

View File

@ -69,13 +69,6 @@ static int gfboost_qadjust(int qindex) {
(1.32 * q) + 79.3);
}
static int kfboost_qadjust(int qindex) {
const double q = vp9_convert_qindex_to_q(qindex);
return (int)((0.00000973 * q * q * q) +
(-0.00613 * q * q) +
(1.316 * q) + 121.2);
}
// Resets the first pass file to the given position using a relative seek from
// the current position.
static void reset_fpf_position(struct twopass_rc *p,
@ -826,12 +819,6 @@ void vp9_first_pass(VP9_COMP *cpi) {
++cm->current_video_frame;
}
// Estimate a cost per mb attributable to overheads such as the coding of modes
// and motion vectors. This currently makes simplistic assumptions for testing.
static double bitcost(double prob) {
return -(log(prob) / log(2.0));
}
static double calc_correction_factor(double err_per_mb,
double err_divisor,
double pt_low,
@ -2131,7 +2118,7 @@ void vp9_rc_get_first_pass_params(VP9_COMP *cpi) {
VP9_COMMON *const cm = &cpi->common;
if (!cpi->refresh_alt_ref_frame &&
(cm->current_video_frame == 0 ||
cm->frame_flags & FRAMEFLAGS_KEY)) {
(cm->frame_flags & FRAMEFLAGS_KEY))) {
cm->frame_type = KEY_FRAME;
} else {
cm->frame_type = INTER_FRAME;

View File

@ -1272,7 +1272,7 @@ void vp9_rc_get_one_pass_vbr_params(VP9_COMP *cpi) {
int target;
if (!cpi->refresh_alt_ref_frame &&
(cm->current_video_frame == 0 ||
cm->frame_flags & FRAMEFLAGS_KEY ||
(cm->frame_flags & FRAMEFLAGS_KEY) ||
rc->frames_to_key == 0 ||
(cpi->oxcf.auto_key && test_for_kf_one_pass(cpi)))) {
cm->frame_type = KEY_FRAME;
@ -1378,7 +1378,7 @@ void vp9_rc_get_one_pass_cbr_params(VP9_COMP *cpi) {
RATE_CONTROL *const rc = &cpi->rc;
int target;
if ((cm->current_video_frame == 0 ||
cm->frame_flags & FRAMEFLAGS_KEY ||
(cm->frame_flags & FRAMEFLAGS_KEY) ||
rc->frames_to_key == 0 ||
(cpi->oxcf.auto_key && test_for_kf_one_pass(cpi)))) {
cm->frame_type = KEY_FRAME;

View File

@ -65,12 +65,6 @@ static double similarity(unsigned long sum_s, unsigned long sum_r,
return ssim_n * 1.0 / ssim_d;
}
static double ssim_16x16(uint8_t *s, int sp, uint8_t *r, int rp) {
unsigned long sum_s = 0, sum_r = 0, sum_sq_s = 0, sum_sq_r = 0, sum_sxr = 0;
vp9_ssim_parms_16x16(s, sp, r, rp, &sum_s, &sum_r, &sum_sq_s, &sum_sq_r,
&sum_sxr);
return similarity(sum_s, sum_r, sum_sq_s, sum_sq_r, sum_sxr, 256);
}
static double ssim_8x8(uint8_t *s, int sp, uint8_t *r, int rp) {
unsigned long sum_s = 0, sum_r = 0, sum_sq_s = 0, sum_sq_r = 0, sum_sxr = 0;
vp9_ssim_parms_8x8(s, sp, r, rp, &sum_s, &sum_r, &sum_sq_s, &sum_sq_r,

View File

@ -18,15 +18,6 @@
static int update_bits[255];
static int split_index(int i, int n, int modulus) {
int max1 = (n - 1 - modulus / 2) / modulus + 1;
if (i % modulus == modulus / 2)
i = i / modulus;
else
i = max1 + i - (i + modulus - modulus / 2) / modulus;
return i;
}
static int recenter_nonneg(int v, int m) {
if (v > (m << 1))
return v;

View File

@ -298,13 +298,6 @@ static void is_skippable(int plane, int block,
args->skippable[0] &= (!args->x->plane[plane].eobs[block]);
}
static int sb_is_skippable(MACROBLOCK *x, BLOCK_SIZE bsize) {
int result = 1;
struct is_skippable_args args = {x, &result};
vp9_foreach_transformed_block(&x->e_mbd, bsize, is_skippable, &args);
return result;
}
int vp9_is_skippable_in_plane(MACROBLOCK *x, BLOCK_SIZE bsize, int plane) {
int result = 1;
struct is_skippable_args args = {x, &result};

View File

@ -13,7 +13,6 @@
#include "vp9/common/vp9_pragmas.h"
#include "vpx_ports/mem.h"
extern unsigned int vp9_get_mb_ss_mmx(const int16_t *src_ptr);
extern unsigned int vp9_get8x8var_mmx
(
const unsigned char *src_ptr,

View File

@ -24,10 +24,6 @@ extern unsigned int vp9_get4x4var_mmx
int *Sum
);
unsigned int vp9_get_mb_ss_sse2
(
const int16_t *src_ptr
);
unsigned int vp9_get16x16var_sse2
(
const unsigned char *src_ptr,