I have been reading both functions and am trying to come up with a clever way to implement it but I have to admit I have absolutely no idea what to do...
lets say this is a 16x16 square with these vectors:
D=(0,0,-1)
A=(0,15,6)
B=(15,0,7)
C=(15,15,0)
the coords are (x,y,height)How would I calculate which triangle H1 or H2 are on?
How would I get the height of H1?
How would I get the height of H2?
H1 inside triangle ACD or BCD?
H2 inside triangle ACD or BCD?
H1=(3,11,?)
H2=(13,3,?)
![](http://img100.imageshack.us/img100/2553/polysquare.jpg)