Im working on a project were I need to draw some thick lines. I noticed that by default p5js lines are rounded at the ends. Is there a way to change this behavior?
strokeWeight(50);
line(150,150,300,200);
The only way around I've thought around this would be to use a quad() but Id need to calculate the rotation and use transform, or use multiple lines but Id need to calculate their start and end positions
Is there a better way? I've read the documentation I've also looked for keywords like line endings line caps line mode or something but have found nothing
Any help is appreciated
What you're looking for is the "stroke cap".
strokeCap(SQUARE);