判断点是否在封闭图形

时间:2021-06-20 02:42:38
【文件属性】:

文件名称:判断点是否在封闭图形

文件大小:7KB

文件格式:JAVA

更新时间:2021-06-20 02:42:38

java程序

封闭图形是有一串左边表示,判断一个坐标是在封闭图形什么位置 String s5="[{\"mapLat\":1,\"mapLng\":2},{\"mapLat\":3,\"mapLng\":5},{\"mapLat\":8,\"mapLng\":5},{\"mapLat\":5,\"mapLng\":3},{\"mapLat\":8,\"mapLng\":2},{\"mapLat\":4,\"mapLng\":1}]"; System.out.println(judger1.isInPolygon("3", "2", s5)); System.out.println(judger1.isInPolygon("4", "5", s5)); System.out.println(judger1.isInPolygon("2", "1", s5)); System.out.println(judger1.isInPolygon("6", "2", s5)); System.out.println(judger1.isInPolygon("7", "3", s5));


网友评论