Silverlight扫描器的.Net源代码
乐博网本地下载:
SilverlightScanner源代码.zip 分类: C# 大小: 72.3 KB (74,067 字节)
代码介绍:
This code shows how to create an application that uses Windows Image Acquisition (WIA) to grab an image from either a digital camera, a scanner or a web-cam (or other WIA enabled imaging device).
The code works by spinning up a listener on port 8888 using the .NET HttpListener class and waiting for one of two requests. A request to the Silverlight clientaccesspolicy.xml file, or a request to return a scanned image. The policy enables access to the subsequent URL.
When a scanned image is requested WIA is used to quickly gather the image and return it. The code has no error handling and has only been tested against the test micro-driver scanner from the Windows Driver Kit (WDK), but it should work without modification for your WIA enabled devices.
Use this code as a starting point to do your own integration with hardware devices locally.
|