TWAIN Working Group

Newsletter Signup
Donate
Help keep TWAIN free
  • About TWAIN
    • What’s New?
    • News
    • Events
    • Membership
    • Consider a Donation
    • Contact Us
  • Why TWAIN?
  • Developers
    • Driver Developer
    • Application Developer
    • TWAIN Features
    • Specification & Tools
    • Self Certification Process
  • Support Forums
  • Scanner End-User
  • Find Certified Drivers
    • Facebook
    • LinkedIn
    • Vimeo

How to set Sensitivity of AutoDiscardBlankPage function ?

Forums › TWAIN Classic › How to set Sensitivity of AutoDiscardBlankPage function ?

  • This topic has 2 replies, 2 voices, and was last updated 6 years ago by rufree.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • August 6, 2014 at 2:52 am #22964 Reply
    rufree
    Participant
    • Topics - 1
    • Replies - 1
    • Total Posts - 2

    My Project must to implement AutoDiscardBlankPage function to Fujitsu Scanner fi-6670 with C++ language
    So,It works correctly but It refers sensitivity value in ScanAllPro Program
    Even if ScanAllPro set sensitivity = 0 , my function (AutoDiscardBlankPage) doesn’t skip blank page .
    I need to know how to use Twain Library for set sensitivity of AutoDiscardBlankPage function with C++ ?

    Thanks for all the Suggestions ^^”
    (Sorry for my english skill)

    this my code

    BOOL CMyTwainDlg::TWAIN_UTIL_SetAutoDiscardBlankPages(BOOL bEnabled,int check)
    {

    TW_CAPABILITY twDPI;
    pTW_ONEVALUE ptwOneVal;
    BOOL ret = FALSE;

    if(DSOpen() || OpenSource())
    {
    twDPI.Cap = ICAP_AUTODISCARDBLANKPAGES;
    twDPI.ConType = TWON_ONEVALUE;

    if(check == 1){
    twDPI.hContainer = GlobalAlloc(GHND, sizeof(TW_ONEVALUE));
    ptwOneVal = (pTW_ONEVALUE) GlobalLock(twDPI.hContainer);
    ptwOneVal->ItemType = TWTY_INT32;
    ptwOneVal->Item = (TW_UINT32)TWBP_AUTO;
    ret = CallTwainProc(&m_AppId, &m_Source, DG_CONTROL, DAT_CAPABILITY, MSG_SET,(TW_MEMREF)&twDPI);
    GlobalUnlock(twDPI.hContainer);
    GlobalFree(twDPI.hContainer);
    }else {
    twDPI.hContainer = GlobalAlloc(GHND, sizeof(TW_ONEVALUE));
    ptwOneVal = (pTW_ONEVALUE) GlobalLock(twDPI.hContainer);
    ptwOneVal->ItemType = TWTY_INT32;
    //ptwOneVal->ItemType = 2;
    ptwOneVal->Item = (TW_UINT32)TWBP_DISABLE;
    ret = CallTwainProc(&m_AppId, &m_Source, DG_CONTROL, DAT_CAPABILITY, MSG_RESET,(TW_MEMREF)&twDPI);
    GlobalUnlock(twDPI.hContainer);
    GlobalFree(twDPI.hContainer);
    }

    }
    return ret;
    }

    November 12, 2014 at 9:09 am #26179 Reply
    Catherine Sea
    Participant
    • Topics - 0
    • Replies - 59
    • Total Posts - 59

    You may want to adjust the settings of Blank Image Threshold and Blank Image MaxStdDev. This kb article might help.

    The two properties are from Dynamic Web TWAIN. You should be find the corresponding capabilities in TWAIN Specification.

    February 17, 2015 at 3:42 am #26180 Reply
    rufree
    Participant
    • Topics - 1
    • Replies - 1
    • Total Posts - 2

    If I used ICAP_THRESHOLD , So I must to scan in Blank&White mode only , right ?
    because I read Twain’s manual (2.3)
    Description
    Specifies the dividing line between black and white. This is the value the Source will use to
    threshold, if needed, when ICAP_PIXELTYPE = TWPT_BW.

    but I need to use skipblankpages function in all of Pixeltype’s mode (ICAP_PIXELTYPE)

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: Reply #26179 in How to set Sensitivity of AutoDiscardBlankPage function ?
Your information:




Quick Links

Service Providers
TWAIN Support Forums
Membership
Contact Us
Privacy Policy

Newsletter Signup

TWAIN Working Group Family

TWAIN Working Group
TWAIN Direct®
TWAIN Resources
TWAIN Certified Drivers
PDF/raster

  • Facebook
  • GitHub
  • LinkedIn
  • Vimeo

Recent Topics

  • Scanner starts transfer when console gets closed (CITRIX)
  • Kodak RFS 3600
  • Didn’t save enough file scan
  • EPSON V600 TWAIN and WIA on Windows 10
  • When and how to use WaitForEvents command ?
  • Quarterly Newsletter
  • TWAIN Working Group Membership
  • Logo Usage
  • TWAIN License
  • Contact Us
Privacy Policy • Privacy Tools • Copyright © 2021 TWAIN Working Group • by iHwy, LLC • Log in

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.