KB: How to set the brightness and contrast at scanning?

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

Moderator: Alex

Post Reply
Alex
Site Admin
Posts: 2303
Joined: Thu Jul 10, 2008 2:21 pm

KB: How to set the brightness and contrast at scanning?

Post by Alex »

Brightness and contrast of color, gray and palette images may be set with the Brightness capability:

Code: Select all

  VSTwain1.StartDevice()
  VSTwain1.OpenDataSource()
  VSTwain1.Brightness = VSTwain1.BrightnessMaxValue
  VSTwain1.Contrast = VSTwain1.ContrastMaxValue
  VSTwain1.Acquire()
Brightness and contrast of black-white images may be set with the IThreshold capability:

Code: Select all

  VSTwain1.StartDevice()
  VSTwain1.OpenDataSource()
  VSTwain1.Capability = DeviceCapability.IThreshold
  VSTwain1.CapType = CapType.OneValue
  VSTwain1.capValue = 150      ' can be changed from 0 to 255
  VSTwain1.SetCap()
  VSTwain1.Acquire()
Post Reply