GrAPiC
Graphics for Algo/Prog in C/C++

◆ isInTriangle()

bool grapic::isInTriangle ( float  px,
float  py,
float  ax,
float  ay,
float  bx,
float  by,
float  cx,
float  cy 
)

Decide if a point (px, py) is inside the triangle (ax, ay), (bx, by), (cx, xy). (Code provided by Bastien DOIGNIES, many thanks)

Returns
true if inside, false otherwise