The graphics command sets graphical rendering parameters, with additional options detailed below:
Given without options, graphics reports the current background color in the Log. See also: set, preset, Graphics icons, making images• graphics bgColor color-spec
Set background color. Any transparency in the color is ignored; however, images can be saved with a (completely) transparent background using the save command option transparentBackground true. Background color can also be changed with set bgColor.• graphics driver [ verbose true | false ]
Report system graphics (OpenGL) information to the Log in terse (default) or verbose fashion.• graphics quality [ subdivision level ] [ atomTriangles Na ] [ bondTriangles Nb ] [ totalAtomTriangles maxa ] [ totalBondTriangles maxb ] [ ribbonDivisions divisions ] [ ribbonSides sides ] [ colorDepth 8 | 16 ]
Control triangulation fineness and bits per color. Normally, the fineness of atom and bond triangulation is adjusted automatically depending on the display contents (e.g., the number of atoms displayed), within the ranges of 10-2000 triangles per atom and 24-160 per bond, up to maximum totals for atoms and bonds set with totalAtomTriangles and totalBondTriangles, respectively (initial default five million each, 5000000). By default, vr temporarily lowers the limits on total triangles for faster rendering.• graphics rate [ true | false ] [ maxFrameRate N ] [ waitForVsync true | false ]
Automatic adjustment can be tuned in either direction with the subdivision parameter (initial default 1), where higher values increase the apparent smoothness of stick, ball-and-stick, and sphere display styles by increasing the number of triangles used to draw them. At a given subdivision level, the fineness of triangulation is adjusted automatically depending on the display contents (e.g., the number of atoms displayed), within the range of 10-2000 triangles per atom and 24-160 per bond. Subdivision level can also be controlled with the command set subdivision.
As an alternative to automatic adjustment, the graphics command allows using fixed numbers of triangles per atom and bond:
Subsequent use of the subdivision option returns to automatic adjustment, overriding any fixed values. Given without options, graphics quality reports the current subdivision level, triangles per atom and bond, and ribbon divisions per residue in the Log. Total numbers of triangles per model can be reported with graphics triangles. The number of ribbon sides and divisions can also be set or reported with cartoon style. For molecular surface subdivisions, see the gridSpacing option of surface.
- atomTriangles Na – triangles per atom (minimum 4, except that 0 specifies going back to automatic adjustment)
- bondTriangles Nb – triangles per bond (minimum 12, except that 0 specifies going back to automatic adjustment)
- ribbonDivisions Nd – divisions per residue lengthwise along the cartoon (initial default 20, minimum 2)
- ribbonSides Ns – number of sides used to approximate an oval or round cartoon cross-section (initial default 12, minimum 4)
The colorDepth option sets the number of bits used per color component (red, green, blue, and alpha) in offscreen framebuffers, with initial default 8. Switching to 16 bits causes all rendering to occur in an offscreen framebuffer and then get copied to the display, and may slow the frame rate by a factor of two or more. The 16-bit setting may improve the appearance of volume solid rendering if the color mode is also set to 16 bits, e.g., volume colorMode auto16.
• graphics restart
Setting graphics rate true or false indicates whether to report the average frame rate each second in the status line (initial default false). Given without options, graphics rate reports the current maximum frame rate in the Log.
The maxFrameRate option sets the target frame rate in ChimeraX to Nf frames per second (initial default 60). The actual redraw rate may be lower than the target, depending on the rendering speed of the computer and the complexity of the scene.
The waitForVsync option indicates whether to synchronize drawing to the display vertical refresh rate, typically 60 Hz (initial default usually true, but depends on the graphics driver settings). Without synchronization, the frame rate can exceed the vertical refresh rate and the display can exhibit image tearing.
Reinitiate graphics drawing after an error.• graphics selection [ color color-spec ] [ width linewidth ]
Set selection outline color (initial default lime• graphics silhouettes [ true | false ] [ color color-spec ] [ width linewidth ] [ depthJump depth ]
) and width in pixels (initial default is the system display scaling factor, typically 1, but 2 on high-DPI displays such as Apple Retina). Given without options, graphics selection reports the current settings in the Log.
Setting graphics silhouettes true or false specifies whether to show silhouettes, outlines that emphasize borders and discontinuities. Additional options:• graphics triangles model-spec
Given without options, graphics silhouettes reports the current settings in the Log.
- color (initial default black
- width in pixels (initial default is the system display scaling factor, typically 1, but 2 on high-DPI displays such as Apple Retina)
- depthJump – change in depth needed to trigger drawing silhouettes, expressed as a fraction of the distance between the near and far clipping planes (initial default 0.03, but changed to 0.01 by the flat lighting preset)
Report in the Log the total number of triangles used to draw the specified model(s), with breakdowns per model and per representation type within a model. Triangulation fineness can be controlled with graphics quality.