From e1e9be350223a18b6d1dfeb9a28a2fb6de5ed4ef Mon Sep 17 00:00:00 2001 From: James Zern Date: Fri, 15 Jul 2011 18:58:56 -0700 Subject: [PATCH] cosmetics: spelling/grammar in README and lib headers Change-Id: Ib8648adf652d29dd38887e5e07b09b4aa3965c6e --- README | 21 +++++++++++---------- src/webp/decode.h | 4 ++-- src/webp/decode_vp8.h | 4 ++-- src/webp/encode.h | 8 ++++---- 4 files changed, 19 insertions(+), 18 deletions(-) diff --git a/README b/README index 34e24124..769c3004 100644 --- a/README +++ b/README @@ -32,9 +32,9 @@ By running: nmake /f Makefile.vc CFG=release-static RTLIBCFG=static OBJDIR=output -the directory output\release-static\x86\bin will contain the tools -cweb.exe and dweb.exe. The directory output\release-static\x86\lib will -contains the libwebp static library. +the directory output\release-static\(x64|x86)\bin will contain the tools +cwebp.exe and dwebp.exe. The directory output\release-static\(x64|x86)\lib will +contain the libwebp static library. Unix build using makefile.unix: ------------------------------- @@ -170,7 +170,7 @@ visual quality are: -m Namely: - * 'preset' will set up a default encoding configuration targetting a + * 'preset' will set up a default encoding configuration targeting a particular type of input. It should appear first in the list of options, so that subsequent options can take effect on top of this preset. Default value is 'default'. @@ -262,7 +262,7 @@ The encoding flow looks like: // ... additional tuning config.sns_strength = 90; config.filter_sharpness = 6; - config_error = WebPValidateConfig(&config); // not mandartory, but useful + config_error = WebPValidateConfig(&config); // not mandatory, but useful // Setup the input data WebPPicture pic; @@ -290,7 +290,7 @@ The encoding flow looks like: // initialize 'wrt' here... // Compress! - int ok = WebPEncode(&config, &pic); // ok = 0 => error occured! + 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. @@ -308,9 +308,9 @@ uint8_t* WebPDecodeRGB(const uint8_t* data, uint32_t data_size, int *width, int *height); Please have a look at the file src/webp/decode.h for the details. -There are variants for decoding in BGR/RGBA/BGRA order, along with decoding to -raw Y'CbCr samples. One can also decode the image directly into a pre-allocated -buffer. +There are variants for decoding in BGR/RGBA/ARGB/BGRA order, along with +decoding to raw Y'CbCr samples. One can also decode the image directly into a +pre-allocated buffer. To detect a WebP file and gather picture's dimensions, the function: int WebPGetInfo(const uint8_t* data, uint32_t data_size, @@ -343,7 +343,7 @@ or by just mentioning the new size of the transmitted data: WebPIUpdate(idec, buffer, size_of_transmitted_buffer); Note that 'buffer' can be modified between each calls to WebPIUpdate, in -particular when the buffer is resized to accomodate larger data. +particular when the buffer is resized to accommodate larger data. These functions will return the decoding status: either VP8_STATUS_SUSPENDED if decoding is not finished yet, or VP8_STATUS_OK when decoding is done. @@ -374,3 +374,4 @@ Discuss: ======== Email: webp-discuss@webmproject.org +Web: http://groups.google.com/a/webmproject.org/group/webp-discuss diff --git a/src/webp/decode.h b/src/webp/decode.h index 939cb964..ccb4c369 100644 --- a/src/webp/decode.h +++ b/src/webp/decode.h @@ -234,7 +234,7 @@ WEBP_EXTERN(WebPIDecoder*) WebPINewYUV( uint8_t* u, int u_size, int u_stride, uint8_t* v, int v_size, int v_stride); -// Deletes the WebpBuffer object and associated memory. Must always be called +// Deletes the WebPIDecoder object and associated memory. Must always be called // if WebPINew, WebPINewRGB or WebPINewYUV succeeded. WEBP_EXTERN(void) WebPIDelete(WebPIDecoder* const idec); @@ -329,7 +329,7 @@ WEBP_EXTERN(VP8StatusCode) WebPGetFeaturesInternal( const uint8_t*, uint32_t, WebPBitstreamFeatures* const, int); // Retrieve features from the bitstream. The *features structure is filled -// with informations gathered from the bitstream. +// with information gathered from the bitstream. // Returns false in case of error or version mismatch. // In case of error, features->bitstream_status will reflect the error code. static inline diff --git a/src/webp/decode_vp8.h b/src/webp/decode_vp8.h index 6aa07c6a..af276add 100644 --- a/src/webp/decode_vp8.h +++ b/src/webp/decode_vp8.h @@ -21,7 +21,7 @@ extern "C" { //----------------------------------------------------------------------------- // Lower-level API // -// Thes functions provide fine-grained control of the decoding process. +// These functions provide fine-grained control of the decoding process. // The call flow should resemble: // // VP8Io io; @@ -105,7 +105,7 @@ WEBP_EXTERN(int) VP8InitIoInternal(VP8Io* const, int); // Set the custom IO function pointers and user-data. The setter for IO hooks // should be called before initiating incremental decoding. Returns true if -// WebPIdecoder object is successfully modified, false otherwise. +// WebPIDecoder object is successfully modified, false otherwise. WEBP_EXTERN(int) WebPISetIOHooks(WebPIDecoder* const idec, VP8IoPutHook put, VP8IoSetupHook setup, diff --git a/src/webp/encode.h b/src/webp/encode.h index 176d6a66..af6f0a2c 100644 --- a/src/webp/encode.h +++ b/src/webp/encode.h @@ -113,14 +113,14 @@ WEBP_EXTERN(int) WebPValidateConfig(const WebPConfig* const config); typedef struct WebPPicture WebPPicture; // main structure for I/O -// non-essential structure for storing auxilliary statistics +// non-essential structure for storing auxiliary statistics typedef struct { float PSNR[4]; // peak-signal-to-noise ratio for Y/U/V/All int coded_size; // final size int block_count[3]; // number of intra4/intra16/skipped macroblocks - int header_bytes[2]; // approximative number of bytes spent for header + int header_bytes[2]; // approximate number of bytes spent for header // and mode-partition #0 - int residual_bytes[3][4]; // approximative number of bytes spent for + int residual_bytes[3][4]; // approximate number of bytes spent for // DC/AC/uv coefficients for each (0..3) segments. int segment_size[4]; // number of macroblocks in each segments int segment_quant[4]; // quantizer values for each segments @@ -256,7 +256,7 @@ WEBP_EXTERN(int) WebPPictureImportBGRA( //----------------------------------------------------------------------------- // Main call -// Main encoding call, after config and picture have been initialiazed. +// Main encoding call, after config and picture have been initialized. // 'picture' must be less than 16384x16384 in dimension, and the 'config' object // must be a valid one. // Returns false in case of error, true otherwise.