Sha256: 2371d7b15190fae722a291d93d76942597a55224085cd278b30c4e2b4f50b7e5
Contents?: true
Size: 625 Bytes
Versions: 9
Compression:
Stored size: 625 Bytes
Contents
package wordcram; import processing.core.PApplet; import processing.core.PConstants; abstract class HsbWordColorer implements WordColorer { private PApplet host; private int range; HsbWordColorer(PApplet host) { this(host, 255); } HsbWordColorer(PApplet host, int range) { this.host = host; this.range = range; } @Override public int colorFor(Word word) { host.pushStyle(); host.colorMode(PConstants.HSB, range); int color = getColorFor(word); host.popStyle(); return color; } abstract int getColorFor(Word word); }
Version data entries
9 entries across 9 versions & 1 rubygems