This is driving me mad. All I want to do is copy pixels or clone pixels from one Sprite into another empty sprite. I can get it to do it but it brings the data in as a square. I basically have a Sprite with a circle bitmap inside it. well its a png so its got transparency.
Below half works. But its also so much code to just get a copy of one sprite to another.
Actionscript Code:var bmd:BitmapData = new BitmapData(button.model.width, button.model.height);
bmd.draw( button );
var newBmd:BitmapData = new BitmapData( bmd.width, bmd.height);
newBmd.copyPixels(bmd, bmd.rect, new Point(0,0), null,null,true );
var bitmap:Bitmap = new Bitmap( newBmd );