Pascal Massimino
1db888ba40
take colorspace into account when cropping
...
(cherry picked from commit 4e33653b52637c74ae30adde7990265d1d43994b)
Conflicts:
src/dec/vp8l.c
2012-03-30 12:48:24 -07:00
Pascal Massimino
61c2d51fd7
move the rescaling code into its own file and make enc/ and dec/ use it.
...
(cherry picked from commit 8e92d9e380a89b7443a2e2c3d16ce5a222e8c1e8)
Conflicts:
Android.mk
makefile.unix
src/dec/vp8l.c
src/utils/Makefile.am
2012-03-30 12:16:25 -07:00
Urvang Joshi
efc2016a31
Make rescaler methods generic
...
to be used in rescaling of lossless bitstreams.
(cherry picked from commit 2e12a3045498b6faf13b93bc25391e8226119f0a)
2012-03-30 11:57:07 -07:00
Urvang Joshi
3eacee8158
Move rescaler methods out of io.c.
...
(cherry picked from commit b5e9db1824f6efbe0bfb87e94b8d6e88a7973ef7)
2012-03-30 11:56:51 -07:00
Scott LaVarnway
ed278e2279
Removed unnecessary lookup
...
The lookup value is the same as the index. The index in this
case is either a 0 or 1.
Change-Id: I0432dfcbea9e7bb20bca7574e25fb1fd8a51c8e9
2012-03-26 11:44:04 -04:00
Pascal Massimino
cd8c3ba78f
fix some warnings: down-cast and possibly-uninitialized variable
...
Change-Id: I5baf59bbcd5dcff69316b0601483ff5abe8e1454
2012-03-16 20:20:33 -07:00
pascal massimino
8abaf82083
Merge "silence some type size related warnings"
2012-02-09 19:21:39 -08:00
James Zern
1601a39b09
silence some type size related warnings
...
size_t/ptrdiff_t -> uint32_t
Change-Id: Ic4d889b9239752311b9ed906c83076829d850874
2012-02-09 13:00:09 -08:00
pascal massimino
f3abe520ac
Merge "idec: simplify buffer size calculation"
2012-02-09 01:25:00 -08:00
James Zern
a9c5cd4c97
idec: simplify buffer size calculation
...
Change-Id: Id0e20c44704ef9b0e14dcf5e71a05cea488fd95a
2012-02-08 14:29:25 -08:00
James Zern
5081db78be
configure/automake: no -version-info for convenience libs
...
Silences:
libtool: link: warning: `-version-info/-version-number' is ignored for
convenience libraries
Change-Id: I5705383b58f529fb06c2bf0932976b5a202446b6
2012-02-07 18:06:20 -08:00
pascal massimino
85b6ff6897
Merge "idec: fix WebPIUpdate failure"
2012-01-31 23:39:02 -08:00
James Zern
7bb6a9ccd6
idec: fix internal state corruption
...
A call to Append/Update would index the parts_ array w/-1 as num_parts_
had yet to be set by DecodePartition0. This would cause corruption
within the VP8Decoder member.
Fixes issue #106 .
Change-Id: Ib9f2811594ff19e948a66fda862a4e0a384bb9aa
2012-01-31 17:10:29 -08:00
James Zern
89cd1bb85b
idec: fix WebPIUpdate failure
...
If the first call to WebPIUpdate contained all of partition 0, but not
enough to decode a macroblock the test for max macro block size could
fail (4096 bytes) due to a memory buffer offset not being updated.
This change offsets the buffer in the same manner as Append().
Fixes issue #105 .
Change-Id: I90ca3d0dde92eedc076933b8349d2d297f2469e8
2012-01-31 16:55:10 -08:00
pascal massimino
631117ea5e
Merge "cosmetics & warnings"
2012-01-30 22:04:11 -08:00
James Zern
a0b2736d79
cosmetics & warnings
...
- 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
2012-01-30 17:19:53 -08:00
Pascal Massimino
f73947f41d
use 32bit for storing dequant coeffs, instead of 16b.
...
is a tad faster
Change-Id: Ibef8f3b4f3f04a9a647098e5946f616e211a61cd
2012-01-29 17:38:37 -08:00
Pascal Massimino
28a9d9b41a
speed-up GetResidualCost()
...
+ misc cosmetics and code polishing
Change-Id: I5830cd2f268d64c072b1cbccc0a4674833875055
2012-01-23 02:36:38 -08:00
Pascal Massimino
378086bd0a
misc cosmetics
...
Change-Id: Iafc73f9fece13b5ca900a8b9c1039268872a181b
2012-01-22 23:20:53 -08:00
Pascal Massimino
f0d2c7a76f
pass of cosmetics
...
Change-Id: Id031221b7499e8cfc460c873d0f8124c9bef3aa3
2012-01-17 18:32:27 -08:00
Vikas Arora
221a06bb16
Fix bug for Alpha in RGBA_4444 color-mode.
...
Fix bug for Alpha data in RGBA_4444 color-mode.
The Alpha data is required to be clipped [0, 15] while
converting from 8 bits to 4 bits.
Change-Id: I80705d575c35121beb9633a05ec8823435c79586
2012-01-09 14:07:30 +05:30
James Zern
ad1e163a0d
cosmetics: normalize copyright headers
...
Change-Id: I5e2462b101e0447a4f15a1455c07131bc97a52dd
2012-01-06 14:49:06 -08:00
James Zern
b1662b0530
fix some more type conversion warnings w/MSVC
...
API & memory related warnings will be dealt with separately
Change-Id: I8a7893baa4d5035c963fb3c16e0bb4eee742e968
2011-12-21 16:07:16 -08:00
Pascal Massimino
223d8c60aa
fix some uint64_t -> int conversion warnings with MSC
...
Change-Id: I5dc314c9d1a3cbda095be3c90886983500104867
2011-12-21 14:43:52 -08:00
James Zern
421eb99db3
Merge "Remove assigned-but-not-used variable "br""
2011-12-08 10:41:18 -08:00
Martin Olsson
a5d7ed5c4b
Remove assigned-but-not-used variable "br"
...
Fixes gcc 4.6.x -Wunused-but-set-variable compiler warning:
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -Wextra -Wall -Wunused-but-set-variable -MT libwebpdecode_la-idec.lo -MD -MP -MF .deps/libwebpdecode_la-idec.Tpo -c idec.c -fPIC -DPIC -o .libs/libwebpdecode_la-idec.o
idec.c: In function 'DecodeRemaining':
idec.c:371:17: warning: variable 'br' set but not used [-Wunused-but-set-variable]
Change-Id: Ib037be9634b5b802ba9f1e2ef156a8fdf9630752
2011-12-08 15:42:01 +01:00
Pascal Massimino
f62d2c9497
remove unused 'has_alpha' from VP8GetInfo() signature
...
alpha information is not to be found at RIFF chunks level, not
in the VP8 bitstream (that was a tmp hack)
Change-Id: Idd1629c696b03c26f6f30650d7216f627f1761df
2011-12-08 06:41:40 -08:00
Urvang Joshi
8666a93aae
Some bug-fixes for images with alpha.
...
- Fix the off-by-one diff when cropping with simple-filter.
- Fix a bug in incremental decoding in case of alpha.
- In VP8FinishRow(), do not decode alpha when y_start > y_end.
- Correct output of alpha channel for MODE_ARGB.
- Correct output of alpha channel for MODE_RGBA_4444.
Change-Id: I785763a2a704b973cc742ad93ffbb53699d1fc0a
2011-12-07 15:12:50 +05:30
Pascal Massimino
273a12a013
fix off-by-1 diff in case cropping and simple filtering
...
Change-Id: I6dea172d0cf129f9986b8a3e1eea85fa97a70402
2011-12-05 08:37:55 -08:00
James Zern
721f3f48e7
fix alpha decode
...
- remove left-over WEBP_EXPERIMENTAL_FEATURES #ifdef
Change-Id: I2b91ccd2e2b3ebea63d5f698f90206feec30a4db
2011-12-02 11:00:27 -08:00
Pascal Massimino
60942c8cea
fix the has_alpha_ order
...
Change-Id: I26211732584f6181bf763497818b45515e394c21
2011-12-02 10:26:42 -08:00
Vikas Arora
885f25bc83
Updated the includes to relative paths.
...
Change-Id: I0ea1a59dd0f6cb1df9f41e048e0c5a13e7fb8335
2011-12-01 15:30:41 +05:30
Vikas Arora
d117a94046
Add Alpha Decode support from WebPDecode.
...
Extend WebP decode functionality to extract Alpha data (support ALPH
chunk) and decode the Alpha plane using Alpha (utils/alpha) core-lib.
Change-Id: I6f0ee1b189c13caba3c1dd9b681383bfd00aa212
2011-12-01 11:24:50 +05:30
pascal massimino
059f03ef99
Merge "dec: validate colorspace before using as array index"
2011-11-17 10:24:59 -08:00
James Zern
469d6eb974
Merge "Makefile.am: remove redundant noinst_HEADERS"
2011-11-16 18:41:55 -08:00
James Zern
9fe3372f19
dec: validate colorspace before using as array index
...
Change-Id: I5bcf01769d58d39a5f8d50f54cf0cd83a2309602
2011-11-16 18:21:56 -08:00
James Zern
ced3e3f4e0
Makefile.am: remove redundant noinst_HEADERS
...
When they appear in _SOURCES they won't be installed [1].
[1]: http://www.gnu.org/software/automake/manual/automake.html#Headers
Change-Id: I14fd816294682e7bd0fccefd6428e1526c9470d8
2011-11-11 16:29:32 -08:00
James Zern
964387ed19
use WEBP_INLINE for inline function declarations
...
removes a #define inline, objectionable in certain projects
Change-Id: Iebe0ce0b25a030756304d402679ef769e5f854d1
2011-11-11 10:53:58 -08:00
Vikas Arora
f07b2138cd
Rectify the Chunk parsing logic.
...
For odd-sized chunk-payload, there's one Byte padding at the end to make the
next chunk start at even-address. The chunk-skip logic needs to be updated to
handle such cases.
Change-Id: I8939ed07584a6195092fbe703eb0ea711fa5f153
2011-10-31 18:47:33 -07:00
Pascal Massimino
42c2e682e0
Fix missing coma (on uncompiled code)
...
Spotted by Jakub, Thanks!
Change-Id: Ic2509acc683690748089b831ee3d109ad2162dc2
2011-10-27 06:37:36 -07:00
James Zern
563e52d62e
cosmetics after '76036f5 Refactor decoder library'
...
reference 'VP8X' consistently / spelling
sort header size defines alphabetically on their logical boundaries
drop useless cast
const updates
Change-Id: I9409814c5b89773ae8910dc74887f91435e6ac82
2011-09-16 12:32:03 -07:00
Urvang Joshi
76036f547e
Refactor decoder library
...
- Move common defines to dec/webpi.h
- Regularize naming and parameters of various "CheckAndSkip" functions.
Also they return VP8StatusCode for clarity.
- Move WebP header/chunk parsing functions to webpi.h
- Fix a bug in static function GetFeatures()
Change-Id: Ibc3da4ba210d860551724dc40741959750d66b89
2011-09-16 10:55:24 -07:00
James Zern
0ee683b593
update libtool version-info
...
consistent with:
http://www.gnu.org/software/libtool/manual/libtool.html#Versioning
current=2 matches the ABI version for both encode & decode
Change-Id: Ie175b2bdb8f5e14690f4cf6357fc0e0c6c78fe7d
2011-09-13 15:49:13 -07:00
Pascal Massimino
b112e83647
create a libwebputils under src/utils
...
with bit_reader bit_writer and thread for now.
Change-Id: If961933fcfc43e60220913fe4d527230ba8f46bb
2011-09-13 15:34:15 -07:00
Pascal Massimino
ee697d9fc9
harmonize the include guards and #endif comments
2011-09-13 15:31:52 -07:00
Pascal Massimino
e06ac0887f
create a separate libwebpdsp under src/dsp
...
Gathers all DSP-related function (and SSE2 implementations).
Clean-up some unwanted symbolic dependencies so that webp_encode,
webp_decode and webp_dsp are truly independent libraries.
+ opportunistic clean-up:
* remove unneeded VP8DspInitTables(), now integrated in VP8DspInit()
* make consistent use of VP8GetCPUInfo() in the various DspInit() funcs
* change OUT macro to DST
2011-09-13 12:29:44 -07:00
Pascal Massimino
812dfa1ae1
bump up versions in preparations for 0.1.3
...
Change-Id: Icbadada515a5be7810473ff530565c2cb4fb904d
2011-08-29 22:52:47 -07:00
James Zern
7c43663036
Silence some (more) Visual Studio warnings.
...
Change-Id: Idac44feac894ab13630e032222c4744d6fa785df
2011-08-29 18:08:26 -07:00
James Zern
c7e86abab6
cosmetics: fix comment line lengths
...
add additional '-' to //----... style comments globally instead of
polluting further commits
Change-Id: I951acc68b7b5384b4d6e235349b0067d1aa6fa8b
2011-08-26 12:19:33 -07:00
Pascal Massimino
dfcc2136e1
reorganize chunk-parsing code
...
make room for future VP8X extensions
Change-Id: Ic78217c26f142403b733740b17980aa81602f83d
2011-08-18 11:07:13 -07:00