Commit Graph

14902 Commits

Author SHA1 Message Date
Scott LaVarnway
e7fc39fdf5 Merge "VPX: x86 asm version of vpx_idct32x32_34_add()" 2015-11-20 15:11:00 +00:00
Alex Converse
6aa2163b69 bitreader/writer: Change shift to signed
Silences several legal but suspicious unsigned overflows found with
clang -fsanitize=integer.

Change-Id: I69399751492a183167932b0a10751c433c32ca7b
2015-11-19 15:13:39 -08:00
Alex Converse
42b7c44b2f Fix a signed shift overflow in vpx_rb_read_inv_signed_literal.
Found with clang -fsanitize=integer

Change-Id: I17cb2166c06ff463abfaf9b0e6bc749d0d6fdf94
2015-11-19 15:04:20 -08:00
Alex Converse
b1fcd1751e Fix unsigned overflow in rd_variance_adjustment.
Found with clang -fsanitize=integer

Change-Id: I2538e7483cb2d5f06bceecbd3326bdd88bfecfa1
2015-11-19 15:00:59 -08:00
Jian Zhou
d76032ae87 Speed up h_predictor_4x4
Modify h_predictor_4x4 with XMM registers.
Speed up by ~25% in ./test_intra_pred_speed.

Change-Id: Id01c34c48e75b9d56dfc2e93af12cf0c0326a279
2015-11-19 11:34:22 -08:00
Paul Wilkins
f3f6b6fe3e Merge "Changes to best quality settings." 2015-11-19 16:13:43 +00:00
Jian Zhou
4993158ee5 Merge "Speed up tm_predictor_4x4" 2015-11-19 02:32:48 +00:00
Jian Zhou
79b68626ae Speed up tm_predictor_4x4
tm_predictor_4x4 is implemented with SSE2 using XMM registers.
Speed up by ~25% in ./test_intra_pred_speed.

Change-Id: I25074b78d476a2cb17f81cf654bdfd80df2070e0
2015-11-18 16:44:25 -08:00
Marco
eed5494fc6 vp9-svc: Fix to key frame counter for spatial layers.
Existing condition only applied to temporal layers.

Change-Id: Icef20a59d0afc61d4e14dea01aff4786fa9e41ae
2015-11-18 14:31:37 -08:00
Paul Wilkins
85aea16f17 Merge "Changes to exhaustive motion search." 2015-11-18 11:10:13 +00:00
Scott LaVarnway
ed833048c2 VPX: x86 asm version of vpx_idct32x32_34_add()
Change-Id: Ic81f38998fb1b8d33f5a5d7424c2c41002786cef
2015-11-17 17:42:24 -08:00
James Zern
6e6dbbc67d configure: simplify x86 asm dependencies
--disable-XXX has the effect of disabling all extensions above it, e.g.,
--disable-ssse3 disables ssse3-avx2.

Change-Id: If02b44ca71ee12e4acb12010db8593a7989f2a9d
2015-11-17 16:15:57 -08:00
Zoe Liu
8a782c7eac Fixed a few sanity checks.
Change-Id: Ieec4a7be5945dc6de192e2d8292ab978baf47f53
(cherry picked from commit 2096296421)
2015-11-17 22:54:03 +00:00
paulwilkins
8ba98516fd Changes to best quality settings.
Small changes to the best quality default speed trade off.
Some speedup settings are worth while even for best quality as they
have only a very small impact on quality but a significant impact on
encode time.

These changes give as much as a further 50-60% increase in encode
speed for my test animations clip with minimal impact on quality.

For this sequence these changes improve the best quality encode  speed
to about the same level as good quality speed 0 in Q3 2015 whilst
retaining the large quality gain of over 1 db

For many natural videos though the quality difference from good 0
to best is much smaller.

Change-Id: I28b3840009d77e129817a78a7c41e29cb03e1132
2015-11-17 16:20:20 +00:00
jackychen
204cde580a Enable resize test(down&up) by changing the bitrate.
Change-Id: I5a4f1f7b9de20fbfc28cb743dcd29c0eeca736f8
2015-11-13 16:46:00 -08:00
Ralph Giles
2635573a7f Use Interlocked calls in win32 once() implementation.
This is simpler than the previous scheme, which tried to allocate
the CRITICAL_SECTION struct in a thread-safe manner before it
could use it to run the wrapped function in a thread-safe manner.

Change-Id: I172e5544e5f16403a3a0e5e2b9104b1292a0d786
2015-11-13 13:04:36 -08:00
Marco
988fd77c1f Reduce sampling time for noise estimate.
Change-Id: I46abd85e2187b8f4c2846416a23fab26d9b9f67d
2015-11-13 08:11:30 -08:00
Marco
006fd19246 Fix resize internal test.
Temporary fix to make sure it always passes.

Change-Id: I56a0529986ad7049b6090f871c14e9e06d573d5f
2015-11-13 06:22:27 -08:00
Marco Paniconi
5f5d185d01 Merge "VP9 noise estimation: add frame level motion metrics and adjust thresholds." 2015-11-13 14:09:19 +00:00
paulwilkins
0149fb3d6b Changes to exhaustive motion search.
This change alters the nature and use of exhaustive motion search.

Firstly any exhaustive search is preceded by a normal step search.
The exhaustive search is only carried out if the distortion resulting
from the step search is above a threshold value.

Secondly the simple +/- 64 exhaustive search is replaced by a
multi stage mesh based search where each stage has a range
and step/interval size. Subsequent stages use the best position from
the previous stage as the center of the search but use a reduced range
and interval size.

For example:
  stage 1: Range +/- 64 interval 4
  stage 2: Range +/- 32 interval 2
  stage 3: Range +/- 15 interval 1

This process, especially when it follows on from a normal step
search, has shown itself to be almost as effective as a full range
exhaustive search with step 1 but greatly lowers the computational
complexity such that it can be used in some cases for speeds 0-2.

This patch also removes a double exhaustive search for sub 8x8 blocks
which also contained  a bug (the two searches used different distortion
metrics).

For best quality in my test animation sequence this patch has almost
no impact on quality but improves encode speed by more than 5X.

Restricted use in good quality speeds 0-2 yields significant quality gains
on the animation test of 0.2 - 0.5 db with only a small impact on encode
speed. On most clips though the quality gain and speed impact are small.

Change-Id: Id22967a840e996e1db273f6ac4ff03f4f52d49aa
2015-11-13 10:16:31 +00:00
JackyChen
6fb3d6db99 VP9 noise estimation: add frame level motion metrics and adjust thresholds.
Change-Id: Ia1aba00603b32cee6835951d3d8f740937cf20f4
2015-11-12 23:41:42 -08:00
James Zern
7501728327 Merge "libs.mk, testdata: rm redundant test of LIBVPX_TEST_DATA" 2015-11-13 06:49:00 +00:00
James Zern
34159b72d9 Merge "Add AVX vectorized vp9_diamond_search_sad" 2015-11-13 06:29:20 +00:00
Marco
419da5c734 Adjust variance threshold for 16x16 split at low resolutions.
Change-Id: I635e37f81237e9703d7d9a11ed76a043f4ec6eb0
2015-11-12 17:58:31 -08:00
Marco Paniconi
866c9357c2 Revert "Update to noise estimation."
This reverts commit 6b79a1e3e0.

Change-Id: I5a4923ca8a6de842855ce0725e92567ccbed6fb7
2015-11-13 00:13:32 +00:00
Marco
6b79a1e3e0 Update to noise estimation.
Add frame level global check and adjust some parameters.

Change-Id: I42103394f2d329781195d94ce6cbb5b3383eea17
2015-11-12 09:18:35 -08:00
Marco Paniconi
1b63238b67 Merge "Non-rd partition: reduce variance threshold low resolutions." 2015-11-12 06:08:38 +00:00
Marco Paniconi
0941ff72a0 Merge "Adjust varianace threshold for high noise condition." 2015-11-12 06:06:51 +00:00
Marco
384fc5e381 Adjust motion threshold to limit cyclic refresh.
Change-Id: Icfca27a567eb8929c312c6315856ee130d982a04
2015-11-11 18:22:21 -08:00
Marco
1827764450 Adjust varianace threshold for high noise condition.
Change-Id: I91c722e480328ff95b8c57614d8176ccaceb2539
2015-11-11 18:06:21 -08:00
Marco Paniconi
4d38dbdfb5 Merge "vp9 denoiser: Add another noise level to denoising." 2015-11-11 20:40:29 +00:00
James Zern
9ecb99abf0 Merge "Revert "VPX: x86 asm version of vpx_idct32x32_34_add()"" 2015-11-11 20:39:12 +00:00
Marco
ff32369804 vp9 denoiser: Add another noise level to denoising.
Change-Id: Idc755ab54e4f78bb7d75bc97634c451804edad99
2015-11-11 11:21:26 -08:00
James Zern
0ccad4d649 Revert "VPX: x86 asm version of vpx_idct32x32_34_add()"
This reverts commit 9aeaa2016e.

This causes some test vectors to fail.

Change-Id: I3659a2068404ec5a0591fba5c88b1bec0c9059a4
2015-11-11 11:12:38 -08:00
James Zern
8f7bc45b5b Revert "VP9: Only zero counts when !frame_parallel_decoding_mode"
This reverts commit 380a5519cc.

This causes an assertion failure in debug_check_frame_counts() which
probably isn't valid with this change; leaving the investigation for
later now.

Change-Id: Ieda5ca811ed2fa50a0cc6935919a8d10dca996e0
2015-11-11 11:11:00 -08:00
Geza Lore
5eefd3ebfd Add AVX vectorized vp9_diamond_search_sad
This function now has an AVX intrinsics version which is about 80%
faster compared to the C implementation. This provides a 2-4% total
speed-up for encode, depending on encoding parameters. The function
utilizes 3 properties of the cost function lookup table, constructed
in 'cal_nmvjointsadcost' and 'cal_nmvsadcosts'.
For the joint cost:
  - mvjointsadcost[1] == mvjointsadcost[2] == mvjointsadcost[3]
For the component costs:
  - For all i: mvsadcost[0][i] == mvsadcost[1][i]
        (equal per component cost)
  - For all i: mvsadcost[0][i] == mvsadcost[0][-i]
        (Cost function is even)
These must hold, otherwise the AVX version of the function cannot be used.

Change-Id: I6c2791d43022822a9e6ab43cd124a773946d0bdc
2015-11-11 14:03:47 +00:00
James Zern
ec45003a8f libs.mk, testdata: rm redundant test of LIBVPX_TEST_DATA
the return value of enabled, which may be empty, is handled by the for
loop. this avoids making an unnecessarily long command line which may
fail in certain cases.

Change-Id: Ib88ecbbe2c0f6d7debb600b4caed4884497263b1
2015-11-10 17:54:51 -08:00
Marco
064a9eca49 Non-rd partition: reduce variance threshold low resolutions.
Change-Id: I06306905d187948a92f839357df5d21413823808
2015-11-10 15:42:58 -08:00
Marco Paniconi
79a194692f Merge "Add bias to zero/small motion for noisy source." 2015-11-10 23:10:31 +00:00
James Zern
e3efed7f4c Merge "convolve_copy_sse2: replace SSE w/SSE2 code" 2015-11-10 22:35:12 +00:00
Scott LaVarnway
f48321974b Merge "VPX: x86 asm version of vpx_idct32x32_34_add()" 2015-11-10 21:40:11 +00:00
Scott LaVarnway
9aeaa2016e VPX: x86 asm version of vpx_idct32x32_34_add()
Change-Id: I8a933c63b7fbf3c65e2c06dbdca9646cadd0b7cb
2015-11-10 11:54:56 -08:00
Marco
bd6bf25969 Add bias to zero/small motion for noisy source.
Change is only for real-time mode, speed >= 5, and non-screen content mode.
Add bias to zero/low motion for big blocks, if noise estimation
is enabled and noise level is above threshold.

Change-Id: I3a0a4608ede6aa535bda6eca528d20f8aba738e7
2015-11-10 11:23:40 -08:00
James Zern
40dab58941 convolve_copy_sse2: replace SSE w/SSE2 code
this should be neutral or slightly faster on modern (P4+) architectures

Change-Id: Iec4c080275941eb8c9e05a66a2daf0405d86a69b
2015-11-09 23:45:16 -08:00
JackyChen
19272d866b VP9 noise estimate: no noise estimate if frame size change.
Change-Id: I521f7b53c143d562a88fe7de330aa3f0ef09f414
2015-11-09 19:18:29 -08:00
Jacky Chen
394d6c122a Merge "VP9: add unit test for realtime external resize." 2015-11-10 03:05:30 +00:00
Johann
f937114402 Merge branch 'javanwhistlingduck'
Change-Id: Ib63fde31ae7b3f71e608830f7433113733b2a275
2015-11-09 17:00:37 -08:00
jackychen
55c8843791 VP9: add unit test for realtime external resize.
Change-Id: I9bfa80de73847d9be88b6ce9865d7bb5fafaaa57
2015-11-09 16:48:18 -08:00
Jacky Chen
7155f7ab78 Merge "VP9 dynamic resize: enable resize unit test(DownUp)." 2015-11-09 22:54:53 +00:00
James Zern
e1fbc886e1 Merge "VP9: Only zero counts when !frame_parallel_decoding_mode" 2015-11-09 22:23:34 +00:00