public class MaskData extends ShapeData
READONLY_FLAG, settings| Constructor and Description |
|---|
MaskData()
Creates a new instance of MaskData.
|
MaskData(double x,
double y,
double width,
double height,
byte[] mask)
Creates a new instance of the MaskData.
|
MaskData(omero.model.Shape shape)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
byte |
getBit(byte[] data,
int bit)
Sets the bit value in a byte array at position bit to be the value
value.
|
double |
getHeight()
Returns the height of the mask.
|
ImageData |
getImage()
Get the image this masks belongs to
|
byte[] |
getMask()
Returns the mask as a byte array.
|
int[][] |
getMaskAsBinaryArray()
Returns the mask image.
|
java.awt.image.BufferedImage |
getMaskAsBufferedImage()
Returns the mask image.
|
java.lang.String |
getText()
Returns the text of the shape.
|
double |
getWidth()
Returns the width of the mask.
|
double |
getX()
Returns the x-coordinate of the top-left corner of the mask.
|
double |
getY()
Returns the y-coordinate of the top-left corner of the mask.
|
void |
setBit(byte[] data,
int bit,
int val)
Sets the bit value in a byte array at position bit to be the value
value.
|
void |
setHeight(double height)
Sets the height of an untransformed mask.
|
void |
setImage(ImageData image)
Set the image this masks belongs to
|
void |
setMask(boolean[] mask)
Set the mask
|
void |
setMask(boolean[][] mask)
Set the mask
|
void |
setMask(java.awt.image.BufferedImage image)
Sets the mask from the bufferedImage.
|
void |
setMask(byte[] mask)
Sets the mask image.
|
void |
setMask(int[] mask)
Set the mask
|
void |
setMask(int[][] mask)
Set the mask
|
void |
setText(java.lang.String text)
Sets the text of the shape.
|
void |
setWidth(double width)
Sets the width of an untransformed mask.
|
void |
setX(double x)
Sets the x-coordinate top-left corner of an untransformed mask.
|
void |
setY(double y)
Sets the y-coordinate top-left corner of an untransformed mask.
|
java.lang.String |
toString()
Overridden to return the name of the class and the object id.
|
fromPoints, getC, getROICoordinate, getShapeSettings, getT, getTransform, getZ, isClientObject, isReadOnly, parsePointsToIntegerList, parsePointsToPoint2DList, setC, setClientObject, setDirty, setReadOnly, setROICoordinate, setShapeSettings, setT, setTransform, setZ, toNumber, toPointsasAnnotation, asChannel, asDataset, asExperimenter, asFolder, asGroup, asIAnnotated, asImage, asIObject, asPixels, asPlaneInfo, asPlate, asPojo, asPojos, asPojos, asProject, asScreen, asWell, asWellSample, canAnnotate, canChgrp, canChown, canDelete, canEdit, canLink, getCreated, getDetails, getGroupId, getId, getOwner, getPermissions, getUpdated, getVersion, isDirty, isLoaded, nullDetails, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, setId, setValue, setVersion, timeOfEventpublic MaskData(omero.model.Shape shape)
shape - The shape this object represents.public MaskData()
public MaskData(double x,
double y,
double width,
double height,
byte[] mask)
x - The x-coordinate of the top-left corner of the image.y - The y-coordinate of the top-left corner of the image.width - The width of the image.height - The height of the image.mask - The mask image.public java.lang.String getText()
public void setText(java.lang.String text)
text - See above.public double getX()
public void setX(double x)
x - The value to set.public double getY()
public void setY(double y)
y - See above.public double getWidth()
public void setWidth(double width)
width - See above.public double getHeight()
public void setHeight(double height)
height - See above.public void setMask(byte[] mask)
mask - See above.public void setMask(java.awt.image.BufferedImage image)
image - See above.public java.awt.image.BufferedImage getMaskAsBufferedImage()
public int[][] getMaskAsBinaryArray()
public byte[] getMask()
public void setBit(byte[] data,
int bit,
int val)
data - See above.bit - See above.val - See above.public byte getBit(byte[] data,
int bit)
data - See above.bit - See above.public void setMask(int[] mask)
mask - The binary maskpublic void setMask(int[][] mask)
mask - The binary mask (int[width][height])public void setMask(boolean[] mask)
mask - The binary maskpublic void setMask(boolean[][] mask)
mask - The binary mask (boolean[width][height])public ImageData getImage()
public void setImage(ImageData image)
image - The imagepublic java.lang.String toString()
DataObjecttoString in class DataObjectObject.toString()