O'Reilly logo

Instant EaselJS Starter by Fabio Biondi

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Top 8 features you'll want to know about

In this section, we will create a small interactive advertising application step-by-step, learning the most commonly used tasks and EaseJS features.

Drawing graphic primitives

One of the main features of EaselJS is the Graphics class that exposes a lot of useful methods to generate vector shapes, fills, and strokes. If you came from Adobe Flash, you'll be glad to know that those methods and usages are pretty similar.

The following script shows how to create a graphic object in which we draw a circle using the Graphics methods. We also need to create a new Shape object to hold and display our graphic on the screen.

To see how it works, replace the <script> block of the previous example with the following code ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required