public class MorphologicalSegmentation extends Object implements ij.plugin.PlugIn
Modifier and Type | Class and Description |
---|---|
static class |
MorphologicalSegmentation.ResultMode
enumeration of result modes
|
Modifier and Type | Field and Description |
---|---|
static String |
CREATE_IMAGE
name of the macro method to show current segmentation result in a new window
|
static String |
MERGE_LABELS
name of the macro method to merge selected labels
|
static String |
RUN_SEGMENTATION
name of the macro method to segment the
current image based on the current parameters
|
static String |
SET_DISPLAY
name of the macro method to set the output display format
|
static String |
SET_GRADIENT_TYPE
name of the macro method to set the gradient method
|
static String |
SET_INPUT_TYPE
name of the macro method to set the input image type
|
static String |
SET_RADIUS
name of the macro method to set the gradient radius
|
static String |
SHOW_GRADIENT
name of the macro method to set the flag to show the gradient image
|
static String |
SHOW_RESULT_OVERLAY
name of the macro method to toggle the current overlay
|
static String |
SHUFFLE_COLORS
name of the macro method to shuffle color labels
|
Constructor and Description |
---|
MorphologicalSegmentation() |
Modifier and Type | Method and Description |
---|---|
static void |
createResultImage()
Show current result in a new image
|
static void |
mergeLabels()
Merge labels that are selected either by a freehand or a point ROI.
|
static void |
record(String command,
String... args)
Macro-record a specific command.
|
void |
run(String arg0) |
static void |
segment(String dynamic,
String calculateDams,
String connectivity)
Segment current image (GUI needs to be running)
|
static void |
segment(String dynamic,
String calculateDams,
String connectivity,
String usePriorityQueue)
Deprecated.
the priority queue method is now the only one
|
static void |
setDisplayFormat(String format)
Set the display format in the GUI
|
static void |
setGradientRadius(String radius)
Set the gradient radius
|
static void |
setGradientType(String method)
Set the gradient method to use
|
static void |
setInputImageType(String type)
Set input image type
|
static void |
setShowGradient(String bool)
Set GUI to show gradient image in the main canvas
|
static void |
shuffleColors()
Shuffle LUT of current display image.
|
static void |
toggleOverlay()
Toggle current result overlay image
|
public static String RUN_SEGMENTATION
public static String SHOW_RESULT_OVERLAY
public static String CREATE_IMAGE
public static String SET_INPUT_TYPE
public static String SHOW_GRADIENT
public static String SET_DISPLAY
public static String SET_RADIUS
public static String SET_GRADIENT_TYPE
public static String MERGE_LABELS
public static String SHUFFLE_COLORS
public void run(String arg0)
run
in interface ij.plugin.PlugIn
public static void record(String command, String... args)
command
- name of the command including package infoargs
- set of arguments for the commandpublic static void segment(String dynamic, String calculateDams, String connectivity, String usePriorityQueue)
dynamic
- string containing dynamic value (format: "dynamic=[integer value]")calculateDams
- string containing boolean flag to create dams (format: "calculateDams=[boolean])connectivity
- string containing connectivity value (format: "connectivity=[4 or 8 / 6 or 26])usePriorityQueue
- string containing boolean flag to use priority queue (format: "usePriorityQueue=[boolean])public static void segment(String dynamic, String calculateDams, String connectivity)
dynamic
- string containing dynamic value (format: "dynamic=[integer value]")calculateDams
- string containing boolean flag to create dams (format: "calculateDams=[boolean])connectivity
- string containing connectivity value (format: "connectivity=[4 or 8 / 6 or 26])public static void toggleOverlay()
public static void mergeLabels()
public static void shuffleColors()
public static void createResultImage()
public static void setInputImageType(String type)
type
- input image type (border or object)public static void setShowGradient(String bool)
bool
- true to display gradient image and false to display input imagepublic static void setDisplayFormat(String format)
format
- output mode ("Overlaid basins", "Overlaid dams", "Catchment basins", "Watershed lines")public static void setGradientRadius(String radius)
radius
- gradient radius size (in pixels)public static void setGradientType(String method)
method
- name of the gradient method to useCopyright © 2014–2023 INRA-IJPB Modeling and Digital Imaging lab. All rights reserved.