Green Flag and watch. Vertices are draggable.
Met the @chooper100's challenge to draw a clipped triangle as pieces of triangles (triangulation) in an efficient way. Based on Sutherland–Hodgman's polygon within polygon clipping algorithm (thank you @l8P for mentioning the name), but in simpler application where it clips only triangle-rectangle First, we do triangle clipping through Horizontal boundary, then we do clip the result through Vertical boundary. Pretty simple, isn't it? I knew there are many possibilities to connect all the vertices, but I had used a non-mathematical way to do this: either all points [a,b,c,d,e,...] sorted in clockwise or counter-clockwise, simply connect abc, acd, ade, etc... No, not Delaunay, it is complicated. Although the result would be impressive, I doubt that it is fast. #triangle #clip #3d #engine #math #pen