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

New to scanner world, need help on TWAIN scanner standard.

Forums › TWAIN Classic › New to scanner world, need help on TWAIN scanner standard.

  • This topic has 13 replies, 5 voices, and was last updated 7 years, 9 months ago by danny rough.
Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • March 11, 2006 at 4:56 pm #21888 Reply
    Anonymous
    Participant
    • Topics - 60
    • Replies - 107
    • Total Posts - 167

    Hi All,

    I am working in a orgainzation situated in India.
    I have been assigned a task.To get list of TWAIN Driver Installed in the Windows System & I can customize the Scanner setting & those settings need to used by a Product to scan the picture based on those setting into their software.

    Please help me. I will be thankful to you all.

    March 16, 2006 at 10:43 am #23253 Reply
    gabe
    Participant
    • Topics - 9
    • Replies - 583
    • Total Posts - 592

    whats the development enviroment?

    March 16, 2006 at 5:39 pm #23254 Reply
    Sahaj
    Participant
    • Topics - 0
    • Replies - 4
    • Total Posts - 4

    Developement environmnent is .net but I have some liberty to implement it in VC++ too.
    but my main dev envt is .net & windows.

    Thanks,
    Sahaj

    March 16, 2006 at 9:15 pm #23255 Reply
    Anonymous
    Participant
    • Topics - 60
    • Replies - 107
    • Total Posts - 167

    c#, vb.net or other?
    2003 or 2005?

    if you havent read the 1.9 spec, read it. read it a lot.
    any specific scanner hardware being targeted? any specific OS targeted?

    the hardware specific questions are (i think) rather important, as if you’re only tasked with writing an app to manipulate the settings covered by the twain spec you’ll be alright, but a lot of the manufactures have custom capabilities, custom operations, and custom return codes. i think writing an app to be competely hardware agnostic and still offer complete device manipulation is a rather large request (or maybe your project timeline is just massive – or perhaps you have massive resources available)

    Are you looking for an off the shelf library, or are you planning to write the twain_32 wrapper as well?
    Are you trying to run the twain device from a winform, webform or service? Have you taken a look as WIA2?, it could be (depending on the scanner and OS you’re targetting as not all hardware or OSs support WIA2)
    There exist several rather decent twain librarys around, most for just a few hundred dollars. Not that I’m trying to talk you out of writing your our library (i am).

    What setting are you trying to manipulate?

    If you don’t mind my asking, whats the project timeline, how much do you have implemented so far?

    Sorry if I appear to ask more questions than i answer, but i think this will come to a point rather soon, if you answer them all.

    gabe

    March 17, 2006 at 3:48 pm #23256 Reply
    Sahaj
    Participant
    • Topics - 0
    • Replies - 4
    • Total Posts - 4

    Hi gabe,

    Thanks for taking interest in my queries.

    Well I like to inform you that,I am totaly new to this domain. I am developing the application in C#.Net.

    I am asked to create an application which can interact with any twain or ISIS enabled scanner device.
    then I need to scan the Images based on the setting of Scanner.
    some times without opening the scanner interface.

    OS used are windows 2000/Xp/2003 they are also targeting this application for 64bit platform too.

    I have downloaded twain1.8 specification file. I am not able to find the TWAIN1.9 spec file.Currently I have started looking into 1.8 spec.

    This application can be run through web too. Hence need to support scanning through web also.

    My project time line is 3 months.Currently I have just created the UI enviorment as per our client expectation.

    I don’t have any knowledge about WIA2.

    Thanks,
    Sahaj

    March 17, 2006 at 3:51 pm #23257 Reply
    Sahaj
    Participant
    • Topics - 0
    • Replies - 4
    • Total Posts - 4

    Hi Gabe,

    Please ask if any queries if you have.
    I will be thankful to you. if you can provide me start, to my task.
    Please if you can provide me some guiding material too.

    if you project timeline doesn’t hamper.

    Thanks,
    Sahaj

    March 17, 2006 at 3:53 pm #23258 Reply
    gabe
    Participant
    • Topics - 9
    • Replies - 583
    • Total Posts - 592

    wow. thats quite a request for 3 months…

    the 1.9 spec is here
    https://www.twain.org/docs/Spec1_9_197.pdf

    March 17, 2006 at 10:51 pm #23259 Reply
    gabe
    Participant
    • Topics - 9
    • Replies - 583
    • Total Posts - 592

    Where to start…, um maybe with my twain background so this will be taken in the right context. I’m a nobody. I started a project that sounded like yours maybe 2 months ago. Yeah I’ve read the spec a couple dozen times, and been through this forum’s archive for a few things, but that’s it. With that out of the way,

    >with any twain device,
    This part hurts. This part hurts a lot, but I’ll be finishing with this part not starting.

    >with any ISIS device,
    I honestly have no idea of where to even start with ISIS. Lemme know if you find any .net resources in that direction, I haven’t looked into anything other than twain and wia2.

    >then I need to scan the Images based on the setting of Scanner.
    I like the sound of this part, especially the part where you say ‘based on the setting of the scanner’, that makes me maybe think that whatever the settings for the device happen to be at the time, that they are acceptable, or maybe that the default settings for any particular device will do, that I think (if it were me tasked with this assignment) is possible.
    But somehow I don’t think that’s how it’s really meant. I get the feeling that you are tasked with an ‘everything for everyone’ twain project.
    If my feeling here is even close to right and that part actually means that you’ll maybe have to adjust the current settings for any device (that last ‘any’ is important and I’ll be coming back to it) then this project is going to either go over 3 months or cut a feature, or two, or all but one or two. (Again, this is just Gabe talking – take no offence)

    >some times without opening the scanner interface.
    This I like, but only a little bit. Some devices won’t let you do this via twain. Reference the twain spec, and pay attention to the part where it says ‘Set the ShowUI field of the TW_USERINTERFACE structure to FALSE.’ In particular if you look thru for all the parts of the spec that mention ShowUI, you’ll get a pretty decent idea of what’s possible here, what’s not, and when.

    >OS used are windows 2000/Xp/2003
    I like this part too, it gives me the feeling that WIA2 may be able to do some of the heavy lifting that this project may take – well at least for the xp/2003 part. I don’t think 2000 supports WIA2. Check that part, it might.

    >they are also targeting this application for 64bit platform too.
    This part makes me a little uncomfortable; I don’t think the 64bit bits of twain are final yet – at least not with good driver support. Maybe someone else here on the board can share their experiences with 64bit windows twain support.

    >This application can be run through web too. Hence need to support scanning through web also.
    Yeah, that just makes uncomfortable. I’m pretty sure it can be done, but I’m not that guy – sorry. But it is another reason to start looking further into WIA2, as WIA2 is specifically targeted to web development.

    >My project time line is 3 months.
    man I hope you’re a better developer than I am, (no that’s not true – honestly I’m fairly competitive, I only say that in the hope that you’ll pull this off, and immediately thereafter post the code for everyone to learn from and use in their projects as well) Meaning that I lack the confidence to state that I could reach all those goals by myself in that time period.

    >I don’t have any knowledge about WIA2.
    Start looking into the samples, the msdn library that is attached to vs2005 has a real nice set of samples and articles dealing with WIA2 – Windows Image Automation 2. Be warned that wia2 looks to be supported only in the XP sp2 and up OSs, and is not completely supported by every scanner out there – maybe most of the new ones but not all.
    Checkout what the people that wrote ‘Paint.net’ have done with WIA, its nothing short of amazing. Paint.net is available with full source code (bout 100,000 lines of pretty solid code), google for it.

    OK, with that out of the way. My feeling is that the hardest part of getting this project delivered 100% as stated starts with the ‘any’ part. The more twain devices I see the more I think that calling twain a protocol is maybe a stretch. I’d call it more of a guideline, or maybe a set of best practices.
    The kicker is that even when a manufacturer does follow the spec, the spec leaves a lot of room for custom capabilities. For example, HP or Canon may decide that they can provide a better image by added a few more capabilities (and they almost always do), but where exactly are those documented? Call the vendor, then what do you do if two vendors use the same number for different capabilities, or even if they use the same capability Id, if they define is differently, so one takes an array and the other takes an enumeration? Write seperate libraries for seperate vendors? Ok even if you’re willing to do that, what happens with the vendor changes the capabiliy from one driver to another. You can’t really call foul becasue after all, this is a custom capability in the first place. Or you could choose to just ignore all the custom capabilities, but I bet that eventually someone is going to ask for feature x, that works with the vendors software but not yours. Lately when I think of the twian spec, for some reason, the League of Nations comes to mind. (maybe I should sleep more)

    If you could narrow you project down a bit, if you could for instance choose to support only one vendor’s hardware, or if you could choose to support only the capabilities listed in the spec and no custom capacities, they project would start to look more do-able (again this is just me talking)

    Finishing with more positive stuff. Resources. If you haven’t already started looking at the c# twain article on code project, go their.
    If you have the luxury of seriously considering one of the twain libraries already on the self, start looking at what’s out there. … I already mentioned looking into WIA2, what else…

    Feel free to contact me on or off the board, I just sit round working on my twain library anyway so I have code right in front of me. You’re more than welcome to the code that I have (just drop me an email), eventually I’ll feel that it warrants a gotdotnet or sourceforge site and I’ll post it. Its vb.net 2005 code and should come out of sharpDevelop’s beta 2 in decent enough shape for you to figure out the minor conversion problems, and its got more than a bit of comments (but doesn’t everyone think this about their own code – at least while its fresh in memory?)

    gabe

    March 17, 2006 at 11:00 pm #23260 Reply
    gabe
    Participant
    • Topics - 9
    • Replies - 583
    • Total Posts - 592

    darnit, and after all of that I left out the best resource. the twiain toolkit, its c++ but its easily the best resource I have. https://www.twain.org/devfiles/twainkit.exe

    March 19, 2006 at 7:02 pm #23261 Reply
    Sahaj
    Participant
    • Topics - 0
    • Replies - 4
    • Total Posts - 4

    Hi Gabe,

    Thanks a lot

    I will be in your touch after reading the TWIAN1.9 & will do R & D on TWIAN Toolkit.

    Thanks,
    Sahaj

    March 24, 2006 at 9:11 am #23262 Reply
    sourabhv
    Participant
    • Topics - 3
    • Replies - 4
    • Total Posts - 7

    hey Gabe,
    can you do me a favour? please mail the code you wrote to me..I m working on the same project over here. I am anot able to scan the image as per user’s PIXEL type specification(RGB,GREY,B&W) it is scanning the image in RGB mode only. I have Kodak i5o scanner at my desk.
    Thanking you in anticipation.
    Ragards,
    Saurabh.

    March 24, 2006 at 9:14 am #23263 Reply
    gabe
    Participant
    • Topics - 9
    • Replies - 583
    • Total Posts - 592

    email you the code…..

    do i have your address?, i don’t see it on your profile. -check my profile and send me an email and i’ll get it out to ya,

    gabe

    March 24, 2006 at 9:17 am #23264 Reply
    sourabhv
    Participant
    • Topics - 3
    • Replies - 4
    • Total Posts - 7

    Gabe,
    just mailed you on your gmail account. PLz reply.
    Thanks alot for your support. Can i get your yahoo id plz? so that we can chat on messenger.
    Saurabh.

    May 2, 2013 at 2:05 am #23265 Reply
    danny rough
    Participant
    • Topics - 0
    • Replies - 8
    • Total Posts - 8

    If you are new to the area, i think you can just use diiferent kinds of scanners to accumulate experience, for example, to scan an ISIS image , you can employ different versions of scanners. there are many scanners on the internet , i suggest you to download some and try them on different formats, then you can get to know the standard gradually.

  • Author
    Posts
Viewing 14 posts - 1 through 14 (of 14 total)
Reply To: New to scanner world, need help on TWAIN scanner standard.
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

  • EPSON V600 TWAIN and WIA on Windows 10
  • When and how to use WaitForEvents command ?
  • Problem enumerating list of installed scanners in windows server 2012
  • Failed to create TWAIN progress! Error code is 1260.
  • To get the list of scanners from javascript client side (browser)
  • 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.