Class DistortSupport


  • public class DistortSupport
    extends java.lang.Object
    Provides low level functions that DistortImageOps can call.
    • Constructor Summary

      Constructors 
      Constructor Description
      DistortSupport()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <Input extends boofcv.struct.image.ImageGray<Input>,​Output extends boofcv.struct.image.ImageGray<Output>>
      ImageDistort<boofcv.struct.image.Planar<Input>,​boofcv.struct.image.Planar<Output>>
      createDistortPL​(java.lang.Class<Output> outputType, boofcv.struct.distort.PixelTransform<georegression.struct.point.Point2D_F32> dstToSrc, InterpolatePixelS<Input> interp, boolean cached)
      Creates a ImageDistort for the planar images of the specified image type, transformation and interpolation instance.
      static georegression.struct.affine.Affine2D_F32 rotateCenterAffine​(float x0, float y0, float x1, float y1, float angle)
      Creates a PixelTransformAffine_F32 from the dst image into the src image.
      static PixelTransformAffine_F32 transformRotate​(float x0, float y0, float x1, float y1, float angle)
      Creates a PixelTransformAffine_F32 from the dst image into the src image.
      static PixelTransformAffine_F32 transformScale​(boofcv.struct.image.ImageBase from, boofcv.struct.image.ImageBase to, PixelTransformAffine_F32 distort)
      Computes a transform which is used to rescale an image.
      • Methods inherited from class java.lang.Object

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

      • DistortSupport

        public DistortSupport()
    • Method Detail

      • transformScale

        public static PixelTransformAffine_F32 transformScale​(boofcv.struct.image.ImageBase from,
                                                              boofcv.struct.image.ImageBase to,
                                                              PixelTransformAffine_F32 distort)
        Computes a transform which is used to rescale an image. The scale is computed directly from the size of the two input images and independently scales the x and y axises.
      • transformRotate

        public static PixelTransformAffine_F32 transformRotate​(float x0,
                                                               float y0,
                                                               float x1,
                                                               float y1,
                                                               float angle)
        Creates a PixelTransformAffine_F32 from the dst image into the src image.
        Parameters:
        x0 - Center of rotation in input image coordinates.
        y0 - Center of rotation in input image coordinates.
        x1 - Center of rotation in output image coordinates.
        y1 - Center of rotation in output image coordinates.
        angle - Angle of rotation.
      • rotateCenterAffine

        public static georegression.struct.affine.Affine2D_F32 rotateCenterAffine​(float x0,
                                                                                  float y0,
                                                                                  float x1,
                                                                                  float y1,
                                                                                  float angle)
        Creates a PixelTransformAffine_F32 from the dst image into the src image.
        Parameters:
        x0 - Center of rotation in input image coordinates.
        y0 - Center of rotation in input image coordinates.
        x1 - Center of rotation in output image coordinates.
        y1 - Center of rotation in output image coordinates.
        angle - Angle of rotation.
      • createDistortPL

        public static <Input extends boofcv.struct.image.ImageGray<Input>,​Output extends boofcv.struct.image.ImageGray<Output>> ImageDistort<boofcv.struct.image.Planar<Input>,​boofcv.struct.image.Planar<Output>> createDistortPL​(java.lang.Class<Output> outputType,
                                                                                                                                                                                                                                               boofcv.struct.distort.PixelTransform<georegression.struct.point.Point2D_F32> dstToSrc,
                                                                                                                                                                                                                                               InterpolatePixelS<Input> interp,
                                                                                                                                                                                                                                               boolean cached)
        Creates a ImageDistort for the planar images of the specified image type, transformation and interpolation instance.
        Parameters:
        dstToSrc - Transform from dst to src image.
        interp - Which interpolation algorithm should be used.