Correct the referencing of an argument search_sites While referencing the argument 'search_sites' in functions av1_make_default_fullpel_ms_params() and av1_set_mv_search_method(), the size of this array is used as NUM_SEARCH_METHODS instead of allocated size NUM_DISTINCT_SEARCH_METHODS. This CL corrects the same for better understanding. BUG=aomedia:3205 Change-Id: I1a6c20f1755b2e920638941df2cc93268d94cbb2 (cherry picked from commit 67dc8da7228a1b6b93581ef35fdb477e9fe53bf6)
diff --git a/av1/encoder/mcomp.c b/av1/encoder/mcomp.c index ef7cb1f..5a308a2 100644 --- a/av1/encoder/mcomp.c +++ b/av1/encoder/mcomp.c
@@ -94,7 +94,7 @@ void av1_make_default_fullpel_ms_params( FULLPEL_MOTION_SEARCH_PARAMS *ms_params, const struct AV1_COMP *cpi, const MACROBLOCK *x, BLOCK_SIZE bsize, const MV *ref_mv, - const search_site_config search_sites[NUM_SEARCH_METHODS], + const search_site_config search_sites[NUM_DISTINCT_SEARCH_METHODS], int fine_search_interval) { const MV_SPEED_FEATURES *mv_sf = &cpi->sf.mv_sf;
diff --git a/av1/encoder/mcomp.h b/av1/encoder/mcomp.h index b2539f5..20ec34f 100644 --- a/av1/encoder/mcomp.h +++ b/av1/encoder/mcomp.h
@@ -209,7 +209,7 @@ void av1_make_default_fullpel_ms_params( FULLPEL_MOTION_SEARCH_PARAMS *ms_params, const struct AV1_COMP *cpi, const MACROBLOCK *x, BLOCK_SIZE bsize, const MV *ref_mv, - const search_site_config search_sites[NUM_SEARCH_METHODS], + const search_site_config search_sites[NUM_DISTINCT_SEARCH_METHODS], int fine_search_interval); /*! Sets the \ref FULLPEL_MOTION_SEARCH_PARAMS to intra mode. */ @@ -238,7 +238,7 @@ // Mv beyond the range do not produce new/different prediction block. static INLINE void av1_set_mv_search_method( FULLPEL_MOTION_SEARCH_PARAMS *ms_params, - const search_site_config search_sites[NUM_SEARCH_METHODS], + const search_site_config search_sites[NUM_DISTINCT_SEARCH_METHODS], SEARCH_METHODS search_method) { // Array to inform which all search methods are having // same candidates and different in number of search steps.