Commit f0911886 authored by Dmitry Kovalev's avatar Dmitry Kovalev Committed by Gerrit Code Review
Browse files

Merge "Renaming 'Speed' to 'speed' inside VP9_COMP struct." into experimental

parents 60dd610e 4be190d9
...@@ -35,7 +35,7 @@ static unsigned int do_16x16_motion_iteration(VP9_COMP *cpi, ...@@ -35,7 +35,7 @@ static unsigned int do_16x16_motion_iteration(VP9_COMP *cpi,
// Further step/diamond searches as necessary // Further step/diamond searches as necessary
int step_param = cpi->sf.first_step + int step_param = cpi->sf.first_step +
(cpi->Speed < 8 ? (cpi->Speed > 5 ? 1 : 0) : 2); (cpi->speed < 8 ? (cpi->speed > 5 ? 1 : 0) : 2);
vp9_clamp_mv_min_max(x, ref_mv); vp9_clamp_mv_min_max(x, ref_mv);
......
...@@ -695,7 +695,7 @@ static void set_rd_speed_thresholds(VP9_COMP *cpi, int mode, int speed) { ...@@ -695,7 +695,7 @@ static void set_rd_speed_thresholds(VP9_COMP *cpi, int mode, int speed) {
void vp9_set_speed_features(VP9_COMP *cpi) { void vp9_set_speed_features(VP9_COMP *cpi) {
SPEED_FEATURES *sf = &cpi->sf; SPEED_FEATURES *sf = &cpi->sf;
int mode = cpi->compressor_speed; int mode = cpi->compressor_speed;
int speed = cpi->Speed; int speed = cpi->speed;
int i; int i;
// Only modes 0 and 1 supported for now in experimental code basae // Only modes 0 and 1 supported for now in experimental code basae
...@@ -830,7 +830,7 @@ void vp9_set_speed_features(VP9_COMP *cpi) { ...@@ -830,7 +830,7 @@ void vp9_set_speed_features(VP9_COMP *cpi) {
cpi->mb.optimize = cpi->sf.optimize_coefficients == 1 && cpi->pass != 1; cpi->mb.optimize = cpi->sf.optimize_coefficients == 1 && cpi->pass != 1;
#ifdef SPEEDSTATS #ifdef SPEEDSTATS
frames_at_speed[cpi->Speed]++; frames_at_speed[cpi->speed]++;
#endif #endif
} }
...@@ -1215,7 +1215,7 @@ void vp9_change_config(VP9_PTR ptr, VP9_CONFIG *oxcf) { ...@@ -1215,7 +1215,7 @@ void vp9_change_config(VP9_PTR ptr, VP9_CONFIG *oxcf) {
cpi->last_boosted_qindex = cpi->oxcf.fixed_q; cpi->last_boosted_qindex = cpi->oxcf.fixed_q;
} }
cpi->Speed = cpi->oxcf.cpu_used; cpi->speed = cpi->oxcf.cpu_used;
if (cpi->oxcf.lag_in_frames == 0) { if (cpi->oxcf.lag_in_frames == 0) {
// force to allowlag to 0 if lag_in_frames is 0; // force to allowlag to 0 if lag_in_frames is 0;
......
...@@ -466,7 +466,7 @@ typedef struct VP9_COMP { ...@@ -466,7 +466,7 @@ typedef struct VP9_COMP {
// for real time encoding // for real time encoding
int avg_encode_time; // microsecond int avg_encode_time; // microsecond
int avg_pick_mode_time; // microsecond int avg_pick_mode_time; // microsecond
int Speed; int speed;
unsigned int cpu_freq; // Mhz unsigned int cpu_freq; // Mhz
int compressor_speed; int compressor_speed;
......
...@@ -2258,7 +2258,7 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x, ...@@ -2258,7 +2258,7 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x,
best_txfm_rd[i] = INT64_MAX; best_txfm_rd[i] = INT64_MAX;
// Create a mask set to 1 for each frame used by a smaller resolution. // Create a mask set to 1 for each frame used by a smaller resolution.
if (cpi->Speed > 0) { if (cpi->speed > 0) {
switch (block_size) { switch (block_size) {
case BLOCK_64X64: case BLOCK_64X64:
for (i = 0; i < 4; i++) { for (i = 0; i < 4; i++) {
...@@ -2298,8 +2298,8 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x, ...@@ -2298,8 +2298,8 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x,
frame_mv[NEWMV][ref_frame].as_int = INVALID_MV; frame_mv[NEWMV][ref_frame].as_int = INVALID_MV;
frame_mv[ZEROMV][ref_frame].as_int = 0; frame_mv[ZEROMV][ref_frame].as_int = 0;
} }
if (cpi->Speed == 0 if (cpi->speed == 0
|| (cpi->Speed > 0 && (ref_frame_mask & (1 << INTRA_FRAME)))) { || (cpi->speed > 0 && (ref_frame_mask & (1 << INTRA_FRAME)))) {
mbmi->mode = DC_PRED; mbmi->mode = DC_PRED;
for (i = 0; i <= (bsize < BLOCK_SIZE_MB16X16 ? TX_4X4 : for (i = 0; i <= (bsize < BLOCK_SIZE_MB16X16 ? TX_4X4 :
(bsize < BLOCK_SIZE_SB32X32 ? TX_8X8 : (bsize < BLOCK_SIZE_SB32X32 ? TX_8X8 :
...@@ -2337,7 +2337,7 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x, ...@@ -2337,7 +2337,7 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x,
|| (cpi->ref_frame_flags & flag_list[ref_frame]))) { || (cpi->ref_frame_flags & flag_list[ref_frame]))) {
continue; continue;
} }
if (cpi->Speed > 0) { if (cpi->speed > 0) {
if (!(ref_frame_mask & (1 << ref_frame))) { if (!(ref_frame_mask & (1 << ref_frame))) {
continue; continue;
} }
......
...@@ -147,12 +147,10 @@ static int temporal_filter_find_matching_mb_c(VP9_COMP *cpi, ...@@ -147,12 +147,10 @@ static int temporal_filter_find_matching_mb_c(VP9_COMP *cpi,
xd->plane[0].pre[0].stride = arf_frame->y_stride; xd->plane[0].pre[0].stride = arf_frame->y_stride;
// Further step/diamond searches as necessary // Further step/diamond searches as necessary
if (cpi->Speed < 8) { if (cpi->speed < 8)
step_param = cpi->sf.first_step + step_param = cpi->sf.first_step + ((cpi->speed > 5) ? 1 : 0);
((cpi->Speed > 5) ? 1 : 0); else
} else {
step_param = cpi->sf.first_step + 2; step_param = cpi->sf.first_step + 2;
}
/*cpi->sf.search_method == HEX*/ /*cpi->sf.search_method == HEX*/
// TODO Check that the 16x16 vf & sdf are selected here // TODO Check that the 16x16 vf & sdf are selected here
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment