Working with easing


show more Working with easing provides you with in-depth training on Developer. Taught by Barton Poulson as part of the Interactive Data Visualization with Processing show less
please wait ...

Working with easing

One of the more interesting dynamic tricks that you can do in Processing is to have an object follow your mouse. Now, this is pretty easy to do, because when you specify, for instance, the center of an ellipse, instead of using X and Y, you can simply use the built-in Processing commands mouseX and mouseY. However, the problem with that, they end of following too quickly, and it doesn't seem natural. It's a little jerking in motion. Instead you can use an adaptation of this that's known as easing. Now, there's not a built-in function for easing.

It's something you have to code, but it's a simple adaptation, and it allows things to gradually follow with some lag where the mouse, for instance, is going. And that's what I'm going to show you in this particular sketch. Put a comment in with the name. Then I'm going to bring it in a color palette from the palette text file. I'll use this one down here at the bottom. Then what I am going to do ...

Working with easing
Video duration: 10m 51s 7h 43m Beginner

Viewers:

Working with easing provides you with in-depth training on Developer. Taught by Barton Poulson as part of the Interactive Data Visualization with Processing

Subjects:
Developer IT
Software:
Processing
Author:
please wait ...