VintaSoft Twain .NET SDK Discussions
Questions, comments and suggestions concerning VintaSoft Twain .NET SDK.
Board index < VintaSoft Twain < VintaSoft Twain .NET SDK Discussions
DeviceCapability filterCap = device.Capabilities.Find(DeviceCapabilityId.IFilter);
if (filterCap == null)
throw new ApplicationException("ICAP_FILTER capability is not supported by device.");
Next, you need get supported values of capability:
DeviceCapabilityValueBase filterCapValue = filterCap.GetValue();
switch (filterCapValue.ContainerType)
{
case DeviceCapabilityContainerType.Array:
ArrayDeviceCapabilityValue filterCapValueAsArray = (ArrayDeviceCapabilityValue)filterCapValue;
// get supported values of capability
...
break;
case DeviceCapabilityContainerType.Enum:
EnumDeviceCapabilityValue filterCapValueAsEnum = (EnumDeviceCapabilityValue)filterCapValue;
// get supported values of capability
...
break;
}
Finally, you need set value of capability:
filterCap.SetValue(X);Best regards, Alexander
VSTwain1.Capability = (int)Vintasoft.Twain.DeviceCapability.IFilter;
if (!VSTwain1.IsCapSupported())
throw new ApplicationException("ICAP_FILTER capability is not supported by device.");
Next, you need get supported values of capability:
VSTwain1.GetCap();
switch (VSTwain1.CapType)
{
case CapType.Array:
// get supported values of capability
...
break;
case CapType.Enum:
// get supported values of capability
...
break;
}
Finally, you need set value of capability:
VSTwain1.CapType = CapType.OneValue; VSTwain1.CapValue = X; VSTwain1.SetCap();Best regards, Alexander
Although I had to guess the Green value to be '1' as the CapType (0 for red and 2 for blue I think) for this capability is OneValue and I could not get all the valid values.Here is a list of available values for ICAP_FILTER capability:
Is there anyway to get the Capabilities of a particular scanner (before purchasing it) so that we can recommend the client which scanner to purchase incase they need to dropout any particular color?Most of photo scanners can dropout colors.