拍照摄像头,从C# [英] take picture from webcam c#
问题描述
我的视频流,以我与DirectShowLib窗口形式。我还希望保存图像时我preSS按钮保存为例。如何从摄像头的画面,DirectShowLib方法或WIN32 API的方法呢?
I'm streaming video to my Window Form with DirectShowLib. I also want to save image when i press button "Save" for example. How to get picture from webcam with DirectShowLib methods or with WIN32 API methods?
推荐答案
DirectShow.NET样片有:的http://sourceforge.net/projects/directshownet/files/DirectShowSamples/2010-February/下面的示例demoes所请求的功能:
DirectShow.NET Samples are there: http://sourceforge.net/projects/directshownet/files/DirectShowSamples/2010-February/ The following sample demoes the requested function:
样品\ VMR9 \ vMR9Snapper ------------------------ 此示例演示如何捕捉来自VMR9位图。
Samples\VMR9\vMR9Snapper ------------------------ This sample shows how to capture bitmaps from VMR9.
有与其他渲染器的工作可能需要小code修改。
Having it working with other renderer might require small code modifications.
这个问题也讨论了在MSDN论坛进行多次,并在$ C $的CProject,例如: <一href="http://social.msdn.microsoft.com/Forums/en-US/windowsdirectshowdevelopment/thread/e41d1837-866d-4372-8165-e68217573cb5/"相对=nofollow>如何保存BMP文件从IVMRWindowlessControl9-> GetCurrentImage()。
The question also discussed a multitude of times at MSDN Forums, and on CodeProject, e.g. how to save bmp file from IVMRWindowlessControl9->GetCurrentImage().
这篇关于拍照摄像头,从C#的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!