diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2015-04-08 10:10:02 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2015-04-09 08:41:30 +0000 |
commit | 600a2d18d40ba87a273e1a258ce3189b0edc11f8 (patch) | |
tree | d80ede3880cb86f06eae50191e5dd3b102482189 /src/3rdparty/libwebp/README | |
parent | 32e437b1244e7bf45011e4fd770fc0eef40d02de (diff) | |
download | qtimageformats-600a2d18d40ba87a273e1a258ce3189b0edc11f8.tar.gz |
libwebp: update to 0.4.3
This commit imports libwebp 0.4.3, including AUTHORS, COPYING, ChangeLog,
NEWS, PATENTS, README and src directories. In src, only includes header
and source files.
The patches required to build it in Qt will follow in separate
commit(s).
Change-Id: I23ebfd69e47a468c91a9e9b109e9cb8ac63705d4
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
Diffstat (limited to 'src/3rdparty/libwebp/README')
-rw-r--r-- | src/3rdparty/libwebp/README | 132 |
1 files changed, 69 insertions, 63 deletions
diff --git a/src/3rdparty/libwebp/README b/src/3rdparty/libwebp/README index 64e9f2d..c3f32c5 100644 --- a/src/3rdparty/libwebp/README +++ b/src/3rdparty/libwebp/README @@ -4,7 +4,7 @@ \__\__/\____/\_____/__/ ____ ___ / _/ / \ \ / _ \/ _/ / \_/ / / \ \ __/ \__ - \____/____/\_____/_____/____/v0.4.0 + \____/____/\_____/_____/____/v0.4.3 Description: ============ @@ -140,28 +140,30 @@ A longer list of options is available using the -longhelp command line flag: Usage: cwebp [-preset <...>] [options] in_file [-o out_file] -If input size (-s) for an image is not specified, it is assumed to be a PNG, -JPEG or TIFF file. -options: +If input size (-s) for an image is not specified, it is +assumed to be a PNG, JPEG, TIFF or WebP file. + +Options: -h / -help ............ short help -H / -longhelp ........ long help -q <float> ............. quality factor (0:small..100:big) - -alpha_q <int> ......... Transparency-compression quality (0..100). - -preset <string> ....... Preset setting, one of: + -alpha_q <int> ......... transparency-compression quality (0..100) + -preset <string> ....... preset setting, one of: default, photo, picture, drawing, icon, text - -preset must come first, as it overwrites other parameters. + -preset must come first, as it overwrites other parameters + -m <int> ............... compression method (0=fast, 6=slowest) -segments <int> ........ number of segments to use (1..4) - -size <int> ............ Target size (in bytes) - -psnr <float> .......... Target PSNR (in dB. typically: 42) + -size <int> ............ target size (in bytes) + -psnr <float> .......... target PSNR (in dB. typically: 42) - -s <int> <int> ......... Input size (width x height) for YUV - -sns <int> ............. Spatial Noise Shaping (0:off, 100:max) + -s <int> <int> ......... input size (width x height) for YUV + -sns <int> ............. spatial noise shaping (0:off, 100:max) -f <int> ............... filter strength (0=off..100) -sharpness <int> ....... filter sharpness (0:most .. 7:least sharp) - -strong ................ use strong filter instead of simple (default). - -nostrong .............. use simple filter instead of strong. + -strong ................ use strong filter instead of simple (default) + -nostrong .............. use simple filter instead of strong -partition_limit <int> . limit quality to fit the 512k limit on the first partition (0=no degradation ... 100=full) -pass <int> ............ analysis pass number (1..10) @@ -169,41 +171,40 @@ options: -resize <w> <h> ........ resize picture (after any cropping) -mt .................... use multi-threading if available -low_memory ............ reduce memory usage (slower encoding) - -map <int> ............. print map of extra info. - -print_psnr ............ prints averaged PSNR distortion. - -print_ssim ............ prints averaged SSIM distortion. - -print_lsim ............ prints local-similarity distortion. - -d <file.pgm> .......... dump the compressed output (PGM file). - -alpha_method <int> .... Transparency-compression method (0..1) - -alpha_filter <string> . predictive filtering for alpha plane. - One of: none, fast (default) or best. - -alpha_cleanup ......... Clean RGB values in transparent area. - -blend_alpha <hex> ..... Blend colors against background color + -map <int> ............. print map of extra info + -print_psnr ............ prints averaged PSNR distortion + -print_ssim ............ prints averaged SSIM distortion + -print_lsim ............ prints local-similarity distortion + -d <file.pgm> .......... dump the compressed output (PGM file) + -alpha_method <int> .... transparency-compression method (0..1) + -alpha_filter <string> . predictive filtering for alpha plane, + one of: none, fast (default) or best + -alpha_cleanup ......... clean RGB values in transparent area + -blend_alpha <hex> ..... blend colors against background color expressed as RGB values written in hexadecimal, e.g. 0xc0e0d0 for red=0xc0 - green=0xe0 and blue=0xd0. - -noalpha ............... discard any transparency information. - -lossless .............. Encode image losslessly. - -hint <string> ......... Specify image characteristics hint. - One of: photo, picture or graph + green=0xe0 and blue=0xd0 + -noalpha ............... discard any transparency information + -lossless .............. encode image losslessly + -hint <string> ......... specify image characteristics hint, + one of: photo, picture or graph -metadata <string> ..... comma separated list of metadata to copy from the input to the output if present. Valid values: all, none (default), exif, icc, xmp -short ................. condense printed message - -quiet ................. don't print anything. - -version ............... print version number and exit. - -noasm ................. disable all assembly optimizations. + -quiet ................. don't print anything + -version ............... print version number and exit + -noasm ................. disable all assembly optimizations -v ..................... verbose, e.g. print encoding/decoding times -progress .............. report encoding progress Experimental Options: - -jpeg_like ............. Roughly match expected JPEG size. - -af .................... auto-adjust filter strength. + -jpeg_like ............. roughly match expected JPEG size + -af .................... auto-adjust filter strength -pre <int> ............. pre-processing filter - The main options you might want to try in order to further tune the visual quality are: -preset @@ -262,19 +263,19 @@ Use following options to convert into alternate image formats: -yuv ......... save the raw YUV samples in flat layout Other options are: - -version .... print version number and exit. - -nofancy ..... don't use the fancy YUV420 upscaler. - -nofilter .... disable in-loop filtering. - -nodither .... disable dithering. + -version .... print version number and exit + -nofancy ..... don't use the fancy YUV420 upscaler + -nofilter .... disable in-loop filtering + -nodither .... disable dithering -dither <d> .. dithering strength (in 0..100) -mt .......... use multi-threading -crop <x> <y> <w> <h> ... crop output with the given rectangle -scale <w> <h> .......... scale the output (*after* any cropping) - -alpha ....... only save the alpha plane. + -alpha ....... only save the alpha plane -incremental . use incremental decoding (useful for tests) - -h ....... this help message. + -h ....... this help message -v ....... verbose (e.g. print encoding/decoding times) - -noasm ....... disable all assembly optimizations. + -noasm ....... disable all assembly optimizations Visualization tool: =================== @@ -288,19 +289,19 @@ Usage: vwebp in_file [options] Decodes the WebP image file and visualize it using OpenGL Options are: - -version .... print version number and exit. - -noicc ....... don't use the icc profile if present. - -nofancy ..... don't use the fancy YUV420 upscaler. - -nofilter .... disable in-loop filtering. - -dither <int> dithering strength (0..100). Default=50. - -mt .......... use multi-threading. - -info ........ print info. - -h ....... this help message. + -version .... print version number and exit + -noicc ....... don't use the icc profile if present + -nofancy ..... don't use the fancy YUV420 upscaler + -nofilter .... disable in-loop filtering + -dither <int> dithering strength (0..100), default=50 + -mt .......... use multi-threading + -info ........ print info + -h ....... this help message Keyboard shortcuts: - 'c' ................ toggle use of color profile. - 'i' ................ overlay file information. - 'q' / 'Q' / ESC .... quit. + 'c' ................ toggle use of color profile + 'i' ................ overlay file information + 'q' / 'Q' / ESC .... quit Building: --------- @@ -336,24 +337,24 @@ vwebp. Usage: gif2webp [options] gif_file -o webp_file -options: +Options: -h / -help ............ this help - -lossy ................. Encode image using lossy compression. - -mixed ................. For each frame in the image, pick lossy - or lossless compression heuristically. + -lossy ................. encode image using lossy compression + -mixed ................. for each frame in the image, pick lossy + or lossless compression heuristically -q <float> ............. quality factor (0:small..100:big) -m <int> ............... compression method (0=fast, 6=slowest) - -kmin <int> ............ Min distance between key frames - -kmax <int> ............ Max distance between key frames + -kmin <int> ............ min distance between key frames + -kmax <int> ............ max distance between key frames -f <int> ............... filter strength (0=off..100) -metadata <string> ..... comma separated list of metadata to - copy from the input to the output if present. + copy from the input to the output if present Valid values: all, none, icc, xmp (default) -mt .................... use multi-threading if available - -version ............... print version number and exit. - -v ..................... verbose. - -quiet ................. don't print anything. + -version ............... print version number and exit + -v ..................... verbose + -quiet ................. don't print anything Building: --------- @@ -442,15 +443,20 @@ The encoding flow looks like: // Set up a byte-output write method. WebPMemoryWriter, for instance. WebPMemoryWriter wrt; + WebPMemoryWriterInit(&wrt); // initialize 'wrt' + pic.writer = MyFileWriter; pic.custom_ptr = my_opaque_structure_to_make_MyFileWriter_work; - // initialize 'wrt' here... // Compress! int ok = WebPEncode(&config, &pic); // ok = 0 => error occurred! WebPPictureFree(&pic); // must be called independently of the 'ok' result. // output data should have been handled by the writer at that point. + // -> compressed data is the memory buffer described by wrt.mem / wrt.size + + // deallocate the memory used by compressed data + WebPMemoryWriterClear(&wrt); -------------------------------------- END PSEUDO EXAMPLE |