Tag Archives: triangle
Javascript: Is Point In Triangle
Excellent article on determining if a point is in a triangle. Point in triangle test I needed a javascript version of the Barycentric coordinate method. Here is the function: function is_in_triangle (px,py,ax,ay,bx,by,cx,cy){ //credit: http://www.blackpawn.com/texts/pointinpoly/default.html var v0 = [cx-ax,cy-ay]; var v1 … Continue reading
Context Free Sierpinski Triangle Tutorial
Context Free site tutorial: http://www.contextfreeart.org/mediawiki/index.php/Tutorials/Fractals The generated image: Context Free Code: startshape B rule B { TRIANGLE{} B {s 0.5 y 0.288 b 0.1} B {s 0.5 x -0.25 y -0.144 b 0.1} B {s 0.5 x 0.25 y -0.144 … Continue reading
Posted in Uncategorized
Tagged context free, fractal, Seirpinski, triangle, tutorial
Leave a comment