ImageGear Professional v18.2 > API Reference Guide > ISIS Component API Reference > ISIS Component Functions Reference > Single-Step Driver Control Functions > IG_ISIS_drv_run_step |
Transfer another buffer of data through an ISIS pipe.
Copy Code
|
|
---|---|
AT_ERRCOUNT ACCUAPI IG_ISIS_drv_run_step( HISISDRVRUN hRun, LPBYTE lpBuffer, WORD wCount, AT_MODE nFlags ); |
Name | Type | Description |
hRun | HISISDRVRUN | The handle of the "run" (zone data structure) being processed. This handle is initialized by the IG_ISIS_drv_run_start function that invoked the pipe. |
lpBuffer | LPBYTE | A pointer to the buffer that will hold the data to be transferred during the operation. |
wCount | WORD | The number of bytes to transfer during each IG_ISIS_drv_run_step. |
nFlags | AT_MODE |
A flag that specifies whether or not to wait until the number of bytes specified in wCount is available before transferring the data. The values of nFlags are as follows:
|
Returns the number of ImageGear errors that occurred during this function call. If there are no errors, the return value is IGE_SUCCESS.
Depends on the scanner driver.
See IG_ISIS_drv_run_start examples.
IG_ISIS_drv_run_step transfers a specified number of bytes or all available bytes through the ISIS pipe.
IG_ISIS_drv_run_step should only be called after calling IG_ISIS_drv_run_start. Also, if any parameters need to be set prior to invoking the ISIS pipe, IG_ISIS_drv_run_zone must be called after IG_ISIS_drv_run_start and before IG_ISIS_drv_run_step. Then, IG_ISIS_drv_run_step is called repeatedly until it returns a value of IG_ISIS_ERR_ENDZONE indicating that the run is complete. After all data is transferred, IG_ISIS_drv_run_done must be called to complete the run.
The iCount parameter of IG_ISIS_drv_run_step can be set as follows:
You must check the return value of the IG_ISIS_drv_put_data and wait for IG_ISIS_ERR_ENDZONE before assuming data transfer is complete. Some three-pass color scanners take minutes to reset after each pass. Furthermore, when each pass completes, depending on the driver and the status of the wWait flag, you may get the remainder of the bytes from the current pass, or you may not get the remainder of the bytes until the scanner has completed enough of the next pass to give you wCount bytes (in which case part of the data in lpcBuffer will be one color and part will be another color). |
IG_ISIS_drv_run_done can be called before IG_ISIS_drv_run_step has returned IG_ISIS_ERR_ENDZONE to stop zone processing. This is useful in implementing, for example, a "Cancel Scan" button.
IG_ISIS_drv_run_step is one of the basic components of IG_ISIS_drv_run_zone. It is one of four functions that when used together invoke an ISIS pipe. Invoking a pipe starts a scanning, reading, writing, compression, or other operation as defined by the drivers linked in the pipe.