package { //Credit to Paul Bourke (pbourke@swin.edu.au) for the original Fortran 77 Program :)) //Converted to a standalone C# 2.0 library by Morten Nielsen (www.iter.dk) //Check out: http://astronomy.swin.edu.au/~pbourke/terrain/triangulate/ //You can use this code however you like providing the above credits remain in tact /** * @author nicoptere * http://en.nicoptere.net/ */ public class Edge { public var p1:Point; public var p2:Point; /** * Initializes a new edge instance * @param point1 Start edge vertex index * @param point1 Start edge vertex index */ public function Edge( point1:Point, point2:Point ) { p1 = point1; p2 = point2; } /** * Checks whether two edges are equal disregarding the direction of the edges * @param other the edge to compare */ public function Equals( other:Edge ):Boolean { return ((this.p1 == other.p2) && (this.p2 == other.p1)) || ((this.p1 == other.p1) && (this.p2 == other.p2)); } } }