X-Git-Url: http://www2.svjatoslav.eu/gitweb/?p=imagesqueeze.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Feu%2Fsvjatoslav%2Fimagesqueeze%2Fcodec%2FColorStats.java;h=3ffb83d4db482e2a62ab7c9f78ec94ed0d6ff235;hp=8d206cf46c8f221b4316b934350181656c19b7c3;hb=4595d6b97aff8e6d9dcce902bc2f1119d4ab2f0e;hpb=4bcffe8896c08c9f60b2707da71bb39a64618d93 diff --git a/src/main/java/eu/svjatoslav/imagesqueeze/codec/ColorStats.java b/src/main/java/eu/svjatoslav/imagesqueeze/codec/ColorStats.java index 8d206cf..3ffb83d 100755 --- a/src/main/java/eu/svjatoslav/imagesqueeze/codec/ColorStats.java +++ b/src/main/java/eu/svjatoslav/imagesqueeze/codec/ColorStats.java @@ -1,43 +1,42 @@ /* - * Imagesqueeze - Image codec optimized for photos. - * Copyright (C) 2012, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu - * + * Imagesqueeze - Image codec. Copyright ©2012-2019, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu + * * This program is free software; you can redistribute it and/or - * modify it under the terms of version 2 of the GNU General Public License - * as published by the Free Software Foundation. + * modify it under the terms of version 3 of the GNU Lesser General Public License + * or later as published by the Free Software Foundation. */ package eu.svjatoslav.imagesqueeze.codec; -public class ColorStats { +class ColorStats { - int ySum; - int uSum; - int vSum; + int ySum; + int uSum; + int vSum; - int pixelCount; + int pixelCount; - public ColorStats() { - reset(); - } + public ColorStats() { + reset(); + } - public int getAverageU() { - return uSum / pixelCount; - } + public int getAverageU() { + return uSum / pixelCount; + } - public int getAverageV() { - return vSum / pixelCount; - } + public int getAverageV() { + return vSum / pixelCount; + } - public int getAverageY() { - return ySum / pixelCount; - } + public int getAverageY() { + return ySum / pixelCount; + } - public void reset() { - ySum = 0; - uSum = 0; - vSum = 0; - pixelCount = 0; - } + public void reset() { + ySum = 0; + uSum = 0; + vSum = 0; + pixelCount = 0; + } }