Leadtools.ImageProcessing.Core Send comments on this topic. | Back to Introduction - All Topics | Help Version 15.12.10
Flags Property
See Also  Example
Leadtools.ImageProcessing.Core Namespace > BlankPageDetectorCommand Class : Flags Property




Gets or sets flags that indicate whether the page is empty or noisy, whether to ignore bleed-through, whether to ignore lines, whether to use the active area and whether to use default margins or the user-specified margins.

Syntax

Visual Basic (Declaration) 
Public Property Flags As BlankPageDetectorCommandFlags
Visual Basic (Usage)Copy Code
Dim instance As BlankPageDetectorCommand
Dim value As BlankPageDetectorCommandFlags
 
instance.Flags = value
 
value = instance.Flags
C# 
public BlankPageDetectorCommandFlags Flags {get; set;}
Managed Extensions for C++ 
public: __property BlankPageDetectorCommandFlags get_Flags();
public: __property void set_Flags( 
   BlankPageDetectorCommandFlags value
);
C++/CLI 
public:
property BlankPageDetectorCommandFlags Flags {
   BlankPageDetectorCommandFlags get();
   void set (BlankPageDetectorCommandFlags value);
}

Return Value

Gets or sets flags that indicate whether the page is empty or noisy, whether to ignore bleed-through, whether to ignore lines, whether to use the active area and whether to use default margins or the user-specified margins. The default value is BlankPageDetectorCommandFlags::DetectEmptyPage | BlankPageDetectorCommandFlags::DontIgnoreBleedThrough | BlankPageDetectorCommandFlags::DontDetectLinedPage | BlankPageDetectorCommandFlags::DontUseActiveArea | BlankPageDetectorCommandFlags::UseDefaultMargins

Example

Visual BasicCopy Code
ImageProcessing.Core.BlankPageDetectorCommand
   Public Sub BlankPageDetectorCommandExample()
      RasterCodecs.Startup()
      Dim codecs As New RasterCodecs()
      codecs.ThrowExceptionsOnInvalidImages = True

      Dim leadImage As RasterImage = codecs.Load("C:\Program Files\LEAD Technologies\LEADTOOLS 15\Images\Clean.tif")

      ' Prepare the command
      Dim command As BlankPageDetectorCommand = New BlankPageDetectorCommand
        'Determine whether the image is blank.
      command.Flags = BlankPageDetectorCommandFlags.DetectNoisyPage

      command.Run(leadImage)
      MessageBox.Show(" Is Blank : " & command.IsBlank & "\n Accuracy : " & (command.Accuracy * 1.0 / 100) & "%", "Blank Page Detection Results")


      RasterCodecs.Shutdown()
   End Sub
C#Copy Code
ImageProcessing.Core.BlankPageDetectorCommand 
      public void BlankPageDetectorCommandExample() 
      { 
         // Load an image 
         RasterCodecs.Startup(); 
         RasterCodecs codecs = new RasterCodecs(); 
         codecs.ThrowExceptionsOnInvalidImages = true; 
 
         RasterImage image = codecs.Load(@"C:\Program Files\LEAD Technologies\LEADTOOLS 15\Images\Clean.tif"); 
 
         // Prepare the command 
         BlankPageDetectorCommand command = new BlankPageDetectorCommand(); 
         //Determine whether the image is a blank page 
         command.Flags = BlankPageDetectorCommandFlags.DetectNoisyPage; 
         command.Run(image); 
 
         MessageBox.Show(" Is Blank   : " + command.IsBlank + "\n Accuracy : " + (command.Accuracy * 1.0 / 100) + "%", "Blank Page Detection Results"); 
 
         RasterCodecs.Shutdown(); 
      }

Requirements

Target Platforms: Microsoft .NET Framework 2.0, Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also