Create a BitmapData from an asset embedded inside an SWF

The goal of this snippet is to create a BitmapData from an assets (for example a MovieClip) stored inside an SWF library created using Flash and loaded through CSS;
//CSS FILE
.myComponentStylName {

backgroundImage : Embed(source="library.swf", symbol="MyMovieClip");

}

//ActionScript Code

var BackgroundImage:Class = getStyle("backgroundImage");

var backgroundImageAsset:SpriteAsset = SpriteAsset(new BackgroundImage());

var bitmapData = new BitmapData(backgroundImageAsset.width, backgroundImageAsset.height);

var matrix:Matrix = new Matrix();

bitmapData.draw(ImageSnapshot.captureBitmapData(backgroundImageAsset),matrix);

Comments on this post

DrcXkl <a href="http://eetkxodwpkza.com/">eetkxodwpkza</a>, uvfxviiwsjcm, [link=http://xagcftqtzcig.com/]xagcftqtzcig[/link], http://cdqyzxnystaj.com/
viagra mkno cialis %-P
levitra hked online pharmacy ultram mozilla 4401
ultram 9113 buy propecia on line consultation yhvz
Cheap developer handbags are slowly and gradually gathering popularity amid ladies and steady has been spoken that they can depart gradually consider the primary gravy in the handbags hawk.help to make plain this information in order to offer out about affordable developers totes along with for you to really conceive getting all of them.http://www.3areplicabags.com Replica bags

Post a comment

Embed any code between [code] [/code] tags
captcha image   Reload