public static Point transformPoint(AffineTransform af, Point pt) {
        Point2D src = new Point2D.Float(pt.x, pt.y);
        Point2D dest = af.transform(src, null);
        Point point = new Point((int) Math.floor(dest.getX()), (int) Math.floor(dest.getY()));
        return point;
    }
Given an arbitrary point, get the point with the given transform.

@param af affine transform
@param pt point to be transformed
@return point after transform
plugins/org.jkiss.dbeaver.ui.editors.image/src/org/jkiss/dbeaver/ui/controls/imageview/ImageViewUtil.java