Commit Graph

135 Commits

Author SHA1 Message Date
James Zern
c37c23e594 README: cosmetics
- update swig function references
- remove references to decode_vp8.h (no longer installed)
- add lossless references
- some grammar/spelling changes

Change-Id: Icebfbcf6f638762f42d844b6bd3c0129c64d9340
2012-07-19 12:38:46 -07:00
Pascal Massimino
c2416c9b61 add lossless quick encoding functions to the public API
New functions:
   WebPEncodeLosslessRGB()
   WebPEncodeLosslessBGR()
   WebPEncodeLosslessRGBA()
   WebPEncodeLosslessBGRA()

Change-Id: Id56da7569eee80c57de8f1f053fb87b217d33a4b
2012-07-17 12:02:53 -07:00
pascal massimino
1efaa5a369 Merge "bump versions" into 0.2.0 2012-07-14 10:57:58 -07:00
James Zern
12f9aede7e README: update cwebp help output
Change-Id: Ifc2fafca8131e53a894056e37bb22d25fedfa150
2012-07-13 14:55:39 -07:00
James Zern
f0b5defb0a bump versions
lib - 0.1.99
libtool - 3.0.0 (interface changes)

Change-Id: Id52f8b8df5b941b15af6cb54b1cc05daf322179f
2012-07-13 14:07:51 -07:00
James Zern
02f27fbd3b dec: remove deprecated WebPINew()
Change-Id: I22ad1d297333f5ebc84456d142426a4e0e9a044b
2012-04-27 19:47:35 -07:00
James Zern
9b3d1f3a1b decode.h: use size_t consistently
replaces mixed use of int/uint32_t for buffer sizes
further changes the API/ABI.

Change-Id: I91d70fd82ee3e1ac34b884b8ead9a114a9b1015a
2012-04-19 14:31:31 -07:00
Pascal Massimino
d61479f95b add -print_psnr and -print_ssim options to cwebp.
These will report the 7x7-averaged PSNR or SSIM, using the
new internal function WebPPictureDistortion().
This is for information only. These flags have no encoding impact.

+misc opportunistic cosmetics

Change-Id: I64c0a7eca679134d39062e438886274b22bb643f
2012-01-20 07:37:29 -08:00
Pascal Massimino
2e3e8b2ef5 add a WebPCleanupTransparentArea() method
to 'clean up' the fully-transparent area and make it more compressible
new cwebp flags: -alpha_cleanup (off by default, since gain is not 100% guaranteed)

Change-Id: I74d77e1915eee146584cd61c9c1132a41db922eb
2012-01-18 14:01:24 -08:00
Pascal Massimino
8ca2076de1 Introduce a 'fast' alpha mode
.. 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
2012-01-09 02:37:44 -08:00
Pascal Massimino
7937b409e7 simple WebP viewer, based on OpenGL
Quite handy and simple (for now).
It's not yet incorporated within the build system (autotools or
makefile.unix), because it gets complicated with OpenGL. TODO(later).

For now, there's some ready-to-use command line for compiling on Linux
or Mac in the header of vwebp.c

Later, this tool will be supplemented with support for animation,
tiling, zooming, etc.

Change-Id: I292972cea4862536afbe8c9ec444c590d152f086
2011-12-13 14:02:04 -08:00
Pascal Massimino
30971c9e95 Implement progress report (and user abort)
New cwebp flag is -progress

Change-Id: Ied872cca13f512036860783bbee1bdbccad72768
2011-12-01 14:19:40 -08:00
James Zern
206b686b39 README: correct advanced decode api pseudo-code
Change-Id: I09e5365cc15cb9b6c53a1d5d4e16a51bfc353b10
2011-09-13 15:47:53 -07:00
James Zern
227a91e522 README: minor wording update
Change-Id: I2683f9d8a00a476ccb90bef911804378ec6a5558
2011-08-30 17:27:46 -07:00
Pascal Massimino
4cbbb2901b Merge "bump up version for next freeze" 2011-08-26 16:24:23 -07:00
Pascal Massimino
a329167426 bump up version for next freeze 2011-08-26 16:23:14 -07:00
Vikas Arora
fac15ec78e Update NEWS & README for next release V0.1.3
Update ChangeLog, NEWS & README file for next release V0.1.3
2011-08-25 09:11:08 +05:30
Pascal Massimino
900286e091 add a -partition_limit option to limit the number of bits used by intra4x4
Although it degrades quality, this option is useful to avoid the 512k
limit for partition #0.
If not enough to reach the lower bound of 4bits per macroblock header,
one should also limit the number of segments used (down to -segments 1)

See the man file for extra details.

Change-Id: Ia59ffac13176c85b809ddd6340d37b54ee9487ea
2011-08-23 15:58:22 -07:00
Pascal Massimino
fc7815d692 multi-thread decoding: ~25-30% faster
To be enabled with the flag WEBP_USE_THREAD.
For now it's only available on unix (pthread), when using Makefile.unix
Will be switched on more generally later.

In-loop filtering and output (=rescaling/yuv->rgb conversion)
is done in parallel to bitstream decoding, lagging 1 row behind.

Example:
examples/dwebp bryce.webp -v
Time to decode picture: 0.680s

examples/dwebp bryce.webp -v -mt
Time to decode picture: 0.515s

Change-Id: Ic30a897423137a3bdace9c4e30465ef758fe53f2
2011-07-22 15:14:18 -07:00
James Zern
e1e9be3502 cosmetics: spelling/grammar in README and lib headers
Change-Id: Ib8648adf652d29dd38887e5e07b09b4aa3965c6e
2011-07-15 18:58:56 -07:00
James Zern
d646d5c743 swig: add WebPDecodeARGB
Change-Id: I6f22cf0f87a7274f2ed63e4aa96267a8155a5e35
2011-07-14 19:05:55 -07:00
Pascal Massimino
d260310511 add Advanced Decoding Interface
You can now use WebPDecBuffer, WebPBitstreamFeatures and WebPDecoderOptions
to have better control over the decoding process (and the speed/quality tradeoff).

WebPDecoderOptions allow to:
 - turn fancy upsampler on/off
 - turn in-loop filter on/off
 - perform on-the-fly cropping
 - perform on the-fly rescale
(and more to come. Not all features are implemented yet).

On-the-fly cropping and scaling allow to save quite some memory
(as the decoding operation will now scale with the output's size, not
the input's one). It saves some CPU too (since for instance,
in-loop filtering is partially turned off where it doesn't matter,
and some YUV->RGB conversion operations are ommitted too).

The scaler uses summed area, so is mainly meant to be used for
downscaling (like: for generating thumbnails or previews).

Incremental decoding works with these new options.
More doc to come soon.

dwebp is now using the new decoding interface, with the new flags:
  -nofancy
  -nofilter
  -crop top left width height
  -scale width height

Change-Id: I08baf2fa291941686f4ef70a9cc2e4137874e85e
2011-06-20 15:30:52 -07:00
James Zern
54f2170a15 swig/java: basic encode support
Wrap WebPEncode???* to provide an interface similar to decode.
As only WebPGetEncoderVersion is wrapped directly from encode.h avoid
including it in the swig file to reduce %ignore's.
This change also removes unnecessary incremental decoding related enums.

Change-Id: I0b5424026aa6ae012c6a29ad2f2301c2681ca301
2011-06-15 10:37:53 -07:00
James Zern
f6fb3877ed add swig interface
Currently only supports a subset of decode functions and likely only
works fully for java.

For java bindings:
The generated java source can be compiled and the class files added to
libwebp.jar.
The generated jni source can be compiled to, e.g., libwebp_jni.so, which
can then be loaded via System.loadLibrary("webp_jni").

Change-Id: I8225933cbaf85c9cfa4b78c2e5f167cee8b62408
2011-05-06 16:41:00 -07:00
Pascal Massimino
2ab4b72f53 EXPERIMENTAL: add support for alpha channel
This is a (minor) bitstream change: if the 'color_space' bit is set to '1'
(which is normally an undefined/invalid behaviour), we add extra data at the
end of partition #0 (so-called 'extensions')

Namely, we add the size of the extension data as 3 bytes (little-endian),
followed by a set of bits telling which extensions we're incorporating.
The data then _preceeds_ this trailing tags.

This is all experimental, and you'll need to have
'#define WEBP_EXPERIMENTAL_FEATURES' in webp/types.h to enable this code
(at your own risk! :))

Still, this hack produces almost-valid WebP file for decoders that don't
check this color_space bit. In particular, previous 'dwebp' (and for instance
Chrome) will recognize this files and decode them, but without the alpha
of course. Other decoder will just see random extra stuff at the end of
partition #0.

To experiment with the alpha-channel, you need to compile on Unix platform
and use PNGs for input/output.

If 'alpha.png' is a source with alpha channel, then you can try (on Unix):

  cwebp alpha.png -o alpha.webp
  dwebp alpha.webp -o test.png

cwebp now has a '-noalpha' flag to ignore any alpha information from the
source, if present.

More hacking and experimenting welcome!

Change-Id: I3c7b1fd8411c9e7a9f77690e898479ad85c52f3e
2011-04-25 23:29:39 -07:00
Pascal Massimino
276ae82512 Remove files not mean to be in git, and update .gitignore
Makes things lighter at the expense of requiring the user
to be up-to-date for autotools.

patch by Jan Engelhardt (jengelh at medozas dot de)

Change-Id: Icfcab2d899828a213d9fade0dab350dacd0c070a
2011-03-29 09:07:06 -07:00
Pascal Massimino
fa70d2b771 update version number in the DOC
Change-Id: I791be1c6678fa4bd2f0f330cd53aa5837dedbebf
2011-03-25 16:54:47 -07:00
Pascal Massimino
0de013b3a4 fix typos
Change-Id: Ib83202e639a16d569ce21e7d057fe83817479d61
2011-03-24 16:32:29 -07:00
Pascal Massimino
be4867d2f8 doc for incremental decoding
Change-Id: Idff912525b38aaed22113557a50abcb8422a9ab5
2011-03-24 15:50:02 -07:00
Pascal Massimino
4704146a1f add missing precision in the man
Change-Id: I55ae0547abf742b4620d9faae7fe5163d8459c19
2011-03-23 17:13:54 -07:00
Pascal Massimino
f7a9549dcb Add a simple top-level makefile.unix for quick & easy build.
Just use:
  make -f makefile.unix
instead of the autoconf system.

Change-Id: Idcedfd22e543023d1731f5753fb4958f02d0dd75
2011-02-20 11:17:44 -08:00
Pascal Massimino
5f36b94403 update the doc for the -f option
Change-Id: I0ae23bf755b516f0149539ac849e20c15fa26209
2011-02-19 09:34:48 -08:00
Pascal Massimino
f61d14aabf a WebP encoder
converts PNG & JPEG to WebP

This is an experimental early version, with lot of room
of later optimizations in both speed and quality.

Compile with the usual `./configure && make`
Command line example is examples/cwebp

Usage:

   cwebp [options] -q quality input.png -o output.webp

where 'quality' is between 0 (poor) to 100 (very good).
Typical value is around 80.

More encoding options with 'cwebp -longhelp'

Change-Id: I577a94f6f622a0c44bdfa9daf1086ace89d45539
2011-02-18 23:54:59 -08:00
Pascal Massimino
1dc4611a3a add support for PNG output (default)
regularize include guards

Change-Id: Ia1d0fa49c8c98e2c11f775b839d04a24e5450170
2011-01-31 22:25:44 -08:00
Pascal Massimino
c3f41cb47e Initial commit
Change-Id: I4712afb3912625e7aaccfa5160dcf78ee252f159
2010-09-30 09:55:07 -04:00