		6-dec-79
	N.C.A.R
	Boulder, colorado
	(303)-494-5151 x718
	Bob Brown

	This briefly describes IMG the image manipulation utility.
	It may be used with its companion SHO.

	IMG is designed to move images from device to device and to and
from FILES-11 devices as well. The implementation can be used with
most any video display device with 512x512 organization. Other display
formats may be easily accomdated provided that small parametric changes
are made to IMG source. The pixel resolutions handled are 8 bit byte and
1 bit . Others could be handled with reworking of source.

 The first implementation handles 
features of the COMTAL Vision 1 display which has 3 images planes and 4
graphic overlay planes as well as a function memory for each image and
a color table for psuedo-color enhancement. The image planes are 
addressed as CD:,CD1:,CD2: but if the user has ASNed logical
names ,ie. ASN CD:=IM1:/GBL ,the logical should be used as they make it easier
on the user. The color and function memory tables are in
CD7: thru CD14:.

	ALL units are directly addressed,even though they are not
512x512 by 8 bits. The image memory planes may be reassigned to be IM1:,
IM2:,IM3: because people dont like to think of plane 1 as unit 0.
	It should be easy to use the code in a RSX-11 system where more or
less image or graphic memories are present.
	 The only QIO
required to be recognized by the device IO.RLB/IO.WLB for standard 
raster line moves of data. The QIO must include as parameters the 
starting Y line # and X byte element #. Currently the X byte element
is always zero,(and not honored by the driver).

	QIO$s #IO.RLB,lun,lun,,iosb,,<#BUF,NBYTES,,,YLINE,X>


	To assemble the code:
	MAC @IMGASM

	There are 2 fortran subroutines CONVOL & GRAPHL
	they work when compiled with F4P x=x/-TR.
	I dont know what will happen with FOR
	To Compile the 2 subs:
	F4P @IMGCMP

	To build the task:
	TKB @IMG

	Example of command strings in 
	EDGE.CMD
	extracts edge information from an image
USER SITE MODIFICATIONs:
The printer spooled to is a PRINTRONIX 300 which has 780 dots across each
row, the 512 images are there printed as 1 bit deep graphics using only
the 1st 512 dots. The code GRAPHL.FTN formats the graphics line into
the bit patterns the printer wants to see ,could be modified for Versatec
or Gould easily.

The CONVOL.FTN code is simple Fortran for implementing the digital convolver
as a 3x3 kernel that moves over the data. It can easily be enhanced and 
perhaps speeded up greatly by others or add different filtering modes.


	KNOWN ERRORS:/AP - does not appear to actaully append
 to the end of an exisiting file.

/FL - FILE n on mag tape seems to work.

To date no glaring errors are apparent although some combinations of 
switches may produce bizarre results. Currently errors are reported
but the exact cause,ie. 'PRIVELEDGE VIOLATION' is not. This will
be enhanced later as will be portability.

	Some switches in some strings will be ignored without error
comment if the code does not expect them in the current context.

************************************************************


	To assemble SHO:
	MAC @SHOASM

	To build SHO
	TKB @SHO

This code SHO is specific for the Comtal Vision One but could be altered
for another display .

end of readme.1st
