class IndexedSegmentF : SegmentF
IndexedSegmentF(i: IndexedPointF, j: IndexedPointF)IndexedSegmentF(i: Int, j: Int, ix: Float, iy: Float, jx: Float, jy: Float) |
val i: Int |
|
val j: Int |
val ix: Float |
|
val iy: Float |
|
val jx: Float |
|
val jy: Float |
|
val length: Float |
fun hasIndex(index: Int): Boolean |
|
fun intersects(other: SegmentF): Boolean
Not an easy task. Some references: https://github.com/locationtech/jts/blob/master/modules/core/src/main/java/org/locationtech/jts/algorithm/RobustLineIntersector.java https://stackoverflow.com/questions/3838329/how-can-i-check-if-two-segments-intersect |
fun orientation(x: Float, y: Float): Int
Returns -1 if the point is clockwise (right) from us. Returns +1 if the point is counterclockwise (left) from us. 0 if the point is collinear. https://github.com/locationtech/jts/blob/master/modules/core/src/main/java/org/locationtech/jts/algorithm/CGAlgorithmsDD.java#L47-L53 |