Skip to content

Stick figure animation in the Processing programming language

License

Notifications You must be signed in to change notification settings

Antony74/StickFigure

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Stick Figure

Welcome to stick figure animation for the Processing programming language! Let's start with a simple example:

Hello, World!

  StickFigure stickFigure;

  void setup() {
    size(300, 300);
    stickFigure = new StickFigure(50); // Create a size 50 stick figure
    strokeWeight(18);
    stroke(0);
    fill(0);

    stickFigure.pv.y = 185; // Place the stick figure so it's slightly more central
  }

  void draw() {
    background(128);
    stickFigure.rightHand().heading = (0.25 * sin(frameCount/10.0)) + 2; // Wave!
    stickFigure.draw();
  }

A stick figure waving hello

Run this sketch in your browser

Other examples

  • TweenTest - A visual demonstration of how a stick figure can be posed with the mouse, and how in-between poses can be automatically generated.
  • TheClimb - A short animation

JavaDoc documentation of the three stick figure classes can be found here.

About

Stick figure animation in the Processing programming language

Resources

License

Stars

Watchers

Forks

Packages

No packages published