public twain() { appid = new twainDefs.TwIdentity(); appid.Id = IntPtr.Zero; appid.Version.MajorNum = 1; appid.Version.MinorNum = 1; appid.Version.Language = LanguageCHINESE; appid.Version.Country = CountryUSA; appid.Version.Info = "Version 2.0"; appid.ProtocolMajor = twainDefs.TwProtocol.Major; appid.ProtocolMinor = twainDefs.TwProtocol.Minor; appid.SupportedGroups = (int)(twainDefs.TwDG.Image | twainDefs.TwDG.Control); appid.Manufacturer = "PBSoftware"; appid.ProductFamily = "InfinityPOS"; appid.ProductName = "PBSoftware TWAIN"; srcds = new twainDefs.TwIdentity(); //srcds.Id = IntPtr.Zero; evtmsg.EventPtr = Marshal.AllocHGlobal(Marshal.SizeOf(winmsg)); }
private static extern twainDefs.TwRC DSpxfer([In, Out] twainDefs.TwIdentity origin, [In] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, [In, Out] twainDefs.TwPendingXfers pxfr);
private static extern twainDefs.TwRC DSixfer([In, Out] twainDefs.TwIdentity origin, [In] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, ref IntPtr hbitmap);
private static extern twainDefs.TwRC DSiinf([In, Out] twainDefs.TwIdentity origin, [In] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, [In, Out] twainDefs.TwImageInfo imginf);
private static extern twainDefs.TwRC DScap([In, Out] twainDefs.TwIdentity origin, [In] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, [In, Out] twainDefs.TwCapability capa);
private static extern twainDefs.TwRC DSstatus([In, Out] twainDefs.TwIdentity origin, [In] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, [In, Out] twainDefs.TwStatus dsmstat);
private static extern twainDefs.TwRC DSevent([In, Out] twainDefs.TwIdentity origin, [In, Out] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, ref twainDefs.TwEvent evt);
private static extern twainDefs.TwRC DSuserif([In, Out] twainDefs.TwIdentity origin, [In, Out] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, twainDefs.TwUserInterface guif);
private static extern twainDefs.TwRC DSMImageLayout([In, Out] twainDefs.TwIdentity origin, [In, Out] twainDefs.TwIdentity dest, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, [In, Out] twainDefs.TwImageLayout idds);
private static extern twainDefs.TwRC DSMident([In, Out] twainDefs.TwIdentity origin, IntPtr zeroptr, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, [In, Out] twainDefs.TwIdentity idds);
private static extern twainDefs.TwRC DSMparent([In, Out] twainDefs.TwIdentity origin, IntPtr zeroptr, twainDefs.TwDG dg, twainDefs.TwDAT dat, twainDefs.TwMSG msg, ref IntPtr refptr);