Reviewed and revised December 2023
tab(-10, AG_IMAGE); opcode, <parameters>; chr(127); Tab(-10,x) Syntax Notes
Note: as with most other AG_xxx functions, the subroutine front-end is preferable if available. In this case, that would be AUI_IMAGE, which see for definitions of the parameters—including status—referenced below.
AG_IMAGE (35) provides access to A-Shell's image processing functions. Use the following syntax:
tab(-10,AG_IMAGE); IMGOP_LOAD, handle, fspec; chr(127);
tab(-10,AG_IMAGE); IMGOP_CLOSE, handle; chr(127);
tab(-10,AG_IMAGE); IMGOP_DISPLAY, handle, srow, scol, erow, ecol, flags; chr(127);
tab(-10,AG_IMAGE); IMGOP_LOADDISP, handle, srow, scol, erow, ecol, flags, fspec; chr(127);
tab(-10,AG_IMAGE); IMGOP_INFO, handle, fspec; chr(127);
tab(-10,AG_IMAGE); IMGOP_HIDE, handle; chr(127);
tab(-10,AG_IMAGE); IMGOP_ACQUIRE, handle, fspec, compfactor, appname, pages, scanflags; chr(127);
tab(-10,AG_IMAGE); IMGOP_SELECTSRC, handle, srcname; chr(127);
tab(-10,AG_IMAGE); IMGOP_TWERR, handle; chr(127);
tab(-10,AG_IMAGE); IMGOP_CAPTURE, handle, fspec, compfactor, winid; chr(127);
tab(-10,AG_IMAGE); IMGOP_SAVEAS, handle, fspec, compfactor; chr(127);
tab(-10,AG_IMAGE); IMGOP_PAGEINFO, handle, fspec; chr(127);
Response
For IMGOP_INFO:
status, handle, owidth, olength, dwidth, dlength, bpp CR
For IMGOP_ACQUIRE:
stspages <CR> (a composite two byte value, with the status in the lower byte and the number of pages scanned in the upper byte).
For IMGOP_PAGEINFO:
pages <CR> (number of pages in the specified file)
For all other opcodes:
status, handle CR
Example
map1 status, i, 4
map1 handle, i, 4
map1 imgspec$,s,160
writecd tab(-10,AG_IMGOP_LOAD); handle, imgspec$; chr(127);
input "", status ,handle
See Also