Class SbKernel2i32

    • Constructor Detail

      • SbKernel2i32

        public SbKernel2i32​(SbKernel2i32 copyFrom)
      • SbKernel2i32

        public SbKernel2i32​(int numRows,
                            int numCols)
        Constructor defining the size of the kernel. Kernel is initialized to zero values.
      • SbKernel2i32

        public SbKernel2i32​(SbVec2i32 size)
        Constructor defining the size of the kernel (numRows, numColumns). Kernel is initialized to zero values.
      • SbKernel2i32

        public SbKernel2i32()
        Default constructor. The kernel is not initialized.
    • Method Detail

      • getNumRows

        public long getNumRows()
        Returns the number of rows.
      • setSize

        public void setSize​(long numRows,
                            long numCols)
        Set the size of the kernel. Size is the number of rows and number of columns.

        If numCols (or numRows) is smaller than the current number of columns (or rows), the kernel is reduced to the first numCols columns (or numRows rows).
        If numCols (or numRows) is greater than the current number of columns (or rows), values inside the old bounds are preserved and values outside the old bounds are filled to 0.

      • toArray

        public static SbKernel2i32[] toArray​(long nativeArray,
                                             long length)
      • setValue

        public void setValue​(SbKernel2i32 copyFrom)
      • getNumCols

        public long getNumCols()
        Returns the number of columns.
      • getSize

        public SbVec2i32 getSize()
        Returns the size of the kernel. Size is the number of rows and number of columns.
      • setValue

        public void setValue​(int indexRow,
                             int indexCol,
                             int value)
        Sets the value of the kernel at position (row, col). Throws an SbException if indices are out of bounds.
      • setSize

        public void setSize​(SbVec2i32 dimension)
        Set the size of the kernel. Size is the number of rows and number of columns.

        If numCols (or numRows) is smaller than the current number of columns (or rows), the kernel is reduced to the first numCols columns (or numRows rows).
        If numCols (or numRows) is greater than the current number of columns (or rows), values inside the old bounds are preserved and values outside the old bounds are filled to 0.

      • getValue

        public int getValue​(int indexRow,
                            int indexCol)
        Returns the value of the kernel at position (row, col). Throws an SbException if indices are out of bounds.