- Joined
- Sep 26, 2009
- Messages
- 2,520
Hi guys, I'm having a little problem finding out if point X lies in region or not.
Look at this graph:
I have 4 points - A, B, C and D, I know their x and y position on the graph. Connecting those 4 points creates a region.
If it helps, those 4 points are not static, but they are always placed so they create a rectangle (i.e. the angles ABD; BDC; DCA and CAB are 90°; ranges |AB| = |CD| and |AC| = |BD|).
Now I also have point X, I know its x and y position as well.
The thing I have problems with currently is finding out if X lies in the "region" created by points A, B, C and D.
Can someone help me with this?
----------------
Look at this graph:
I have 4 points - A, B, C and D, I know their x and y position on the graph. Connecting those 4 points creates a region.
If it helps, those 4 points are not static, but they are always placed so they create a rectangle (i.e. the angles ABD; BDC; DCA and CAB are 90°; ranges |AB| = |CD| and |AC| = |BD|).
Now I also have point X, I know its x and y position as well.
The thing I have problems with currently is finding out if X lies in the "region" created by points A, B, C and D.
Can someone help me with this?
----------------