saintmike has asked for the wisdom of the Perl Monks concerning the following question:
I realized that this module would only solve easy tasks, so I gave it a simple image containing a single character. The documentation is a bit sketchy (what's the format of a character map?), so I dumped out the result with Data::Dumper:
which printed the following:use OCR::PerfectCR; use GD; use Data::Dumper; my($file) = @ARGV; die "No file" unless defined $file; my $recognizer = OCR::PerfectCR->new; $recognizer->load_charmap_file("charmap"); my $image = GD::Image->new($file) or die; my(@out) = $recognizer->recognize($image); print Dumper(\@out);
Hmm. So where's the result? Is it really "\x{fffd}"? Alternatively, can anyone recommend a solution that works?'width' => 18, 'str' => "\x{fffd}", 'endcol' => 18, 'startcol' => 0, 'color' => '163', 'bgrgb' => [ 148, 202, 212 ], 'chrwidth' => '18', 'md5' => '9454596172a32923111c25373a801472', 'prespace' => 0
As previously discussed, there's issues with getting proper OCR, but if you know of anything that actually works, please let me know.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Does OCR::PerfectCR work at all?
by eric256 (Parson) on Feb 11, 2007 at 05:48 UTC | |
by saintmike (Vicar) on Feb 11, 2007 at 09:18 UTC | |
by eric256 (Parson) on Feb 11, 2007 at 16:24 UTC | |
by Corion (Patriarch) on Feb 11, 2007 at 09:59 UTC | |
|
Re: Does OCR::PerfectCR work at all?
by theorbtwo (Prior) on Feb 12, 2007 at 01:31 UTC | |
|
Re: Does OCR::PerfectCR work at all?
by dpavlin (Friar) on Feb 11, 2007 at 12:47 UTC | |
|
Re: Does OCR::PerfectCR work at all?
by dirving (Friar) on Feb 11, 2007 at 20:27 UTC |