Created
October 15, 2017 20:07
-
-
Save grkvlt/2be3efeec22737a91910d91d29ced7d8 to your computer and use it in GitHub Desktop.
Exploring Iterated Function Systems
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Paint pixels unless using density rendering | |
if (!render.isDensity()) { | |
// Apply controller gamma correction | |
Color.RGBtoHSB(color.getRed(), color.getGreen(), color.getBlue(), hsb); | |
g.setPaint(alpha(Color.HSBtoRGB(hsb[0], | |
unity().apply(hsb[1] * vibrancy).floatValue() * vibrancyLimit, | |
unity().apply(Math.pow(hsb[2], config.getGamma()) * vibrancy).floatValue() * vibrancyLimit), | |
octet().apply((int) (color.getAlpha() * vibrancy)))); | |
rect.setLocation(x, y); | |
g.fill(rect); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment