More Related Content
More from FLASH开发者交流会 (20)
Flash 实时摄像中运动捕捉应用与探索
- 4. 可用手段: 1. getColorBoundsRect方法 var rect:Rectangle = _blendFrame.getColorBoundsRect(0xffffff, 0, false); 2. threshold方法 blendFrame.threshold(_blendFrame, _blendFrame.rect, new Point(), "<", 0x00330000, 0xff000000, 0x00ff0000, true); 3. 给视频添加模糊滤镜 _video.filters = [new BlurFilter(10, 10, 1)]; Next
- 5. 4. 使用混合模式 _blendFrame.draw(_oldFrame);//混合层获得旧图像 _newFrame.draw(_video);//获得新图像 _oldFrame.draw(_newFrame);//旧图像更新数据 _blendFrame.draw(_newFrame, null, null, BlendMode.DIFFERENCE);// 新旧图像进行混合比较 5. 调色板映射 _bmpdata.paletteMap(_bmpdata, _bmpdata.rect, new Point(), _red, _green, _blue); Next
- 6. 一 . 头像运动捕捉 1、自动捕捉(扑球游戏) // 基于OpenCV (Open Computer Vision Library) 由Object Detection移植而来 Next
- 10. 2、定义自己的目标图样 有个在线地址可以生成目标图样的.PAT文件: http://flash.tarotaro.org/ar/MarkerGeneratorOnline.swf 修改调用.pat文件的代码重新编译, 就能识别自己定义的图样了。 init('../resources/Data/camera_para.dat', '../resources/Data/tudou.pat'); Next
- 11. 四 . 运动判断类(打气球游戏) 1、运动方向判断类GetDirection 用于改变炮弹方向 2、运动频率判断类GetFrequency 用于改变炮弹能量 Next
- 12. 3、运动速度判断类GetSpeed 用于改变炮弹速度 4、运动区域面积等级判断类GetArea 5、运动边缘判断类GetEdge Next