Пример #1
0
  /**
   * Returns true iff the line segments overlap; weaker than <code>theSame</code>.
   *
   * @param other
   * @return true iff this and other overlap
   */
  public boolean isOverlapping(LineSegment other) {
    if (!VectorUtils.areEqual(m, other.m) && !VectorUtils.areEqual(b, other.b)) return false;

    // same line, now check for overlap---
    // the start point of one should be inside the other
    return containsPoint(other.start) || other.containsPoint(start);
  }