Class ColorWheel

java.lang.Object
java.awt.Component
java.awt.Canvas
gov.nih.mipav.view.ColorWheel
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class ColorWheel extends Canvas
Author:
pandyan This is the Color Wheel class for the DTI Color Display Plugin References: Developed in concert with Sinisa Pajevic from the NIH/CIT/DCB/MSCL group, Lin-Ching Chang D.Sc., Carlo Pierpaoli MD Ph.D., and Lindsay Walker MS from the the NIH/NICHD/LIMB/STBB group and Olga Vogt from the NIH/CIT/DCB/ISL/BIRSS group: Mathematical and Statistical Computing Laboratory (MSCL) Biomedical Imaging Research Services Section (BIRSS) Imaging Sciences Laboratory (ISL) Division of Cumputational Bioscience (DCB) Center for Informational Technology (CIT) Section on Tissue Biophysics and Biomimetics (STBB) Laboratory of Integrative and Medical Biophysics (LIMB) National Institute of Child Health invalid input: '&' Humann Development National Institutes of Health Publication Reference: S. Pajevic and C. Pierpaoli, "Color Schemes to Represent the Orientation of Anisotropic Tissues from Diffusion Tensor Data: Application to White Matter Fiber Tract Mapping in the Human Brain," Magnetic Resonance in Medicine, vol. 42, no. 3, pp. 526-540, 1999
See Also:
  • Field Details

    • offImage

      private Image offImage
      offscreen image
    • offGraphics

      private Graphics offGraphics
      offscreen graphics handle
    • r1

      private int r1
      radii of all the circles...r6 is the outermost radius
    • r2

      private int r2
      radii of all the circles...r6 is the outermost radius
    • r3

      private int r3
      radii of all the circles...r6 is the outermost radius
    • r4

      private int r4
      radii of all the circles...r6 is the outermost radius
    • r5

      private int r5
      radii of all the circles...r6 is the outermost radius
    • r6

      private int r6
      radii of all the circles...r6 is the outermost radius
    • type

      private String type
      type of color wheel ABSVAL, NOSYMM, ROTATIONALSYMM, MIRRORSYMM
    • pS

      private float pS
      sat vs theta
    • pC

      private float pC
      color range
    • pB

      private float pB
      blue saturation
    • gamma

      private float gamma
      gamma correction
    • pG

      private float pG
      green adj
    • stevensBeta

      private float stevensBeta
      Stevens Beta
    • blueShiftColors

      private float[] blueShiftColors
      array of r,g,b values after blue shifting
    • redShiftColors

      private float[] redShiftColors
      array of r,g,b values after red shifting
    • greenAdjColors

      private float[] greenAdjColors
      array of r,g,b values after green adj
  • Constructor Details

    • ColorWheel

      public ColorWheel(String initialType, int radius)
      constructor
      Parameters:
      radius -
      type -
  • Method Details

    • paint

      public void paint(Graphics g)
      paint method
      Overrides:
      paint in class Canvas
    • calculateRadii

      public void calculateRadii()
      calculates radii of the interior circles using Lambertian equal areas equation used: r = 2 |sin(theta/2)|
    • paintAbsValColorWheel

      public void paintAbsValColorWheel()
      Paints the Absolute Value Color Wheel
    • paintNoSymmColorWheel

      public void paintNoSymmColorWheel()
      Paints the No Symmetry Color Wheel
    • paintRotationalSymmColorWheel

      public void paintRotationalSymmColorWheel()
      Paints the Rotational Symmetry Color Wheel
    • paintMirrorSymmColorWheel

      public void paintMirrorSymmColorWheel()
      Paints the Mirror Symmetry Color Wheel
    • shiftBlue

      public float[] shiftBlue(float r1, float g1, float b1)
      blue shift
      Parameters:
      r1 -
      g1 -
      b1 -
      Returns:
    • shiftRed

      public float[] shiftRed(float r1, float g1, float b1)
      red shift
      Parameters:
      r1 -
      g1 -
      b1 -
      Returns:
    • adjustGreen

      public float[] adjustGreen(float r1, float g1, float b1)
      adjust green intensity
      Parameters:
      r1 -
      g1 -
      b1 -
      Returns:
    • update

      public void update(Graphics g)
      Calls paint without erasing background - this reduces flicker!
      Overrides:
      update in class Canvas
      Parameters:
      g - Graphics handle
    • setGamma

      public void setGamma(float gamma)
    • setPB

      public void setPB(float pb)
    • setPC

      public void setPC(float pc)
    • setPG

      public void setPG(float pg)
    • setPS

      public void setPS(float ps)
    • setStevensBeta

      public void setStevensBeta(float stevensBeta)
    • setType

      public void setType(String type)
    • getType

      public String getType()