|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Canvas
|
+--DrawArea
The DrawArea class the part of the Lissa application
draws the Lissajous figures.
It works as an animator with double buffering.
| Inner classes inherited from class java.awt.Canvas |
java.awt.Canvas.AccessibleAWTCanvas |
| Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.AWTTreeLock |
| Field Summary | |
(package private) static int |
dx
|
(package private) static int |
dy
|
(package private) static int |
ldx
|
(package private) static int |
ldy
|
(package private) static int |
maxDelta
|
| Fields inherited from class java.awt.Component |
accessibleContext, actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, componentListener, componentListenerK, componentOrientation, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, graphicsConfig, hasFocus, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowListenerK, x, y |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
DrawArea(java.awt.Dimension daSize,
DebugArea da)
Constructs a new DrawArea and sets its
initial values to their defaults. |
|
| Method Summary | |
Pix |
getAmp()
Returns amplitude values. |
Pix |
getFreq()
Returns frequency values. |
Pix |
getPhase()
Returns phase values. |
void |
paint(java.awt.Graphics g)
Painting function. |
void |
reset()
Reset the drawing with initial time constant. |
void |
reset(double i)
Reset the drawing with given time constant. |
void |
run()
Animator run function. |
void |
setAmp(double a1,
double a2)
Set amplitudes according to two given double values. |
void |
setAmp(Pix amp)
Set amplitudes according to given Pix |
void |
setFreq(double f1,
double f2)
Set frequencies according to two given double values. |
void |
setFreq(Pix freq)
Set frequencies according to given Pix |
void |
setINC()
Set time constant to its initial value. |
void |
setINC(double i)
Set time constant. |
void |
setPhase(double p1,
double p2)
Set phases according to two given double values. |
void |
setPhase(Pix phase)
Set phases according to given Pix |
void |
setSize(java.awt.Dimension daSize)
Set size of this DrawArea |
void |
start()
Animator start function. |
void |
stop()
Animator stop function. |
java.lang.String |
toString()
Returns a String that represents the state of this DrawArea. |
void |
update(java.awt.Graphics g)
Update override. |
| Methods inherited from class java.awt.Canvas |
|
| Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, areInputMethodsEnabled, bounds, checkGD, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createChildHierarchyEvents, createHierarchyEvents, createImage, createImage, deliverEvent, disable, disableEvents, dispatchEvent, dispatchEventImpl, doLayout, enable, enable, enableEvents, enableInputMethods, eventEnabled, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getAlignmentX, getAlignmentY, getBackground, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getMaximumSize, getMinimumSize, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getPreferredSize, getSize, getSize, getToolkit, getToolkitImpl, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isShowing, isValid, isVisible, keyDown, keyUp, layout, lightweightPaint, lightweightPrint, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, numListening, paintAll, paintHeavyweightComponents, paramString, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, printHeavyweightComponents, processComponentEvent, processEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, resetGC, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFont, setForeground, setLocale, setLocation, setLocation, setName, setSize, setVisible, show, show, size, transferFocus, validate |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
static int ldx
static int ldy
static int dx
static int dy
static int maxDelta
| Constructor Detail |
public DrawArea(java.awt.Dimension daSize,
DebugArea da)
DrawArea and sets its
initial values to their defaults.daSize - initial size of drawing areada - DebugArea used to output debug information,
should be set up by parent object| Method Detail |
public void setFreq(Pix freq)
Pixfreq - Pix containing new frequency values
public void setFreq(double f1,
double f2)
f1 - new x-axis frequency valuef2 - new y-axis frequency valuepublic void setPhase(Pix phase)
Pixphase - Pix containing new phase values
public void setPhase(double p1,
double p2)
p1 - new x-axis phase valuep2 - new y-axis phase valuepublic void setAmp(Pix amp)
Pixamp - Pix containing new amplitude values
public void setAmp(double a1,
double a2)
a1 - new x-axis amplitude valuea2 - new y-axis amplitude valuepublic Pix getFreq()
public Pix getPhase()
public Pix getAmp()
public void setSize(java.awt.Dimension daSize)
DrawAreasetSize in class java.awt.ComponentdaSize - new DrawArea sizepublic void reset()
public void reset(double i)
i - new time constantpublic void setINC(double i)
i - new time constantpublic void setINC()
public void update(java.awt.Graphics g)
update in class java.awt.Componentpublic void paint(java.awt.Graphics g)
paint in class java.awt.Canvaspublic void stop()
public void start()
public void run()
run in interface java.lang.Runnablepublic java.lang.String toString()
String that represents the state of this DrawArea.toString in class java.awt.ComponentDrawArea state
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||