Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
mcychan authored Jul 22, 2024
1 parent db89c17 commit f35d2ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/nQuant/j2se/GilbertCurve.java
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public int compare(ErrorBox o1, ErrorBox o2) {

DITHER_MAX = weight < .01 ? (weight > .0025) ? (byte) 25 : 16 : 9;
double edge = hasAlpha ? 1 : Math.exp(weight) - .25;
double deviation = weight > .002 ? -.75 : 1;
double deviation = weight > .002 ? -.25 : 1;
ditherMax = (hasAlpha || DITHER_MAX > 9) ? (byte) BitmapUtilities.sqr(Math.sqrt(DITHER_MAX) + edge * deviation) : DITHER_MAX;
final int density = palette.length > 16 ? 3200 : 1500;
if(palette.length / weight > 5000 && (weight > .045 || (weight > .01 && palette.length <= 64)))
Expand Down

0 comments on commit f35d2ee

Please sign in to comment.