ij.gui
Class ImageRoi
java.lang.Object
ij.gui.AbstractRoi
ij.gui.AttributeRoi
ij.gui.Roi
ij.gui.ImageRoi
- All Implemented Interfaces:
- RoiBeans, RoiConstance, java.io.Serializable, java.lang.Cloneable
public class ImageRoi
- extends Roi
An ImageRoi is an Roi that displays an image as an overlay.
- See Also:
ImagePlus.setOverlay(ij.gui.Overlay)
,
Serialized Form
Fields inherited from class ij.gui.Roi |
asp_bk, aspect, cachedMask, center, clipboard, clipHeight, clipHeightd, clipWidth, clipWidthd, clipX, clipXd, clipY, clipYd, constrain, defaultFillColor, handleColor, ic, imageID, instanceColor, lineWidth, mag, nonScalable, oldHeight, oldHeightd, oldWidth, oldWidthd, oldX, oldXd, oldY, oldYd, onePixelWide, overlay, pasteMode, previousRoi, roundRect, updateFullWindow |
Fields inherited from class ij.gui.AttributeRoi |
drawDoubleClick, fillColor, fillDoubleClick, imp, ROIColor, stroke, strokeColor, type, wideLine, xMax, yMax |
Fields inherited from interface ij.gui.RoiConstance |
ADD_TO_ROI, ANGLE, COMPOSITE, CONSTRUCTING, DRAW_HANDLE, EVT_HANDLE_SIZE, FILL_HANDLE, FREELINE, FREEROI, HANDLE_SIZE, LINE, MOVING, MOVING_HANDLE, MOVING_ROUNDRECT_HANDLE, NO_MODS, NORMAL, NOT_PASTING, OVAL, POINT, POLYGON, POLYLINE, RECTANGLE, RESIZING, SUBTRACT_FROM_ROI, TRACED_ROI |
Constructor Summary |
ImageRoi(int x,
int y,
java.awt.image.BufferedImage bi)
Creates a new ImageRoi from a BufferedImage. |
ImageRoi(int x,
int y,
ImageProcessor ip)
Creates a new ImageRoi from a ImageProcessor. |
Method Summary |
void |
draw(java.awt.Graphics g)
|
double |
getOpacity()
Returns the current opacity. |
void |
setComposite(java.awt.Composite composite)
Sets the composite mode. |
void |
setOpacity(double opacity)
Sets the composite mode using the specified opacity (alpha), in the
range 0.0-1.0, where 0.0 is fully transparent and 1.0 is fully opaque. |
Methods inherited from class ij.gui.Roi |
abortPaste, clipRectMargin, clone, contains, drawfillOverlay, drawHandle, drawOverlay, drawPixels, drawPixels, drawPixels, drawRoiHandle, drawStroke, endPaste, equals, fillRoiHandle, getBoundingRect, getBounds, getCornerDiameter, getCurrentPasteMode, getDrawOffset, getFloatBounds, getFloatPolygon, getHandleSize, getLength, getMagnification, getMask, getPasteMode, getPolygon, getPrototypeOverlay, getRoundRectArcSize, getScaledStroke, getState, getTypeAsString, grow, handleMouseDown, handleMouseDrag, handleMouseUp, isArea, isDrawingTool, isHandle, isLine, isVisible, mouseDownInHandle, moveHandle, nudge, nudgeCorner, screenX, screenXD, screenY, screenYD, setCornerDiameter, setDrawOffset, setImage, setInstanceColor, setLineWidth, setLocation, setNonScalable, setPasteMode, setPrototypeOverlay, setRoundRectArcSize, showStatus, startPaste, subPixelResolution, temporarilyHide, toFloat, toInt, toInt, toIntR, toString, update, updateClipRect, updateWideLine |
Methods inherited from class ij.gui.AttributeRoi |
copyAttributes, getAngle, getColor, getConvexHull, getCPosition, getDefaultFillColor, getFeretsDiameter, getFeretValues, getFillColor, getImage, getImageID, getName, getPosition, getStroke, getStrokeColor, getStrokeWidth, getTPosition, getType, getZPosition, setColor, setDefaultFillColor, setFillColor, setName, setPosition, setPosition, setStroke, setStrokeColor, setStrokeWidth, setStrokeWidth |
Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ImageRoi
public ImageRoi(int x,
int y,
java.awt.image.BufferedImage bi)
- Creates a new ImageRoi from a BufferedImage.
ImageRoi
public ImageRoi(int x,
int y,
ImageProcessor ip)
- Creates a new ImageRoi from a ImageProcessor.
draw
public void draw(java.awt.Graphics g)
- Specified by:
draw
in interface RoiBeans
- Overrides:
draw
in class Roi
setComposite
public void setComposite(java.awt.Composite composite)
- Sets the composite mode.
setOpacity
public void setOpacity(double opacity)
- Sets the composite mode using the specified opacity (alpha), in the
range 0.0-1.0, where 0.0 is fully transparent and 1.0 is fully opaque.
getOpacity
public double getOpacity()
- Returns the current opacity.