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

Questions, comments and suggestions concerning VintaSoft Twain ActiveX.

Moderator: Alex

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

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

Post by Alex » Thu Jul 24, 2008 8:26 am

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 = 4387     ' 0x1123
  VSTwain1.CapType = 0           ' One value
  VSTwain1.capValue = 150        ' can be changed from 0 to 255
  VSTwain1.SetCap()
  VSTwain1.Acquire()

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests