Edit script

Description

Allows to edit a script.

Required input

Script name: each script requires a unique name.

Shortcut key: assign a shortcut key to the script. You can select a character in the range A..Z or 1..9. For example when you select the letter A, you will be able to execute the script by pressing the key combination Shift + Ctrl + A

Script commands: a list of commands that make up the script.

Script commands

Image manipulation and enhancement

BackgroundCorrection
Corrects image defects caused by uneven illumination.
Brightness red green blue
Sets the brightness of the different color components (see Selective color brightness). Values for the red, green, and blue components must be in the range [0..100].
ContrastAutoFix
Maximizes contrast automatically.
Despeckle
Removes noise from images without blurring edges.
Flip vertical | horizontal
Flips the image vertically or horizontally.
Grayscale
Converts the image to a grayscale image.
Invert
Creates a negative of the image.
Rotate left | right
Rotate the image left or right.
SelectAll
Selects all measurement objects in the image window.
Sharpen [filtersize] [intensity]
Applies a sharpen filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect
intensity: % filter intensity
StretchHistogram
Optimizes contrast.

Filters

GeometricMeanFilter [filtersize]
Applies a Geometric Mean Filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.
HarmonicMeanFilter [filtersize]
Applies a Harmonic Mean Filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.
MaximumFilter [filtersize]
Applies a Minimum filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.
MeanFilter [filtersize]
Applies an Arithmetic Mean Filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.
MedianFilter [filtersize]
Applies a Median Filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.
MinimumFilter [filtersize]
Applies a Minimum filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.
RangeFilter [filtersize]
Applies a Range filter to the image.
Optional parameters:
filtersize: larger filter size yields stronger effect; the default value is 3.

Binarization

Binarize [lower threshold] [higher threshold]
Converts the image to a binary image by converting all pixels between two threshold values to red and those below the lower or above the higher threshold to white.
Optional parameters:
lower threshold: a value in the range [0..255]
higher threshold: a value in the range [0..255]
If only one threshold value is given this value is used as the higher threshold and the lower threshold is set to 0.
If no thresholds are specified, the software uses histogram-derived threshold values.
MorphDilate
Adds pixels at region boundaries and fill in holes (Morphological Dilate operation after binarization).
MorphErode
Removes pixels at boundaries or regions and increase the size of holes (Morphological Erode operation after binarization).
MorphOpen
Smooths boundaries, break narrow isthmuses and eliminate small noise regions (Morphological Open operation after binarization).
MorphClose
Smooths boundaries, join narrow breaks and fill small holes caused by noise (Morphological Close operation after binarization).
NoiseReduction
Reduces noise in the binary image.

Analyzes objects after binarization

ExcludeBorderObjects yes | no
Sets the option to exclude objects that are on the image border. The default is to exclude objects that are on the image border.
MinimumArea value
Sets the minimum area of objects. The default is not to take into account a minimum area.
MaximumArea value
Sets the maximum area of objects. The default is not to take into account a maximum area.
MinimumLength value
Sets the minimum length of objects. The default is not to take into account a minimum length.
MaximumLength value
Sets the maximum length of objects. The default is not to take into account a maximum length.
AnalyzeObjects
Extracts object contours from the binary image using the setting listed above.

See also