jwo.landserf.gui3d
Class SurfaceDetailBox
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Dialog
javax.swing.JDialog
jwo.utils.gui.JWDialogue
jwo.landserf.gui3d.SurfaceDetailBox
- All Implemented Interfaces:
- ActionListener, ItemListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, ChangeListener, RootPaneContainer, WindowConstants
public class SurfaceDetailBox
- extends JWDialogue
- implements ItemListener, ActionListener, ChangeListener
Allows surface detail texture to be controlled (texture to
use, level of transparency, size etc).
- Version:
- 2.3, 6th October, 2007.
- Author:
- Jo Wood
- See Also:
- Serialized Form
Constructor Summary |
SurfaceDetailBox(GUI3d gui3d)
Create a dialog allowing vector appearance to be changed. |
Method Summary |
void |
actionPerformed(ActionEvent event)
Responds to a button press by updating the relevant scale of drape. |
float |
getDetailSize()
Reports the size at which the the texture should be drawn in multiples
of the raster grid resolution. |
int |
getDetailType()
Reports the type of detail image used (for example USER_DEFINED, RIPPLES
or one of the other default types). |
Image |
getTextureImage()
Reports the image used for texture. |
float |
getTransparency()
Reports the transparency value selected. |
boolean |
isDrawDetail()
Reports if the detailed texture is drawn or not. |
boolean |
isFadeDetail()
Reports if the detailed texture is to fade with distance. |
void |
itemStateChanged(ItemEvent event)
Sets the clip and smooth state of the vector display. |
void |
stateChanged(ChangeEvent e)
Responds to a change in a slider by updating the relevant control. |
Methods inherited from class javax.swing.JDialog |
addImpl, createRootPane, dialogInit, getAccessibleContext, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update |
Methods inherited from class java.awt.Dialog |
addNotify, getTitle, hide, isModal, isResizable, isUndecorated, setModal, setResizable, setTitle, setUndecorated, show |
Methods inherited from class java.awt.Window |
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, finalize, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getMostRecentFocusOwner, getOwnedWindows, getOwner, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindowStateListeners, isActive, isAlwaysOnTop, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, setAlwaysOnTop, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setLocationByPlatform, setLocationRelativeTo, toBack, toFront |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, removeNotify, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, size, toString, transferFocus, transferFocusUpCycle |
RIPPLES
public static final int RIPPLES
- Ripple texture.
- See Also:
- Constant Field Values
STONES
public static final int STONES
- Stony texture.
- See Also:
- Constant Field Values
MARBLE
public static final int MARBLE
- Marbled texture.
- See Also:
- Constant Field Values
OPAQUE_GRID
public static final int OPAQUE_GRID
- Opaque grid.
- See Also:
- Constant Field Values
TRANSPARENT_GRID
public static final int TRANSPARENT_GRID
- Transparent grid.
- See Also:
- Constant Field Values
USER_DEFINED
public static final int USER_DEFINED
- User defined texture.
- See Also:
- Constant Field Values
NONE
public static final int NONE
- No surface detail defined.
- See Also:
- Constant Field Values
SurfaceDetailBox
public SurfaceDetailBox(GUI3d gui3d)
- Create a dialog allowing vector appearance to be changed.
- Parameters:
gui3d
- Parent GUI controlling 3d view.
getTransparency
public float getTransparency()
- Reports the transparency value selected.
- Returns:
- Transparency value.
getTextureImage
public Image getTextureImage()
- Reports the image used for texture.
- Returns:
- Texture image.
isDrawDetail
public boolean isDrawDetail()
- Reports if the detailed texture is drawn or not.
- Returns:
- True if detail is drawn.
isFadeDetail
public boolean isFadeDetail()
- Reports if the detailed texture is to fade with distance.
- Returns:
- True if detail is to fade with distance.
getDetailSize
public float getDetailSize()
- Reports the size at which the the texture should be drawn in multiples
of the raster grid resolution.
- Returns:
- Number of grid cells over which the texture should be drawn (can
be fractional).
getDetailType
public int getDetailType()
- Reports the type of detail image used (for example USER_DEFINED, RIPPLES
or one of the other default types).
- Returns:
- surface detail type.
actionPerformed
public void actionPerformed(ActionEvent event)
- Responds to a button press by updating the relevant scale of drape.
- Specified by:
actionPerformed
in interface ActionListener
- Parameters:
event
- Button press event.
itemStateChanged
public void itemStateChanged(ItemEvent event)
- Sets the clip and smooth state of the vector display.
- Specified by:
itemStateChanged
in interface ItemListener
- Parameters:
event
- Checkbox item that has changed.
stateChanged
public void stateChanged(ChangeEvent e)
- Responds to a change in a slider by updating the relevant control.
- Specified by:
stateChanged
in interface ChangeListener
- Parameters:
e
- Slider change event.
Copyright Jo Wood, 1996-2009, last modified, 17th April, 2009