From 33357131698ba0abb5b7a32b6f274f6f58170642 Mon Sep 17 00:00:00 2001 From: Urvang Joshi Date: Fri, 19 Feb 2016 16:44:01 +0000 Subject: [PATCH] Near lossless feature: fix some comments. Change-Id: I2c5fc2a3b3fe5123d66b42bf148e361b4862dfb9 --- src/enc/near_lossless.c | 12 ++++++------ src/webp/encode.h | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/enc/near_lossless.c b/src/enc/near_lossless.c index 9bc0f0e7..23464596 100644 --- a/src/enc/near_lossless.c +++ b/src/enc/near_lossless.c @@ -126,12 +126,12 @@ static void NearLossless(int xsize, int ysize, uint32_t* argb, static int QualityToLimitBits(int quality) { // quality mapping: - // 0..19 -> 5 - // 0..39 -> 4 - // 0..59 -> 3 - // 0..79 -> 2 - // 0..99 -> 1 - // 100 -> 0 + // 0..19 -> 5 + // 20..39 -> 4 + // 40..59 -> 3 + // 60..79 -> 2 + // 80..99 -> 1 + // 100 -> 0 return MAX_LIMIT_BITS - quality / 20; } diff --git a/src/webp/encode.h b/src/webp/encode.h index c382ea76..9291b719 100644 --- a/src/webp/encode.h +++ b/src/webp/encode.h @@ -134,8 +134,8 @@ struct WebPConfig { int thread_level; // If non-zero, try and use multi-threaded encoding. int low_memory; // If set, reduce memory usage (but increase CPU use). - int near_lossless; // Near lossless encoding [0 = off(default) .. 100]. - // This feature is experimental. + int near_lossless; // Near lossless encoding [0 = max loss .. 100 = off + // (default)]. int exact; // if non-zero, preserve the exact RGB values under // transparent area. Otherwise, discard this invisible // RGB information for better compression. The default