/ Published in: ActionScript 3
Expand |
Embed | Plain Text
private function snapClip (clip:DisplayObject):BitmapData { var bounds:Rectangle = clip.getBounds (clip); var bmd:BitmapData = new BitmapData (int (bounds.width + 0.5), int (bounds.height + 0.5), true, 0); bmd.draw (clip, new Matrix (1, 0, 0, 1, -bounds.x, -bounds.y)); return bmd; }
Comments
Subscribe to comments
You need to login to post a comment.

nice one