JHotDraw 7.6

org.jhotdraw.color
Class AbstractColorWheelImageProducer

java.lang.Object
  extended by java.awt.image.MemoryImageSource
      extended by org.jhotdraw.color.AbstractColorWheelImageProducer
All Implemented Interfaces:
java.awt.image.ImageProducer
Direct Known Subclasses:
ColorSquareImageProducer, ComplexColorWheelImageProducer, PolarColorWheelImageProducer, QuantizingColorWheelImageProducer

public abstract class AbstractColorWheelImageProducer
extends java.awt.image.MemoryImageSource

AbstractColorWheelImageProducer.

Version:
$Id: AbstractColorWheelImageProducer.java 717 2010-11-21 12:30:57Z rawcoder $
Author:
Werner Randelshofer

Field Summary
protected  int angularIndex
           
protected  java.awt.color.ColorSpace colorSpace
           
protected  int h
           
protected  boolean isLookupValid
           
protected  boolean isPixelsValid
           
protected  int[] pixels
           
protected  int radialIndex
           
protected  int verticalIndex
           
protected  float verticalValue
           
protected  int w
           
 
Constructor Summary
AbstractColorWheelImageProducer(java.awt.color.ColorSpace sys, int w, int h)
           
 
Method Summary
protected abstract  void generateColorWheel()
           
abstract  float[] getColorAt(int x, int y)
           
 java.awt.Point getColorLocation(java.awt.Color c)
           
abstract  java.awt.Point getColorLocation(float[] components)
           
 int getRadius()
           
 boolean needsGeneration()
           
 void regenerateColorWheel()
           
 void setAngularComponentIndex(int newValue)
           
 void setRadialComponentIndex(int newValue)
           
 void setVerticalComponentIndex(int newValue)
           
 void setVerticalValue(float newValue)
           
 
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
 

Field Detail

pixels

protected int[] pixels

w

protected int w

h

protected int h

colorSpace

protected java.awt.color.ColorSpace colorSpace

radialIndex

protected int radialIndex

angularIndex

protected int angularIndex

verticalIndex

protected int verticalIndex

isPixelsValid

protected boolean isPixelsValid

verticalValue

protected float verticalValue

isLookupValid

protected boolean isLookupValid
Constructor Detail

AbstractColorWheelImageProducer

public AbstractColorWheelImageProducer(java.awt.color.ColorSpace sys,
                                       int w,
                                       int h)
Method Detail

setRadialComponentIndex

public void setRadialComponentIndex(int newValue)

setAngularComponentIndex

public void setAngularComponentIndex(int newValue)

setVerticalComponentIndex

public void setVerticalComponentIndex(int newValue)

setVerticalValue

public void setVerticalValue(float newValue)

needsGeneration

public boolean needsGeneration()

regenerateColorWheel

public void regenerateColorWheel()

getRadius

public int getRadius()

generateColorWheel

protected abstract void generateColorWheel()

getColorLocation

public java.awt.Point getColorLocation(java.awt.Color c)

getColorLocation

public abstract java.awt.Point getColorLocation(float[] components)

getColorAt

public abstract float[] getColorAt(int x,
                                   int y)

Copyright 1996-2010 (c) by the authors and contributors of the JHotDraw project.
Some rights reserved.