纳金网

标题: air与unity3d结合使用摄像头 [打印本页]

作者: 奔跑的小兔    时间: 2012-3-22 14:33
标题: air与unity3d结合使用摄像头
比较有实用价值的研究,air与unity3d结合使用摄像头!

There seem to be several solutions to getting webcams to work with Unity, but no one seems to want to post their source. I guess that the arrival of the asset store has made many see the financial opportunities (this of course is no bad thing).
By using sockets, I have created a connection between Flash and Unity3D, I then send the pixel buffer of the webcam over the socket connection and convert the pixel buffer into a UnityEngine.Color array. The current version opens the Air application automatically once you click the Start button, but this seems to only work on Windows. I'll have a look at a Mac solution next week.
If people have a bit of free time (it is a Friday), I'd be grateful if you could take a look and make sure it works on your system. Comments/suggestions are also more than welcome.
Both executables and source can be found here:
https://github.com/rooch84/UnityFlashCam






欢迎光临 纳金网 (http://go.narkii.com/club/) Powered by Discuz! X2.5