#ifndef PROTO_SCANNERDEVICE_H
#define PROTO_SCANNERDEVICE_H


// device functions:
__asm __saveds int DevBeginIO(register __a1 struct IORequest *, register __a6 struct Library *);
__asm __saveds int DevAbortIO(register __a1 struct IORequest *, register __a6 struct Library *);

// public functions:
__asm __saveds struct ScannerInfo *GetScannerInfo(register __d0 ULONG, register __a0 STRPTR);
__asm __saveds struct List *LockScannerList(VOID);
__asm __saveds VOID UnlockScannerList(VOID);

// private functions:
__asm __saveds VOID AddInput(register __a0 struct MsgPort *, register __a1 BOOL receiver(), register __d0 int, register __d1 int);
__asm __saveds VOID RemInput(register __d0 int);
__asm __saveds VOID ParametersSet(register __d0 BYTE, register __a0 struct IOScanRequest *);
__asm __saveds APTR OpenProgressWin(register __a0 struct TagItem *, register __a1 struct IOScanRequest *);
__asm __saveds VOID ShowProgress(register __a0 APTR, register __d0 UBYTE);
__asm __saveds BOOL SavePrefs(register __d0 ULONG, register __a0 APTR, register __d1 int, register __a1 struct TagItem *);
__asm __saveds int OpenPrefs(register __d0 ULONG, register __a0 APTR, register __d1 int, register __a1 struct TagItem *);
__asm __saveds ULONG ReqMemory(register __d0 ULONG, register __d1 ULONG, register __d2 ULONG, register __a0 struct IOScanRequest *);
__asm __saveds BOOL ScanmodeOK(register __d0 ULONG, register __a0 struct IOScanRequest *);
__asm __saveds STRPTR ScannerName(register __d0 ULONG id);

// public functions:
__asm __saveds ULONG InitColorMappingA(register __a0 struct TagItem *);
ULONG __stdargs InitColorMapping(ULONG tag1, ...);
__asm __saveds VOID BuildBestPaletteA(register __d0 ULONG, register __a0 struct TagItem *);
VOID __stdargs BuildBestPalette(ULONG, ...);
__asm __saveds VOID MapToPaletteA(register __d0 ULONG, register __a0 struct TagItem *);
VOID __stdargs MapToPalette(ULONG, ...);
__asm __saveds VOID EndColorMapping(register __d0 ULONG);

#include "pragmas/scannerdevice_pragmas.h"

#endif
