Click her to go to 'Figures/Overheads' section.

Click here to return to course outline.

Click here to return to W.R. Church's home page.

Click here to return to Earth Science course list.

 
Earth Science 505 - construction  of a vector image and its conversion to a raster image

Modules used : DOCUMENT, DISPLAY, INITIAL, COPY, RASTER TO VECTOR 
CONVERSION-LINERAS, PALETTE-WORKSHOP. ASSIGN.
	The following will help you undertand the relationship between vector, image, 
and attribute value files.
	Make an flyourinitials1 directory (e.g. md flwrc1, cd flwrc1), and using IDRISI 
Edit or DOS EDIT make the following `line' entity file, and name it yourinitialstst1.vec 
(USE ONLY TWO INITIALS):

1 2
0 0
20 20
2 2
75 75
100 100
3 2
25 25
60 40
0 0
	The final `0 0' is an end of file marker.
	Make a second file named yourinitialstst2.vec with the form:
2 2
0 0
20 20
2 2
75 75
100 100
2 2
25 25
60 40
0 0

	Make an attribute values file named yourinitialstst1.val:

1 5
2 6
3 7

and an attribute values file named yourinitialstst2.val:

2 4

	The attribute values (1 in `1 2', 2 in `2 2, etc) in these files are geographic 
identifiers; they identify each object by a number, which can be linked to other attribute 
values for the same object contained in a corresponding attribute file. That is `1 1' can be 
matched to `1 5', where the first `1' is the geographic identifier, the second `1' a code 
indicating that we are dealing with points, and `5' is the ppm gold value of the rocks at 
this location.
	Use FILES-DOCUMENT to make document files for yourinitialstst1.vec and 
yourinitialstst2.vec, entering (select `Integer' and `Ascii', and `Line' as object type, and 
the `MAX-MIN' values as 0 and 100. Also make a Document file for the Attribute values 
file, setting `Number of Records' to the number of objects in the image file, and the 
number of fields to 2 (the maximum allowed in this version of IDRISI)


	DISPLAY both vector images with and without the attribute values file.

	In the `DATA ENTRY' menu select INITIAL and create an initial raster image 
with an output image name of `yourinitialststi' with the same coordinate limits as the tst1 
vector image (also click the `Define spatatial parameters individually', integer, and 
binary buttons, and leave the default value in the `initial value' box as `0', and when 
having clicked `OK' enter the `number of rows' and `number of columns' as 512, the max 
X and Y values as in the vector DOCUMENT file, and the value units as `1'). Make a 
DOCUMENT file for the thus defined image file, indicating Minimum and Maximum 
values to be 0 and 3, respectively. Using the IDRISI COPY function, copy the image and 
corresponding .DOC file to yourinitialstst1.img and yourinitialstst2.img.

	In the REFORMAT menu, select `RASTER/VECTOR CONVERSION', and 
LINERAS, and convert the vector image yourinitialstst1.vec to yourinitialstst1.img 
and yourinitialtst2.vec to yourinitialstst2.img.
         
	In Palette Workshops (DISPLAY) get the qual16.smp palette file, make colour 
1 white instead of black, and save as qual16md.smp.
	Display the images using qual16md as the palette; overlay the raster images with 
their corresponding vector images. Note that the vector overlay can be changed in 
DISPLAY by choosing a values file, but that the image file cannot be changed using the 
values file option in the Properties menu of the Composer window. Only polygon images 
can be modified using the Properties menu. Both line and polygon images can however be 
changed by selecting a new palette file in the `Palette File' box of the Properties menu.

	Run ASSIGN to attribute the attribute values in the `yourinitialstst1.val' 
attribute values file to the `yourinitialstst1.img', forming a new image file 
`yourinialstst1md.img'.

	!!Delete all the files and redo the exercise, re-writing the `yourinitialstst1.vec' 
file for a polygon image containing two triangles with different attribute values!! 
Remember, there are four points in a triangle, with the first and last points having the 
same coordinates.
	As 'homework' create an irregular polygon vector image, and a corresponding 
values file, and convert the vector image to a raster image. Use ASSIST to change the 
attribute value of the raster image object.

FIGURES

Figure 1. Plate Tectonics.

RETURN TO:

Click here to return to beginning.

Click here to return to course outline.

Click here to return to W.R. Church's page.

Click here to return to course list.