This section describes how the mol2gif
program determines a
default size for a bitmap image, and how to adjust either the size
of the image (using -width
and -height
) or its scale
(using -scale
and -noauto
).
By default, mol2gif
determines the size of the final image
using the input (or calculated) 2D co-ordinates. By making each
unit in the input co-ordinates equivalent to 25 pixels in the final
image. By adding suitable borders this determines the default image
size. OEChem's depiction algorithm attempt to make each bond
length 1.0, so typically each bond will end up being 25 pixels long.
The entire image can be scaled/resized by using the -scale
command line option. The default scale (25 pixels per unit) is
defined to be 1.0, by the bitmap may be zoomed or shrunk by specifying
a floating point value. For example, the option -scale 0.75
should generate an image a three quarters of the default size, and
-scale 1.5
should generate an image one and a half times the
default.
If both the -wide
and -high
command line options are
used to specify a width and height in pixels, respectively (and the
user hasn't specified -noauto
), the molecule is scaled to
maximally fit the given image dimensions.
Otherwise, if the user specifies just the width, or just the height,
or both but in conjunction with -noauto
, these values no only
set the final image dimensions, but also shrink the scale so that
the molecule fits that dimension. Note, that these values are not
used to zoom a molecule, specify a width and/or height larger than
that required by the current scale, causes the molecule to float in
the middle of the image of the requested size.