如何检查某个点是否为三角形? [英] how can I check that a point is in a triangle?

查看:124
本文介绍了如何检查某个点是否为三角形?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


还考虑到我有4个点并且我将有4个三角形如何检查这三个三角形中的每个点的四个三角形。
谢谢

Hi also consider that I have 4 points and I will have 4 triangles how can I check these four triangles for each point that is the point within the triangles or not. thanks

推荐答案

Polygon 实现 Shape interface,它提供了几个 contains()方法。这是一个简单的示例

Polygon implements the Shape interface, which provides several contains() methods. Here's a simple example.

这篇关于如何检查某个点是否为三角形?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆