public class MandelbrotSetPanel extends AbstractInteractionImageEffectPanel implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener, ISizingPanelListener
javax.swing.JPanel.AccessibleJPanel
javax.swing.JComponent.AccessibleJComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Constructor and Description |
---|
MandelbrotSetPanel()
Creates a
MandelbrotSetPanel object with the default settings for the Mandelbrot set effect. |
Modifier and Type | Method and Description |
---|---|
void |
applySizingChanges(SizingPanel pSizingPanel)
Applies the settings of the specified
SizingPanel to the effect. |
protected void |
drawInteraction(java.awt.Graphics2D pGraphics)
Draws the interaction graphics on top of the result image.
|
EffectParameters |
getEffectParameters()
Returns the
MandelbrotSetParameters object representing the effect parameters of this panel. |
MandelbrotSetParameters |
getMandelbrotSetParameters()
Returns the
MandelbrotSetParameters object representing the effect parameters of this panel. |
AbstractPropertiesPanel |
getPropertiesPanel()
Returns the
MandelbrotSetPropertiesPanel object representing the effect parameters and providing a GUI to modify them. |
void |
mouseClicked(java.awt.event.MouseEvent e)
If the mouse is double clicked the default Mandelbrot set is shown again.
|
void |
mouseDragged(java.awt.event.MouseEvent e)
Sets an end point for the zooming operation.
|
void |
mouseEntered(java.awt.event.MouseEvent e)
Not used at the moment.
|
void |
mouseExited(java.awt.event.MouseEvent e)
Not used at the moment.
|
void |
mouseMoved(java.awt.event.MouseEvent e)
Not used at the moment.
|
void |
mousePressed(java.awt.event.MouseEvent e)
Sets a start point for a zoom operation.
|
void |
mouseReleased(java.awt.event.MouseEvent e)
Realizes the zooming.
|
void |
setDefaultMandelbrotSet()
Sets the effect back to the default settings.
|
void |
setEffectParameters(EffectParameters pEffectParameters)
Sets the effect parameters for the
MandelbrotSet effect that is shown by this MandelbrotSetPanel object. |
void |
setEffectSize(int iWidth,
int iHeight)
Sets the size of the effect.
|
void |
setMandelbrotSetParameters(MandelbrotSetParameters pParameters)
Sets the effect parameters for the
MandelbrotSet effect that is shown by this MandelbrotSetPanel object. |
getEffectImage, getImageXOffset, getImageYOffset, paintComponent, setEffectImage
applyChanges, applyNewSettings
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
public MandelbrotSetPanel()
MandelbrotSetPanel
object with the default settings for the Mandelbrot set effect.public void setMandelbrotSetParameters(MandelbrotSetParameters pParameters)
MandelbrotSet
effect that is shown by this MandelbrotSetPanel
object.pParameters
- The MandelbrotSetParameters
object representing the Mandelbrot set effect parameters.public void setEffectParameters(EffectParameters pEffectParameters)
MandelbrotSet
effect that is shown by this MandelbrotSetPanel
object.
The set operation is only successful if a MandelbrotSetParameters
object has been specified.setEffectParameters
in class AbstractImageEffectPanel
pEffectParameters
- The MandelbrotSetParameters
object representing the Mandelbrot set effect parameters.public void setEffectSize(int iWidth, int iHeight)
setEffectSize
in class AbstractImageEffectPanel
iWidth
- The width in pixels of the effect image.iHeight
- The height in pixels of the effect image.public void setDefaultMandelbrotSet()
public MandelbrotSetParameters getMandelbrotSetParameters()
MandelbrotSetParameters
object representing the effect parameters of this panel.MandelbrotSetParameters
object representing the effect parameters of this panel.public EffectParameters getEffectParameters()
MandelbrotSetParameters
object representing the effect parameters of this panel.getEffectParameters
in class AbstractImageEffectPanel
MandelbrotSetParameters
object representing the effect parameters of this panel.public AbstractPropertiesPanel getPropertiesPanel()
MandelbrotSetPropertiesPanel
object representing the effect parameters and providing a GUI to modify them.getPropertiesPanel
in class AbstractImageEffectPanel
MandelbrotSetPropertiesPanel
object representing the effect parameters and providing a GUI to modify them.protected void drawInteraction(java.awt.Graphics2D pGraphics)
AbstractInteractionImageEffectPanel
drawInteraction
in class AbstractInteractionImageEffectPanel
pGraphics
- The graphics context that is used to perform the drawings.public void mouseClicked(java.awt.event.MouseEvent e)
mouseClicked
in interface java.awt.event.MouseListener
e
- The mouse event that triggers this method.public void mouseEntered(java.awt.event.MouseEvent e)
mouseEntered
in interface java.awt.event.MouseListener
e
- The mouse event that triggers this method.public void mouseExited(java.awt.event.MouseEvent e)
mouseExited
in interface java.awt.event.MouseListener
e
- The mouse event that triggers this method.public void mousePressed(java.awt.event.MouseEvent e)
mousePressed
in interface java.awt.event.MouseListener
e
- The mouse event that triggers this method.public void mouseReleased(java.awt.event.MouseEvent e)
mouseReleased
in interface java.awt.event.MouseListener
e
- The mouse event that triggers this method.public void mouseDragged(java.awt.event.MouseEvent e)
mouseDragged
in interface java.awt.event.MouseMotionListener
e
- The mouse event that triggers this method.public void mouseMoved(java.awt.event.MouseEvent e)
mouseMoved
in interface java.awt.event.MouseMotionListener
e
- The mouse event that triggers this method.public void applySizingChanges(SizingPanel pSizingPanel)
SizingPanel
to the effect.applySizingChanges
in interface ISizingPanelListener
pSizingPanel
- The SizingPanel
from which the size properties are taken.