Package qupath.opencv.ops
Class ImageOps.Core
java.lang.Object
qupath.opencv.ops.ImageOps.Core
- Enclosing class:
- ImageOps
Core operations.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionstatic ImageOpadd(double... values) Add a constant to all pixels.static ImageOpceil()Create an op that ceils floating point values.static ImageOpclip(double min, double max) Create an op that clips Mat values to the specified minimum and maximum.static ImageOpdivide(double... values) Divide all pixels by a constant.static ImageOpensureType(PixelType type) Convert theMatto match a specified pixel type.static ImageOpexp()Create an op that returns Euler's number e raise to the power of the Mat values.static ImageOpfloor()Create an op that floors floating point values.static ImageOpidentity()Create an op that returns its input unchanged.static ImageOplog()Create an op that returns the natural logarithm of values.static ImageOpmultiply(double... values) Multiply all pixels by a constant.static ImageOppower(double value) Raise every pixel element to a power.static ImageOpreplace(double originalValue, double newValue) Create an op that replaces one pixel value in an image with another.static ImageOpreplaceNaNs(double replaceValue) Create an op that replaces NaNs with a specified value.static ImageOpround()Create an op that rounds floating point values.static ImageOpsequential(Collection<? extends ImageOp> ops) Apply a collection of ops sequentially, chaining the output of one op as the input for the next.static ImageOpsequential(ImageOp... ops) Apply an array of ops sequentially, chaining the output of one op as the input for the next.static ImageOpCreate an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by adding corresponding values.static ImageOpsplitDivide(ImageOp opTop, ImageOp opBottom) Create an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by dividing corresponding values.static ImageOpsplitMerge(Collection<? extends ImageOp> ops) Create an op that applies all the specified ops to the inputMat, concatenating the results as channels of the output.static ImageOpsplitMerge(ImageOp... ops) Create an op that applies all the specified ops to the inputMat, concatenating the results as channels of the output.static ImageOpsplitMultiply(ImageOp opLeft, ImageOp opRight) Create an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by multiplying corresponding values.static ImageOpsplitSubtract(ImageOp opLeft, ImageOp opRight) Create an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by subtracting corresponding values.static ImageOpsqrt()Calculate the square root of all pixel values.static ImageOpsubtract(double... values) Subtract a constant from all pixels.
- 
Constructor Details- 
Corepublic Core()
 
- 
- 
Method Details- 
ensureTypeConvert theMatto match a specified pixel type.- Parameters:
- type- the pixel type that the- Matshould be converted to
- Returns:
 
- 
multiplyMultiply all pixels by a constant.- Parameters:
- values- either a single value to apply to all channels, or an array of- Mat.channels()values.
- Returns:
 
- 
divideDivide all pixels by a constant.- Parameters:
- values- either a single value to apply to all channels, or an array of- Mat.channels()values.
- Returns:
 
- 
addAdd a constant to all pixels.- Parameters:
- values- either a single value to apply to all channels, or an array of- Mat.channels()values.
- Returns:
 
- 
subtractSubtract a constant from all pixels.- Parameters:
- values- either a single value to apply to all channels, or an array of- Mat.channels()values.
- Returns:
 
- 
powerRaise every pixel element to a power.- Parameters:
- value-
- Returns:
 
- 
sqrtCalculate the square root of all pixel values.- Returns:
 
- 
sequentialApply a collection of ops sequentially, chaining the output of one op as the input for the next.- Parameters:
- ops-
- Returns:
- an op that represents the result of chaining the other ops together
 
- 
sequentialApply an array of ops sequentially, chaining the output of one op as the input for the next.- Parameters:
- ops-
- Returns:
- an op that represents the result of chaining the other ops together
 
- 
splitMergeCreate an op that applies all the specified ops to the inputMat, concatenating the results as channels of the output.- Parameters:
- ops-
- Returns:
- a single op that combines all other ops by split and merge
 
- 
splitMergeCreate an op that applies all the specified ops to the inputMat, concatenating the results as channels of the output.- Parameters:
- ops-
- Returns:
- a single op that combines all other ops by split and merge
 
- 
identityCreate an op that returns its input unchanged. This is useful where an op is required, but no processing should be performed (e.g. withsplitSubtract(ImageOp, ImageOp)).- Returns:
 
- 
expCreate an op that returns Euler's number e raise to the power of the Mat values.- Returns:
 
- 
logCreate an op that returns the natural logarithm of values.- Returns:
 
- 
roundCreate an op that rounds floating point values. Non-finite input values are left unchanged.- Returns:
 
- 
floorCreate an op that floors floating point values. Non-finite input values are left unchanged.- Returns:
 
- 
ceilCreate an op that ceils floating point values. Non-finite input values are left unchanged.- Returns:
 
- 
replaceNaNsCreate an op that replaces NaNs with a specified value.- Parameters:
- replaceValue- the value to replace NaNs
- Returns:
 
- 
replaceCreate an op that replaces one pixel value in an image with another.- Parameters:
- originalValue- the value in the input image to replace
- newValue- the value to use in the output image
- Returns:
 
- 
splitAddCreate an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by adding corresponding values.- Parameters:
- opLeft- op to apply to first duplicate
- opRight- op to apply to second duplicate
- Returns:
- new split-combine op
 
- 
splitSubtractCreate an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by subtracting corresponding values.- Parameters:
- opLeft- op to apply to first duplicate
- opRight- op to apply to second duplicate
- Returns:
- new split-combine op
 
- 
splitMultiplyCreate an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by multiplying corresponding values.- Parameters:
- opLeft- op to apply to first duplicate
- opRight- op to apply to second duplicate
- Returns:
- new split-combine op
 
- 
splitDivideCreate an op that duplicates a Mat, applies different operations to each duplicate, and combines the result by dividing corresponding values.- Parameters:
- opTop- op to apply to first duplicate
- opBottom- op to apply to second duplicate
- Returns:
- new split-combine op
 
- 
clipCreate an op that clips Mat values to the specified minimum and maximum.- Parameters:
- min-
- max-
- Returns:
- Since:
- v0.3.1
 
 
-