public class LocalThicknessWrapper extends Object implements ij.plugin.filter.PlugInFilter
This plugin overlaps with Local_Thickness_Driver
. Both execute all the steps of local thickness
in one go. However, this class offers more control over the execution, e.g. "running silent"
which means that none of the intermediate images are shown. It also has some additional
features needed by BoneJ, e.g. masking artifact pixels created by the algorithm that weren't
present in the input image.
This duplication makes the package messy, but I wanted to left the original code as is, because I don't understand it well enough to confidently alter it.
Modifier and Type | Field and Description |
---|---|
boolean |
calibratePixels
Controls whether the pixel values in the Thickness map get scaled @see
LocalThicknessWrapper.calibratePixels()
|
boolean |
inverse
Inverts thresholding so that pixels with values >= threshold are
considered background.
|
boolean |
maskThicknessMap
Controls whether the Thickness map gets masked with the original @see
MaskThicknessMapWithOriginal
|
int |
threshold
A pixel is considered to be a part of the background if its color <
threshold
|
CONVERT_TO_FLOAT, DOES_16, DOES_32, DOES_8C, DOES_8G, DOES_ALL, DOES_RGB, DOES_STACKS, DONE, FINAL_PROCESSING, KEEP_THRESHOLD, NO_CHANGES, NO_IMAGE_REQUIRED, NO_UNDO, NO_UNDO_RESET, PARALLELIZE_IMAGES, PARALLELIZE_STACKS, ROI_REQUIRED, SNAPSHOT, STACK_REQUIRED, SUPPORTS_MASKING
Constructor and Description |
---|
LocalThicknessWrapper() |
Modifier and Type | Method and Description |
---|---|
ij.ImagePlus |
getResultImage() |
ij.ImagePlus |
processImage(ij.ImagePlus inputImage)
Creates a thickness map from the given image
|
void |
run(ij.process.ImageProcessor ip) |
void |
setShowOptions(boolean show)
Controls whether the options dialog in EDT_S1D is shown to the user before
processing starts.
|
void |
setSilence(boolean silent)
Sets whether intermediate images are shown to the user, or only the final
result
|
void |
setTitleSuffix(String imageTitleSuffix) |
int |
setup(String arg,
ij.ImagePlus imp) |
public int threshold
public boolean inverse
public boolean maskThicknessMap
public boolean calibratePixels
public void setShowOptions(boolean show)
show
- If true, then the dialog is shown.public void setSilence(boolean silent)
silent
- If true, then no intermediate images are shown in the GUI.public ij.ImagePlus processImage(ij.ImagePlus inputImage)
inputImage
- An 8-bit binary imagepublic void setTitleSuffix(String imageTitleSuffix)
imageTitleSuffix
- The suffix that's added to the end of the title of
the resulting thickness map imagepublic ij.ImagePlus getResultImage()
public int setup(String arg, ij.ImagePlus imp)
setup
in interface ij.plugin.filter.PlugInFilter
public void run(ij.process.ImageProcessor ip)
run
in interface ij.plugin.filter.PlugInFilter
Copyright © 2015–2021 Fiji. All rights reserved.