I have an image in my Flash library (called sun.png) and I want to load this directly into an instance of a Bitmap (or equivalent) without using Actionscript linkage and creating its own class.
I have tried:
var sun:Bitmap = flash.utils.getDefinitionByName("sun.png") as Bitmap;
and:
var sun:Bitmap = this.loaderInfo.applicationDomain.getDefinition("sun.png") as Bitmap;
But neither of these work (I believe these functions are used for loading classes)
How can I do this without creating a class or loading from the filesystem? Or is this even possible?