[SerializableAttribute()]
public class PageRecognitionOptions
<SerializableAttribute()>
Public Class PageRecognitionOptions
public class PageRecognitionOptions
implements java.io.Serializable
[SerializableAttribute()]
public ref class PageRecognitionOptions
IncludeRectangles forms the region of the image that will be considered for feature extraction, any region outside the include region will be ignored.
If IncludeRectangles does not have a rectangle then the whole image will be considered as one include region for the feature extraction.
ExcludeRectangles forms the region of the image that will be ignored for feature extraction.
IncludeRectangles are considered first then the ExcludeRectangles will be excluded from the include region.
SvgDocument is the optional SVG document representation of this page if the original format supports loading as SVG. This is created and used by the recognition or processing engine.
This example adds a page image to an attributes.
using Leadtools.Forms.Common;
using Leadtools.Forms.Recognition;
using Leadtools.Codecs;
///This method add a page to the form attributes.
public void AddPageToFormAttributes(RasterImage page, FormRecognitionAttributes attributes, FormRecognitionEngine engine)
{
PageRecognitionOptions pageOptions = new PageRecognitionOptions();
pageOptions.AutoCleanUp = true;
pageOptions.UpdateImage = true;
pageOptions.TradeoffMode = FormsTradeoffMode.Accurate;
//Page is normal page, Not a card
pageOptions.PageType = FormsPageType.Normal;
pageOptions.IncludeRectangles.Add(new LeadRect(0, 0, page.Width, page.Height));
pageOptions.ExcludeRectangles.Add(new LeadRect(page.Width * 6 / 10,
page.Height * 4 / 10,
page.Width * 3 / 10,
page.Height * 2 / 10));
pageOptions.RegionOfInterestRectangles.Add(new LeadRect(page.Width * 1 / 10,
page.Height * 1 / 10,
page.Width * 2 / 10,
page.Height * 2 / 10));
FormRecognitionProperties properties = engine.GetFormProperties(attributes);
if (properties.IsMaster)
{
engine.OpenMasterForm(attributes);
engine.AddMasterFormPage(attributes, page, pageOptions);
engine.CloseMasterForm(attributes);
}
else
{
engine.OpenForm(attributes);
engine.AddFormPage(attributes, page, pageOptions);
engine.CloseForm(attributes);
}
}
Imports Leadtools.Forms.Common
Imports Leadtools.Forms.Recognition
Imports Leadtools.Codecs
'''This method add a page to the form attributes.
Public Sub AddPageToFormAttributes(page As RasterImage, attributes As FormRecognitionAttributes, engine As FormRecognitionEngine)
Dim pageOptions As New PageRecognitionOptions()
pageOptions.AutoCleanUp = True
pageOptions.UpdateImage = True
pageOptions.TradeoffMode = FormsTradeoffMode.Accurate
'Page is normal page, Not a card
pageOptions.PageType = FormsPageType.Normal
pageOptions.IncludeRectangles.Add(New LeadRect(0, 0, page.Width, page.Height))
pageOptions.ExcludeRectangles.Add(New LeadRect(page.Width * 6 / 10, page.Height * 4 / 10, page.Width * 3 / 10, page.Height * 2 / 10))
pageOptions.RegionOfInterestRectangles.Add(New LeadRect(page.Width * 1 / 10, page.Height * 1 / 10, page.Width * 2 / 10, page.Height * 2 / 10))
Dim properties As FormRecognitionProperties = engine.GetFormProperties(attributes)
If properties.IsMaster Then
engine.OpenMasterForm(attributes)
engine.AddMasterFormPage(attributes, page, pageOptions)
engine.CloseMasterForm(attributes)
Else
engine.OpenForm(attributes)
engine.AddFormPage(attributes, page, pageOptions)
engine.CloseForm(attributes)
End If
End Sub
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.