Commit Graph

4195 Commits

Author SHA1 Message Date
Scott LaVarnway
f77140b7b4 Merge "Removed shadow warnings : loopfilter*.c" 2013-03-14 10:55:58 -07:00
Yaowu Xu
f4d2ad6915 Remove leftover reference to 2nd order dc/ac quant
Change-Id: Ib8dacf1d2797743569771b8f699e40e1aeb085cb
2013-03-14 10:46:15 -07:00
Scott LaVarnway
96e41cb461 Removed shadow warnings : bitstream.c encodeframe.c onyx_if.c
ratectrl.c and quantize.c

Adding -Wshadow to CFLAGS generated a bunch of warnings.  This patch
removes these warnings.

Change-Id: I8c8faa9fde57c1c49662d332a90bc8d9a0f4a2ce
2013-03-14 09:49:38 -07:00
Scott LaVarnway
fc6a190af4 Removed shadow warnings : reconintra.c
Adding -Wshadow to CFLAGS generated a bunch of warnings.  This patch
removes these warnings.

Change-Id: I9d52c4a44351607d7d20d52e2a1bffe2a067891a
2013-03-14 08:28:34 -07:00
Scott LaVarnway
60bbd43995 Removed shadow warnings : loopfilter*.c
Adding -Wshadow to CFLAGS generated a bunch of warnings.  This commit
is based on work already done by jzern.

Change-Id: Iefc08a7ab601c4d1b507f039577433bfb1c6cc9d
2013-03-14 08:23:26 -07:00
John Koleszar
9b7be88883 Fix pulsing issue with scaling
Updates the YV12_BUFFER_CONFIG structure to be crop-aware. The
exiting width/height parameters are left unchanged, storing the
width and height algined to a 16 byte boundary. The cropped
dimensions are added as new fields.

This fixes a nasty visual pulse when switching between scaled and
unscaled frame dimensions due to a mismatch between the scaling
ratio and the 16-byte aligned sizes.

Change-Id: Id4a3f6aea6b9b9ae38bdfa1b87b7eb2cfcdd57b6
2013-03-13 19:10:10 -07:00
John Koleszar
b3c350a1a9 Add VP9_GET_REFERENCE control
This is like VP8_COPY_REFERENCE, but returns a pointer to the reference
frame rather than a copy of it. This is useful when the application
doesn't know what the size of the reference is, as is the case when
scaling is in effect.

Change-Id: I63667109f65510364d0e397ebe56217140772085
2013-03-13 19:08:06 -07:00
Jingning Han
76c12ab9c9 Support +/-2048 motion vector coding
Enable entropy coding of motion vectors up to +/-2048. Also
extend the motion search range accordingly.

Change-Id: Iac2bb015e8934521cef83a19edbe967d9f097436
2013-03-13 14:08:27 -07:00
Yaowu Xu
88862c0454 put refmvselection under experiment
and turn the experiment off by default.

Change-Id: If9e684aa6cc49eacd39f36645a110a447e38d2de
2013-03-13 10:40:31 -07:00
Yaowu Xu
005552639b removed reference to "LLM" and "x8"
The commit changed the name of files and function to remove obselete
reference to LLM and x8.

Change-Id: I973b20fc1a55149ed68b5408b3874768e6f88516
2013-03-13 08:35:46 -07:00
John Koleszar
bd9cd9a185 fix superframe index marker masks
The superframe index marker byte carries data in the lower 5 bits. Only the
upper 3 should be used as part of the mask to detect it. By masking with
0xf0, the previous code was incorrect for frames over 65k bytes.

Change-Id: I6248889f5af227457f359a56b2348ef6db87a3b4
2013-03-12 19:04:32 -07:00
John Koleszar
c11313e31e fix superframe index with lagged encoding
If a superframe (ARF) is generated while flushing the lagged frames
at the end of the clip, the buffer pointer wasn't being properly
updated to account for the size of the index, causing the next
frame to overwrite the index on the previous frame.

Change-Id: Ib158cc8e4183d663bdfb9ba002dd4c98916abdc9
2013-03-12 16:33:38 -07:00
Paul Wilkins
a2c6f6e945 Merge "disambiguate superframe index in vp9_stop_encode()" into experimental 2013-03-12 16:00:30 -07:00
John Koleszar
872fc3ded8 disambiguate superframe index in vp9_stop_encode()
If the bool-coded partition naturally ends in a byte that matches the
superframe index marker, it could lead to a parse error. This commit
ensures that if such a marker is seen, it is padded out with an
additional zero byte to disambiguate it.

Change-Id: Id977de05745b6fa9ef08afb71e210a2a3ecca02e
2013-03-12 14:30:23 -07:00
Paul Wilkins
21ba242bfd Merge "Change buffer update rules on ARF overlay." into experimental 2013-03-12 11:07:20 -07:00
Ronald S. Bultje
8fc3ab7c62 Merge "Fix typo in comment for number of extra bits for cat6 tokens." into experimental 2013-03-12 10:45:12 -07:00
John Koleszar
5c1e57c3ce Merge "fix an assumption about uv_stride" into experimental 2013-03-12 10:44:31 -07:00
Ronald S. Bultje
516f7ac04e Fix typo in comment for number of extra bits for cat6 tokens.
Change-Id: I07ddf3be8bc5d6c2eb561d4241879777c315b183
2013-03-12 10:25:43 -07:00
Paul Wilkins
49d1425d19 Merge "Changes to maximum gf/arf interval." into experimental 2013-03-12 09:59:43 -07:00
Paul Wilkins
8be3056c45 Change buffer update rules on ARF overlay.
When coding the frame that corresponds to the midpoint frame
defining an ARF, do not update the last reference frame buffer.
Previously this buffer was updated meaning that when coding the next
ARF all the reference buffers were the same (or nearly so).
Turning the update off means that the frame before is still available
as an alternative predictor and for use in compound prediction.

Also fixed inconsistency in test for mismatch (patch from JK).

Net average gains (derf 0.049, yt 0.163, yt-hd 0.207, std-hd 0.286)

Change-Id: Ifee21da21ccbb1648ac2eafe890d3ce60562c7bc
2013-03-12 16:57:39 +00:00
John Koleszar
045c53f51e fix an assumption about uv_stride
Use the uv_stride from the framebuffer rather than deriving it from the
y_stride.

Change-Id: I94581cb741539d094ff062b3d008235556903b8c
2013-03-12 09:22:44 -07:00
Dmitry Kovalev
ff553ba113 Merge "Code cleanup." into experimental 2013-03-11 17:22:21 -07:00
Dmitry Kovalev
2891d70b23 Code cleanup.
Removing redundant code, introducing new functions for better
decomposition, adding 'clamp' function to vp9_common.h.

Change-Id: Ic3b8ca13bbc38f60f0c9c43910b5802005e31aaf
2013-03-11 17:02:27 -07:00
John Koleszar
a07eb47b25 Merge "Reinitialize motion search tables on frame size change" into experimental 2013-03-11 16:32:03 -07:00
John Koleszar
0a18228274 Merge "Add 'superframe' index" into experimental 2013-03-11 16:31:48 -07:00
John Koleszar
e6d5ad6ea7 Merge "Update ResizeInternalTest threshold" into experimental 2013-03-11 16:18:36 -07:00
John Koleszar
2bf563c335 vpxenc: improve progress indicators with --skip
Account for skipped input frames when calculating frame rates, ETA.

Fixes https://code.google.com/p/webm/issues/detail?id=556

Change-Id: I9c8b51e02e9ff0ab2cf6f16fc9382fc7f6c77b80
2013-03-11 15:03:00 -07:00
John Koleszar
83f2a112ac vpxdec: fix use of uninitialized do_scale argument
This fixes a potential crash with VP8 streams that have an alt-ref on
the first frame, as well as potentially scaling the output in cases
where that wasn't desired.

Change-Id: I1fd74b5ab43329fbbffecb004dfd44de34c4dc22
2013-03-11 12:30:29 -07:00
Paul Wilkins
08d2c3829a Changes to maximum gf/arf interval.
This patch puts in an adjustment to the maximum gf/arf
interval based on the active q range.  It sets a fixed
baseline maximum of 16 but can drop this down to 12 at
lower q. This required some re-ordering in the first pass
code to insure we have a Q range estimate before defining
the first gf sequence.

The main gains seed are int he STD hd set on 50fps clips
where previously the interval could rise as high as 25.
On the std hd clip the gains are around 2.8% with limit set
to 300 frames.

When combined with the one shot rate control flags we get
combined of:

derf 1.55% (limit300), yt 7.25%, hd 5.17% std-hd 5.84% (limit300)

Change-Id: Ib380d51354511f2ff0f171a8df4e74291c0421f9
2013-03-11 19:25:10 +00:00
John Koleszar
9b4095c537 Fix vp9_tree_probs_from_distribution with CONFIG_CODE_NONZEROCOUNT
The automatic merge result was incomplete.

Change-Id: I8976318bfc346d867660a013a302c80edb25fc29
2013-03-11 11:03:36 -07:00
John Koleszar
52fc4f8a78 Merge "Simplify vp9_adapt_nmv_probs" into experimental 2013-03-11 09:57:53 -07:00
John Koleszar
ee4649ded2 Simplify vp9_adapt_nmv_probs
Remove the temporary branch count arrays and build the adapted probabilities
while walking the tree. Gives an additional 1.5% or so on CIF.

Change-Id: I875d61e5e0ec778e5d2f7f9d0837b989a91cf3a3
2013-03-11 09:44:22 -07:00
Deb Mukherjee
fad43d4249 Merge "Minor optimization in mv entropy adaptation" into experimental 2013-03-11 09:43:54 -07:00
John Koleszar
e6257342b1 Merge "Optimize vp9_tree_probs_from_distribution" into experimental 2013-03-11 09:32:11 -07:00
Deb Mukherjee
f74c55eb03 Minor optimization in mv entropy adaptation
Adds a check to exit from the increment_nmv_count function when the
increment is 0.

Change-Id: I99c1e342d351f7800e23590f9c2419881bf1d708
2013-03-11 08:49:14 -07:00
John Koleszar
bd84685f78 Optimize vp9_tree_probs_from_distribution
The previous implementation visited each node in the tree multiple times
because it used each symbol's encoding to revisit the branches taken and
increment its count. Instead, we can traverse the tree depth first and
calculate the probabilities and branch counts as we walk back up. The
complexity goes from somewhere between O(nlogn) and O(n^2) (depending on
how balanced the tree is) to O(n).

Only tested one clip (256kbps, CIF), saw 13% decoding perf improvement.

Note that this optimization should port trivially to VP8 as well. In VP8,
the decoder doesn't use this function, but it does routinely show up
on the profile for realtime encoding.

Change-Id: I4f2848e4f41dc9a7694f73f3e75034bce08d1b12
2013-03-10 13:39:30 -07:00
Deb Mukherjee
a28139c849 Continued experiment with nonzero count
Adds probability updates for extra bits for the nzcs, code for
getting nzc stats, plus some minor cleanups and fixes.

Change-Id: If2814e7f04fb52f5025ad9f400f3e6c50a00b543
2013-03-08 16:37:08 -08:00
Ronald S. Bultje
0643c3f133 Merge "Add support for tx_select in i8x8 encoding in keyframes." into experimental 2013-03-08 16:25:27 -08:00
Yunqing Wang
cb7acbc0e1 Merge "Add vp9_idct4_1d_sse2" into experimental 2013-03-08 15:14:02 -08:00
Yunqing Wang
11ca81f8b6 Add vp9_idct4_1d_sse2
Added SSE2 idct4_1d which is called by vp9_short_iht4x4. Also,
modified the parameter type passed to vp9_short_iht functions to
make it work with rtcd prototype.

Change-Id: I81ba7cb4db6738f1923383b52a06deb760923ffe
2013-03-08 15:04:22 -08:00
Dmitry Kovalev
3edbc77ae3 Merge "Consistent usage of ROUND_POWER_OF_TWO macro." into experimental 2013-03-08 11:35:22 -08:00
James Zern
1e8b3da75e Merge "vp8: clamp probability values" 2013-03-08 11:20:49 -08:00
Yunqing Wang
2e0553227e Merge "Optimize add_constant_residual function" into experimental 2013-03-08 10:18:52 -08:00
Jingning Han
2a5278bdbd Extend diff MV limit from +/-256 to +/-1024
Increase the motion search range by 4x. Change MV_CLASS tree of the
entropy coding to allow two additional mv classes to cover the
extended motion vector limit. The codec determines the effective
motion search range conditioned on the actual frame dimension.

It provides coding gains:

stdhd 0.39%
yt    0.56%
hd    0.47%

Major coding performance gains are packed in several sequences with
intense motion activities, e.g., ped_1080p gains 7% at high bit-rates,
and on average 3%.

TODO: Need to further tune the rate control and motion search units.

Change-Id: Ib842540a6796fbee5a797809433ef6a477c6d78d
2013-03-08 10:04:36 -08:00
Ronald S. Bultje
b41dee8428 Add support for tx_select in i8x8 encoding in keyframes.
Also enable tx_select for keyframes.

Change-Id: Iadb1231d9fa7af0c8dce3d9b41830b93a302479e
2013-03-08 09:28:46 -08:00
Yunqing Wang
f240782650 Optimize add_constant_residual function
Optimized adding constant diff to predictor, which gave about
2% decoder performance gain.

Change-Id: I47db20c31428e8c4a8f16214a85cbe386a6e9303
2013-03-07 15:49:07 -08:00
Yunqing Wang
6fdd4d26de Merge "Allocate 16-byte aligned diff buffer" into experimental 2013-03-07 15:40:38 -08:00
Yunqing Wang
b339aea675 Allocate 16-byte aligned diff buffer
This was done based on John's suggestion.

Change-Id: I62516a513c31fe3dbea0d6cd063df79d9e819ec8
2013-03-07 15:29:27 -08:00
Dmitry Kovalev
3603dfb62c Consistent usage of ROUND_POWER_OF_TWO macro.
Change-Id: I44660975e9985310d8c654c158ee7a61291b5a08
2013-03-07 12:24:35 -08:00
Ronald S. Bultje
89e4ce20d0 Update ADST selection if tx_size < block_size.
Change-Id: Ic9b336486774c95ffbb92adcb110cc0fc2a83cc5
2013-03-07 11:19:15 -08:00