* each with their own decoder instances.
* Refactor the incremental buffer-update code a lot.
* remove br_offset_ for VP8LDecoder along the way
* make VP8GetHeaders() be used only for VP8, not VP8L bitstream
* remove VP8LInitDecoder()
* rename VP8LBitReaderResize() to VP8LBitReaderSetBuffer()
(cherry picked from commit 5529a2e6d47212a721ca4ab003215f97bd88ebb4)
Change-Id: I58f0b8abe1ef31c8b0e1a6175d2d86b863793ead
import changes from experimental 5529a2e^
and enable build in autoconf and makefile.unix; windows will be treated
separately.
Change-Id: Ie2e177a99db63190b4cd647b3edee3b4e13719e9
Pulled from the parent of the current version (5529a2e^).
The history of this and related files is a bit entangled so rather
trying to split the changes and introduce some noise in master's history
we'll start with a fresh snapshot.
The file progression is still available in the experimental branch.
Change-Id: I6dae97fc381cd6c1d1640c4c565b2084a41ec955
Pulled from the current HEAD (218c32e).
The history of this and related files is a bit entangled so rather
trying to split the changes and introduce some noise in master's history
we'll start with a fresh snapshot.
The file progression is still available in the experimental branch.
Change-Id: Ie57be21bf50ad83808c72aeb5fc706d9954d01d8
Pulled from the current HEAD (218c32e).
The history of this and related files is a bit entangled so rather
trying to split the changes and introduce some noise in master's history
we'll start with a fresh snapshot.
The file progression is still available in the experimental branch.
Change-Id: Id879be453a94d9f44ec8d47747823ca7297ae008
by packing the symbol map more efficiently.
This is mainly useful in making it harder to generate invalid bitstream:
before this change, one could code the same symbol twice. Now, it's
impossible, since we code the position using empty symbol slots, instead
of total position.
* Fix the HasOnlyLeftChild() naming while at it.
Change-Id: I63c56c80a4f04a86ac83eded1e3306329815b6c9
_byteswap_ulong is defined in stdlib.h, release builds seem to pull it
in through a different path.
Change-Id: I510d2624150f89a4a77734bf3dc5b4db60a4ba95
- remove some unused functions
- move global arrays from data to read only section
- explicitly cast malloc returns; not specifically necessary, but helps
show intent
- miscellaneous formatting
Change-Id: Ib15fe5b37fe6c29c369ad928bdc3a7290cd13c84
MAX_LEN -> max_len
This was sub-optimal at the end of the picture, when there's
less than MAX_LEN bytes left to match.
Change-Id: I5ebe1fca4e7c112dcd34748a082d1c97f95eb099
often reduces compressed size by ~10's of bytes
+ refactored / sped-up the prediction code (gradient: ~30% faster)
Change-Id: I26bd983655dad4f85d5c5ddc20a1980f384c4dd6
.. where only 2 filtering modes are potentially
tried, instead of all of them. This is fast than the exhaustive 'best'
mode, and not much worse.
Options for cwebp are:
-alpha_filter none
-alpha_filter fast (<- default)
-alpha_filter best (<- slow)
Change-Id: I8cb90ee11b8f981811e013ea4ad5bf72ba3ea7d4
Add predictive filtering option for Alpha plane.
Valid range for filter option is [0, 5] corresponding to prediction
methods none, horizontal, vertical, gradient & paeth filter.
The prediction method 5 will try all the prediction methods (0 to 4)
and pick the prediction method that gives best compression.
Change-Id: I9244d4a9c5017501a9696c7cec5045f04c16d49b
- add check for native log2 to configure
- use a common define (NOT_HAVE_LOG2) to enable use of local library
version for non-autoconf platforms without their own version,
currently msvc and android
This uses a negative (NOT_HAVE_) to simplify the ifdef
Change-Id: Id0610eed507f8bb9c5da338918112853d5c8127a
This speeds things up for long message, while not damaging
the stats too much for usual-sized cases
Change-Id: I3f45e28b771d701e2e1da11eb800de18c4ed12fc
Add code for Alpha encoding & decoding. The alpha compression is done
via backward reference counts encoded with Arithmetic encoder (TCoder).
Also provided is lossy Alpha pre-processing option via level-quantizations
using kNN heuristic.
Change-Id: Ib6b13530c1a4ab6493edcb586ad29fe242bc1766
CloseHandle returns non-zero on success so earlier versions would leave
'ok' with a misleading value, though the return itself was correct.
Change-Id: I21b74a59d90f7bf1b484a55f3960962e933f577b