Commit Graph

3043 Commits

Author SHA1 Message Date
James Zern
971c5a16a9 vp8/error_concealment: remove shift of negative value
fixes:
shifting a negative signed value is undefined [-Wshift-negative-value]

Change-Id: I3a55f2dac7c51c0e264d40081ffce98e2abacb89
2016-05-19 19:19:19 -07:00
Yaowu Xu
a45596cff7 Merge "Added a measure of rc drift." 2016-05-11 18:02:00 +00:00
paulwilkins
45df87ca57 Added a measure of rc drift.
Added actual and absolute rate miss values to the opsnr.stt
stats output line.

Changes to the borg graphing may be needed before merge.

Change-Id: I1e9d548ce445d29002f0c59ebfd3957a6f15e702
2016-05-11 15:15:07 +01:00
Johann Koenig
0741629c88 Merge "Alignment is required for sad_array8" 2016-05-09 21:01:45 +00:00
Johann
f68f9eefdf Alignment is required for sad_array8
For at least some of the implementations of sdx8f, such as
vpx_sad4x4x8_sse4_1, aligned moves are used to move the results into the
array.

Change-Id: I83df5a8e657b44e906d0d8b0bc154f1e5660f7f9
2016-05-09 18:39:24 +00:00
Johann
ce11055d57 Remove sixtap/bilinear 4x4 neon implementations
These implementations rely on casting the pointers to load the data.
Clang implemented optimizations which automatically add alignment hints
to such loads. The 4x4 filters do not guarantee the necessary alignment
so the resulting assembly is broken.
https://llvm.org/bugs/show_bug.cgi?id=24421

BUG=webm:817
BUG=webm:892

Change-Id: I608885299f1f86ff83653b65e0e40d0ae87fb3fe
2016-05-06 17:20:15 -07:00
James Bankoski
e755a283dd Merge "Move vpx_add_plane from codec to vpx_dsp and dedup." 2016-05-03 14:11:57 +00:00
Jim Bankoski
fce3cee8dd Move vpx_add_plane from codec to vpx_dsp and dedup.
Change-Id: I12218d8331c0558c0587a66321e3ca46da7e5cc7
2016-05-02 12:17:39 -07:00
Alex Converse
d3fe3b2abb Avoid an unsigned overflow in invert_quant
Change-Id: I16a570b2af66b6580d1cd6f8345a25f079009bf4
2016-04-27 15:07:22 -07:00
Marco
a136c1769d vp8: Adjust consec_zeromv thresholds for skin detection.
Change-Id: Iab5aed7bf86538352232e208bce58c3528cc9a4e
2016-04-26 16:03:44 -07:00
Marco
d33be6caa9 vp8: Update on sum_diff_threshold.
Reset to previous values.

Change-Id: Ia49bafc1d1ec5f657819ffba04d11fd701f315e8
2016-04-19 15:59:48 -07:00
Marco
6877acb67e vp8-denoiser: Avoid doing the mcomp if we don't denoise.
Avoid doing the mcomp in denoiser if we don't denoise the
block (because of motion/SSE/skin threshold, etc).
This can reduce encoding time (with denoiser enabled) by ~1.5-2%.

Change-Id: Ia699b68dfd37b89cdf3a82b8aa40e8c8f98a3d4f
2016-04-04 13:25:38 -07:00
Marco
bc6c199785 vp8 denoiser: Some adjustments to usage of skin and motion.
Switch to use new skin model.

And fix condition for denoising skin block.
Previous condition did not denoise skin blocks if the selected
mode was non-zero motion in current frame. Modify condition to
also force no denoising if that mode was not selected as zero motion
now and for at least "x" past frames in a row (x = 2).

Change-Id: I00753e3fe45b9a308a7ef43c58f11868e3bfc6b0
2016-04-01 11:36:45 -07:00
James Zern
8d8ee1f644 Merge "vp8_peek_si_internal: quiet static analysis warning" 2016-03-30 05:38:59 +00:00
James Zern
1bf7a0fb29 vp8_peek_si_internal: quiet static analysis warning
the vpx_decoder layer guarantees that when called directly this won't
receive NULL data and the reuse via decode() is protected by a NULL data
check and 0 size check (NULL data and non-zero data size is protected by
the vpx_decoder layer).

Change-Id: I7437fb5ca4e4aa431963d55b909d4d920f339be3
2016-03-25 10:00:30 -07:00
Marco
5f90713b2b vp8-denoiser: Use the same skin detection for model=1 as in vp9.
Keep setting for model = 0 for now in vp8.

Change-Id: I79c5fa24d5d16b14651f44db9526aa01dbd70ec9
2016-03-24 15:44:40 -07:00
Yaowu Xu
a624692776 Merge "Simplify the loopfilter synchronization logic in VP8 encoder" 2016-03-22 23:45:28 +00:00
Yunqing Wang
b198bcd528 Simplify the loopfilter synchronization logic in VP8 encoder
This patch was to fix a reported Hangouts deadlock/freezing issue
in VP8 encoder(issue 27232610). The original encoder loopfilter
synchronization happened in the following frame, which was prone
to causing problems in some complex use cases. This patch simplified
the synchronization logic.

More testing needs to be done.

Change-Id: I38fd3f35d11f98fae1e44546aa5e4c6d6e19c4be
2016-03-22 14:13:18 -07:00
Marco
a3562b60d5 vp8-denoiser: Update on the sum_diff threshold.
Change-Id: I0d459c7ba358da287aff1c706279603d6d4d3c48
2016-03-18 08:39:42 -07:00
Marco Paniconi
9ef41cf577 Merge "vp8-denoiser: Update some denoiser thresholds." 2016-02-27 00:20:53 +00:00
James Zern
02fe3ae907 vp8_dx_iface: add missing alloc checks
Change-Id: Id9f4022b0cb4b5d0b3dd8759fd491da4e2ba5cb1
2016-02-17 18:04:23 -08:00
James Zern
61b112b67b vp8/onyx_if: add missing alloc checks
Change-Id: I9b0aa340518f45e16fa9754afd87347aabf968d7
2016-02-17 18:04:14 -08:00
James Zern
a3d23877f6 vp8/denoising: add missing alloc check
Change-Id: I51ede902cd9d7bafa41f7caa3f9adf77f9df5903
2016-02-17 16:33:56 -08:00
Marco
3c0772977b vp8-denoiser: Update some denoiser thresholds.
Change-Id: I67090d72c0fefd3105ac380415249599e053d3bd
2016-02-17 10:38:35 -08:00
James Zern
ba7ebbb35c vp8: fix build with mingw+pthreads
Change-Id: Icc34a00759c95b7b8ac356cdcc4adae848b61431
2016-02-05 21:08:45 -08:00
James Zern
8faccb709a Merge changes If13946e4,I61a1814d,I2ca9aa3c,I44d91eaa
* changes:
  intrapred: protect functions w/CONFIG check
  vp9_noise_estimate: protect copy_frame w/CONFIG check
  vp8_cx_iface: delete 3 unused functions
  vp8: mark intra_prediction_down_copy inline
2016-01-30 00:17:16 +00:00
James Zern
4f780e94a1 vp9/10: fix encoder crash on flush
the lookahead buffer allocation is deferred to receipt of the first
frame to allow profile changes. if the encoder was flushed before
supplying any frames the encoder would crash trying to dereference the
NULL buffer. vp8 is unaffected.

fixes mozilla bug:
https://bugzilla.mozilla.org/show_bug.cgi?id=1237848

Change-Id: Icee4b64de760476eee0d33b568f0a1010335ff13
2016-01-28 12:53:41 -08:00
JackyChen
d1e3d0467c VPX skin map improvement.
Use multiple clusters instead of one and decrease
the distance thresholds.

Add a define to switch between models.
Default is set to existing (1 cluster) model.

Change-Id: I802cd9bb565437ae8983ef39453939f5d5073bb1
2016-01-28 10:38:14 -08:00
James Zern
42c2c6bf33 vp8_cx_iface: delete 3 unused functions
vp8e_update_entropy, vp8e_update_reference, vp8e_use_reference have been
unused since:
a046f56 vp8cx: remove deprecated reference/entropy controls

Change-Id: I2ca9aa3c3f1a209a534a1492432b16852e3d8629
2016-01-26 20:08:37 -08:00
James Zern
abd62063ee vp8: mark intra_prediction_down_copy inline
avoids -Wunused-function warnings when INLINE is set

Change-Id: I44d91eaa7efba7bc2427501fb9f63a93f32aaa7f
2016-01-26 20:07:42 -08:00
Yunqing Wang
e6f05e78fe Fix a clang/win build error
Made the definition of THREAD_FUNCTION consistent.

Change-Id: I1ac099484e201e359298ed16de0b81ec781075ce
2016-01-26 10:10:07 -08:00
Marco
4800e179fe vp8-denoiser: Fix threshold for skin map.
Make it consistent with the comment/intended behavior,
that is, only denoise if current block is zero_mv.

Change-Id: I3909761e802e80089752a493ab3646dc32698ded
2016-01-20 13:48:46 -08:00
Yaowu Xu
cfe9758c4e Remove duplicate definitions
This fixes the build errors with msvc.

Change-Id: Ie2716e4c15a1bacfb00a8d41ec3283d718af88fc
2016-01-20 08:56:41 -08:00
Yunqing Wang
ff0107f60d Amend and improve VP8 multithreading implementation
There are flaws in current implementation of VP8 multithreading encoder
and decoder as reported in the following issue:
https://code.google.com/p/chromium/issues/detail?id=158922

Although the data race warnings are harmless, and wouldn't cause real
problems while encoding and decoding videos, it is better to fix the
warnings so that VP8 code could pass the TSan test.

To synchronize the thread-shared data access and maintain the speed
(i.e. decoding speed), use multiple mutexes based on mb_rows to reduce
the number of synchronizations needed, make the reads and writes of
the shared data protected, and reduce the number of mb_col writes by
nsync times.

The decoder speed tests showed < 3% speed loss while using 2 ~ 4
threads.

Change-Id: Ie296defffcd86a693188b668270d811964227882
2016-01-08 11:59:49 -08:00
James Zern
44fe73ec37 Merge "vp8: fix loop filter level clamping" 2015-12-09 01:38:09 +00:00
James Zern
2e693eb80e vp8: fix loop filter level clamping
the loop filter level is transmitted as 6-bits + sign so needs to be clamped in
the delta + absolute case.

BUG=https://bugzilla.mozilla.org/show_bug.cgi?id=1224363

Change-Id: Icbdca4fdbf043466429bd5c9d59dbe913bf153bc
2015-12-03 16:18:48 -08:00
James Zern
ff3674a15e vp8: fix quantizer clamping
the quantizer is transmitted as 7-bits + sign so needs to be clamped in
the delta + absolute case.

BUG=https://bugzilla.mozilla.org/show_bug.cgi?id=1224361

Change-Id: I9115f5d1d5cf7e0a1d149d79486d9d17de9b9639
2015-12-03 16:16:28 -08:00
Ronald S. Bultje
92c4d8149a Merge "vp10: add extended-intra prediction edges experiment." 2015-10-20 15:57:05 +00:00
James Zern
a046f56491 vp8cx: remove deprecated reference/entropy controls
VP8E_UPD_ENTROPY, VP8E_UPD_REFERENCE and VP8E_USE_REFERENCE have been
deprecated since the initial public release

Change-Id: Ied16b441eec13434d85f1ab115d49ccaf5f2f7b0
2015-10-16 17:02:36 -07:00
Ronald S. Bultje
c7dc1d78bf vp10: add extended-intra prediction edges experiment.
This experiment allows using full above/right edges for all transform
sizes whenever available (for d45/d63), and adds bottom/left edges for
d207.

See issue 1043.

Change-Id: I5cf7f345e783e8539bb6b6d2c9972fb1d6d0a78b
2015-10-16 19:30:39 -04:00
Ronald S. Bultje
b1d85bf60f vp8: align left pixel array by 16 bytes.
The x86 simd expects this. Identical alignment can be found in vp9
and vp10 also. Fixes crashes on 32bit x86 systems.

Change-Id: I229c88d8f696acbef5337c8fa9503528df4e1c40
2015-10-01 10:11:54 -04:00
Ronald S. Bultje
c26a9ecaa2 vp8: change build_intra4x4_predictors() to use vpx_dsp.
I've added a few new functions (d45e, d63e, he, ve) to cover the
filtered h/v 4x4 predictors that are vp8-specific, the "correct"
d45 with the correctly filtered bottom-right pixel (as opposed to
the unfiltered version in vp9), and the "broken" d63 with weirdly
filtered bottom-right pixels (which is correctly filtered in vp9).

There may be a minor performance impact on all systems because we
have to do an extra copy of the Above pixel array to incorporate
the topleft pixel in the same array (thus fitting the vpx_dsp API).
In addition, armv6 will have a more serious performance impact b/c
I removed the armv6/vp8-specific assembly. I'm not sure anyone
cares...

Change-Id: I7f9e5ebee11d8e21aca2cd517a69eefc181b2e86
2015-09-30 18:45:49 -04:00
Ronald S. Bultje
7cdcfee82c vp8: change build_intra_predictors_mbuv_s to use vpx_dsp.
Change-Id: I936c2430c3c5b1e0ab5dec0a20110525e925b5e4
2015-09-30 18:45:46 -04:00
Ronald S. Bultje
54d48955f6 vp8: change build_intra_predictors_mby_s to use vpx_dsp.
Change-Id: I2000820e0c04de2c975d370a0cf7145330289bb2
2015-09-30 18:45:40 -04:00
Marco Paniconi
7d28d12ef3 Merge "VP8: Update rate correction factor for drop_overshoot feature." 2015-09-28 19:53:10 +00:00
Marco
bd3088fd56 VP8: Update rate correction factor for drop_overshoot feature.
Update rate correction factor when we drop the frame due to overshoot.
Only affects when the drop_overshoot feature is on: screen_content_mode = 2.

Change-Id: I67e24de979b4c74744151d2ceb3cd75fec2a1e7a
2015-09-28 12:11:33 -07:00
Ronald S. Bultje
812945a8f1 vp9/10: improve support for render_width/height.
In the decoder, map this to the output variable vpx_image_t.r_w/h.
This is intended as an improved version of VP9D_GET_DISPLAY_SIZE,
which doesn't work with parallel frame decoding. In the encoder,
map this to a codec control func (VP9E_SET_RENDER_SIZE) that takes
a w/h pair argument in a int[2] (identical to VP9D_GET_DISPLAY_SIZE).

Also add render_size to the encoder_param_get_to_decoder unit test.

See issue 1030.

Change-Id: I12124c13602d832bf4c44090db08c1009c94c7e8
2015-09-25 22:18:22 -04:00
Marco
ece841f03f VP8: Adjust rate correction factor for drop due to overshoot.
Change-Id: Id70ca2e18a46247720eb631ae13a8430bd8b0954
2015-09-24 16:40:29 -07:00
Marco
3140e90175 vp8: Small adjustment to cyclic_refresh max_mbs_perframe.
For 3 temporal layers, reduce somewhat the
cyclic_refresh_mode_max_mbs_perframe parameter, from 20% to ~14%.
Small increase in PSNR/SSIM metrics.

Change-Id: Ia216fa5474048f1ef7fe3db88cd60dfef2a1bf8a
2015-09-09 15:34:58 -07:00
Debargha Mukherjee
1c8567ff09 Remove some trailing whitespaces
Change-Id: Icf06d35ca347713253d1eba341a894b51efa81a9
2015-09-08 01:31:04 -07:00