Documentation of 'Catalano.Imaging.Concurrent.Filters.YCbCrFiltering' Java class
YCbCrFiltering
Catalano.Imaging.Concurrent.Filters

Class YCbCrFiltering

  • All Implemented Interfaces:
    IApplyInPlace


    public class YCbCrFiltering
    extends java.lang.Object
    implements IApplyInPlace
    Color filtering in YCbCr color space. The filter operates in YCbCr color space and filters pixels, which color is inside/outside of the specified YCbCr range - it keeps pixels with colors inside/outside of the specified range and fills the rest with FillColor specified color.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void applyInPlace(FastBitmap fastBitmap)
      Apply filter to an image.
      FloatRange getCb()
      Get Range of cb component, [-0.5, 0.5].
      FloatRange getCr()
      Get Range of cr component, [-0.5, 0.5].
      float[] getFillColor()
      Get fill color used to fill filtered pixels.
      FloatRange getY()
      Get Range of Y component, [0, 1].
      boolean isFillOutsideRange()
      Verify if pixels should be filled inside or outside specified color range.
      boolean isUpdatedCb()
      Verify if cb value of filtered pixels should be updated.
      boolean isUpdatedCr()
      Verify if cr value of filtered pixels should be updated.
      boolean isUpdatedY()
      Verify if y value of filtered pixels should be updated.
      void setCb(FloatRange cb)
      Set Range of cb component, [-0.5, 0.5].
      void setCr(FloatRange cr)
      Set Range of cr component, [-0.5, 0.5].
      void setFillColor(float y, float cb, float cr)
      Set fill color used to fill filtered pixels.
      void setFillOutsideRange(boolean fillOutsideRange)
      Determines, if pixels should be filled inside or outside specified.
      void setHue(FloatRange y)
      Set Range of Y component, [0, 1].
      void setUpdateCb(boolean update)
      Determines, if cb value of filtered pixels should be updated.
      void setUpdateCr(boolean update)
      Determines, if cr value of filtered pixels should be updated.
      void setUpdateY(boolean update)
      Determines, if y value of filtered pixels should be updated.
      • Methods inherited from class java.lang.Object

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

      • YCbCrFiltering

        public YCbCrFiltering()
        Initializes a new instance of the YCbCrFiltering class.
      • YCbCrFiltering

        public YCbCrFiltering(FloatRange y,
                              FloatRange cb,
                              FloatRange cr)
        Initializes a new instance of the YCbCrFiltering class.
        Parameters:
        y - Range of y component.
        cb - Range of cb component.
        cr - Range of cr component.
    • Method Detail

      • getY

        public FloatRange getY()
        Get Range of Y component, [0, 1].
        Returns:
        Y component.
      • setHue

        public void setHue(FloatRange y)
        Set Range of Y component, [0, 1].
        Parameters:
        yRange - Y component.
      • getCb

        public FloatRange getCb()
        Get Range of cb component, [-0.5, 0.5].
        Returns:
        Cb component.
      • setCb

        public void setCb(FloatRange cb)
        Set Range of cb component, [-0.5, 0.5].
        Parameters:
        cb - Cb component.
      • getCr

        public FloatRange getCr()
        Get Range of cr component, [-0.5, 0.5].
        Returns:
        Cr component.
      • setCr

        public void setCr(FloatRange cr)
        Set Range of cr component, [-0.5, 0.5].
        Parameters:
        cr - Cr component.
      • getFillColor

        public float[] getFillColor()
        Get fill color used to fill filtered pixels.
        Returns:
        YCbCr color.
      • setFillColor

        public void setFillColor(float y,
                                 float cb,
                                 float cr)
        Set fill color used to fill filtered pixels.
        Parameters:
        y - Y, [0, 1].
        cb - Cb, [-0.5, 0.5].
        cr - Cr, [-0.5, 0.5].
      • isFillOutsideRange

        public boolean isFillOutsideRange()
        Verify if pixels should be filled inside or outside specified color range.
        Returns:
        True if fill outside the range, otherwise false.
      • setFillOutsideRange

        public void setFillOutsideRange(boolean fillOutsideRange)
        Determines, if pixels should be filled inside or outside specified.
        Parameters:
        fillOutsideRange - True if fill outside the range, otherwise false.
      • isUpdatedY

        public boolean isUpdatedY()
        Verify if y value of filtered pixels should be updated.
        Returns:
        True if should be updated, otherwise false.
      • setUpdateY

        public void setUpdateY(boolean update)
        Determines, if y value of filtered pixels should be updated.
        Parameters:
        update - True if should be updated, otherwise false.
      • isUpdatedCb

        public boolean isUpdatedCb()
        Verify if cb value of filtered pixels should be updated.
        Returns:
        True if should be updated, otherwise false.
      • setUpdateCb

        public void setUpdateCb(boolean update)
        Determines, if cb value of filtered pixels should be updated.
        Parameters:
        update - True if should be updated, otherwise false.
      • isUpdatedCr

        public boolean isUpdatedCr()
        Verify if cr value of filtered pixels should be updated.
        Returns:
        True if should be updated, otherwise false.
      • setUpdateCr

        public void setUpdateCr(boolean update)
        Determines, if cr value of filtered pixels should be updated.
        Parameters:
        update - True if should be updated, otherwise false.
      • applyInPlace

        public void applyInPlace(FastBitmap fastBitmap)
        Description copied from interface: IApplyInPlace
        Apply filter to an image.
        Specified by:
        applyInPlace in interface IApplyInPlace
        Parameters:
        fastBitmap - Image to be processed.

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.