Pegasus Imaging Corporation
Accusoft Pegasus

imaging SDKs that accelerate development

OCR Xpress™ FAQ

Contact Support



Q1How can I determine if I have the latest version of an Accusoft Pegasus control?
Q2How do I distribute my application?
Q3What DLL’s do I need to distribute with my application?
Q4I have an image with X and Y resolutions that are not equal and after processing with OCR Xpress the exported OCR results are not as accurate as I would like. Why is this occurring and how can the recognition results be improved?
Q5What languages does OCR Xpress support?

Q1: How can I determine if I have the latest version of an Accusoft Pegasus control?
Please download the PegConnect utility program from the following link: PegConnect
or reference the Latest Builds page.

Q2: How do I distribute my application?
Please note: You must have received unlock codes in order to distribute applications. These are received when runtimes are purchased. If you have not received them please Contact Sales.

1) If you are using the .NET interface you must call the UnlockRuntime method in the Licensing class where the application begins and pass the unlock codes as the parameters. For example:

ocrXpress1.Licensing.UnlockRuntime(1234,1234,1234,1234);

2) If you are using the ActiveX control you must call the UnlockRuntime method where your application begins and pass the unlock codes as the parameters. For example:

OCRXpress1.UnlockRuntime 1234,1234,1234,1234


Q3: What DLL’s do I need to distribute with my application?
1) If you are using the ActiveX interface please distribute the following DLL:

PegasusImaging.ActiveX.OcrXpress1.dll

Please Note: You must register the PegasusImaging.ActiveX.OcrXpress1.dll via your installation program or manually via the regsvr32.exe utility.

2) If you are using the .NET interface please distribute the following DLL:

PegasusImaging.WinForms.OcrXpress1.dll

Q4: I have an image with X and Y resolutions that are not equal and after processing with OCR Xpress the exported OCR results are not as accurate as I would like. Why is this occurring and how can the recognition results be improved?
The current OCR Xpress toolkit requires that the X and Y resolutions be equal to obtain accurate OCR results. A verification of the resolutions can be done with ImagXpress and if the resolutions are different the image data resized. The code detailed below outlines how to get around this issue:

If using the ActiveX version of ImagXpress:

If ImagXpress1.IResX > ImagXpress1.IResY Then
   ImagXpress1.ResizeEx RT_Fast, ImagXpress1.IWidth, ImagXpress1.IHeight * ImagXpress1.IResX / ImagXpress1.IResY
   ImagXpress1.IResY = ImagXpress1.IResX
ElseIf ImagXpress1.IResX < ImagXpress1.IResY Then
   ImagXpress1.ResizeEx RT_Fast, ImagXpress1.IWidth * ImagXpress1.IResX / ImagXpress1.IResY, ImagXpress1.IHeight
   ImagXpress1.IResX = ImagXpress1.IResY
End If

OcrXpress1.AddPageHdib ImagXpress1.hDIB

If using the .NET version of ImagXpress:

if (ix8.Image.HorizontalResolution() > ix8.Image.VerticalResolution())
{ // If the x resolution is larger than the y resolution,
    // Set the y resolution to the x resolution and increase the height of the image
   ix8.Image.Resolution.Units = System.Drawing.GraphicsUnit.Inch;
   float myDiv = ix8.Image.HorizontalResolution() / ix8.Image.VerticalResolution();
   int myInt = System.Convert.ToInt32(myDiv) * 1000;
   System.Drawing.Size mySize = new System.Drawing.Size(ix8.Image.ImageXData.Width, (ix8.Image.ImageXData.Height * myInt) / 1000);
   ix8Proc.Image = ix8.Image;
   ix8Proc.Resize(mySize, ResizeType.Fast);
   ix8.Image = ix8Proc.Image;
    //set resolution
   ix8.Image.Resolution.Dimensions = new System.Drawing.SizeF(ix8.Image.HorizontalResolution(), ix8.Image.HorizontalResolution());
   System.IO.MemoryStream memStream = new System.IO.MemoryStream();
   ix8.Image.SaveStream(memStream, ImageXFormat.Tiff);
   memStream.Seek(0, System.IO.SeekOrigin.Begin);
   ix8.Image = PegasusImaging.WinForms.ImagXpress8.ImageX.FromStream(memStream);
   OcrXpress1.Document.AddPage(ix8.Image.ToHdib(False));
}
else if (ix8.Image.HorizontalResolution() < ix8.Image.VerticalResolution() )
{ // If the y resolution is larger than the x resolution,
    // Set the x resolution to the y resolution and increase the width of the image
   ix8.Image.Resolution.Units = System.Drawing.GraphicsUnit.Inch;
   float myDiv = ix8.Image.VerticalResolution() / ix8.Image.HorizontalResolution();
   int myInt = System.Convert.ToInt32(myDiv) * 1000;
   System.Drawing.Size mySize = new System.Drawing.Size((ix8.Image.ImageXData.Width * myInt) / 1000, ix8.Image.ImageXData.Height);
   ix8Proc.Image = ix8.Image;
   ix8Proc.Resize(mySize, ResizeType.Fast);
   ix8.Image = ix8Proc.Image;
   //set resolution
   ix8.Image.Resolution.Dimensions = new System.Drawing.SizeF(ix8.Image.VerticalResolution(), ix8.Image.VerticalResolution());
   System.IO.MemoryStream memStream = new System.IO.MemoryStream();
   ix8.Image.SaveStream(memStream, ImageXFormat.Tiff);
   memStream.Seek(0, System.IO.SeekOrigin.Begin);
   ix8.Image = PegasusImaging.WinForms.ImagXpress8.ImageX.FromStream(memStream);
   OcrXpress1.Document.AddPage(ix8.Image.ToHdib(False));
}

Q5: What languages does OCR Xpress support?
OCR Xpress supports the following languages:
English, French, German, Italian, Spanish, Portuguese, Danish, Dutch, Swedish, Norwegian, Hungarian, Polish, and Finnish