Commit Graph

331 Commits

Author SHA1 Message Date
John Koleszar
88f99f4ec2 Adds a test for the VP8E_SET_SCALEMODE control
Tests that the external interface to set the internal codec scaling
works as expected. Also updates the test to pull the height from
the decoded frame size rather than parsing the keyframe header,
in anticipation of allowing resolution changes on non-keyframes.

Change-Id: I3ed92117d8e5288fbbd1e7b618f2f233d0fe2c17
2013-02-08 12:20:30 -08:00
John Koleszar
29d47ac80e Restore SSSE3 subpixel filters in new convolve framework
This commit adds the 8 tap SSSE3 subpixel filters back into the code
underneath the convolve API. The C code is still called for 4x4
blocks, as well as compound prediction modes. This restores the
encode performance to be within about 8% of the baseline.

Change-Id: Ife0d81477075ae33c05b53c65003951efdc8b09c
2013-02-08 12:18:14 -08:00
John Koleszar
7a07eea13f Convert subpixel filters to use convolve framework
Update the code to call the new convolution functions to do subpixel
prediction rather than the existing functions. Remove the old C and
assembly code, since it is unused. This causes a 50% performance
reduction on the decoder, but that will be resolved when the asm for
the new functions is available.

There is no consensus for whether 6-tap or 2-tap predictors will be
supported in the final codec, so these filters are implemented in
terms of the 8-tap code, so that quality testing of these modes
can continue. Implementing the lower complexity algorithms is a
simple exercise, should it be necessary.

This code produces slightly better results in the EIGHTTAP_SMOOTH
case, since the filter is now applied in only one direction when
the subpel motion is only in one direction. Like the previous code,
the filtering is skipped entirely on full-pel MVs. This combination
seems to give the best quality gains, but this may be indicative of a
bug in the encoder's filter selection, since the encoder could
achieve the result of skipping the filtering on full-pel by selecting
one of the other filters. This should be revisited.

Quality gains on derf positive on almost all clips. The only clip
that seemed to be hurt at all datarates was football
(-0.115% PSNR average, -0.587% min). Overall averages 0.375% PSNR,
0.347% SSIM.

Change-Id: I7d469716091b1d89b4b08adde5863999319d69ff
2013-02-05 14:23:17 -08:00
John Koleszar
5ca6a3667f Add 8-tap generic convolver
This commit introduces a new convolution function which will be used to
replace the existing subpixel interpolation functions. It is much the
same as the existing functions, but allows for changing the filter
kernel on a per-pixel basis, and doesn't bake in knowledge of the
filter to be applied or the size of the resulting block into the
function name.

Replacing the existing subpel filters will come in a later commit.

Change-Id: Ic9a5615f2f456cb77f96741856fc650d6d78bb91
2013-02-05 14:19:28 -08:00
Deb Mukherjee
a53be60904 Merge "Adding a frame parallel decoding mode" into experimental 2013-01-30 12:03:45 -08:00
Ronald S. Bultje
b499c24c2f Merge "don't code the branch for the predicted seg_id if that flag is false." into experimental 2013-01-30 10:02:51 -08:00
Ronald S. Bultje
3a4b18bc67 don't code the branch for the predicted seg_id if that flag is false.
Change-Id: Icb6e21dc0c2d9918faa33c8bf70943660df7ad88
2013-01-30 09:30:46 -08:00
Ronald S. Bultje
4d53a95a34 Merge "Default superblock skip flag to 32x32 for skip-blocks." into experimental 2013-01-30 09:12:17 -08:00
Ronald S. Bultje
de6718a3b9 Merge "Reset skip flag in superblock RD loop." into experimental 2013-01-30 09:12:02 -08:00
Deb Mukherjee
d28750537e Merge "Further improvement on compound inter-intra expt" into experimental 2013-01-30 08:38:17 -08:00
Ronald S. Bultje
3febf9707d Default superblock skip flag to 32x32 for skip-blocks.
This is identical to the later decisions made in encode_superblock().
This commit doesn't actually change anything, but makes the mbmi state
more consistent between the RD loop and the final encode result.

Change-Id: I9e735afb7c5a52e5b61728cb88c67ef9b9bf59be
2013-01-29 21:46:31 -08:00
Ronald S. Bultje
b90996c51b Reset skip flag in superblock RD loop.
This is the superblock equivalent of commit 290b83a.

Change-Id: Ib3945dd9e992fa9ec1fdea5a11e17a3cc0e37637
2013-01-29 21:42:56 -08:00
Ronald S. Bultje
2f6fce3e5a Write only visible area (for better comparison with rec.yuv).
Change-Id: I32bf4ee532a15af78619cbcd8a193224029fab50
2013-01-29 16:58:52 -08:00
Ronald S. Bultje
5a9da2d906 Merge "Fix block pointer corruption in intra8x8 prediction with 4x4 transform." into experimental 2013-01-29 12:49:42 -08:00
Ronald S. Bultje
64401f838f Merge "Fix overread/write reported by valgrind if (mb_cols) & 3 != 0." into experimental 2013-01-29 12:49:22 -08:00
Paul Wilkins
d8e86af263 Merge "Remove eob_max_offset markers." into experimental 2013-01-29 09:29:45 -08:00
Paul Wilkins
5d1c62c639 Merge "Segment Skip Flag" into experimental 2013-01-29 09:29:26 -08:00
Scott LaVarnway
8b7eced6fe Merge "Added eob == 0 check to vp9_dequant_idct_add_32x32_c" into experimental 2013-01-29 09:19:58 -08:00
Ronald S. Bultje
ffc2e4f4af Fix block pointer corruption in intra8x8 prediction with 4x4 transform.
The RD loop would change the pointer after the first mode (DC) was tested,
leading to corrupt block objects being provided for the others. This
would essentially render the i8x8 predictor useless.

Change-Id: I16c5906ca64fb34878ac32ce59af8974e4582bb8
2013-01-29 09:18:47 -08:00
Paul Wilkins
93762ca9b2 Remove eob_max_offset markers.
Remove eob_max_offset markers and replace
with the generic skip_block flag to indicate
to the quantizer that all coeffs to be set to 0
and eob position set to 0;

Change-Id: Id477e8f8d4ec1a5562758904071013c24b76bfd7
2013-01-29 13:39:34 +00:00
Deb Mukherjee
3b04d467ac Further improvement on compound inter-intra expt
Adds a special combination mode specific to intra prediciton
mode D45.

Current results with the compound inter/intra experiment:
derf: 0.2%
yt: 0.55%
std-hd: 0.75%
hd: 0.74%

Change-Id: I8976bdf3b9b0b66ab8c5c628bbc62c14fc72ca86
2013-01-29 00:21:29 -08:00
Paul Wilkins
0ff9b033b0 Segment Skip Flag
First step in simplifying the segment mode and
segment EOB flags into a simpler segment skip
flag that implies 0,0 mv and EOB at position 0.

Change-Id: Ib750cac31a7a02dc21082580498efd9f7d8d72a5
2013-01-28 17:28:04 +00:00
Paul Wilkins
5f2429259f Merge "Simplify Zero bin and zero bin run code." into experimental 2013-01-28 08:35:36 -08:00
Paul Wilkins
8e2c03fbfd Simplify Zero bin and zero bin run code.
Simplification to eliminate a number of very large data
data structures. All zero run, zbin boosts for different
transform sizes are now limited to a maximum run length
of 15 before they max out the boost.

Some further work still needs be done to refactor, rationalize
and optimize the multiple quantizer functions.

The simplification coupled with tweaks to the 16 element array
now used for all transform sizes, has minimal effect on quality.

Change-Id: I6f3948b8ca0418b60d4db9030ff19026a34ed423
2013-01-28 13:21:10 +00:00
Ronald S. Bultje
9dc9f07fb8 Fix overread/write reported by valgrind if (mb_cols) & 3 != 0.
We'd backup and restore all cols for a 64x64 SB, but the array wouldn't
be big enough to hold all that data.

Change-Id: Ic68ea721bf07e0b2f3937bd16b0b734bcc743ce1
2013-01-25 17:18:08 -08:00
Deb Mukherjee
dfd89f2eab Adding a frame parallel decoding mode
Adds a flag to disable features that would inhibit frame parallel
decoding. This includes backward adaptation and MV sorting based
on search in ref frame buffer.

Also includes some minor clean-ups.

Change-Id: I434846717a47b7bcb244b37ea670c5cdf776f14d
2013-01-25 17:16:19 -08:00
Ronald S. Bultje
3ca5b35ce5 Merge "Remove "update_context" variable from VP9_COMP context." into experimental 2013-01-25 09:43:42 -08:00
Scott LaVarnway
9d4c26531b Added eob == 0 check to vp9_dequant_idct_add_32x32_c
Added a quick eob == 0 check.  Once the integer version of the dct32x32 is
complete, we can check for other eob cases.

For the 1080p clip used, the decoder performance improved by 4%.

Change-Id: I9390b6ed3c8be0c0c0a0c44c578d9a031d6e026e
2013-01-24 17:09:56 -08:00
Ronald S. Bultje
0a7b3953f0 Remove "update_context" variable from VP9_COMP context.
The variable is always zero.

Change-Id: Id5cdbecad543bca465a5b1d471badaec7e112c8d
2013-01-24 16:28:53 -08:00
Paul Wilkins
fcb4a25cd5 Mvref speedup
Quality / decode speed trade off changes.
Simpler insert method without sort. Quality impact small.

Change-Id: Id0c0941bc508d985405abd06a13ffe7489170b62
2013-01-24 17:26:37 +00:00
Scott LaVarnway
70019f6070 Merge "Intrinsic version of loopfilter now matches C code" into experimental 2013-01-24 08:45:22 -08:00
Deb Mukherjee
01cafaab1d Adds an error-resilient mode with test
Adds an error-resilient mode where frames can be continued
to be decoded even when there are errors (due to network losses)
on a prior frame. Specifically, backward updates are turned off
and probabilities of various symbols are reset to defaults at
the beginning of each frame. Further, the last frame's mvs are
not used for the mv reference list, and the sorting of the
initial list based on search on previous frames is turned off
as well.

Also adds a test where an arbitrary set of frames are skipped
from decoding to simulate errors. The test verifies (1) that if
the error frames are droppable - i.e. frame buffer updates have
been turned off - there are no mismatch errors for the remaining
frames after the error frames; and (2) if the error-frames are non
droppable, there are not only no decoding errors but the mismatch
PSNR between the decoder's version of the post-error frames and the
encoder's version is at least 20 dB.

Change-Id: Ie6e2bcd436b1e8643270356d3a930e8989ff52a5
2013-01-23 21:56:15 -08:00
Deb Mukherjee
ebb1157cde Merge "Modifies the comp inter-intra expt" into experimental 2013-01-23 09:43:07 -08:00
Scott LaVarnway
6a997400ff Intrinsic version of loopfilter now matches C code
Updated the instrinsic code to match Yaowu's latest loopfilter change.
(I584393906c4f5f948a581d6590959522572743bb)

The decoder performance improved by ~30% for the test clip used.

Change-Id: I026cfc75d5bcb7d8d58be6f0440ac9e126ef39d2
2013-01-23 09:31:40 -08:00
John Koleszar
bed59eb8de Merge changes Ia82cef79,I7324a75a,I7b66daad,I73344451,I91dc210f,I5945b5ce into experimental
* changes:
  Use alt-ref frame context for keyframes
  Preserve the previous golden frame on golden updates
  Generalize and increase frame coding contexts
  Start to anonymize reference frames
  Update encoder to use fb_idx_ref_cnt
  Remove buffer-to-buffer copy logic
2013-01-22 08:31:55 -08:00
John Koleszar
2f24ad9e85 Use alt-ref frame context for keyframes
This matches the behavior prior to generalizing the frame context
selection, and intuitively makes sense in that the first forward ref
is immediately after the keyframe, so it's quality is improved a bit
by using the keyframe's entropy context rather than the default.

Change-Id: Ia82cef79382b9d8cfafdc44ba0533d4dc3e44053
2013-01-18 14:40:39 -08:00
Yaowu Xu
b95ed6883a a minor change to a portion of loop filtering
The loop filtering used for MB edge or internal edge of a MB using 8x8
tranform was reading 5 pixel each side and writting 3 pixel each side.
With suggestion from Aki and Scott on hardware&software performance,
this commit changed to read 4 pixel each side and write 3 pixel each
side.

Change-Id: I584393906c4f5f948a581d6590959522572743bb
2013-01-18 10:44:13 -08:00
John Koleszar
26bd81b955 Preserve the previous golden frame on golden updates
This commit restores the quality lost when the buffer-to-buffer copy
logic was removed. Note that this is specific to the current use of
golden frames and will need rework when RTC functionality is added.

Change-Id: I7324a75acd96eafd9e0f9b8633d782e390d5dc21
2013-01-16 15:57:02 -08:00
John Koleszar
4b65837bc6 Generalize and increase frame coding contexts
Previously there were two frame coding contexts tracked, one for normal
frames and one for alt-ref frames. Generalize this by signalling the
context to use in the bitstream, rather than tieing it to the alt ref
refresh bit. Also increase the number of contexts available to 4, which
may be useful for temporal scalability.

Change-Id: I7b66daaddd55c535c20cd16713541fab182b1662
2013-01-16 14:07:27 -08:00
John Koleszar
da832a80e4 Start to anonymize reference frames
Remove lst_fb_idx, gld_fb_idx, alt_fb_idx, refresh_last_frame,
refresh_golden_frame, refresh_alt_ref_frame from common. Gold/Alt are
encode side conventions. From the decoder's perspective, we want to be
dealing with numbered references.

Updates to active_ref 2 signal mode context switches, vestigial from
refresh_alt_ref_frame. This needs some clean up to make sense with
increased numbers of reference frames, as well as reimplementing the
swapping of alt/golden which was previously done using the
buffer-to-buffer copy mechanism removed in an earlier commit.

Change-Id: I7334445158b7666f9295d2a2dd22aa03f4485f58
2013-01-16 14:06:23 -08:00
John Koleszar
394b0a6a30 Update encoder to use fb_idx_ref_cnt
Do reference counting the same way on the encoder as the decoder does,
rather than maintaining the 'flags' member of YV12_BUFFER_CONFIG.

Change-Id: I91dc210ffca081acaf9d5c09a06e7461b3c3139c
2013-01-15 17:36:39 -08:00
John Koleszar
b8e027989f Remove buffer-to-buffer copy logic
This is the first in a series of commits to add additional reference
frames to the codec. Each frame will be able to update any of the
available references, but copying between references is not
supported.

Change-Id: I5945b5ce6cc3582c495102b4e7eed4f08c44d5a1
2013-01-15 17:36:39 -08:00
Yaowu Xu
9bf73f46f9 fix a number issues that cause failures
During master jenkins verification proces

Change-Id: I3722b8753eaf39f99b45979ce407a8ea0bea0b89
2013-01-14 18:32:32 -08:00
Deb Mukherjee
b34838bea5 Modifies the comp inter-intra expt
Uses a single 1D table to implement the weighting of the predictors
for the compound inter-intra experiment.

Change-Id: I204ffbe4f9fc79d5d43b6c724ad253d800461012
2013-01-14 17:32:26 -08:00
John Koleszar
24bc1a7189 Use INT64_MAX instead of LLONG_MAX
These variables have the type int64_t, not long long. long long could
be a larger type than 64 bits. Emulate INT64_MAX for older versions of
MSVC, and remove the unreferenced vpx_ports/vpxtypes.h

Change-Id: Ideaca71838fcd3849d816d5ab17aa347c97d03b0
2013-01-14 15:57:21 -08:00
Ronald S. Bultje
c9071601a2 Remove compound intra-intra experiment.
This experiment gives little gains and adds relatively much code
complexity (and it hinders other experiments), so let's get rid of
it.

Change-Id: Id25e79a137a1b8a01138aa27a1fa0ba4a2df274a
2013-01-14 15:47:25 -08:00
Yaowu Xu
741fbe9656 Merge experiment "subpelrefmv"
Change-Id: Iac7f3d108863552b850c92c727e00c95571c9e96
2013-01-14 15:18:47 -08:00
Yaowu Xu
f7dab60096 Merge experiment "widerlpf"
Change-Id: I0c94475075e66e13cfe4c20fab7db6474441ae86
2013-01-14 15:17:35 -08:00
Yaowu Xu
d8c5bceee5 Merge "changed UV plane loop filtering for TX_8X8" into experimental 2013-01-14 14:47:31 -08:00
Yaowu Xu
8750414368 Merge "change to evaluate reference mvs using above only" into experimental 2013-01-14 14:40:38 -08:00