public class CubeStrel extends AbstractSeparableStrel3D
BallStrel
,
LinearHorizontalStrel
,
LinearVerticalStrel
,
LinearDepthStrel3D
Strel3D.Shape
BACKGROUND, FOREGROUND
Constructor and Description |
---|
CubeStrel(int size)
Creates a new cubic structuring element of a given size.
|
CubeStrel(int size,
int offset)
Creates a new cubic structuring element of a given size and with a given
offset.
|
Modifier and Type | Method and Description |
---|---|
Collection<InPlaceStrel3D> |
decompose()
Returns a collection of three linear-shape structuring element, along
each principal direction.
|
static CubeStrel |
fromDiameter(int diam)
Creates a new cube-shape structuring element with the specified diameter
(equal to cube side length).
|
static CubeStrel |
fromRadius(int radius)
Creates a new cube-shape structuring element with the specified radius
(such that cube side length equals 2 * radius + 1).
|
int[][][] |
getMask3D()
Returns the structuring element as a mask.
|
int[] |
getOffset()
Returns the offset in the mask for each direction.
|
int[][] |
getShifts3D()
Returns the structuring element as a set of shifts.
|
int[] |
getSize()
Returns the size of the structuring element, as an array of size in each
direction.
|
CubeStrel |
reverse()
The reversed structuring element of a separable strel is also separable.
|
algoProgressChanged, algoStatusChanged, closing, dilation, erosion, opening
addBorder, convertMaskToShifts, cropBorder, fireProgressChanged, fireProgressChanged, fireStatusChanged, fireStatusChanged, showProgress, showProgress
addAlgoListener, removeAlgoListener
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
showProgress, showProgress
addAlgoListener, removeAlgoListener
public CubeStrel(int size)
size
- the length of each side of the cubepublic CubeStrel(int size, int offset)
size
- the length of each side of the cubeoffset
- the position of the reference pixel in each directionpublic static final CubeStrel fromDiameter(int diam)
diam
- the side length of the cubepublic static final CubeStrel fromRadius(int radius)
radius
- the "radius" of the cubepublic Collection<InPlaceStrel3D> decompose()
SeparableStrel.decompose()
public int[][][] getMask3D()
Strel3D
public int[] getOffset()
Strel3D
public int[][] getShifts3D()
Strel3D
public int[] getSize()
Strel3D
public CubeStrel reverse()
SeparableStrel3D
Copyright © 2014–2023 INRA-IJPB Modeling and Digital Imaging lab. All rights reserved.