How to access camera preview frames with MediaCapture class in Unity?

ε祈祈猫儿з 提交于 2019-12-23 22:55:52

问题


I am trying to access camera preview frames of Hololens in a script of a Unity application, but I have some problems. I want to access the camera preview with MediaCapture class. I know that it is posible in a UWP application but I want to do it in Unity. In the UWP application need to create a CaptureElement in the XAML page and after that to set the source of this element, like that:

captureElement.source = mediaCapture;
mediaCapture.StartPreviewAsync();

But in a Unity application I don't know how to create a CaptureElement or if it is possible. How can I access the preview in this case? Or how to create a CaptureElement in Unity? Do you have any ideas?

Thank you!

来源:https://stackoverflow.com/questions/45065616/how-to-access-camera-preview-frames-with-mediacapture-class-in-unity

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!