jvs:cigal:manual:chapter2:moresketch
CIGAL Reference Manual, Chapter 2 (Commands): moresketch
moresketch --
Graphics Menu While running SKETCH you will probably want to use a graphics menu as an easy way of selecting what you want to do (see [GRAPHMENU][1]). If the graphics menu has been activated, then moving into that region will cause SKETCH to read whatever command you select. These can be either SKETCH operators (from the list above) or regular CIGAL commands. The difference is that graphics menu entries that are SKETCH operators appear as the single letter code (shown above) PRECEDED BY A SEMICOLON. The semicolon means: ignore this particular menu entry as a comment while you are not in SKETCH, but provide a flag for SKETCH itself. Activating such a menu entry during SKETCH, produces the same result you would receive had you typed the character code on the keyboard. However, if the menu entry does not begin with a semicolon then it is assumed to be a normal CIGAL command, and therefore SKETCH terminates and control returns to the main command line processor in order to execute the commands in that menu entry. BUT, if the menu entry ends with a semicolon, then SKETCH uses this as a flag to return to SKETCH after the menu commands have finished. Therefore, the semicolon, which CIGAL normally ignores as a comment delimiter, is used as a flag by SKETCH to decide how to make use of entries in the graphics menu. Graphics Data Storage When drawing, all of the graphics data are stored in an internal variable called VECS. VECS is a pointer to a file vector list variable. You can manipulate VECS once you are outside of SKETCH in the same manner as any other CIGAL variable. For example, you can scale, offset, or rotate VECS as: scale vecs .1 .1 .1 ; scale down by 10 rotate vecs 0 0 90 ; rotate 90 deg around Z offset vecs 100 ; shift horizontally by 100 pin vecs 255 100 ; hold pt 255 100 still during rotation and scaling These transformations do not become apparent until you REDRAW the graphics display. You can freeze the display in the new orientation by using the FREEZE command. The macro VRESET resets all transformations on VECS to default values. Save all of graphics vectors in a permanent disk file if you wish (as opposed to VECS itself which is a temporary file, VECS.TMP) by calling the OUTPUT command. This file can later be read back in using INPUT. Morphometry Data Storage If you do any measurements while you are in SKETCH, the length and area values are printed on the screen (or you can redirect this to a disk file or printer -- see [REDIRECT][1]). The values are also stored in another internal variable, called VDATA. VDATA is a file matrix variable and again can be manipulated by normal CIGAL commands just like other variables. For example, you can calculate means, standard deviations, etc. You can also easily save VDATA in a disk file by just typing the CIGAL command: type vdata > filename (where FILENAME is whatever name you wish to give this data file.)
See Also:
GRAPHMENU(1),
REDIRECT(1)
jvs/cigal/manual/chapter2/moresketch.txt · Last modified: 2024/06/21 15:44 by 127.0.0.1