Chapter 6 : Summary Of Commands

In this section, we give a synopsis of all commands available in 3DVIEWNIX. Its purpose is to give the users a quick overview of 3DVIEWNIX from an operational viewpoint. They can decide from this summary which commands are relevant to their application, so that they may study only such commands in detail.

The complete command tree is shown in Figure 6.1.

Fig 6.1: 3DVIEWNIX Command Tree.


These commands allow porting data from external sources into 3DVIEWNIX and taking data out from 3DVIEWNIX. The term "data" here refers mainly to image data.

FromACR-NEMA: This command allows bringing image data into 3DVIEWNIX that are in the standard ACR-NEMA (version 2.0) format.

There are many vendors of imaging devices (such as medical scanners) and there are also many modalities. Unfortunately, vendors follow their own format of image data representation. Proprietary restrictions on these formats pose special difficulties for open system development and distribution activities such as that of 3DVIEWNIX. These difficulties, combined with the fact that different computing platforms may have different byte ordering for the different types of data entities (such as for text, and for integers of various lengths), makes image data access in a machine- and imaging-device-independent fashion really a vexing problem. We firmly believe that the standards suggested by the ACR-NEMA are the only solution to this problem. We strongly encourage users of 3DVIEWNIX to urge their imaging equipment vendors to provide a standard ACR-NEMA interface to the image data generated by these devices. 3DVIEWNIX at present interfaces to ACR-NEMA Version 2.0. When further enhancements to these standards, such as the DICOM Version 3.0, are established, 3DVIEWNIX will be modified to establish the interface to the enhancements.

FromTape: These commands allow accessing image data from various vendors of CT, MR and PET scanners.

EasyHeader: This is a quick command that allows the user to interactively convert any image data set into scene data (IM0 File) of 3DVIEWNIX. The image data should be stored in rectangular array form and the spacing between slices should be uniform.

CreateFileHeader: This command is a more comprehensive version of EasyHeader to convert image data into a 3DVIEWNIX IM0 File. Input image data should still be in the form of a rectangular array but slice spacing need not be uniform.

ModifyFileHeader: This command allows modifying the header of any 3DVIEWNIX data file.

Retrieve: This is a command for retrieving 3DVIEWNIX files from a backup medium previously created via BackUp command.

BackUp: The purpose of this command is to allow dumping 3DVIEWNIX files on a chosen medium for archival.


Commands in this branch of the command tree (see Figure 6.1) allow carrying out various preprocessing operations on scenes and structures.

6.2.1 Scene Operations

Commands in this group operate on scenes and produce scenes or structures as output. They accept scenes of any dimensionality up to 4. Note that since the notion of scenes includes binary scenes, most of these commands accept binary scenes also as input and produce appropriate output. Some commands in this group require multiple input IM0 files, some require only one, and others can accept any number of input files.

Input: This command allows the user to select any IM0 files available in the current user directory.

VOI: It accepts one IM0 file as input and outputs another IM0 file after a volume-of-interest operation. Both the region-of-interest (ROI) and intensity-of-interest (IOI) can be specified by the user.

Interpolate: This command supports both intensity and shape-based interpolation. In each of these classes of operation, nearest neighbor, linear or a cubic form of interpolation can be used independently in each dimension. Lower- as well as higher-resolution output scenes can be created.

Filter: This command carries out various filtering operations on input scenes. These include: a smoothing operation based on a 3D neighborhood, a smoothing operation based on a Gaussian function in 2D, an enhancing operation called tobogganing , and an enhancing operation based on gradient magnitude computed within the slice.

Segment: This command produces a scene, a binary scene, a structure, or a structure system from a given scene. Threshold converts the given scene into a binary scene by the thresholding operation. Multiple threshold intervals can be specified. Threshold can also do surface detection and output a BS0 or a BS1 file or a structure system consisting of respective shells. Interactive2D can be used to carry out either a masking operation to create a binary scene (interactive segmentation), or a live-wire tracing operation also to create a binary scene. It also supports a masking operation that creates a scene. 2Features allows doing a clustering operation based on two features supplied in two scenes. Its output is a binary scene.

Classify: This command can be used to produce a scene or a non-binary Shell0 structure from a given scene. 1Feature does classification based on cell intensity and 2Features classifies based on cell density and gradient magnitude.

6.2.2 Structure Operations

The commands in this group operate primarily on structures or structure systems and produce primarily structures, structure systems, structure plans or scenes.

Input: This command is used to select input files -- BS0, BS1 and PLN -- for this group of commands.

Surface Normal: This command can be used to compute surface normal information for an input shell (of type binary Shell0 or binary Shell1) and replace such information that may already be contained in the shell description. It requires a secondary scene input which is specified by the user. The surface normal is determined using a gradient operator on this scene.

MergeStructures: This command allows merging input structures (BS0, BS1) into a structure system. All input structures should be of the same type and resolution.

ToStructure: This command is for converting one type of structure into another between binary Shell0 and binary Shell1 (Shell0ToShell1 and Shell1ToShell0).

ToScene: This command converts an input binary Shell0 or a binary Shell1 or a Curve0 structure into a binary scene by making cells interior to the object 1-cells and those exterior to the object 0-cells. This command provides an important link between structure operations including manipulation and scene operations. Often 2D contour data in parallel planes are produced in several applications. Curve0ToScene allows inputting these data into 3DVIEWNIX for carrying out further 3D imaging operations on them.


Commands in this branch of the command tree (see Figure 6.1) support various visualization operations. Depending on the mode of visualization, they are grouped into three categories: Slice, Surface, and Volume.

6.3.1 Slice

This group of commands supports very sophisticated ways of viewing (and measuring) in a "slice mode" (2D mode). Valid input data are scenes (IM0 files) and display data (MV0 files). Scenes may be of any finite dimensionality.

Input: This is for providing input files to this group of commands.

Montage: This command is for providing a montage-type display of the slices in the input scene and the pictures in the display data. Any number of scenes and display data sets can be viewed simultaneously with any color map.

Cycle: These commands are for viewing in a mode in which how the frames are laid out is under user control. Very sophisticated layouts can be realized and the data can be displayed in a static or dynamic mode.

In the above Slice commands, 3D distances (and their cumulative value) between points selected on the displayed slices can be measured. These measurements may not make sense for display data and hence not provided for them.

Reslice: This command can be used for visualizing cell intensity values on planes of any orientation and location. Dynamic scenes are frozen in time for reslicing. It can also produce an output scene consisting of a set of resliced "slices".

6.3.2 Surface

These commands allow visualizing (and measuring) structure systems and plans made up of binary shells, in particular, of type Shell1 via surface rendering.

Input: This allows selecting input structure systems and plans via BS1 files.

View: This command allows viewing the structure system or plan at any viewing angle at any (reasonable) magnification using any colors and opacities assigned to the structures and in any combination of the structures in the system. If the structure system represents a dynamic object, the dynamics can be visualized in a natural way.

Measure: This command allows measuring 3D linear and curvilinear distances and angles by selecting points on the visualized surfaces. For dynamic structures, the rate of change of distances can also be measured.

CreateMovie: This command allows creation of sophisticated animations of the structure system or plan and saving this in MV0 files for later replay.

6.3.3 Volume

These commands are for visualizing (and measuring) structures represented as non-binary shells, in particular, of the Shell0 kind via volume rendering.

Input: This allows selection of non-binary Shell0 structures for visualization. At present only one SH0 file is permitted at a time as input.

View: This command allows viewing non-binary shells at any viewing angle at any (reasonable) magnification using any color and opacity settings. If the object consists of multiple components and/or multiple materials, they should all be captured in a single shell.

Measure: This command can be used to measure 3D linear and curvilinear distances and angles by selecting points on the surface of rendered fuzzy structures.

CreateMovie: These commands can be used to create sophisticated animations of the rendered structures which can be saved in a MV0 file for later replay.


Commands in this branch of the command tree (see Figure 6.1) constitute one of the most advanced and sophisticated set of operations in 3DVIEWNIX. They allow altering structures in various ways. They can also be used for visualizing structures. Valid inputs to these commands are structure systems or structure plans. They output structures, structure systems, or structure plans. At present, all structures should be of the binary Shell0 kind.

The main mode of display for all commands in this group is a surface rendition of the input structures. The structures can be viewed in any combination at any angle at any magnification in any color and in opaque or transparent mode.

Input: This serves to provide the appropriate input files to these commands.

SelectSlice: The purpose of these commands is to make it possible to interactively select an arbitrary plane passing through any structure among the input structures and to compute and display the intensity distribution in the plane within any of the scenes from which the input structures were derived.

Measure: The purpose of these commands is to measure 3D linear and curvilinear distances between points selected on the surfaces and angle between line segments connecting these points. Artificial landmarks can be painted on the surfaces for guidance of measurement and of manipulative operations.

Reflect: This command allows interactively selecting an arbitrary plane passing through any structure and reflecting the part of each structure on one side of this plane to the other side. The reflected objects can be rendered with all the flexibility available for structures.

Cut: These commands allow interactively cutting a selected structure into two parts using planar or curved cuts and retaining one of them. The retained part becomes a new structure, which along with other structures, can be further manipulated.

Separate: Using this command any selected structure from among the input structures can be cut into two parts. Each part can be rotated independently and further cut, whence, the subpart just separated is added to the other part of the structure. In this fashion, the selected structure is eventually separated in a desired way into two segments each of which becomes a new structure. These new structures along with other structures can be further manipulated.

Move: This group of commands is for making it possible to move any selected structures relative to the remaining structures with full six degrees of freedom (i.e., translation in any direction and rotation about any specified axis). The line that constitutes the axis of rotation or translation is selected interactively by the user.

CreateMovie: These commands allow generation of sophisticated animations of the input structures and saving these in MV0 files for later replay.


Commands in this branch of the command tree (see Figure 6.1) support various analysis operations. Depending on the mode of visualization used, they are further divided into two groups.

6.5.1 Scene

This group makes it possible to interact directly with slices of input scenes to obtain certain measurements. Valid inputs are scenes of any dimensionality of up to 4.

Input: This allows selecting the needed IM0 file.

DensityProfile: The purpose of this command is to compute and display as a graph the variation of intensity along any path selected by the user in the domain of input scenes. A path is specified by selecting a series of points on the slices. The slices can be laid out in a variety of ways as in Visualize-Slice-Cycle commands.

ROIStatistics: This command can be used to probe any selected region in the domains of the input scenes for computing properties based on cell intensities in this region such as minimum, maximum, mean, and standard deviation of intensities, and minimum, maximum, mean, and standard deviation of gradient magnitudes. In addition, area and volume of these regions are also computed. These entities can be saved in a file for later recall.

6.5.2 Surface

This group of commands is for carrying out certain analysis tasks on structures represented by binary shells.

Input: This allows selecting valid input files, which are of the BS1 kind.

Register: Given two structures, or structure systems, this command allows representing the two entities in a common coordinate system based on homologous features that can be observed in the surface renditions of the two entities. These may be an entire surface, or points and curves specified by the user on the renditions. The output of this operation is a structure plan.

Kinematics: Given a structure system or a structure plan, this command allows computing motion of each distinct object in the input assuming it is rigid. The outcome of this operation is a structure plan.


The commands in this group do not actually process scene, structure or display data, but they provide some useful functions.

ColorLayout: This command can be used to change the colors used for the various entities displayed in the various windows. This allows the user to customize the screen appearance.

ShowScreen: This command is the inverse of the SVSCRN option to save the picture of the screen described in Section 6.7. It allows the screen dumps previously saved in a file to be redisplayed. These two commands together provide a useful composing option for making prints, slides and other hard copies used for publication and presentation.

6.7 Static Options

In addition to the commands discussed so far, certain options are made available during the execution of most of the 3DVIEWNIX commands. These are provided as buttons and switches in the mouse window.

HELP: This option provides on-line access to the 3DVIEWNIX user manual. Information can be accessed by topic.

INFORMATION: This option provides a brief description of the pertinent details related to the input data.

ANNOTATION: This allows marking annotative graphics and text on displayed pictures for the purpose of composing and making a hard copy.

SVSCRN: This option allows saving the current appearance of the screen as a picture on a file.

User Manual Library Ref. Manual Tutorial