The mask command extracts a volume data subregion bounded by surfaces and creates a new volume data set. See algorithm for details.
Volume-model is the model number (preceded by #) of the starting volume data set. A new data set will be generated and opened as a different model.
Surf-models specifies the bounding surface(s) and can be one or more comma-separated model numbers (preceded by #) or the word sel to indicate the currently selected surfaces or surface components. The surface(s) must be of type Surface_Model. This includes:
axis x,y,z
Projection axis vector (default is along the data Z axis: 0,0,1). This is relevant when the surfaces have holes. The region between surface layers is computed along the specified axis (see algorithm). Vector coordinates x,y,z are relative to the untransformed data. The vector can point in any direction (need not be parallel to the X, Y, or Z axis) and need not be of unit length.
fullmap
Make the masked volume data set have the same dimensions as the original volume data set. Otherwise, the bounds will be set as small as possible to enclose the surfaces, and the masked volume may be smaller.
pad distance
Before computing the masked volume, move the surface by the specified distance along the surface normals. This allows extracting a larger or smaller region than is enclosed by the original surface. Positive or negative values can be used, and the units of length are the same as for the data (generally angstroms or nanometers).
sandwich
Include only volume voxels lying between two surface layers. Otherwise, the volume projected along the axis beyond a single surface layer will also be included (see algorithm).
The masked volume is computed by looking at intercepts of lines parallel to the projection axis with the surfaces. For a given line, the volume data between the 1st and 2nd, 3rd and 4th, 5th and 6th, ... intercepts are included in the masked volume, while those between the 2nd and 3rd, 4th and 5th, ... are excluded. The intercepts are computed for lines through points on a rectangular grid normal to the projection axis with spacing equal to the minimum grid plane spacing of the volume data set. For each volume voxel, the intercepts of the closest grid line are used to determine inclusion in the masked volume. If there is an odd number of intercept points, then points beyond the final intercept are included in the masked volume unless the sandwich option is used. In the new data set, values outside the masked region are set to zero and those inside are set to the original volume values. The grid points of the calculated volume align exactly with those of the original volume. The bounds are set to minimally enclose the surfaces unless the fullmap option is used.
This command currently uses the full size of the original volume data set even if only a subregion is being displayed.
See also: volume, Icosahedron Surface