Unclear DetectBorder feature

Questions, comments and suggestions concerning VintaSoft Twain .NET SDK.

Moderator: Alex

Post Reply
isoler
Posts: 3
Joined: Thu Apr 06, 2017 1:01 pm

Unclear DetectBorder feature

Post by isoler »

Hello all,

we don't understand what the DetectBorder method does and how it works. Documentation just says:
Detects the border around the image.
borderSize
Size of border around the image. Possible values: 0 - 100. Default value is 5.
We need to detect if there is a border on the image and remove it but we don't know the border size so how can we specify its size on the parameter? And what does the method when detects the border? Deletes it? Change the border color?

Thanks in advance.
Alex
Site Admin
Posts: 2305
Joined: Thu Jul 10, 2008 2:21 pm

Re: Unclear DetectBorder feature

Post by Alex »

Hello,

The DetectBorder method:
  • finds the background color
  • finds the pixels with background color on the image border and determines the image border rectangle
  • inflates the image border rectangle if borderSize parameter is greater than 0
  • crops the image using the image border rectangle
Please try to use VintaSoft Document Cleanup .NET Plug-in if you need professional functionality for processing of document images.

Best regards, Alexander
Post Reply