So I’m trying to load an embedded image this way:
[Bindable]
[Embed(source="path")]
private var cls_img:Class;
var img:Image = new Image();
img.source = cls_img;
Now I’m trying to copy pixel chunks from it however I get an error that img.bitmapData is null and the error goes away when I add it to the application with addElement(img);
Isn’t it possible to force flex to load the image in memory so I can manipulate it without adding it to the stage?
Yes – you can use cls_img as a BitmapAsset.
For more information, check out the documentation:
http://livedocs.adobe.com/flex/3/html/help.html?content=embed_4.html