Importing bitmaps and vector graphics


show more Importing bitmaps and vector graphics provides you with in-depth training on Web. Taught by Ray Villalobos as part of the EaselJS First Look show less
please wait ...

Importing bitmaps and vector graphics

You don't always want to or need to create graphics with EaselJS. You may want create more complex graphics in a separate program and import them into your stage. EaselJS provides the bitmap class that lets you easily bring not just bitmap data, but most types of external graphics, so let's take a look. The bitmap class is a child of the DisplayObject. You may want to check out some of the methods and property of the DisplayObject class as well as the bitmap class in the EaselJS documentation. So I am starting off with a basic HTML template. If you haven't already, make sure you watch the video on creating a template and installing EaselJS.

To the basic template we've added a script file that already has a canvas, a stage, as well as an animation using the Ticker class. I've also added a few images in different formats in an images folder. Let's go ahead and add one of them to the stage. To the bitmap class we just need to pass along the location of the image we want to add, ...

Importing bitmaps and vector graphics
Video duration: 4m 16s 1h 28m Beginner

Viewers:

Importing bitmaps and vector graphics provides you with in-depth training on Web. Taught by Ray Villalobos as part of the EaselJS First Look

Subject:
Web
Software:
CreateJS EaselJS
Author:
please wait ...