2007/05/02 | [原创]MovieClip转Bitmap方法
类别(Flash及RIA) | 评论(2) | 阅读(473) | 发表于 14:58

function MctoBitmap(mc1:MovieClip) {

         tempObj.removeMovieClip();

         _root.removeMovieClip("photo");

         var myBitmap:BitmapData = new BitmapData(mc1._width, mc1._height, true, 0);

         myBitmap.draw(mc1);

         var tempObj:MovieClip = _root.createEmptyMovieClip("photo", _root.getNextHighestDepth());

         trace(mc1._width+" __ "+mc1._height);

         tempObj._x = 200;

         tempObj._y = 200;

         tempObj.attachBitmap(myBitmap, 1, "always", true);

}

0

评论Comments