diff options
Diffstat (limited to 'vp8/encoder')
-rw-r--r-- | vp8/encoder/denoising.c | 14 | ||||
-rw-r--r-- | vp8/encoder/encodeframe.c | 7 | ||||
-rw-r--r-- | vp8/encoder/ethreading.c | 6 | ||||
-rw-r--r-- | vp8/encoder/firstpass.c | 4 | ||||
-rw-r--r-- | vp8/encoder/mcomp.c | 4 | ||||
-rw-r--r-- | vp8/encoder/onyx_if.c | 36 | ||||
-rw-r--r-- | vp8/encoder/pickinter.c | 4 | ||||
-rw-r--r-- | vp8/encoder/picklpf.c | 2 | ||||
-rw-r--r-- | vp8/encoder/quantize.c | 4 | ||||
-rw-r--r-- | vp8/encoder/rdopt.c | 8 | ||||
-rw-r--r-- | vp8/encoder/segmentation.c | 2 | ||||
-rw-r--r-- | vp8/encoder/temporal_filter.c | 6 | ||||
-rw-r--r-- | vp8/encoder/tokenize.c | 10 | ||||
-rw-r--r-- | vp8/encoder/x86/quantize_sse2.c | 2 |
14 files changed, 54 insertions, 55 deletions
diff --git a/vp8/encoder/denoising.c b/vp8/encoder/denoising.c index b9fbf061e..d197f8f81 100644 --- a/vp8/encoder/denoising.c +++ b/vp8/encoder/denoising.c @@ -415,8 +415,8 @@ int vp8_denoiser_allocate(VP8_DENOISER *denoiser, int width, int height, vp8_denoiser_free(denoiser); return 1; } - vpx_memset(denoiser->yv12_running_avg[i].buffer_alloc, 0, - denoiser->yv12_running_avg[i].frame_size); + memset(denoiser->yv12_running_avg[i].buffer_alloc, 0, + denoiser->yv12_running_avg[i].frame_size); } denoiser->yv12_mc_running_avg.flags = 0; @@ -428,19 +428,19 @@ int vp8_denoiser_allocate(VP8_DENOISER *denoiser, int width, int height, return 1; } - vpx_memset(denoiser->yv12_mc_running_avg.buffer_alloc, 0, - denoiser->yv12_mc_running_avg.frame_size); + memset(denoiser->yv12_mc_running_avg.buffer_alloc, 0, + denoiser->yv12_mc_running_avg.frame_size); if (vp8_yv12_alloc_frame_buffer(&denoiser->yv12_last_source, width, height, VP8BORDERINPIXELS) < 0) { vp8_denoiser_free(denoiser); return 1; } - vpx_memset(denoiser->yv12_last_source.buffer_alloc, 0, - denoiser->yv12_last_source.frame_size); + memset(denoiser->yv12_last_source.buffer_alloc, 0, + denoiser->yv12_last_source.frame_size); denoiser->denoise_state = vpx_calloc((num_mb_rows * num_mb_cols), 1); - vpx_memset(denoiser->denoise_state, 0, (num_mb_rows * num_mb_cols)); + memset(denoiser->denoise_state, 0, (num_mb_rows * num_mb_cols)); vp8_denoiser_set_parameters(denoiser, mode); denoiser->nmse_source_diff = 0; denoiser->nmse_source_diff_count = 0; diff --git a/vp8/encoder/encodeframe.c b/vp8/encoder/encodeframe.c index ca9880928..378e902c6 100644 --- a/vp8/encoder/encodeframe.c +++ b/vp8/encoder/encodeframe.c @@ -665,8 +665,7 @@ static void init_encode_frame_mb_context(VP8_COMP *cpi) x->mvc = cm->fc.mvc; - vpx_memset(cm->above_context, 0, - sizeof(ENTROPY_CONTEXT_PLANES) * cm->mb_cols); + memset(cm->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES) * cm->mb_cols); /* Special case treatment when GF and ARF are not sensible options * for reference @@ -744,7 +743,7 @@ void vp8_encode_frame(VP8_COMP *cpi) const int num_part = (1 << cm->multi_token_partition); #endif - vpx_memset(segment_counts, 0, sizeof(segment_counts)); + memset(segment_counts, 0, sizeof(segment_counts)); totalrate = 0; if (cpi->compressor_speed == 2) @@ -974,7 +973,7 @@ void vp8_encode_frame(VP8_COMP *cpi) int i; /* Set to defaults */ - vpx_memset(xd->mb_segment_tree_probs, 255 , sizeof(xd->mb_segment_tree_probs)); + memset(xd->mb_segment_tree_probs, 255 , sizeof(xd->mb_segment_tree_probs)); tot_count = segment_counts[0] + segment_counts[1] + segment_counts[2] + segment_counts[3]; diff --git a/vp8/encoder/ethreading.c b/vp8/encoder/ethreading.c index dd52d00ab..977b0b032 100644 --- a/vp8/encoder/ethreading.c +++ b/vp8/encoder/ethreading.c @@ -444,7 +444,7 @@ static void setup_mbby_copy(MACROBLOCK *mbdst, MACROBLOCK *mbsrc) z->zbin_mode_boost_enabled = x->zbin_mode_boost_enabled; z->zbin_mode_boost = x->zbin_mode_boost; - vpx_memset(z->error_bins, 0, sizeof(z->error_bins)); + memset(z->error_bins, 0, sizeof(z->error_bins)); } } @@ -470,7 +470,7 @@ void vp8cx_init_mbrthread_data(VP8_COMP *cpi, mbd->subpixel_predict16x16 = xd->subpixel_predict16x16; mb->gf_active_ptr = x->gf_active_ptr; - vpx_memset(mbr_ei[i].segment_counts, 0, sizeof(mbr_ei[i].segment_counts)); + memset(mbr_ei[i].segment_counts, 0, sizeof(mbr_ei[i].segment_counts)); mbr_ei[i].totalrate = 0; mb->partition_info = x->pi + x->e_mbd.mode_info_stride * (i + 1); @@ -545,7 +545,7 @@ int vp8cx_create_encoder_threads(VP8_COMP *cpi) vpx_malloc(sizeof(sem_t) * th_count)); CHECK_MEM_ERROR(cpi->mb_row_ei, vpx_memalign(32, sizeof(MB_ROW_COMP) * th_count)); - vpx_memset(cpi->mb_row_ei, 0, sizeof(MB_ROW_COMP) * th_count); + memset(cpi->mb_row_ei, 0, sizeof(MB_ROW_COMP) * th_count); CHECK_MEM_ERROR(cpi->en_thread_data, vpx_malloc(sizeof(ENCODETHREAD_DATA) * th_count)); diff --git a/vp8/encoder/firstpass.c b/vp8/encoder/firstpass.c index 0e0764fa6..75c136261 100644 --- a/vp8/encoder/firstpass.c +++ b/vp8/encoder/firstpass.c @@ -1779,7 +1779,7 @@ static void define_gf_group(VP8_COMP *cpi, FIRSTPASS_STATS *this_frame) start_pos = cpi->twopass.stats_in; - vpx_memset(&next_frame, 0, sizeof(next_frame)); /* assure clean */ + memset(&next_frame, 0, sizeof(next_frame)); /* assure clean */ /* Load stats for the current frame. */ mod_frame_err = calculate_modified_err(cpi, this_frame); @@ -2735,7 +2735,7 @@ static void find_next_key_frame(VP8_COMP *cpi, FIRSTPASS_STATS *this_frame) double kf_group_coded_err = 0.0; double recent_loop_decay[8] = {1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0}; - vpx_memset(&next_frame, 0, sizeof(next_frame)); + memset(&next_frame, 0, sizeof(next_frame)); vp8_clear_system_state(); start_position = cpi->twopass.stats_in; diff --git a/vp8/encoder/mcomp.c b/vp8/encoder/mcomp.c index 237c8ebd1..7149f5f02 100644 --- a/vp8/encoder/mcomp.c +++ b/vp8/encoder/mcomp.c @@ -1978,8 +1978,8 @@ void print_mode_context(void) #ifdef VP8_ENTROPY_STATS void init_mv_ref_counts() { - vpx_memset(mv_ref_ct, 0, sizeof(mv_ref_ct)); - vpx_memset(mv_mode_cts, 0, sizeof(mv_mode_cts)); + memset(mv_ref_ct, 0, sizeof(mv_ref_ct)); + memset(mv_mode_cts, 0, sizeof(mv_mode_cts)); } void accum_mv_refs(MB_PREDICTION_MODE m, const int ct[4]) diff --git a/vp8/encoder/onyx_if.c b/vp8/encoder/onyx_if.c index 8e294393f..e7cbbc38b 100644 --- a/vp8/encoder/onyx_if.c +++ b/vp8/encoder/onyx_if.c @@ -428,10 +428,10 @@ static void setup_features(VP8_COMP *cpi) cpi->mb.e_mbd.mode_ref_lf_delta_enabled = 0; cpi->mb.e_mbd.mode_ref_lf_delta_update = 0; - vpx_memset(cpi->mb.e_mbd.ref_lf_deltas, 0, sizeof(cpi->mb.e_mbd.ref_lf_deltas)); - vpx_memset(cpi->mb.e_mbd.mode_lf_deltas, 0, sizeof(cpi->mb.e_mbd.mode_lf_deltas)); - vpx_memset(cpi->mb.e_mbd.last_ref_lf_deltas, 0, sizeof(cpi->mb.e_mbd.ref_lf_deltas)); - vpx_memset(cpi->mb.e_mbd.last_mode_lf_deltas, 0, sizeof(cpi->mb.e_mbd.mode_lf_deltas)); + memset(cpi->mb.e_mbd.ref_lf_deltas, 0, sizeof(cpi->mb.e_mbd.ref_lf_deltas)); + memset(cpi->mb.e_mbd.mode_lf_deltas, 0, sizeof(cpi->mb.e_mbd.mode_lf_deltas)); + memset(cpi->mb.e_mbd.last_ref_lf_deltas, 0, sizeof(cpi->mb.e_mbd.ref_lf_deltas)); + memset(cpi->mb.e_mbd.last_mode_lf_deltas, 0, sizeof(cpi->mb.e_mbd.mode_lf_deltas)); set_default_lf_deltas(cpi); @@ -602,7 +602,7 @@ static void cyclic_background_refresh(VP8_COMP *cpi, int Q, int lf_adjustment) // Set every macroblock to be eligible for update. // For key frame this will reset seg map to 0. - vpx_memset(cpi->segmentation_map, 0, mbs_in_frame); + memset(cpi->segmentation_map, 0, mbs_in_frame); if (cpi->common.frame_type != KEY_FRAME && block_count > 0) { @@ -686,8 +686,8 @@ static void set_default_lf_deltas(VP8_COMP *cpi) cpi->mb.e_mbd.mode_ref_lf_delta_enabled = 1; cpi->mb.e_mbd.mode_ref_lf_delta_update = 1; - vpx_memset(cpi->mb.e_mbd.ref_lf_deltas, 0, sizeof(cpi->mb.e_mbd.ref_lf_deltas)); - vpx_memset(cpi->mb.e_mbd.mode_lf_deltas, 0, sizeof(cpi->mb.e_mbd.mode_lf_deltas)); + memset(cpi->mb.e_mbd.ref_lf_deltas, 0, sizeof(cpi->mb.e_mbd.ref_lf_deltas)); + memset(cpi->mb.e_mbd.mode_lf_deltas, 0, sizeof(cpi->mb.e_mbd.mode_lf_deltas)); /* Test of ref frame deltas */ cpi->mb.e_mbd.ref_lf_deltas[INTRA_FRAME] = 2; @@ -1087,7 +1087,7 @@ void vp8_set_speed_features(VP8_COMP *cpi) if (Speed >= 15) sf->half_pixel_search = 0; - vpx_memset(cpi->mb.error_bins, 0, sizeof(cpi->mb.error_bins)); + memset(cpi->mb.error_bins, 0, sizeof(cpi->mb.error_bins)); }; /* switch */ @@ -1298,7 +1298,7 @@ void vp8_alloc_compressor_data(VP8_COMP *cpi) CHECK_MEM_ERROR(cpi->active_map, vpx_calloc(cm->mb_rows * cm->mb_cols, sizeof(*cpi->active_map))); - vpx_memset(cpi->active_map , 1, (cm->mb_rows * cm->mb_cols)); + memset(cpi->active_map , 1, (cm->mb_rows * cm->mb_cols)); #if CONFIG_MULTITHREAD if (width < 640) @@ -1891,7 +1891,7 @@ struct VP8_COMP* vp8_create_compressor(VP8_CONFIG *oxcf) cm = &cpi->common; - vpx_memset(cpi, 0, sizeof(VP8_COMP)); + memset(cpi, 0, sizeof(VP8_COMP)); if (setjmp(cm->error.jmp)) { @@ -2867,7 +2867,7 @@ static void update_alt_ref_frame_stats(VP8_COMP *cpi) } /* Update data structure that monitors level of reference to last GF */ - vpx_memset(cpi->gf_active_flags, 1, (cm->mb_rows * cm->mb_cols)); + memset(cpi->gf_active_flags, 1, (cm->mb_rows * cm->mb_cols)); cpi->gf_active_count = cm->mb_rows * cm->mb_cols; /* this frame refreshes means next frames don't unless specified by user */ @@ -2916,7 +2916,7 @@ static void update_golden_frame_stats(VP8_COMP *cpi) } /* Update data structure that monitors level of reference to last GF */ - vpx_memset(cpi->gf_active_flags, 1, (cm->mb_rows * cm->mb_cols)); + memset(cpi->gf_active_flags, 1, (cm->mb_rows * cm->mb_cols)); cpi->gf_active_count = cm->mb_rows * cm->mb_cols; /* this frame refreshes means next frames don't unless specified by @@ -3830,9 +3830,9 @@ static void encode_frame_to_data_rate } // Reset the zero_last counter to 0 on key frame. - vpx_memset(cpi->consec_zero_last, 0, cm->mb_rows * cm->mb_cols); - vpx_memset(cpi->consec_zero_last_mvbias, 0, - (cpi->common.mb_rows * cpi->common.mb_cols)); + memset(cpi->consec_zero_last, 0, cm->mb_rows * cm->mb_cols); + memset(cpi->consec_zero_last_mvbias, 0, + (cpi->common.mb_rows * cpi->common.mb_cols)); } #if 0 @@ -4362,9 +4362,9 @@ static void encode_frame_to_data_rate disable_segmentation(cpi); } // Reset the zero_last counter to 0 on key frame. - vpx_memset(cpi->consec_zero_last, 0, cm->mb_rows * cm->mb_cols); - vpx_memset(cpi->consec_zero_last_mvbias, 0, - (cpi->common.mb_rows * cpi->common.mb_cols)); + memset(cpi->consec_zero_last, 0, cm->mb_rows * cm->mb_cols); + memset(cpi->consec_zero_last_mvbias, 0, + (cpi->common.mb_rows * cpi->common.mb_cols)); vp8_set_quantizer(cpi, Q); } diff --git a/vp8/encoder/pickinter.c b/vp8/encoder/pickinter.c index a13808cae..c4c0e7e9e 100644 --- a/vp8/encoder/pickinter.c +++ b/vp8/encoder/pickinter.c @@ -862,8 +862,8 @@ void vp8_pick_inter_mode(VP8_COMP *cpi, MACROBLOCK *x, int recon_yoffset, mode_mv = mode_mv_sb[sign_bias]; best_ref_mv.as_int = 0; - vpx_memset(mode_mv_sb, 0, sizeof(mode_mv_sb)); - vpx_memset(&best_mbmode, 0, sizeof(best_mbmode)); + memset(mode_mv_sb, 0, sizeof(mode_mv_sb)); + memset(&best_mbmode, 0, sizeof(best_mbmode)); /* Setup search priorities */ #if CONFIG_MULTI_RES_ENCODING diff --git a/vp8/encoder/picklpf.c b/vp8/encoder/picklpf.c index 81f19c958..890053dcf 100644 --- a/vp8/encoder/picklpf.c +++ b/vp8/encoder/picklpf.c @@ -286,7 +286,7 @@ void vp8cx_pick_filter_level(YV12_BUFFER_CONFIG *sd, VP8_COMP *cpi) YV12_BUFFER_CONFIG * saved_frame = cm->frame_to_show; - vpx_memset(ss_err, 0, sizeof(ss_err)); + memset(ss_err, 0, sizeof(ss_err)); /* Replace unfiltered frame buffer with a new one */ cm->frame_to_show = &cpi->pick_lf_lvl_frame; diff --git a/vp8/encoder/quantize.c b/vp8/encoder/quantize.c index bd47823dd..c5a7bc670 100644 --- a/vp8/encoder/quantize.c +++ b/vp8/encoder/quantize.c @@ -65,8 +65,8 @@ void vp8_regular_quantize_b_c(BLOCK *b, BLOCKD *d) short *dequant_ptr = d->dequant; short zbin_oq_value = b->zbin_extra; - vpx_memset(qcoeff_ptr, 0, 32); - vpx_memset(dqcoeff_ptr, 0, 32); + memset(qcoeff_ptr, 0, 32); + memset(dqcoeff_ptr, 0, 32); eob = -1; diff --git a/vp8/encoder/rdopt.c b/vp8/encoder/rdopt.c index 605d5f8c5..a945890e2 100644 --- a/vp8/encoder/rdopt.c +++ b/vp8/encoder/rdopt.c @@ -1392,7 +1392,7 @@ static int vp8_rd_pick_best_mbsegmentation(VP8_COMP *cpi, MACROBLOCK *x, int i; BEST_SEG_INFO bsi; - vpx_memset(&bsi, 0, sizeof(bsi)); + memset(&bsi, 0, sizeof(bsi)); bsi.segment_rd = best_rd; bsi.ref_mv = best_ref_mv; @@ -1988,9 +1988,9 @@ void vp8_rd_pick_inter_mode(VP8_COMP *cpi, MACROBLOCK *x, int recon_yoffset, best_mode.rd = INT_MAX; best_mode.yrd = INT_MAX; best_mode.intra_rd = INT_MAX; - vpx_memset(mode_mv_sb, 0, sizeof(mode_mv_sb)); - vpx_memset(&best_mode.mbmode, 0, sizeof(best_mode.mbmode)); - vpx_memset(&best_mode.bmodes, 0, sizeof(best_mode.bmodes)); + memset(mode_mv_sb, 0, sizeof(mode_mv_sb)); + memset(&best_mode.mbmode, 0, sizeof(best_mode.mbmode)); + memset(&best_mode.bmodes, 0, sizeof(best_mode.bmodes)); /* Setup search priorities */ get_reference_search_order(cpi, ref_frame_map); diff --git a/vp8/encoder/segmentation.c b/vp8/encoder/segmentation.c index 37972e219..fdd22fceb 100644 --- a/vp8/encoder/segmentation.c +++ b/vp8/encoder/segmentation.c @@ -23,7 +23,7 @@ void vp8_update_gf_useage_maps(VP8_COMP *cpi, VP8_COMMON *cm, MACROBLOCK *x) if ((cm->frame_type == KEY_FRAME) || (cm->refresh_golden_frame)) { /* Reset Gf useage monitors */ - vpx_memset(cpi->gf_active_flags, 1, (cm->mb_rows * cm->mb_cols)); + memset(cpi->gf_active_flags, 1, (cm->mb_rows * cm->mb_cols)); cpi->gf_active_count = cm->mb_rows * cm->mb_cols; } else diff --git a/vp8/encoder/temporal_filter.c b/vp8/encoder/temporal_filter.c index 04501ac9b..0fa0d8d7b 100644 --- a/vp8/encoder/temporal_filter.c +++ b/vp8/encoder/temporal_filter.c @@ -274,8 +274,8 @@ static void vp8_temporal_filter_iterate_c int i, j, k; int stride; - vpx_memset(accumulator, 0, 384*sizeof(unsigned int)); - vpx_memset(count, 0, 384*sizeof(unsigned short)); + memset(accumulator, 0, 384*sizeof(unsigned int)); + memset(count, 0, 384*sizeof(unsigned short)); #if ALT_REF_MC_ENABLED cpi->mb.mv_col_min = -((mb_col * 16) + (16 - 5)); @@ -502,7 +502,7 @@ void vp8_temporal_filter_prepare_c start_frame = distance + frames_to_blur_forward; /* Setup frame pointers, NULL indicates frame not included in filter */ - vpx_memset(cpi->frames, 0, max_frames*sizeof(YV12_BUFFER_CONFIG *)); + memset(cpi->frames, 0, max_frames*sizeof(YV12_BUFFER_CONFIG *)); for (frame = 0; frame < frames_to_blur; frame++) { int which_buffer = start_frame - frame; diff --git a/vp8/encoder/tokenize.c b/vp8/encoder/tokenize.c index 2dc820527..afd46fb21 100644 --- a/vp8/encoder/tokenize.c +++ b/vp8/encoder/tokenize.c @@ -421,7 +421,7 @@ void vp8_tokenize_mb(VP8_COMP *cpi, MACROBLOCK *x, TOKENEXTRA **t) void init_context_counters(void) { - vpx_memset(context_counters, 0, sizeof(context_counters)); + memset(context_counters, 0, sizeof(context_counters)); } void print_context_counters() @@ -596,13 +596,13 @@ void vp8_fix_contexts(MACROBLOCKD *x) /* Clear entropy contexts for Y2 blocks */ if (x->mode_info_context->mbmi.mode != B_PRED && x->mode_info_context->mbmi.mode != SPLITMV) { - vpx_memset(x->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)); - vpx_memset(x->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)); + memset(x->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)); + memset(x->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)); } else { - vpx_memset(x->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)-1); - vpx_memset(x->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)-1); + memset(x->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)-1); + memset(x->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES)-1); } } diff --git a/vp8/encoder/x86/quantize_sse2.c b/vp8/encoder/x86/quantize_sse2.c index f56e64672..7dfb01373 100644 --- a/vp8/encoder/x86/quantize_sse2.c +++ b/vp8/encoder/x86/quantize_sse2.c @@ -55,7 +55,7 @@ void vp8_regular_quantize_b_sse2(BLOCK *b, BLOCKD *d) __m128i dequant0 = _mm_load_si128((__m128i *)(d->dequant)); __m128i dequant1 = _mm_load_si128((__m128i *)(d->dequant + 8)); - vpx_memset(qcoeff_ptr, 0, 32); + memset(qcoeff_ptr, 0, 32); /* Duplicate to all lanes. */ zbin_extra = _mm_shufflelo_epi16(zbin_extra, 0); |