org.jhotdraw.color
Class QuantizingColorWheelImageProducer
java.lang.Object
java.awt.image.MemoryImageSource
org.jhotdraw.color.AbstractColorWheelImageProducer
org.jhotdraw.color.QuantizingColorWheelImageProducer
- All Implemented Interfaces:
- java.awt.image.ImageProducer
public class QuantizingColorWheelImageProducer
- extends AbstractColorWheelImageProducer
Produces the image of a ColorWheel.
- Version:
- $Id: ColorWheelImageProducer.java 628 2010-01-20 14:51:38Z rawcoder $
- Author:
- Werner Randelshofer
- See Also:
JColorWheel
Methods inherited from class java.awt.image.MemoryImageSource |
addConsumer, isConsumer, newPixels, newPixels, newPixels, newPixels, newPixels, removeConsumer, requestTopDownLeftRightResend, setAnimated, setFullBufferUpdates, startProduction |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
angulars
protected float[] angulars
- Lookup table for angular component values.
radials
protected float[] radials
- Lookup table for radial component values.
alphas
protected int[] alphas
- Lookup table for alphas.
The alpha value is used for antialiasing the
color wheel.
angularQuantization
protected int angularQuantization
radialQuantization
protected int radialQuantization
QuantizingColorWheelImageProducer
public QuantizingColorWheelImageProducer(java.awt.color.ColorSpace sys,
int w,
int h)
- Creates a new instance.
generateLookupTables
protected void generateLookupTables()
needsGeneration
public boolean needsGeneration()
- Overrides:
needsGeneration
in class AbstractColorWheelImageProducer
regenerateColorWheel
public void regenerateColorWheel()
- Overrides:
regenerateColorWheel
in class AbstractColorWheelImageProducer
generateColorWheel
public void generateColorWheel()
- Specified by:
generateColorWheel
in class AbstractColorWheelImageProducer
getColorLocation
public java.awt.Point getColorLocation(float[] components)
- Specified by:
getColorLocation
in class AbstractColorWheelImageProducer
getColorAt
public float[] getColorAt(int x,
int y)
- Specified by:
getColorAt
in class AbstractColorWheelImageProducer