Brushstroke for Drawing Program

Screenshot 2021-01-22 221546

Anyone know whats the code for a Crayon and Paintbrush-like stroke?

Thanks,

1 Like

A starting point:

http://perfectionkills.com/exploring-canvas-drawing-techniques/

and


(from here)

11 is the number of points per frame

if  (mode==brushMode) {
    if (startX>=0) {
      noFill();
      for (int i=0; i<11; i++) {
        float r=random(18);
        float angle = random(TWO_PI); 
        float x1=(r*cos(angle)) + mouseX;
        float y1=(r*sin(angle)) + mouseY;
        stroke(255, 0, 0); 
        point(x1, y1);
      }
    }
  }

a lot of brushes: Browse Sketches - OpenProcessing