Java Geometry Algorithm mirrorMoveVertically(Point move, int size)

Here you can find the source of mirrorMoveVertically(Point move, int size)

Description

mirror Move Vertically

License

GNU General Public License

Declaration

public static Point mirrorMoveVertically(Point move, int size) 

Method Source Code

//package com.java2s;
/**/* ww w.  j a  v a  2 s .  c  o  m*/
 * Loki AI
 *
 * Utils.java
 * Created on 2015-12-30
 * Version 0.7.0 Beta
 *
 * Written by Jimmy Nordstr?m.
 * ? 2015-2016 Jimmy Nordstr?m.
 *
 * Licenced under GNU GPLv3.
 * http://www.gnu.org/licenses/gpl-3.0.html
 *
 * If you have questions, contact me at pzyber@pzyber.net
 */

import java.awt.Point;

public class Main {
    public static Point mirrorMoveVertically(Point move, int size) {
        return new Point((size - 1) - move.x, move.y);
    }
}

Related

  1. makeCircle(double xCenter, double yCenter, double r, int nPoints)
  2. makeCornerTo(GeneralPath gp, Point2D cornerPoint, Point2D nextCornerPoint, float radius)
  3. makeLine(Point2D.Double center, Point2D.Double north, Point2D.Double east)
  4. makeNeighbor(Point theHex, int direction)
  5. manhattanDistance(Point a, Point b)
  6. nearestColinearPoint(final double x1, final double y1, final double x2, final double y2, double x, double y)
  7. nearestColinearPoint(final Line2D segment, final Point2D point)
  8. nearestPointOnLine(Line2D l, Point2D p, boolean clampToSegment, Point2D dest)
  9. newZeroPoint()