public class DataSampling extends ImageTransform
Modifier and Type | Field and Description |
---|---|
protected SamplingWidget |
controls
Controls for this data sampling.
|
protected int[] |
max
Maximum index value for each dimension.
|
protected int[] |
min
Minimum index value for each dimension.
|
protected int |
numRange
Range component count for each image.
|
protected boolean[] |
range
List of included range components.
|
protected int |
resX
Width of each image.
|
protected int |
resY
Height of each image.
|
protected int[] |
step
Index step value for each dimension.
|
MICRON, micronHeight, micronStep, micronWidth, xType, yType, zType
Constructor and Description |
---|
DataSampling()
Creates an uninitialized data sampling.
|
DataSampling(DataTransform parent,
String name,
int[] min,
int[] max,
int[] step,
int resX,
int resY,
boolean[] range)
Creates a data sampling from the given transform.
|
Modifier and Type | Method and Description |
---|---|
String |
getCacheId(int[] pos,
boolean global)
Gets a string id uniquely describing this data transform at the given
dimensional position, for the purposes of thumbnail caching.
|
JComponent |
getControls()
Gets associated GUI controls for this transform.
|
String |
getHTMLDescription()
Gets a description of this transform, with HTML markup.
|
BufferedImage |
getImage(int[] pos)
Obtains an image from the source(s) at the given dimensional position.
|
int |
getImageHeight()
Gets height of each image.
|
int |
getImageWidth()
Gets width of each image.
|
int[] |
getMax()
Gets maximum dimensional index values.
|
double |
getMicronStep(int axis)
Gets the physical distance between image planes in microns for the given
axis.
|
int[] |
getMin()
Gets minimum dimensional index values.
|
boolean[] |
getRange()
Gets included range components.
|
int |
getRangeCount()
Gets number of range components at each pixel.
|
int[] |
getStep()
Gets dimensional index step values.
|
void |
initState(Dynamic dyn)
Modifies this object's state to match that of the given object.
|
boolean |
isCompatible(Dynamic dyn)
Tests whether the given dynamic object can be used as an argument to
initState, for initializing this dynamic object.
|
static boolean |
isParentRequired()
Indicates whether this transform type requires a parent transform.
|
boolean |
isValidDimension(int dim)
Gets whether this transform provides data of the given dimensionality.
|
static boolean |
isValidParent(DataTransform data)
Indicates whether this transform type would accept the given transform as
its parent transform.
|
protected void |
makeLabels()
Creates labels based on data transform parameters.
|
static DataTransform |
makeTransform(DataManager dm)
Creates a new data sampling, with user interaction.
|
boolean |
matches(Dynamic dyn)
Tests whether two dynamic objects are equivalent.
|
void |
restoreState(Element el)
Restores the current state from the given DOM element ("DataSampling").
|
void |
saveState(Element el)
Writes the current state to the given DOM element ("DataTransforms").
|
void |
setParameters(int[] min,
int[] max,
int[] step,
int resX,
int resY,
boolean[] range)
Assigns the parameters for this data sampling.
|
canDisplay3D, getData, getImageUnits, getMicronHeight, getMicronStep, getMicronWidth, getRangeTypes, getSuggestedMaps, getType, getXType, getYType, getZType, getZUnit, isImmediate
addTransformListener, canDisplay2D, discard, displayChanged, getDimTypes, getFont, getLabels, getLengths, getName, getParent, getThumbHandler, getTransformId, getUnitDescription, notifyListeners, removeTransformListener, setFont, toString
protected int[] min
protected int[] max
protected int[] step
protected int resX
protected int resY
protected boolean[] range
protected int numRange
protected SamplingWidget controls
public DataSampling()
public DataSampling(DataTransform parent, String name, int[] min, int[] max, int[] step, int resX, int resY, boolean[] range)
public void setParameters(int[] min, int[] max, int[] step, int resX, int resY, boolean[] range)
public int[] getMin()
public int[] getMax()
public int[] getStep()
public boolean[] getRange()
public int getImageWidth()
getImageWidth
in class ImageTransform
public int getImageHeight()
getImageHeight
in class ImageTransform
public int getRangeCount()
getRangeCount
in class ImageTransform
public BufferedImage getImage(int[] pos)
getImage
in class ImageTransform
public double getMicronStep(int axis)
getMicronStep
in class ImageTransform
public static DataTransform makeTransform(DataManager dm)
public static boolean isValidParent(DataTransform data)
public static boolean isParentRequired()
public boolean isValidDimension(int dim)
isValidDimension
in class DataTransform
public String getCacheId(int[] pos, boolean global)
getCacheId
in class DataTransform
public JComponent getControls()
getControls
in class DataTransform
public String getHTMLDescription()
getHTMLDescription
in class ImageTransform
protected void makeLabels()
makeLabels
in class DataTransform
public boolean matches(Dynamic dyn)
matches
in interface Dynamic
matches
in class DataTransform
public boolean isCompatible(Dynamic dyn)
isCompatible
in interface Dynamic
isCompatible
in class DataTransform
public void initState(Dynamic dyn)
initState
in interface Dynamic
initState
in class DataTransform
public void saveState(Element el) throws SaveException
saveState
in interface Saveable
saveState
in class ImageTransform
SaveException
public void restoreState(Element el) throws SaveException
restoreState
in interface Saveable
restoreState
in class ImageTransform
SaveException
Copyright © 2015–2022 SciJava. All rights reserved.