本文介绍了处理多摄像头捕捉 UWP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用一个通用应用程序,该应用程序可让我们为每个摄像头(两个或多个)捕获图像.那么我们有什么办法可以管理所有的摄像头捕捉流沙进程呢?我刚刚在 MSDN 中找到了有关单个相机处理的教程.

我找到了一些关于在 Winforms 中管理多个 IP 摄像头的文章,但没有关于 UWP 的文章.

解决方案

众所周知,对于 UWP 应用,捕捉照片和视频的最简单方法是使用

I'm working with a Universal application that let we capture an image for each camera (two or more). So do we have any ways to manage all camera capture stream sand process it? I just found the tutorial about individual camera handling in MSDN.

I found some article about manage multiple IP cameras in Winforms but nothing for UWP.

解决方案

As we know, for UWP app, the simplest way to capture photos and video is using the MediaCapture class. See Basic photo, video, and audio capture with MediaCapture.

In this official sample Camera frames sample, it shows how to list all capture source and access camera with different profile.

We can initialize multiple MediaCapture instances and read frame by using MediaFrameReader Class. Check out this wrapper to see how to process frame as you need.

Share a multiple camera sample based on the above official sample: Github LINK

The screenshot(Running on my laptop which connected a Microsoft Life Camera HD-3000):

这篇关于处理多摄像头捕捉 UWP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-17 08:37