Commit d4add7ac authored by Brennan Shacklett's avatar Brennan Shacklett Committed by Yaowu Xu

Remove encode_breakout and related speed features

Seems to be dead code

Change-Id: I17b3edc9e82d6a1da172a686522358a6b1a630e9
parent 4b4e5eef
......@@ -425,7 +425,6 @@ static aom_codec_err_t set_encoder_config(
oxcf->key_freq = cfg->kf_max_dist;
oxcf->speed = abs(extra_cfg->cpu_used);
oxcf->encode_breakout = extra_cfg->static_thresh;
oxcf->enable_auto_arf = extra_cfg->enable_auto_alt_ref;
#if CONFIG_EXT_REFS
oxcf->enable_auto_brf = extra_cfg->enable_auto_bwd_ref;
......@@ -505,7 +504,6 @@ static aom_codec_err_t set_encoder_config(
printf("lag_in_frames: %d\n", oxcf->lag_in_frames);
printf("enable_auto_arf: %d\n", oxcf->enable_auto_arf);
printf("Version: %d\n", oxcf->Version);
printf("encode_breakout: %d\n", oxcf->encode_breakout);
printf("error resilient: %d\n", oxcf->error_resilient_mode);
printf("frame parallel detokenization: %d\n",
oxcf->frame_parallel_decoding_mode);
......
......@@ -157,8 +157,6 @@ struct macroblock {
int skip;
int encode_breakout;
// note that token_costs is the cost when eob node is skipped
av1_coeff_cost token_costs[TX_SIZES];
......
......@@ -324,11 +324,8 @@ static void set_offsets(const AV1_COMP *const cpi, const TileInfo *const tile,
mbmi->segment_id = get_segment_id(cm, map, bsize, mi_row, mi_col);
}
av1_init_plane_quantizers(cpi, x, mbmi->segment_id);
x->encode_breakout = cpi->segment_encode_breakout[mbmi->segment_id];
} else {
mbmi->segment_id = 0;
x->encode_breakout = cpi->encode_breakout;
}
#if CONFIG_SUPERTX
......@@ -404,7 +401,6 @@ static void set_segment_id_supertx(const AV1_COMP *const cpi,
if (!seg->enabled) {
seg_id_supertx = 0;
x->encode_breakout = cpi->encode_breakout;
} else {
// Find the minimum segment_id
for (r = 0; r < mih; r++)
......@@ -415,7 +411,6 @@ static void set_segment_id_supertx(const AV1_COMP *const cpi,
// Initialize plane quantisers
av1_init_plane_quantizers(cpi, x, seg_id_supertx);
x->encode_breakout = cpi->segment_encode_breakout[seg_id_supertx];
}
// Assign the the segment_id back to segment_id_supertx
......@@ -1688,7 +1683,6 @@ static void rd_pick_sb_modes(const AV1_COMP *const cpi, TileDataEnc *tile_data,
mbmi->segment_id = av1_vaq_segment_id(energy);
// Re-initialise quantiser
av1_init_plane_quantizers(cpi, x, mbmi->segment_id);
x->encode_breakout = cpi->segment_encode_breakout[mbmi->segment_id];
}
x->rdmult = set_segment_rdmult(cpi, x, mbmi->segment_id);
} else if (aq_mode == COMPLEXITY_AQ) {
......
......@@ -1897,14 +1897,6 @@ void av1_change_config(struct AV1_COMP *cpi, const AV1EncoderConfig *oxcf) {
av1_reset_segment_features(cm);
av1_set_high_precision_mv(cpi, 0);
{
int i;
for (i = 0; i < MAX_SEGMENTS; i++)
cpi->segment_encode_breakout[i] = cpi->oxcf.encode_breakout;
}
cpi->encode_breakout = cpi->oxcf.encode_breakout;
set_rc_buffer_sizes(rc, &cpi->oxcf);
// Under a configuration change, where maximum_buffer_size may change,
......@@ -2167,8 +2159,6 @@ AV1_COMP *av1_create_compressor(AV1EncoderConfig *oxcf,
kf_list = fopen("kf_list.stt", "w");
#endif
cpi->allow_encode_breakout = ENCODE_BREAKOUT_ENABLED;
if (oxcf->pass == 1) {
av1_init_first_pass(cpi);
} else if (oxcf->pass == 2) {
......@@ -4760,8 +4750,6 @@ static void Pass0Encode(AV1_COMP *cpi, size_t *size, uint8_t *dest,
static void Pass2Encode(AV1_COMP *cpi, size_t *size, uint8_t *dest,
unsigned int *frame_flags) {
cpi->allow_encode_breakout = ENCODE_BREAKOUT_ENABLED;
encode_frame_to_data_rate(cpi, size, dest, frame_flags);
#if CONFIG_EXT_REFS
......
......@@ -85,15 +85,6 @@ typedef enum {
#endif
} FRAME_CONTEXT_INDEX;
typedef enum {
// encode_breakout is disabled.
ENCODE_BREAKOUT_DISABLED = 0,
// encode_breakout is enabled.
ENCODE_BREAKOUT_ENABLED = 1,
// encode_breakout is enabled with small max_thresh limit.
ENCODE_BREAKOUT_LIMITED = 2
} ENCODE_BREAKOUT_TYPE;
typedef enum {
NORMAL = 0,
FOURFIVE = 1,
......@@ -223,8 +214,6 @@ typedef struct AV1EncoderConfig {
int enable_auto_brf; // (b)ackward (r)ef (f)rame
#endif // CONFIG_EXT_REFS
int encode_breakout; // early breakout : for video conf recommend 800
/* Bitfield defining the error resiliency features to enable.
* Can provide decodable frames after losses in previous
* frames and decodable partitions after losses in the same frame.
......@@ -449,18 +438,8 @@ typedef struct AV1_COMP {
int allow_comp_inter_inter;
// Default value is 1. From first pass stats, encode_breakout may be disabled.
ENCODE_BREAKOUT_TYPE allow_encode_breakout;
// Get threshold from external input. A suggested threshold is 800 for HD
// clips, and 300 for < HD clips.
int encode_breakout;
uint8_t *segmentation_map;
// segment threashold for encode breakout
int segment_encode_breakout[MAX_SEGMENTS];
CYCLIC_REFRESH *cyclic_refresh;
ActiveMap active_map;
......
......@@ -270,11 +270,6 @@ static void set_rt_speed_feature_framesize_dependent(AV1_COMP *cpi,
sf->partition_search_breakout_dist_thr = (1 << 23);
}
}
if (speed >= 7) {
sf->encode_breakout_thresh =
(AOMMIN(cm->width, cm->height) >= 720) ? 800 : 300;
}
}
static void set_rt_speed_feature(AV1_COMP *cpi, SPEED_FEATURES *sf, int speed,
......@@ -454,11 +449,6 @@ void av1_set_speed_features_framesize_dependent(AV1_COMP *cpi) {
sf->adaptive_pred_interp_filter = 0;
}
if (cpi->encode_breakout && oxcf->mode == REALTIME &&
sf->encode_breakout_thresh > cpi->encode_breakout) {
cpi->encode_breakout = sf->encode_breakout_thresh;
}
// Check for masked out split cases.
for (i = 0; i < MAX_REFS; ++i) {
if (sf->disable_split_mask & (1 << i)) {
......@@ -542,7 +532,6 @@ void av1_set_speed_features_framesize_independent(AV1_COMP *cpi) {
// to FIXED_PARTITION.
sf->always_this_block_size = BLOCK_16X16;
sf->search_type_check_frequency = 50;
sf->encode_breakout_thresh = 0;
// Recode loop tolerance %.
sf->recode_tolerance = 25;
sf->default_interp_filter = SWITCHABLE;
......
......@@ -443,10 +443,6 @@ typedef struct SPEED_FEATURES {
// time mode speed 6.
int reuse_inter_pred_sby;
// This variable sets the encode_breakout threshold. Currently, it is only
// enabled in real time mode.
int encode_breakout_thresh;
// default interp filter choice
InterpFilter default_interp_filter;
......
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