|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.Observable
cdox.util.image.CorrectorSlider
This class is the superclass of all the imageCorrection-classes. At the Time of this writing there are five implementing subclasses:
getSliderPane()
,
Brightness
,
Contrast
,
GammaCorrection
,
Sharpen
,
Blur
Field Summary | |
protected javax.swing.JSlider |
corSlider
The slider which sets the value |
protected ImageCorrector |
imageCorrector
The current filterClass. |
protected java.awt.Component |
obs
The Observer to be called when the slider is dragged. |
protected javax.swing.JPanel |
sliderPane
The panel containing the slider |
protected float |
value
The value used in the filter method |
Constructor Summary | |
protected |
CorrectorSlider(float val)
Constructs a CorrectorSlider without the JSlider. |
protected |
CorrectorSlider(java.util.Observer obs,
java.lang.String paneTitle,
int minValue,
int maxValue,
int startValue,
int spacing,
int labelSpacing,
boolean grid)
Constructs a new CorrectorSlider with the JSlider which is used to set the value to be used in the sub-classes-filter method. |
Method Summary | |
protected java.awt.image.BufferedImage |
getRedrawnImage(java.awt.image.BufferedImage bi)
This method draws the given BufferedImage on a new BufferedImage and returns it. |
javax.swing.JPanel |
getSliderPane()
Returns the container containing the JSlider which can be added to your Dialog, JFrame or every other container. |
int |
getValue()
Returns the current value with which the current filter is working. |
void |
setValue(float val)
This method is used to set the value which is used in the current filter, you should use this method, if you have chosen to define your own JSlider-classes. |
void |
stateChanged(javax.swing.event.ChangeEvent ce)
Called when the JSlider has been moved. |
Methods inherited from class java.util.Observable |
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface cdox.util.image.ImageCorrector |
filter |
Field Detail |
protected javax.swing.JSlider corSlider
protected javax.swing.JPanel sliderPane
protected float value
protected ImageCorrector imageCorrector
protected java.awt.Component obs
Constructor Detail |
protected CorrectorSlider(float val)
val
- The initialization value used in the filter of the subclasses.getRedrawnImage(java.awt.image.BufferedImage)
protected CorrectorSlider(java.util.Observer obs, java.lang.String paneTitle, int minValue, int maxValue, int startValue, int spacing, int labelSpacing, boolean grid)
obs
- the Observer to be notified when the JSlider has been moved,paneTitle
- the title of the titledBorder of the container containing the JSlider,minValue
- the minimum value of the JSlider,maxValue
- the maximum Value of the JSlider,startValue
- the start value of the JSlider,spacing
- the value between the spacings drawn on the JSlider,labelSpacing
- the value between the spacing to draw a text,grid
- true if snaptogrid false otherwhise.stateChanged(javax.swing.event.ChangeEvent)
Method Detail |
public void stateChanged(javax.swing.event.ChangeEvent ce)
stateChanged
in interface javax.swing.event.ChangeListener
ce
- the ChangeEvent representing a movement of the JSlider.public javax.swing.JPanel getSliderPane()
public int getValue()
getValue
in interface ImageCorrector
public void setValue(float val)
val
- the value to set the filters-working-value.protected java.awt.image.BufferedImage getRedrawnImage(java.awt.image.BufferedImage bi)
bi
- the BufferedImage to be redrawn,
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |