diff options
author | Linfeng Zhang <linfengz@google.com> | 2018-05-01 17:57:51 -0700 |
---|---|---|
committer | Linfeng Zhang <linfengz@google.com> | 2018-05-01 17:57:51 -0700 |
commit | 28c563a11c4c1b429ce464eb8076282da641e21e (patch) | |
tree | ae3c019af960041aff3f8503e82def0f5f6db56a /vp9/encoder/vp9_picklpf.c | |
parent | e4408a07bea94740f5fc1cd05e62aa2dda5f57ff (diff) | |
download | libvpx-28c563a11c4c1b429ce464eb8076282da641e21e.tar libvpx-28c563a11c4c1b429ce464eb8076282da641e21e.tar.gz libvpx-28c563a11c4c1b429ce464eb8076282da641e21e.tar.bz2 libvpx-28c563a11c4c1b429ce464eb8076282da641e21e.zip |
Clean switch cases in vp9 encoder
To save a branch.
Change-Id: Ifa2be7583e95c6991784731c654bbd4cce31e993
Diffstat (limited to 'vp9/encoder/vp9_picklpf.c')
-rw-r--r-- | vp9/encoder/vp9_picklpf.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/vp9/encoder/vp9_picklpf.c b/vp9/encoder/vp9_picklpf.c index 1c2c55b9e..4e9649065 100644 --- a/vp9/encoder/vp9_picklpf.c +++ b/vp9/encoder/vp9_picklpf.c @@ -169,14 +169,10 @@ void vp9_pick_filter_level(const YV12_BUFFER_CONFIG *sd, VP9_COMP *cpi, case VPX_BITS_10: filt_guess = ROUND_POWER_OF_TWO(q * 20723 + 4060632, 20); break; - case VPX_BITS_12: + default: + assert(cm->bit_depth == VPX_BITS_12); filt_guess = ROUND_POWER_OF_TWO(q * 20723 + 16242526, 22); break; - default: - assert(0 && - "bit_depth should be VPX_BITS_8, VPX_BITS_10 " - "or VPX_BITS_12"); - return; } #else int filt_guess = ROUND_POWER_OF_TWO(q * 20723 + 1015158, 18); |