Package com.openinventor.imageviz
Class SbKernel3i32
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.imageviz.SbKernel3i32
-
public class SbKernel3i32 extends Inventor
Integer 3D-Kernel for morphological operations. Define an n x m x p integer 3D-kernel.- See Also:
SoSFKernel3i32
,SoMFKernel3i32
,SoMorphoLut3D
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
-
Field Summary
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Constructor Summary
Constructors Constructor Description SbKernel3i32()
Default constructor.SbKernel3i32(long numCols, long numRows, long numSlices)
Constructor defining the size of the kernel.SbKernel3i32(SbKernel3i32 copyFrom)
SbKernel3i32(SbVec3i32 size)
Constructor defining the size of the kernel.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getNumCols()
Returns the number of columns.long
getNumRows()
Returns the number of rows.long
getNumSlices()
Returns the number of slices.SbVec3i32
getSize()
Returns the size of the kernel.int
getValue(int indexCol, int indexRow, int indexSlice)
Returns the value of the kernel at position (i, j, k).void
setSize(long numCols, long numRows, long numSlices)
Set the size of the kernel.void
setSize(SbVec3i32 dimension)
Set the size of the kernel.void
setValue(int indexCol, int indexRow, int indexSlice, int value)
Sets the value of the kernel at position (i, j, k).void
setValue(SbKernel3i32 copyFrom)
static SbKernel3i32[]
toArray(long nativeArray, long length)
-
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
-
-
-
Constructor Detail
-
SbKernel3i32
public SbKernel3i32(SbKernel3i32 copyFrom)
-
SbKernel3i32
public SbKernel3i32(long numCols, long numRows, long numSlices)
Constructor defining the size of the kernel. Kernel is initialized to zero values.
-
SbKernel3i32
public SbKernel3i32(SbVec3i32 size)
Constructor defining the size of the kernel. Kernel is initialized to zero values.
-
SbKernel3i32
public SbKernel3i32()
Default constructor. The kernel is not initialized.
-
-
Method Detail
-
toArray
public static SbKernel3i32[] toArray(long nativeArray, long length)
-
setValue
public void setValue(SbKernel3i32 copyFrom)
-
getNumCols
public long getNumCols()
Returns the number of columns.
-
setSize
public void setSize(SbVec3i32 dimension)
Set the size of the kernel. Size is the number of columns, number of rows and number of slices.If the specified size on a dimension is smaller than the current one, the kernel is reduced to its first elements on the corresponding dimension.
If specified size on a dimension is greater than the current one, values inside the old bounds are preserved and values outside the old bounds are filled to 0.
-
getNumRows
public long getNumRows()
Returns the number of rows.
-
getNumSlices
public long getNumSlices()
Returns the number of slices.
-
setSize
public void setSize(long numCols, long numRows, long numSlices)
Set the size of the kernel. Size is the number of columns, number of rows and number of slices.If the specified size on a dimension is smaller than the current one, the kernel is reduced to its first elements on the corresponding dimension.
If specified size on a dimension is greater than the current one, values inside the old bounds are preserved and values outside the old bounds are filled to 0.
-
setValue
public void setValue(int indexCol, int indexRow, int indexSlice, int value)
Sets the value of the kernel at position (i, j, k). Range of each index is between 0 and n-1 with n, the number of elements in each dimension, i.egetNumCols()
for columns,getNumRows()
for rows, andgetNumSlices()
for slices. Throws anSbException
if indices are out of bounds.
-
getSize
public SbVec3i32 getSize()
Returns the size of the kernel. Size is the number of columns, number of rows and number of slices.
-
getValue
public int getValue(int indexCol, int indexRow, int indexSlice)
Returns the value of the kernel at position (i, j, k). Range of each index is between 0 and n-1 with n, the number of elements in each dimension, i.egetNumCols()
for columns,getNumRows()
for rows, andgetNumSlices()
for slices. Throws anSbException
if indices are out of bounds.
-
-