|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--javax.swing.JComponent | +--com.vistech.jai.render.JAIImageCanvas | +--com.vistech.jai.render.RenderedImageCanvas | +--com.vistech.jai.render.ImageManipulatorCanvas
A component class for displaying and manipulating rendered images.
Inner classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent |
Field Summary | |
protected java.awt.Image |
awtImage
|
protected double |
diffFactor
|
protected int |
displayMode
|
protected int |
flipMode
|
protected int |
imageType
|
protected int |
interpMode
|
protected int |
magCenterX
|
protected int |
magCenterY
|
protected double |
magFactor
|
protected boolean |
magOn
|
protected java.awt.Point |
panOffset
|
protected boolean |
rotateOn
|
protected double |
rotationAngle
|
protected int |
rotationCenterX
|
protected int |
rotationCenterY
|
protected double |
shearFactor
|
protected boolean |
shearOn
|
protected double |
shearX
|
protected double |
shearY
|
Fields inherited from class com.vistech.jai.render.RenderedImageCanvas |
colorModel, displayImage, imageHeight, imageWidth, maxTileCordX, maxTileCordY, maxTileIndexX, maxTileIndexY, minTileCordX, minTileCordY, minTileIndexX, minTileIndexY, origImage, sampleModel, tc, tileGridXOffset, tileGridYOffset, tileHeight, tileWidth, viewerHeight, viewerWidth |
Fields inherited from class com.vistech.jai.render.JAIImageCanvas |
atx, height, image, imageDrawn, MAX_HEIGHT, MAX_WIDTH, panX, panY, scrollAnchor, scrollOn, vpPos, width |
Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface com.vistech.imageviewer.ImageDisplay |
TYPE_AWT_IMAGE, TYPE_BUFFERED_IMAGE |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
ImageManipulatorCanvas()
|
Method Summary | |
void |
applyTransform(java.awt.geom.AffineTransform atx)
Applies the transform |
protected void |
applyTransform(java.awt.image.RenderedImage ri,
java.awt.geom.AffineTransform atx)
|
void |
createTiledImage(javax.media.jai.PlanarImage img)
|
void |
draw(java.awt.Shape shape)
Draws the specified shape on the destination image |
java.awt.Image |
getAWTImage()
Returns the image property. |
java.awt.image.BufferedImage |
getBufferedImage()
Returns the BufferedImage property. |
java.awt.image.BufferedImage |
getDisplayedImage()
Returns the image displayed on the canvas. |
int |
getDisplayMode()
Returns the display mode. |
int |
getFlipMode()
Returns the flip mode. |
javax.media.jai.PlanarImage |
getImage()
|
java.awt.Dimension |
getImageSize()
Returns the image size. |
int |
getImageType()
Returns the image type property. |
int |
getInterpolationType()
|
boolean |
getInvert()
Returns the invert mode. |
double |
getMagFactor()
Gets the magFactor property. |
java.awt.image.BufferedImage |
getOffScreenImage()
Returns the off screen image. |
double |
getRotationAngle()
Gets the rotation angle property. |
double |
getShearFactor()
|
double |
getShearFactorX()
|
double |
getShearFactorY()
|
void |
invert(boolean on)
|
void |
paintComponent(java.awt.Graphics gc)
Paints the tiles that are visible. |
boolean |
paintImage()
This method paints the current image i.e.; the image set by the setImage() method. |
void |
paintImage(int magCenterX,
int magCenterY,
double mag)
|
void |
resetManipulation()
Resets manipulation. |
void |
setAWTImage(java.awt.Image image)
Sets the image property. |
void |
setBufferedImage(java.awt.image.BufferedImage image)
Sets the BufferedImage property. |
void |
setClip(java.awt.Shape clip)
Sets the clip shape on the destination image |
void |
setDisplayImage(java.awt.image.BufferedImage image)
Sets the image to be displayed on the canvas. |
void |
setDisplayMode(int mode)
Sets the display mode. |
void |
setFlipMode(int mode)
Sets the flip mode. |
void |
setImageType(int imageType)
Sets the image type property. |
void |
setInterpolationType(int mode)
Sets the interpolationType property. |
void |
setInvert(boolean on)
Sets the invert mode property. |
void |
setMagFactor(double magFactor)
Sets the magFactor property. |
void |
setOffScreenImage(java.awt.image.BufferedImage image)
Sets the off screen image. |
void |
setRotationAngle(double rotationAngle)
Sets the rotationAngle property. |
void |
setShearFactor(double shearFactor)
Sets the shearFactor property. |
Methods inherited from class com.vistech.jai.render.RenderedImageCanvas |
fireTilePropertyChange, getDisplayImage, getImageHeight, getImageWidth, getMaxTileIndexX, getMaxTileIndexY, getTileHeight, getTileInfo, getTileWidth, makeTiledImage, setImage, setTileHeight, setTileWidth |
Methods inherited from class com.vistech.jai.render.JAIImageCanvas |
getPanOffset, getScrollOn, getTransform, getViewportPosition, isImageDrawn, pan, reset, scroll, setPanOffset, setScrollOn, setTransform, setViewportPosition, startScroll, stopScroll |
Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getUIClassID, getVerifyInputWhenFocusTarget, getVisibleRect, getWidth, getX, getY, grabFocus, hasFocus, hide, isDoubleBuffered, isFocusCycleRoot, isFocusTraversable, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processFocusEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getLayout, insets, invalidate, isAncestorOf, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setLayout, validate, validateTree |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getInputContext, getInputMethodRequests, getLocale, getLocation, getLocationOnScreen, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, imageUpdate, inside, isDisplayable, isEnabled, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.vistech.imageviewer.ImageManipulator |
getPanOffset, getTransform, setPanOffset, setTransform |
Methods inherited from interface com.vistech.imageviewer.ImageDisplay |
addMouseListener, addMouseMotionListener, addPropertyChangeListener, addVetoableChangeListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removeVetoableChangeListener, setCursor |
Field Detail |
protected transient java.awt.Image awtImage
protected int imageType
protected java.awt.Point panOffset
protected boolean magOn
protected double magFactor
protected int magCenterX
protected int magCenterY
protected double rotationAngle
protected boolean rotateOn
protected int rotationCenterX
protected int rotationCenterY
protected boolean shearOn
protected double shearFactor
protected double shearX
protected double shearY
protected int displayMode
protected int flipMode
protected int interpMode
protected double diffFactor
Constructor Detail |
public ImageManipulatorCanvas()
Method Detail |
public javax.media.jai.PlanarImage getImage()
getImage
in class JAIImageCanvas
public java.awt.Dimension getImageSize()
ImageDisplay
getImageSize
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setInterpolationType(int mode)
ImageManipulator
setInterpolationType
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
the
- interpolation typepublic int getInterpolationType()
getInterpolationType
in interface ImageManipulator
public void setDisplayMode(int mode)
ImageDisplay
setDisplayMode
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
dispMode
- the display modepublic int getDisplayMode()
ImageDisplay
getDisplayMode
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setFlipMode(int mode)
ImageDisplay
setFlipMode
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
flipMode
- the flip modepublic int getFlipMode()
ImageDisplay
getFlipMode
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setMagFactor(double magFactor)
ImageManipulator
setMagFactor
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
magFactor
- the magnification factor.public double getMagFactor()
ImageManipulator
getMagFactor
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
public void setShearFactor(double shearFactor)
ImageManipulator
setShearFactor
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
shearFactor
- the shearFactor property.public double getShearFactor()
getShearFactor
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
public double getShearFactorX()
public double getShearFactorY()
public void setRotationAngle(double rotationAngle)
ImageManipulator
setRotationAngle
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
rotationAngle
- the rotation anglepublic double getRotationAngle()
ImageManipulator
getRotationAngle
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
public void paintImage(int magCenterX, int magCenterY, double mag)
protected void applyTransform(java.awt.image.RenderedImage ri, java.awt.geom.AffineTransform atx)
public void applyTransform(java.awt.geom.AffineTransform atx)
ImageManipulator
applyTransform
in interface ImageManipulator
com.vistech.imageviewer.ImageManipulator
the
- transform.public void createTiledImage(javax.media.jai.PlanarImage img)
public void resetManipulation()
ImageManipulator
resetManipulation
in interface ImageManipulator
public void paintComponent(java.awt.Graphics gc)
RenderedImageCanvas
paintComponent
in class RenderedImageCanvas
com.vistech.jai.render.RenderedImageCanvas
gc
- the graphics context.public void setAWTImage(java.awt.Image image)
ImageDisplay
setAWTImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
image
- the image objectpublic java.awt.Image getAWTImage()
ImageDisplay
getAWTImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setImageType(int imageType)
ImageDisplay
setImageType
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
imageType
- the image type.public int getImageType()
ImageDisplay
getImageType
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setClip(java.awt.Shape clip)
ImageDisplay
setClip
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
clipshape
- the shape of the clipping areapublic void setBufferedImage(java.awt.image.BufferedImage image)
ImageDisplay
setBufferedImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
BufferedImage
- the image objectpublic java.awt.image.BufferedImage getBufferedImage()
ImageDisplay
getBufferedImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setOffScreenImage(java.awt.image.BufferedImage image)
ImageDisplay
setOffScreenImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
image
- the off screen image.public java.awt.image.BufferedImage getOffScreenImage()
ImageDisplay
getOffScreenImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void setDisplayImage(java.awt.image.BufferedImage image)
ImageDisplay
setDisplayImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
image
- the image to be displayed.public java.awt.image.BufferedImage getDisplayedImage()
ImageDisplay
getDisplayedImage
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public void draw(java.awt.Shape shape)
ImageDisplay
draw
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
shape
- the shape to be drawnpublic void invert(boolean on)
public void setInvert(boolean on)
ImageDisplay
setInvert
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
onOrOff
- the invert mode.public boolean getInvert()
ImageDisplay
getInvert
in interface ImageDisplay
com.vistech.imageviewer.ImageDisplay
public boolean paintImage()
ImageDisplay
paintImage
in interface ImageDisplay
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |