我正在尝试跟踪用户对我的 Flash 项目的操作并将其存储为 swf 文件或视频任何帮助请我编写此代码来捕获位图并在单击影片剪辑时显示它们
stage.addEventListener(Event.ENTER_FRAME,capture)
var ar=new Array()
function capture(e:Event)
{
trace("done")
var bd:BitmapData = new BitmapData(stage.stageWidth,stage.stageHeight);
bd.draw(stage);
var screenshot:Bitmap = new Bitmap(bd);
ar.push(screenshot)
}
vv.addEventListener(MouseEvent.CLICK,gg)
var xx=0
var intr
var interval
function gg(e:MouseEvent)
{
interval = setInterval(reg_st, 24);
}
function reg_st()
{
stage.removeEventListener(Event.ENTER_FRAME,capture)
stage.addChild(ar[xx])
if(xx<ar.length-1)
{
xx++
}
else
{
xx=0
}
}
谢谢