On this page:
3.4.1 Command Line View Navigation:   Zoom, Pan and Rotate
3.4.2 Mouse Based View Navigation:   Zoom, Pan and Rotate
3.4.3 Updating the Display
3.4.4 Graphics Modes
3.4.5 Drawing, Locating, and Highlighting Entities
3.4.6 Graphics Clipping Plane
3.4.7 Colors
3.4.8 Drawing Locations, Lines and Polygons
3.4.9 Entity Labels
3.4.10 Graphics Camera
3.4.11 Graphics Window Size and Position
3.4.12 Hardcopy Output
3.4.13 Graphics Lighting Model
3.4.14 Mesh Visualization
3.4.15 Miscellaneous Graphics Options
3.4.16 Saving Graphics Views
3.4.17 Geometry and Mesh Entity Visibility
2022.4+26187-e1209cf7 Apr 14, 2022

3.4 Graphics Window Control

The graphics display windows present a graphical representation of the geometry and/or the mesh. The quality and speed of rendering the graphics, the visibility, location and orientation of objects in the window, and the labeling of entities, among other things, can all be controlled by the user. Unless the -nographics option was entered on the command line, a graphics window with a black background and an axis triad will appear when Cubit is first launched. The geometry and mesh will appear in this window, and can be viewed from various camera positions and drawn in various modes (wire frame, hidden line, smooth shade, etc.). This section will discuss methods for manipulating the graphics with the mouse and for controlling the appearance of entities drawn in the graphics window. Graphics in Cubit operates on the principle of a "display list", which keeps track of various entities known to the graphics. All geometry and mesh objects created in Cubit are put into the display list automatically. The visibility and various other attributes of entities in the display list can be controlled individually. In addition, Cubit can also optionally display entities in a temporary mode, independent of their visibility in the display list. Drawing of items in temporary mode can be combined with the display list to customize the appearance. The overall display is controlled by various attributes like graphics mode, camera position, and lighting, to further enhance the graphics functionality.

3.4.1 Command Line View Navigation: Zoom, Pan and Rotate

Commands used to affect camera position or other functions are listed below. All rotation, panning, and zooming operations can include the animation steps qualifier, makes the image pass smoothly through the total transformation. Animation also allows the user to see how a transformation command arrives at its destination by showing the intermediate positions. Rotation

rotate <degrees> about [screen | camera | world] {X | Y | Z} [animation steps <number_steps>]

Rotation of the view can be specified by an angle about an axis in model coordinates, about the camera’s "at" point, or about the camera itself. Additionally rotations can be specified about any general axis by specifying start and end points to define the general vector. The right hand rule is used in all rotations. Plain degree rotations are in the Screen coordinate system by default, which is centered on the camera’s at point. The camera keyword causes the camera to rotate about itself (the camera’s From point). The world keyword causes the rotation to occur about the model’s coordinate system. Rotations can also be performed about the line joining the two end vertices of a curve in the model, or a line connecting two vertices in the model. Panning

pan [{left|right} <factor1>] [{Up|Down} <factor2>] [Screen | World ] [animation steps <number_steps>]

Panning causes the camera to be moved up, down, left, or right. In terms of camera attributes, the from point and at point are translated equal distances and directions, while the perspective angle and up vector remain unchanged. The scene can also be panned by a factor of the graphics window size. Screen and World indicate which coordinate system <factor> is in. If screen is indicated (the default), <factor> is in screen coordinates, in which the width of the screen is one unit. If world is indicated, <factor> is expressed in the model units. Zooming

zoom screen <factor> [animation steps <number_steps>]

zoom screen will move the camera <factor> times closer to its focal point. The result is that objects on the focal plane will appear <factor> times larger. Zooming on a specific portion of the screen is accomplished by specifying the zoom area in screen coordinates; for example, zoom 0 .25 .25 will zoom in on the bottom left quarter of the screen. Zooming on a particular entity in the model is accomplished by specifying the entity type and ID after entering zoom. The image will be adjusted to fit bounding box of the specified entity into the graphics window, and the specified entity will be highlighted. You can specify a final direction to look at when zooming by using the direction option. To center the view on all visible entities, use the zoom reset command. The GUI tool bar buttons for controlling zoom in, zoom out, and zoom reset are as follows:

Figure 62:

3.4.2 Mouse Based View Navigation: Zoom, Pan and Rotate

The mouse can be used to navigate through the scene using various view transformations. These transformations are accomplished by clicking a mouse button in the graphics window and dragging, sometimes while holding a modifier key such as Shift or Control. When run with graphics on, Cubit is always in mouse mode; that is, mouse-based transformations are always available, without needing to enter a Cubit command. Mouse-based view transformations are accomplished by placing the pointer in the graphics window and then either holding down a mouse button and dragging, or by clicking on a location in the graphics window. Some functions also require one or more modifier keys to be held down; the modifier keys used in Cubit are Shift and Control

Each of the available view transformations has a default binding to a mouse button-modifier key combination. This binding can be changed by the user if desired. Transformations and button mappings are summarized in the following table.

These settings are applicable only to the UNIX command line version of Cubit. For a description of the Graphical User Interface Mouse Operations see GUI View Navigation.

The bindings are based on the following mouse button definitions:

Figure 63:

Figure 1. Default Mouse Function Mappings for the Command Line

Table 1. Mouse Function Bindings for Zoom, Pan, and Rotate





Rotates the scene about the camera axis. Dragging the mouse near the center of the graphics window will rotate the camera’s X- or Y-axis; dragging near the edge of the window will rotate about the Z-axis (i.e. about the camera’s line of sight). Type a u in the graphics window to see the dividing line between the two types of rotation.



Zooms the scene in or out by clicking the mouse in the graphics window and dragging up or down. If the mouse has a wheel, the wheel will also zoom.



"Drags" the scene around with the mouse


Navigational Zoom

Zooms the scene by moving both the camera and its focal point forward.

shift_key.gif B2

Telephoto Zoom

Zooms the scene by decreasing the field of view.

shift_key.gif control_key.gif B2

Pan Cursor

Click on new center of view

shift_key.gif B3 Changing the View Transformation Button Bindings

The default mapping of functions to mouse buttons, described in the Default Mouse Function Mappings table above, can be modified. There are two ways to assign a function to a button/modifier combination. First, you can use the command

Mouse Function <function_id> Button <1|2|3> [Shift][Control]

Type help mouse function to see a list of function IDs that may be used in this command. Second, you can assign functions interactively. To do so, first put the pointer into a graphics window and then hit the F key. On-screen instructions will lead you through the rest of the process. The GUI Options panel for managing the mouse bindings can be found at Tools/Options/Mouse, and is as follows:

Figure 64: Saving and Restoring Views

After performing view transformations, it may be useful to return to a previous view. A view is restored by setting the graphics camera attributes to a given set of values. The following keys, pressed while the pointer is in the graphics window, provide this capability:

V - Restores the view as it was the last time Display was entered.

F1 to F12 - These function keys represent 12 saved views. To save a view, hold down the Control key while pressing the function key. To restore that view later, press the same function key without the Control key.

In the Graphical User Interface version the F1, F2 and F3 keys are used as an alternate form of dynamic viewing, therefore the ability to save views is not currently supported in the GUI.

You can also save a view by entering the command

view save [position <1-12>] [window <window_id>]

The current view parameters will be stored in the specified position. If no position is specified, the view can be restored by pressing V in the graphics window. If a position is specified, the view can be restored with the command

view restore position <1-12> [window <window_id>]

These commands are useful in as entries in a .Cubit startup file. For example, to always have F1 refer to a front view of the model, the following commands could be entered into a .Cubit file:

from 0 1 at 0 up 0 1 0 graphics autocenter on view save position 1

The first three commands set the orientation of the camera. The fourth command ensures that the model will be centered each time the view is restored. The final command saves the view parameters in position 1. The view can be restored by pressing F1 while the cursor is in a graphics window. Additionally, you can change the ’gain’ on the mouse movements by changing the mouse gain setting, via the command:

mouse gain <value>

where a value of 3 would be 3X as sensitive to mouse movements, and a value of 0.5 would be half as sensitive.

set reversezoom {on|off}

Another user preference, the direction of ’zooming’ obtained by using the mouse can be ’flipped’, by toggling the reversezoom setting.

3.4.3 Updating the Display

Among the most common graphics-related commands is:


This command clears all highlighting and temporary drawing, and then redraws the model according to the current graphics settings. The GUI tool bar button for executing this command is:

Two related commands are:

graphics flush

graphics clear

graphics flush redraws the graphics without clearing highlighting or temporary drawing. graphics flush is useful when a previously executed command modified the graphics and didn’t update the screen and the user wishes to update the display. The graphics clear command clears the graphics window without redrawing the scene, leaving the window blank.

Although most changes to the model are immediately reflected in the graphics display, some are not (for graphics efficiency). Typing display will update the display after such commands. Ctrl-R will also update the display as long as the mouse is in the graphics window. Prevent Graphics From Updating

For especially large models, it may take excessively long to update the display after an action has been performed. To prevent the graphics from automatically updating, use the following command:

graphics pause

This command prevents the graphics window from being updated until the next time the display command is issued.

The plot command is synonymous to the display command, and either can be used with identical results.

3.4.4 Graphics Modes

By default, the scene is viewed as a smoothshaded model. That is, only curves and edges are drawn, and surfaces are transparent. Surfaces can be drawn differently by changing the graphics mode:

Graphics Mode {Wireframe | Hiddenline | Smoothshade | Transparent } [Geometry | Mesh]

The GUI tool bar buttons for manipulating the graphics modes are as follows:

Figure 65:

Examples and a brief description of each mode are shown below

WireFrame - Surfaces are invisible. (This mode can also be accessed by typing ’wireframe’ at the command prompt.)

HiddenLine - Surfaces are not drawn, but they obscure what is behind them, giving a more realistic representation of the view. (This mode can also be accessed by typing ’hiddenline’ at the command prompt.)

SmoothShade - Surfaces are filled and shaded. Shaded colors are interpolated across the entire surface using the graphics lighting model. This produces the most realistic results. (This mode can also be accessed by typing ’shaded’ at the command prompt.)

Transparent - Renders surfaces as semi-transparent shaded images, allowing objects to shine-through from behind. Is not supported on all platforms, and generally requires advanced graphics hardware. (This mode can also be accessed by typing ’transparent’ at the command prompt.)

This determines what pattern is used to draw lines behind surfaces (e.g. dotted, dashed, etc.; click here for a list of valid line patterns). Displaying Using the Element Facets

There is another option that is similar to a graphics mode, set with the command

graphics use facets [on|off]

This command determines how shaded and filled surfaces are drawn when they are meshed. If Graphics Use Facets is on, the mesh facets (element faces) are used to render the model. This is particularly helpful for curved surfaces which may cut through some of the mesh faces. A comparison of graphics facets on and off is shown below.

Figure 66: A meshed cylinder shown with graphics facets off (left) and graphics facets on (right); note how geometry facets on the curved surface obscure mesh edges when facets are off. Displaying Composite Surface Lines

Composite surfaces are surfaces that have been joined together using virtual geometry. By default, the underlying surfaces are marked with dashed lines. To toggle this setting so that underlying surfaces are not shown, use the following command:

graphics composite {on|off}

Figure 67: A part shown with (a) composite surfaces displayed (b) composite surfaces not displayed

The GUI tool bar button for toggling the display of graphics composites is as follows:

Figure 68:

3.4.5 Drawing, Locating, and Highlighting Entities

In order to effectively visualize the model, it is often necessary to draw an entity by itself, or several entities as a group. This is easily done with the command

Draw {Entity specification} [Color <color_spec>] [Zoom] [Add]

where Entity specification is an entity list as described in Command Line Entity Specification. This command clears the display before drawing the specified entity or entities. Specification of a color will draw those entities in that color. This will not permanently change the color of the entity. The zoom option will zoom in on the selected entities after drawing them in the graphics window. If the add option is specified, the display is not cleared, and the given entity is added to what is already drawn on the screen. The entities specified in this command are drawn regardless of their visibility setting (see Geometry and Mesh Entity Visibility for more details about visibility).

Entities may also be drawn by selecting them with the mouse and then typing Ctrl-D while the mouse is in the graphics window. This will clear the screen and then draw only those entities that are currently selected.

Entities can be highlighted using the command

highlight {entity specification}

This command highlights the specified entities in the current display with the current highlight color. Highlighting can be removed using the command

graphics clear highlight

To return to the normal display of the entire model, type display.

The locate command will label and point to the specified entity or location in the graphics window. The command syntax is:

locate <entity_list> locate <location options>

For example, suppose you have an idless reference to a curve of:

curve ( at 5 5 0 ordinal 1 )

You can find the curve with the following command:

locate location 5 5 0

Additionally, the visibility of individual entities, or sets of entities, can be controlled with the following visibility commands.

{Vertex|Curve|Surface|Volume|Body|Group} <range> [Geometry|Mesh] Visibility {on|off} Drawing Other Objects

In addition to the common geometry, mesh and genesis entities, other objects may be drawn with variations of the Draw command. As with the other Draw commands, typing Display after drawing these objects will restore the scene to its normal display. Displaying Entity Orientation

The normal to one or more surfaces, mesh faces, or mesh triangles may be drawn with the command

draw {surface | face | Tri} <id_range> normal [Length <length>] [face | tri] color <color> [add]

Surface normal command colors the surfaces using two different colors. The surface exposed to the positive half space (i.e, along the direction of normal), will always be colored black. The surace exposed to the negative half space will be colored using the specified <color>.

If the Face or Tri qualifier is included in the Draw Normal command, the normals for all faces or tris that belong to the specified surface are drawn.

Arrow representing the normal will be displayed if "Length" is specified.

Figure 69:

The forward, or tangent, direction of a curve can be drawn with the command:

draw curve <id_range> tangent [length <length>][color <color_spec>]

If a color is not specified, the tangent is drawn in the same color as the curve. Volume Sources and Targets

Once the source and target surfaces have been set on a volume that will be meshed with the sweep algorithm, the source and target may be visually identified with the command

draw volume <volume_id_range> [source][target] [length <size>]

If the Source keyword is included, the normal of the source surface or surfaces will be drawn in green into the specified volume. If the Target keyword is included, the normal of the target surface or surfaces will be drawn in red into the specified volume. Model Axis

The model axis may be drawn with the command

draw axis [length <length>]

The axis is drawn as three lines beginning at the model origin, one line in each of the three coordinate directions. The length of those lines is determined by the length parameter, which defaults to 1. Surface Isoparameter Lines

Isoparameter lines may be drawn on surfaces in the model using the command

draw surface <surface_id_range> isoparametric [number <number>| [u <number>] [v <number>]]

If you specify the Number of lines, then the number of u- and v-parameter lines will be equal. You may specify instead a number of lines for each of the u and v parameters. The u-parameter lines will be drawn in red and the v-parameter lines will be drawn in blue. Surface Overlap

The overlapping regions between two surfaces may be drawn with the command

draw surface <id> <id>overlap [add]

This command will draw the curves of each of the surfaces in green, and the portion of the surfaces that overlap in red. The Add keyword will draw the overlapping surfaces on top of the current graphics display. Without the Add keyword, the display will only show the specified surfaces and their overlapping regions. Volume Overlap

The overlapping region between two volumes may be drawn with the command

draw volume <id> <id> overlap [add]

This command will draw the input volumes in transparent mode and draw the volume(s) of intersection as red, shaded solids. The add keyword will draw the results on top of the current graphics display. Without the add keyword, the display will only show the specified volumes along with the intersection volume(s). Geometry Preview

Several options are available for previewing geometry without actually generating it. This is typically used in conjunction with webcutting and surface creation. The following Draw commands can be used for previewing geometry:

Draw Location On Curve

Draw Location

Draw Direction

Draw Line

Draw Polygon

Draw Axis

Draw Plane

Draw Cylinder

3.4.6 Graphics Clipping Plane

The graphics clipping plane feature allows the user to temporarily cut parts of the model away to help visualize the interior of a geometry or mesh. The command syntax is:

graphics clip {on|off} [ plane <plane> | [location <location>] [direction <direction>]]

graphics clip manipulation {on|off}

The GUI tool bar buttons to enable and manipulate the Graphics Clipping Plane are shown below:

Figure 70:

The first command activates the graphics clip manipulation tools in the graphics window. The keyboard shortcut "Shift-S" while the graphics window is active will also activate the clipping plane. The manipulation of the clipping plane is controlled as follows:

Figure 71: Graphics Clipping Plane

The second command turns on/off the visibility of manipulation widget in the graphics window. The clipping plane is still active, but the controls are hidden. The normal mouse-based view navigation controls apply. Examples

brick x 10 sphere rad 1 graphics clip on location -2 0 0 rotate -45 about y #shows the sphere inside the brick

brick x 10 cylinder rad 2 z 12 subtract 2 from 1 mesh vol 1 quality vol 1 draw mesh graphics clip on #shows the mesh quality on interior elements

Figure 72: Viewing mesh quality of interior elements

3.4.7 Colors Specifying Colors in Commands

There are five ways to refer to a color in a command. They are

  1. <color_name>

  2. user "name"

  3. ID <id>

  4. default

  5. highlight

The first option uses the name of a pre-defined color as listed in the Available Colors Appendix. This option may not be used for user-defined colors. An example of a pre-defined color assignment is given below:

color volume 1 lightblue

The second option is used with user-defined colors only. Include the name of the user-defined color in quotes. Pre-defined colors will not work with this command.

color volume 1 user "mycolor"

The third option allows you to identify a pre-defined color by its ID. The color IDs are also listed in the Available Colors appendix. This option is rarely used.

color volume 1 id 5

The default option is used to set an entity’s color to its default value. The default color may also be specified in drawing commands, but the command’s behavior will be the same as if the color option had not been included at all.

color volume 1 default

The fifth option refers to the current highlight color.

draw curve 1 tangent color highlight User-Defined Colors

Cubit has a palette of 85 pre-defined colors, listed in the Appendix under Available Colors. Users may also define their own colors in addition to those defined by Cubit. Each color is defined by a name and by its RGB components, which range from 0 to 1. To define an additional color, use either of the commands

color define "<name>" RGB <r g b>

color define "<name>" r <r> g <g b <b>

A maximum of 15 user-defined colors may be stored at one time, so it may be necessary to clear a color definition. This is done with the command

color release "<color_name>"

Color names can be listed with the command

help color

They are also listed in the appendix of this manual, along with their RGB definitions. To view a chart of color names and IDs, including those for user-defined colors, use the command

draw colortable Assigning Colors

Colors may be assigned to all geometric entities, and to some other objects as well. To assign a color to an entity or other object, use one of the following commands.

color axis labels {<color_name>| id <color_id>}

color axis labels {<color_name>| id <color_id>}color axis labels {<color_name>| id <color_id>}

Color Block <block_id_range>{<color_name> | id <color_id>}color axis labels {<color_name>| id <color_id>}

Color Body <body_id_range> [Geometry|Mesh] {<color_name>| id <color_id> | Default}

Color Curve <curve_id_range> [Geometry|Mesh] {<color_name>| id <color_id> | Default}

Color Highlight {<color_name>| id <color_id>}

Color Lines <color_name>

Color NodeSet <id_range> { <color_name> | id <color_id> | Default }

Color SideSet <id_range>{ <color_name> | id <color_id> | Default }

Color Surface <surface_id_range> [Geometry|Mesh] {<color_name>|Default}

Color Title {<color_name>|id <color_id>}

Color Volume <volume_id_range> [Geometry|Mesh] {<color_name>| id <color_id> | Default}

Color Group <group_id_range> expand [Geometry|Mesh] {color_name> | id <color_id> | Default}

The use of the ’expand’ keyword for coloring groups. Expanding the group will result in colors applied to each individual member of the group.

Including the Mesh keyword will change the color of the mesh belonging to the specified entity, without changing the color of the entity geometry itself. Conversely, including the Geometry keyword will change the geometry color without changing the mesh color. Including both keywords is identical to including neither keyword.

Colors are inherited by child entities. If you explicitly set the color for a volume, for example, all of its surfaces will also be drawn in that color. Once you assign a color to an entity, however, it will remain that color and will no longer follow color changes to parent entities. To make an entity follow the color of its parent after having explicitly set another color, use Default as the color name in the color command.

Colors can also be assigned to nodesets, sidesets, and element blocks. These colors do not take effect, however, unless the nodeset, sideset, or element block is drawn with a Draw command.

The background color and the color used to draw highlighted entities can be changed to any color.

By default, the axes are labeled with a white X, Y, and Z, indicating the three primary coordinate directions. If the background is changed to white, these labels are impossible to read; the color used to draw axis labels can be changed to any color. Changing the axis label color will change the text color for both the model axis and the triad (corner axis).

When several entity types are labeled, it can become difficult to determine which labels apply to which entities. To help distinguish which entities are being referred to by the labels, you may want to change the color of labels for specific entity types.

When a meshed surface is drawn in a shaded graphics mode, the mesh edges are not drawn in the same color as the surface. This is to prevent confusion between mesh edges and geometric curves, and to make the mesh edges more visible. The color used to draw mesh edges in this situation is known as the line color, and is gray by default; this color can be changed to any color. Assigning Global Colors

Colors may be assigned globally also. To assign a global color, use one of the following commands. Global color assignment is useful if one desires all entities to appear the same.

color global {<color_name>| id <color_id> | default}

Color Global Surface {<color_name>| id <color_id> | default} Curve {<color_name>| id <color_id> | default} Vertex {<color_name>| id <color_id> | default}

The first command assigns the desired color to all geometry entities. The color may be enter by color name or color id. The default option resets colors to the default value.

The second command assigns the desired colors to surfaces, curves and vertices. All three value must be entered. For example, users my select global colors for surface and vertex and specify that curves have default colors.

3.4.8 Drawing Locations, Lines and Polygons

In some cases it may be useful to simply draw a location, line or polygon to the screen to help visualize some aspect of the model. Locations, Lines and polygons are not geometry or mesh entities and are only visible until a refresh or display command is issued. Drawing Locations

Draw Location {options}... [color <color_name>][no_flush]

A single point or series of points may be drawn to the graphics window using this command. Any number of locations may be specified that will be drawn to the graphics window as single points. Options for specifying a location are described in the section Specifying a Location. The optional color argument allows for a custom color to be used. The available color definitions are located in the appendix. Other options for drawing locations and directions are also available dscribed in the section Drawing a Location, Direction, or Axis. Drawing Lines

Draw Line Location {options} Location {options} ... [color <color_name>][no_flush]

A straight line or series of segments may be drawn to the graphics window using this command. Any number of locations may be specified that will be connected with a line. Options for specifying a location are described in the section Specifying a Location. The optional color argument allows for a custom color to be used. The available color definitions are located in the appendix. Drawing Polygons

Draw Polygon Location {options} Location {options} Location {options} ... [color <color_name>][no_flush]

A filled polygon may be drawn to the graphics window using this command. Any number of locations may be specified as vertices. At least three locations must be specified. Locations for vertices can be described using any of the standard location options described in Specifying a Location. The optional color argument allows for a custom color to be used for the fill. The available color definitions are located in the appendix. Buffered Drawing

The optional no_flush argument for both the draw location, draw line and draw polygon commands may also be used when many simultaneous draw commands are being issued. This prevents the graphics from being drawn after each command is issued, which can be very inefficient. Instead the draw commands are buffered and sent all at once to be drawn. The following command:

graphics flush

can be used to force a draw following a series of commands that use the no_flush option. Example

The following is a simple example that will draw the figure below using cubit commands

draw polygon location pos -1 -1 0 location pos 1 -1 0 location pos 1 1 0 location pos -1 1 0 color yellow no_flush
draw line location pos -1 0 0 location pos 1 0 0 color blue no_flush
draw line location pos 0 -1 0 location pos 0 1 0 color blue no_flush
draw location pos 0 0 0 color red no_flush
graphics flush

Figure 73: drawing example

3.4.9 Entity Labels

Most entities may be labeled with text that is drawn at the centroid of the entity. Mesh entities can be labeled with their ID number or their Element ID. Element ID labels are only valid after putting the mesh entities into a block.

Geometric entities can be labeled with their ID number or with other information.

Labels for groups of entity types can be turned on or off.

The following commands will accomplish this.

Label [On|Off|Name [Only|ID]|ID|Interval|Size|Merge|Firmness]

Label All [On|Off|Name [Only|ID]|ID|Interval|Size|Merge|Firmness]

Label Body [On|Off| Name [Only|ID] |ID|Interval|Size| Merge |Firmness]

Label Curve [On|Off|Name [Only|ID] |ID| Interval| Size| Merge| Firmness]

Label {Hex|Tet|Face|Tri|Edge} [On|Off|ElementId]

Label Element [On|Off]

Label Geometry [On|Off|Name [Only|ID] |ID| Interval| Size| Merge| Firmness]

Label Mesh [On|Off]

Label Node [On|Off|ElementId|SphereId]

Label Surface [On|Off|Name [Only|ID] |ID| Interval| Scheme| Size| Merge| Firmness]

Label Vertex [On|Off|Name [Only|ID] |ID|Interval| Size| Merge| Firmness]

Label Volume [On|Off|Name [Only|ID] |ID |Interval| Size |Scheme |Merge |Firmness]

The meaning of each of each label type is listed below. Note that some label types don’t make sense for every entity type.

On - The same as IDs.

Name - Name of the entity, if the entity has been named. Default name otherwise.

Name Only - If the entity has been named, use the name as the label. Otherwise, don’t use a label.

Name IDs - If the entity has been named, use the name as the label. Otherwise, use the ID as the label.

Interval - The number of intervals set on the entity.

Firmness - Same as interval, but followed by a letter indicating the firmness of the interval setting (see the Mesh Generation chapter for description of firmness settings.)

Merge - Whether or not the entity is mergeable. Note that this is sometimes not clear, because, for example, a curve may show that it isn’t mergeable because one of its owning surfaces may be unmergeable, while another owning surface may be mergeable.

Size - The mesh size set on this entity.

ElementId - The Global Element Id of each element. Will only be labeled for hexes, tets, tris, etc. which are in a block.

SphereId - The id of the sphere element associated with this node, if there is one. A sphere element is only associated with a node if the node (or it’s geometry owner) is put into a block.

Three dimensional entity types such as body will have their labels displayed in the center of the entity. Thus, in the smooth shade and hidden line graphics modes the labels will be hidden.

The GUI includes command panels to manipulate the labels settings for any given entity type. The command panel for the Volumes labels settings is shown below as an example:

Figure 74:

3.4.10 Graphics Camera

One way to change what is visible in the graphics window is to manipulate the camera used to generate the scene. A scene camera has attributes described below, and depicted graphically in Figure 75. The values of these camera attributes determine how the scene appears in the graphics window. These view settings may be accessed in the GUI via the Display/View Point menu.

Position (From) - The location of the camera in model coordinates.

View Direction (At) - The focal point of the camera in model coordinates.

Up Direction (Up) - The point indicating the direction to which the top of the camera is pointing. The Up point determines how the camera is rotated about its line of sight.

Projection - Determines how the three-dimensional model is mapped to the two-dimensional graphics window.

Perspective Angle - Twice the angle between the line of sight and the edge of the visible portion of the scene.


Figure 75: Schematic of From, At, Up, and Perspective Angle

The camera can be moved to one of several predefined orientations using the command

View {Front | Back | Top | Bottom | Right | Left | Iso}

At any time, the camera can be moved back to its original position and view using the command

view reset

To see the current settings of these attributes, use the command

list view

The current value of the view attributes will be printed to the terminal window, along with other useful view information such as the current graphics mode and the width of the current scene in model coordinates.

Camera Attributes can be changed using the Rotate, Zoom and Pan commands, or directly as follows. Changing Camera Attributes Directly

Camera attributes are most easily modified using interactive mouse manipulation (see Mouse-Based View Navigation) or using the rotate, pan and zoom commands. However, the camera attributes can also be modified directly with the following commands:

from <x y z>

at <x y z>

at {body|volume|surface|curve|vertex|hex|tet|wedge|tri|face|node}<id_list>

up <x y z>

graphics perspective <on|off>

graphics perspective angle <degrees>

If graphics perspective is on, a perspective projection is used; if graphics perspective is off, an orthographic projection is used. With a perspective projection, the scene is drawn as it would look to a real camera. This gives a three-dimensional sense of depth, but causes most parallel lines to be drawn non-parallel to each other. If an orthographic projection is used, no sense of depth is given, but parallel lines are always drawn parallel to each other.

In a perspective view, changing the perspective angle changes the field of view by changing the angle from the line of sight to the edge of the visible scene. The effect is similar to a telephoto zoom with a camera. A smaller perspective angle results in a larger zoom. This command has no effect when graphics perspective is off.

The GUI tool bar button for changing the graphics perspective mode is as follows:

3.4.11 Graphics Window Size and Position

By default in the command line version, Cubit will create a single graphics window when it starts up (to run Cubit without a graphics window, include -nographics on the command line when launching Cubit.) The graphics window position and size is most easily adjusted using the mouse, like any other window on an X-windows screen. However, the size of the graphics window can also be controlled using the following commands:

graphics windowsize <width_in_pixels> <height_in_pixels>

graphics windowsize maximum

graphics windowsize minimum

After using the graphics windowsize maximum and graphics windowsize minimum commands, the previous window size can be restored by using the command

graphics windowsize restore

The position of the graphics window can also be controlled using the graphics windowlocation command.

graphics windowlocation <x> <y>

The <x> and <y> coordinates refer to the distance in pixels from the upper left hand corner of the monitor. In addition, on Unix workstations, the graphics window size and position can be controlled by placing the following line in the user’s .Xdefaults file:

cubit.graphics.geometry xxY+xpos+ypos

where the X and Y are window width and height in pixels, respectively, and xpos and ypos are the offsets from the upper left hand corner. Using Multiple Windows

You can use up to ten graphics windows simultaneously, each with its own camera and view. Each window has an ID, from 1 to 10, shown in the title bar of the window. Commands that control camera attributes apply to only one window at a time, the active window. Currently, the display lists of all windows are identical.

The following commands are used to create, delete, and make active additional graphics windows. These commands are also valid in the GUI (by typing at the command line prompt.)

graphics window create [ID]

graphics window delete <ID>

graphics window active <ID>

3.4.12 Hardcopy Output