小菜AS3之路

2012.2.17
  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2012年5月31日

摘要: //向右旋转90度publicfunctionrotateRight(bmpData:BitmapData):BitmapData{varmc:Matrix=newMatrix();mc.rotate(Math.PI/2);mc.translate(bmpData.height,0);varbmpData:BitmapData=newBitmapData(bmpData.height,bmpData.width,true,0);bmpData.draw(bmpData,mc);returnbmpData;}//向左旋转90度publicfunctionrotateLeft(bmpData:Bi 阅读全文

posted @ 2012-05-31 15:07 枫雨 阅读(645) 评论(0) 推荐(0)

摘要: 我们在flash加载外部swf,jpg,png,gif时,经常出现安全沙箱错误,通过设置文件所在域的安全策略文件可以解决这个问题。但是有时我们需要加载我们没权限设置安全策略文件的域时,用下面这个方面可以帮你解决:1、首先使用一个loader加载一个外部SWF,监听loader.contentLoaderInfo的Event.COMPLETE事件;2、加载成功后,先暂时不使用这个加载成功的loader,而是另写一个loader2,使用loader2.loadBytes()来加载第一个loader的contentLoaderInfo.bytes,并监听Loader.contentLoaderInf 阅读全文

posted @ 2012-05-31 11:56 枫雨 阅读(1620) 评论(0) 推荐(0)