有没有免费的.NET OCR库,这将直接应用程序窗口中执行OCR? [英] Are there any free .NET OCR libraries that will perform OCR on an application window directly?

查看:243
本文介绍了有没有免费的.NET OCR库,这将直接应用程序窗口中执行OCR?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我要寻找一个免费的.NET OCR库,将能够做OCR在一个给定的应用程序窗口,甚至在内存中的图像(我可以把应用程序窗口自己的快照)。

I am looking for a free .NET OCR library that will be able to do OCR on a given application window or even a image in memory (I can take a snapshot of the application window myself).

我已经看过 tessnet2 和的 MODI 但它们都需要位于磁盘。图片

I have looked at tessnet2 and MODI but both require an image located on disk.

我需要使用OCR,因为应用程序我想了做一些古怪的东西,不能使用Windows API读到写一个脚本,我需要从屏幕抽取数据。我检测了两个 tessnet2 和的 MODI ,他们都可以阅读这些文字,但大多是因为这已在环境,将无法写入到磁盘上运行,我需要它能够直接从applciation窗口或某些类型的内存流的读取。

I need to use OCR because the application I am trying to write a script for does some wacky stuff that cannot be read using windows API and I need to scrape data from the screen. I have tested both of tessnet2 and MODI and they both can read the text mostly but because this has to run in an enviroment that will not be able to write to disk, I need it to be able to read directly from the applciation window or some type of memory stream.

我想OCR是我唯一的soution但也有可能是我没有想到的其他方法。

I am thinking OCR is my only soution but there could be other methods that I am not thinking of.

建议?

修改的基础上的意见:环境是一个C#.NET Windows应用程序与无人接盘。这是一个已经编译和动态执行,这个code是不是应该不需要其他的任何资源比内存上下文中运行code。

Edit based on comments: Environment is a C# .NET windows application with no disk access. It's an application that has code compiled and executed on the fly and this code is running in a context that should not need any resources other than memory.

推荐答案

当我从Tessnet页面例子中看到该库需要一个位图到如此传递,如果你的 Image.FromStream 方法?

As I can see from the Tessnet page example the library requires a Bitmap to be passed in so what if you create it with Image.FromStream Method ?

您可以创建位图对象与此构造:位图构造函数(流)

You can create Bitmap object with this constructor: Bitmap Constructor (Stream)

这篇关于有没有免费的.NET OCR库,这将直接应用程序窗口中执行OCR?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆