Package org.geotools.math

Examples of org.geotools.math.Line


                                                        (a.getCoordinate().y + b.getCoordinate().y)/2);
        double deltaXA_B = a.getCoordinate().x - midPointA_B.getX();
        double deltaYA_B = a.getCoordinate().y - midPointA_B.getY();

        Line bisectorA_B = new Line();
        bisectorA_B.setLine(new Point2D.Double((midPointA_B.getX() + 100*deltaYA_B),
                                               (midPointA_B.getY() - 100*deltaXA_B)),
                            new Point2D.Double((midPointA_B.getX() - 100*deltaYA_B),
                                               (midPointA_B.getY() + 100*deltaXA_B)));
       
        Point2D.Double midPointA_C = new Point2D.Double((a.getCoordinate().x + c.getCoordinate().x)/2,
                                                        (a.getCoordinate().y + c.getCoordinate().y)/2);
        double deltaXA_C = a.getCoordinate().x - midPointA_C.getX();
        double deltaYA_C = a.getCoordinate().y - midPointA_C.getY();     
       
        Line bisectorA_C = new Line();
       
        Point2D intersection = null;
        int i = 1;
        do{
            bisectorA_C.setLine(new Point2D.Double((midPointA_C.getX() + Math.pow(100, i)*deltaYA_C),
                                                   (midPointA_C.getY() - Math.pow(100, i)*deltaXA_C)),
                                new Point2D.Double((midPointA_C.getX() - Math.pow(100, i)*deltaYA_C),
                                                   (midPointA_C.getY() + Math.pow(100, i)*deltaXA_C)));       
            intersection = bisectorA_B.intersectionPoint(bisectorA_C);
            i++;
View Full Code Here

TOP

Related Classes of org.geotools.math.Line

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.