Commit 28b1db92 authored by Deb Mukherjee's avatar Deb Mukherjee
Browse files

Refactoring of switchable filter search for speed

Refactors the switchable filter search in the rd loop to
improve encode speed.

Uses a piecewise approximation to a closed form expression to estimate
rd cost for a Laplacian source with a given variance and quantization
step-size.

About 40% encode time reduction is achieved.

Results (on a feb 12 baseline) show a slight drop:

derf: -0.019%
yt: +0.010%
std-hd: -0.162%
hd: -0.050%

Change-Id: Ie861badf5bba1e3b1052e29a0ef1b7e256edbcd0
parent 1d60b6bc
...@@ -423,6 +423,14 @@ const int vp9_switchable_interp_map[SWITCHABLE+1] = {-1, -1, 0, 1, -1, -1}; ...@@ -423,6 +423,14 @@ const int vp9_switchable_interp_map[SWITCHABLE+1] = {-1, -1, 0, 1, -1, -1};
#else #else
const int vp9_switchable_interp_map[SWITCHABLE+1] = {-1, 0, 1, -1, -1}; const int vp9_switchable_interp_map[SWITCHABLE+1] = {-1, 0, 1, -1, -1};
#endif #endif
#endif // VP9_SWITCHABLE_FILTERS
// Indicates if the filter is interpolating or non-interpolating
// Note currently only the EIGHTTAP_SMOOTH is non-interpolating
#if CONFIG_ENABLE_6TAP
const int vp9_is_interpolating_filter[SWITCHABLE + 1] = {1, 0, 1, 1, 1, -1};
#else
const int vp9_is_interpolating_filter[SWITCHABLE + 1] = {0, 1, 1, 1, -1};
#endif #endif
void vp9_entropy_mode_init() { void vp9_entropy_mode_init() {
......
...@@ -104,6 +104,8 @@ extern const INTERPOLATIONFILTERTYPE vp9_switchable_interp ...@@ -104,6 +104,8 @@ extern const INTERPOLATIONFILTERTYPE vp9_switchable_interp
extern const int vp9_switchable_interp_map[SWITCHABLE + 1]; extern const int vp9_switchable_interp_map[SWITCHABLE + 1];
extern const int vp9_is_interpolating_filter[SWITCHABLE + 1];
extern const vp9_tree_index vp9_switchable_interp_tree extern const vp9_tree_index vp9_switchable_interp_tree
[2 * (VP9_SWITCHABLE_FILTERS - 1)]; [2 * (VP9_SWITCHABLE_FILTERS - 1)];
......
This diff is collapsed.
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