Class Kernel2D_S32


public class Kernel2D_S32
extends Kernel2D
This is a kernel in a 2D convolution. The convolution is performed by convolving this kernel across a 2D array/image. The kernel is square and has the specified width. To promote reuse of data structures the width of the kernel can be changed. All elements in this kernel are floating point numbers.

WARNING: Do not modify. Automatically generated by GenerateKernel2D.

  • Field Summary

    Fields
    Modifier and Type Field Description
    int[] data  

    Fields inherited from class boofcv.struct.convolve.KernelBase

    offset, width
  • Constructor Summary

    Constructors
    Modifier Constructor Description
    protected Kernel2D_S32()  
      Kernel2D_S32​(int width)
    Create a kernel with elements initialized to zero with the specified 'width' and offset equal to width/2
      Kernel2D_S32​(int width, int offset)
    Create a kernel with elements initialized to zero with the specified 'width' and 'offset'.
      Kernel2D_S32​(int width, int[] data)
    Creates a new kernel whose initial values are specified by 'data' and 'width'.
  • Method Summary

    Modifier and Type Method Description
    int computeSum()  
    Kernel2D_S32 copy()  
    int get​(int x, int y)  
    int[] getData()  
    double getDouble​(int x, int y)  
    boolean isInteger()  
    void print()  
    void set​(int x, int y, int value)  
    static Kernel2D_S32 wrap​(int[] data, int width, int offset)
    Creates a kernel whose elements are the specified data array and has the specified width.

    Methods inherited from class boofcv.struct.convolve.Kernel2D

    getDimension

    Methods inherited from class boofcv.struct.convolve.KernelBase

    getRadius

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • data

      public int[] data
  • Constructor Details

    • Kernel2D_S32

      public Kernel2D_S32​(int width, int[] data)
      Creates a new kernel whose initial values are specified by 'data' and 'width'. The length of its internal data will be width*width. Data must be at least as long as width*width. The offset is automatically set to width/2
      Parameters:
      width - The kernels width. Must be odd.
      data - The value of the kernel. Not modified. Reference is not saved.
    • Kernel2D_S32

      public Kernel2D_S32​(int width)
      Create a kernel with elements initialized to zero with the specified 'width' and offset equal to width/2
      Parameters:
      width - How wide the kernel is.
    • Kernel2D_S32

      public Kernel2D_S32​(int width, int offset)
      Create a kernel with elements initialized to zero with the specified 'width' and 'offset'.
      Parameters:
      width - How wide the kernel is.
    • Kernel2D_S32

      protected Kernel2D_S32()
  • Method Details

    • wrap

      public static Kernel2D_S32 wrap​(int[] data, int width, int offset)
      Creates a kernel whose elements are the specified data array and has the specified width.
      Parameters:
      data - The array who will be the kernel's data. Reference is saved.
      width - The kernel's width.
      offset - Kernel origin's offset from element 0.
      Returns:
      A new kernel.
    • get

      public int get​(int x, int y)
    • set

      public void set​(int x, int y, int value)
    • isInteger

      public boolean isInteger()
      Specified by:
      isInteger in class KernelBase
    • getData

      public int[] getData()
    • computeSum

      public int computeSum()
    • print

      public void print()
    • copy

      public Kernel2D_S32 copy()
      Specified by:
      copy in class KernelBase
    • getDouble

      public double getDouble​(int x, int y)
      Specified by:
      getDouble in class Kernel2D