Next: Using the Draw_object
Up: General Drawing Instructions
Previous: General Drawing Instructions
The O graphic descriptor language can be used to draw anything the user
wants. In fact, some of the pictures generated by O are done via the
graphics descriptors, e.g. the CPK models. The picture must be defined in
terms of a number of drawing instruction, that are saved in a text
datablock. The contents of this text datablock can the be drawn on the
screen using the command Draw_object. The current list of
recognised instructions is as follows:
- begin_object
- [name] -- start object with give name
- end_object
- - end current object
- colour
- [value] -- name (e.g. red) or packed integer
defining a new colour
- line_type
- [type] -- character value
(dashed, solid, dotted, dash_dot)
- move
- [x, y, z] -- moveto (x, y, z)
- line
- [x, y, z] -- lineto (x, y, z)
- move_atom
- [mol residue atom] -- move to (x, y, z) of the atom
- line_atom
- [mol residue atom] -- line to (x, y, z) of the atom
- dot
- [ x, y, z] -- place dot at (x, y, z)
- text
- [x y z string] -- place text string at (x, y, z)
- text_size
- [value] -- real value 0
->
1.0,
(small ->
large)
- text_colour
- [integer value] -- name (e.g. red) or
packed integer defining a new colour
- poly
- [number of vertices] [vertex](i) -- polygon using
current colour
- poly_colour
- [colour] -- Set the polygon colour
- instance
- [object] [datablock] -- Object to be instanced
and datablock containing tranformation.
- sphere_atom
- [mol res atom radius colour] -- sphere
at coords mol/residue/atom with radius and colour
- sphere_xyz
- [x, y, z radius] -- sphere
at coords x ,y, z with the given radius.
- stick
- [mol res atm] [mol res atm] [radius] --
Draw a solid stick between 2 atoms, with given radius.
- stick_xyz
- [x1, y1, z1] [x2, y2, z2]
[radius] -- Draw a solid stick between two points in space, with the
given radius.
- mode
- [solid/line] -- Set the solid or line drawing mode.
- cell
- [cell parameters] -- Set the crystallographic unit cell
for the following commands.
- fmove
- [x, y, z] -- Move to (x, y, z), given in
fractional coordinates.
- fline
- [x, y, z] -- Line to (x, y, z), given in
fractional coordinates.
- ftext
- [x y z string] -- place text string at (x, y, z),
given in fractional coordinates.
Next: Using the Draw_object
Up: General Drawing Instructions
Previous: General Drawing Instructions