Documentation of 'boofcv.alg.weights.WeightPixelUniform_F32' Java class
WeightPixelUniform_F32
boofcv.alg.weights

Class WeightPixelUniform_F32

  • All Implemented Interfaces:
    WeightPixel_F32


    public class WeightPixelUniform_F32
    extends java.lang.Object
    implements WeightPixel_F32
    Weights from a uniform distribution within a symmetric square region. All samples within the region return a constant value, which is 1.0/w^2, where w = radius*2+1. For performance reasons, no checks are done to see if the sample point is outside the radius and should be zero.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      int getRadiusX()
      Returns the kernel's radius along the x-axis
      int getRadiusY()
      Returns the kernel's radius along the y-axis
      void setRadius(int radiusX, int radiusY)
      Change the kernel's size
      float weight(int x, int y)
      Access the weight using coordinates.
      float weightIndex(int index)
      Faster way to access the weight.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • WeightPixelUniform_F32

        public WeightPixelUniform_F32()
      • WeightPixelUniform_F32

        public WeightPixelUniform_F32(int radiusX,
                                      int radiusY)
    • Method Detail

      • weightIndex

        public float weightIndex(int index)
        Description copied from interface: WeightPixel_F32

        Faster way to access the weight. Refers to the index in a row major matrix.

        x = (index % widthX) - radiusX
        y = (index / widthX) - radiusY

        Specified by:
        weightIndex in interface WeightPixel_F32
        Parameters:
        index - index of grid element
        Returns:
        the weight
      • weight

        public float weight(int x,
                            int y)
        Description copied from interface: WeightPixel_F32
        Access the weight using coordinates.
        Specified by:
        weight in interface WeightPixel_F32
        Parameters:
        x - x-coordinate: range = -radius to radius, inclusive
        y - y-coordinate: range = -radius to radius, inclusive
        Returns:
        the weight
      • setRadius

        public void setRadius(int radiusX,
                              int radiusY)
        Description copied from interface: WeightPixel_F32
        Change the kernel's size
        Specified by:
        setRadius in interface WeightPixel_F32
        Parameters:
        radiusX - Radius along x-axis
        radiusY - Radius along y-axis
      • getRadiusX

        public int getRadiusX()
        Description copied from interface: WeightPixel_F32
        Returns the kernel's radius along the x-axis
        Specified by:
        getRadiusX in interface WeightPixel_F32
        Returns:
        Radius of kernel
      • getRadiusY

        public int getRadiusY()
        Description copied from interface: WeightPixel_F32
        Returns the kernel's radius along the y-axis
        Specified by:
        getRadiusY in interface WeightPixel_F32
        Returns:
        Radius of kernel

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.