On 10 June 2010 12:52, fifas <[email protected]> wrote:
> Hi all,
>
> I am first tiem on this list. So, Please forgive me if you write
> something stupid.
>

You've automatically earned more tolerance, with that :D

> I don't knwo why but the demo ocr doesn't work on my computer. When I
> load a image and click the "doOCR" button, the application is closed
> immediately. The same happens when I use the demo code in my project.
> After first init, all application is cloased. Could you tell my some
> hints ?? What can it be ??
>
> Ocr ocr = new Ocr();
> using (Bitmap bmp = new Bitmap(@"D:\temp\ocr\b1.bmp"))
> {
>    tessnet2.Tesseract tessocr = new tessnet2.Tesseract();
>
>    tessocr.Init(null, "eng", false);  // !!!!!!!!!! This line causes
> the exit of all application. !!!!!!!!!!!!!!!!!
>

Yes, you need to set a correct path to the language data. Nothing else
will work without the data path being set.

>
>    tessocr.GetThresholdedImage(bmp, Rectangle.Empty).Save("c:\\temp\
> \" + Guid.NewGuid().ToString() + ".bmp");
>    // Tessdata directory must be in the directory than this exe
>    Console.WriteLine("Multithread version");
>    ocr.DoOCRMultiThred(bmp, "eng");
>    Console.WriteLine("Normal version");
>    ocr.DoOCRNormal(bmp, "eng");
> }
>
> /BR
> Grzegorz
>
> Link from I got the demo.
> http://www.pixel-technology.com/freeware/tessnet2/bin.zip
>
> --
> You received this message because you are subscribed to the Google Groups 
> "tesseract-ocr" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/tesseract-ocr?hl=en.
>
>



-- 
<Leftmost> jimregan, that's because deep inside you, you are evil.
<Leftmost> Also not-so-deep inside you.

-- 
You received this message because you are subscribed to the Google Groups 
"tesseract-ocr" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/tesseract-ocr?hl=en.

Reply via email to