public void setQuality(int quality) {
        if (quality < 1)
            quality = 1;
        sample = quality;
    }
Sets quality of color quantization (conversion of images to the maximum 256
colors allowed by the GIF specification). Lower values (minimum = 1)
produce better colors, but slow processing significantly. 10 is the
default, and produces good color mapping at reasonable speeds. Values
greater than 20 do not yield significant improvements in speed.

@param quality int greater than 0.
@return
subs/gif-revert/src/main/java/com/engineer/gif/revert/lib/AnimatedGifEncoder.java