Keywords: main

Next: 6.2 Inventor mental ray Up: 6. Command Line Options Previous: 6. Command Line Options

# 6.1 mental ray

When started from a shell command line, the mental ray rendering software accepts a large number of options. Most of these correspond to similar commands or camera or options statements in the scene file. When an option is given on the command line, it overrides the corresponding command or statement in the scene file, which in turn overrides the defaults. The defaults for certain options given in the option list below apply only if the corresponding command or statement is not present in the scene file.

mental ray is started as

`ray` [options] [scenefile]

If no scene file is given, the scene is read from standard input. Scene file names normally end in `.mi`. If the extension is missing mental ray will read the name as specified, and if this fails, retry with `.mi` added.

Options can be abbreviated as long as the given substring is unambiguous. mental ray checks for ambiguities and prints an error message listing the choices. For example, `-resolution` can be abbreviated as `-res`. For frequently-used options such as `-verbose` and `-filename`, short forms are available. The page numbers on the right side refer to the relevant chapters in the main part of this book. The available options are:

- `-acceleration bsp|grid|raycl`
  Selects the binary space partitioning ( BSP), voxel grid, or ray classification2.1 rendering algorithm. The default is BSP.

- `-approx` [options] `-`3.1
  mental ray 3.1.2 and later allow specifying override approximations on the command line. Override approximations override any object approximations in the scene file. They are primarily useful for fast preview rendering, where approximation accuracy is not required. The following options can be specified:

`view` | view-dependent approximation
`fine` | fine approximation with microtriangles
`sharp` | faceted, useful for fine displacement
`parametric` U V | rectangular grid of U . V . 2 triangles
`regular` U V | rectangular grid that spans patches
`length` L | triangle edge length less than D
`distance` D | distance from true surface less than D
`angle` A | angle between neighboring triangles less than
| A degrees
`any` | it is sufficient if any of length, distance, and
| angle is satisfied
min max | subdivide at least min and at most max times,
| default 0 5

- Except for `any`, which must be spelled out, all options can be abbreviated by their first letter. If no options are specified (`-approx -`), parametric 0 0 is used, which produces a very fast low-quality approximation. See the scene description chapter for detailed information on approximations.

- `-approx_displace` [options] `-`3.1
  This option is similar to `-approx` and accepts the same options, but sets the override approximation for displacement. If no options are given, it defaults to parametric 0 0, which is so low that most displacements turn into a vaguely bumpy surface. High-quality displacement requires an approximation like `-approx fine view length 0.25 0 7 -`.

- `-aperture` aperture
  The aperture is the width of the viewing plane. The height of the viewing plane is aperture divided by aspect.

- `-aspect` aspect
  This is the aspect ratio of the camera. The default is 1.33. In camera space, aperture is the width of the viewing plane, and aperture divided by aspect is the height. The viewing plane is divided into pixels as specified by the `resolution` viewdef, so the aspect will result in nonsquare pixels if it is not equal to the X resolution divided by the Y resolution.

- `-bsp_depth` depth
  The maximum number of levels in the BSP tree. This option is used only if binary space partitioning is enabled. Larger tree depths reduce rendering time but increase memory consumption, and also slightly increase preprocessing time. The default is 40.

- `-bsp_memory` memory
  The maximum memory in megabytes used in BSP preprocessing. A value of zero indicates that there is no limit on the memory consumption; this is the default.

- `-bsp_size` size
  The maximum number of primitives in a leaf of the BSP tree. Larger leaves will be subdivided unless the bsp_depth is reached. This option is used only if binary space partitioning is enabled. Larger leaf sizes reduce memory consumption but increase rendering time. The default is 10.

- `-bsp_shadow on|off`3.1
  mental ray 3.1.2 and later support a separate shadow BSP tree that accelerates raytraced shadows. It can greatly improve speed if shadows are cast by simplified shadow-only objects because it is no longer necessary to populate the master BSP tree with large hero objects. This mode is off by default.

- `-caustic on|off`
  Enable or disable the generation of caustics in an appropriately defined scene. The default is `off`.

- `-caustic_accuracy` nphotons`[`radius`]`
  The number of photons used to estimate caustics during rendering and the maximum radius to be used when picking up the photons. The number of photons may be set to 0, which means that all photons within the given radius are used. The defaults are 100 and a scene-size dependent radius.

- `-clip` hither yon
  The hither (near) and yon (far) planes are planes parallel to the viewing plane that delimit the rendered scene. Points outside the space between the hither and yon planes will not be rendered. The defaults are 0.001 and 1000000.0.

- `-code "`filename`"` ... `-`
  The named filename is interpreted as a C source file (ending with the extension ``.c'') and compiled and linked into mental ray.

- `-colorclip rgb|alpha|raw`
  This option controls the rules used to clip an RGBA color before quantization to an 8-bit or 16-bit frame buffer6.1. The `rgb` mode states that RGB are first to be clipped to the range [0, 1] before A is clipped to [max(R, G, B), 1]. This is the default mode. The alpha mode lets A first be clipped to [0, 1] before RGB is clipped to [0, A]. Both of these modes ensure that all channels are within [0, 1] and that A is no less than any of R, G, and B, which is is the valid domain of premultiplied colors. The third mode, raw, ignores all requirements, and clips both A and RGB to [0, 1]. This is useful to make mental ray modify output colors as little as possible. Because the color output may be invalid, the raw mode overrides the `premultiply off` option if present. Desaturation is always applied if enabled.

- `-contrast` r g b [a]
  The contrast controls oversampling. If neighboring samples differ by more than the color r, g, b, a, oversampling is done as specified by the sampling options. The default is 0.1 0.1 0.1 0.1. If missing, the default for a is the average of r, g, and b.

- `-c_compiler "`filename`"`
  If this option is given, the standard C compiler `"cc"` is replaced with filename.

- `-c_flags "`options`"`
  The options string replaces the standard options given to the C compiler. The defaults depend on the machine type. If the options begin with two plus signs6.2, such as `"++ -I."`, it is inserted into the default options instead of replacing them.

- `-c_linker "`filename`"`
  If this option is given, the standard linker `"ld"` is replaced with filename.

- `-desaturate on|off`
  If a rendered sample returns an RGBA color whose components are outside the legal range, mental ray will clip the color into this legal range. This option determines how the clipping of R, G, and B is performed. If desaturation is turned off, which is the default, the components are clipped individually. If turned on, then if any of R, G, and B exceed the allowed range, the color is shifted towards the grayscale axis of the color cube in order to try to maintain the perceived brightness of that color, effectively bleaching out the color. The valid range of RGBA is controlled by the `colorclip` option.

- `-diagnostic bsp depth|size`
  This diagnostic mode6.3 can be used to visualize the parameters for BSP tree parameters (see `-bsp depth` and `-bsp size` options), to find the reason for unexpected large depths or sizes reported after rendering.

- `-diagnostic grid off|object|world|camera` size
  This diagnostic mode6.4 is intended for scene debugging. Unless set to `off`, it draws a colored grid on all objects in the scene that shows object, world, or camera space coordinates. Steps on the X, Y, and Z axes are shown with red, green, and blue grid lines, respectively. The distance between grid lines is size units. This is useful to estimate the size and distances between objects in mental ray, or to visualize object space coordinates. The `off` argument disables the grid. The default is `off`.

- `-diagnostic photon off|density|irradiance` max
  When rendering caustics or global illumination, this option disables all material shaders in the scene and produces a false-color rendering of photon density, or the average of the red, green, and blue irradiance components. Photon density is the number of photons per unit surface area. max is the density (or irradiance) that is assigned to 100%, or red. The colors are, from 0% to 100%: Blue, cyan, green, yellow, and red. Higher values fade to white. max can be given as zero in which case the appropriate maximum is automatically found. This is done after the whole image has been rendered. This mode is useful when tuning the number of photons in a photonmap and setting the various `_accuracy` options, since the density (or irradiance) is estimated using those settings. The default is `off`.

- `-diagnostic samples`
  Switch to sampling visualization mode and create grayscale images representing sampling densities instead of color images. A black pixel has had no samples, whereas a white pixel has had the maximum amount as specified by the `-samples` option. In addition, a red grid shows task rectangle boundaries.

- `-diagnostic finalgather`3.1
  This mode shows final gathering points, as green dots for initial raster-space final gathering points and red dots for render-time final gathering points.

- `-displace on|off`
  Ignore all displacement shaders if set to `off`. The default is `on`.

- `-dither on|off`
  Dithering dithering mitigates 8-bit and 16-bit color quantization errors by introducing noise into the pixel such that the round-off errors are randomly distributed. The default is `off`.

- `-echo "`filename`"` [`ascii`] [`source`] [`approx`] [`norendercommand`] [`textures`] [`omit "`S`"`] [`norecurse "`S`"`] `-`
  Echo the current scene to the file filename. The options specify the format of the echoed file. Allowed options are:

- `ascii` uses ascii format for the vectors (default is binary),

- `source` prefers source geometry over triangles if available (default),

- `approx` prefers triangles over source geometry if available,

- `norendercommand` disables the echo of the render command,

- `textures` includes texture pixel data verbatim.

- `omit` specifies that certain types of elements, specified by S, should be omitted from the output. It is supported by mental ray 3.0 only. Note that both `omit` and `norecurse` will produce incomplete and nonrenderable scene files. These options are useful for extracting subsets of a scene.

- `norecurse` specifies that references of certain types of elements specified by S should be omitted from the output. It is supported by mental ray 3.0 only. For example, if S contains `icil`, instances of cameras and lights would be echoed (unless disabled by `omit`), but the instanced camera or light would not be echoed first. The S strings of the `omit` and `norecurse` attributes are sequences of the following codes:

code | element | affected statement
`g` | instance group | `instgroup`
`o` | geometric object | `object`
`c` | camera | `camera`
`l` | light source | `light`
`m` | material | `material`
`t` | texture | `texture`
`p` | option block | `options`
`s` | named shader | `shader`
`d` | declaration | `declare`
`u` | user data | `data`
`ig` | instance of an instance group | `instance`
`io` | instance of an object | `instance`
`ic` | instance of a camera | `instance`
`il` | instance of a light | `instance`
`is` | instance of a geometry shader | `instance`

- Note that triangle echos have displacement mapping already applied to the triangles, but the displacement shaders are not removed from the materials so the echoed file will get displaced twice when rendered. The echo option must be terminated with a double minus.

- `-face front|back|both`
  The front side of a geometric object in the scene is defined to be the side its normal vector points away from. By specifying that only front-facing triangles are to be rendered, speed can be improved because fewer triangles need to be tested for a ray. The default is `face both`.

- `-file_name "`filename`"`
  Overrides the file name given by the first file `output` statement in the camera definition in the scene file. The full file or path name must be given, including extension if desired.

- `-file_type "`format`"`
  Overrides the file format given by the first file `output` statement in the camera definition in the scene file. File formats include `"pic"` for Softimage image files, `"rla"` for Wavefront RLA files, and `"ps"` for PostScript files if contour mode is enabled.

- `-filter box|triangle|gauss|mitchell|lanczos` width [height]
  This option specifies how multiple samples in recursive sampling mode are to be combined. The filter defaults to a box filter of width and height 1. The filter size can also be specified, in pixel units. Good filter sizes are 1.0 for `box`, 2.0 for `triangle`, 3.0 for `gauss`, and 4.0 for `mitchell` and `lanczos`6.5. In mental ray 2.0, this option requires a sampling density of at least `1 1`; in mental ray 2.1 and later the sampling density must be at least `-1 0`.

- `-finalgather on|off|fastlookup`
  Enables or disables final gathering6.6. It is disabled by default. Final gathering is a rendering technique used for computing indirect illumination with a one-generation raytracing step. mental ray 3.0 adds a third choice, `fastlookup`, that enables final gathering and also arranges for irradiance to be stored in the photon map. This slows down photon tracing but greatly accelerates final gathering.

- `-finalgather_accuracy` [ `view` ] nrays_int [maxdist [mindist]]
  nrays is the number of rays cast in a final gathering step during rendering. The default is 1000. maxdist is the maximum distance within which a final gather result can be reused. The default is scene dependent. mindist is the minimum distance within which final gather results must be reused. The default is scene dependent. Both distances are specified in world space units, or raster space units if `view`3.x is specified.

- `-focal` distance`|infinity`
  The focal distance is set to distance. The focal distance is the distance from the camera to the viewing plane. The viewing plane is the plane in front of the camera that the rendered scene is projected onto; its edges correspond to the edges of the rendered image. If `infinity` is used in place of the distance, an orthographic view is rendered.

- `-gamma` gamma_factor
  Gamma correction can be applied to rendered color pixels to compensate for output devices with a nonlinear color response. All R, G, B, and alpha component values are raised to gamma_factor. The default gamma factor is 1.0, which turns gamma correction off.

- `-geometry on|off`
  Ignore all geometry shaders if set to `off`. The default is `on`.

- `-globillum on|off`
  Enable or disable the computation of global illumination6.7. The default is `off`. To actually compute global illumination, lights must have an energy, and materials must have photon shaders.

- `-globillum_accuracy` nphotons_int [radius]
  The number of photons used to estimate global illumination during rendering and the maximum radius to be used when reading photons during rendering. The defaults number of photons is 500. If nphotons is set to 0, all photons within the given radius are used. The default radius is scene size dependent.

- `-grid_depth` depthint3.1
  If the hierarchical grid algorithm3.1 is used, this option sets the number of recursion levels. If a voxel of a grid contains too much detail, it is subdivided by a subgrid for that voxel, which adds another level.

- `-grid_resolution` xres [yres zres3.1
  If the hierarchical grid algorithm3.1 is used, this option sets the number of grid voxels in the X, Y, and Z dimensions. If only one number is given, it is used for all three dimensions. The default is 0 0 0, which selects a default computed at runtime.

- `-grid_size` factor
  If the static grid algorithm2.1 is used, `factor` is a correction factor for mental ray's internal guess for the grid resolution, so that numbers greater than 1.0 increase the number of voxels in each dimension and numbers less than 1.0 decrease it.

- `-grid_size` sizeint3.1
  If the hierarchical grid algorithm3.1 is used, this option sets the maximum number of triangles in a grid voxel. If there are more, and the grid depth permits it, the voxel is subdivided into a subgrid.

- `-help`
  Print a summary of all options with their allowed parameters, and terminate.

- `-hosts "`hostname[`:`portnumber] [ remote parameters]`"` ... `-`
  The machine list overrides the machine list taken from the `.rayhosts` file, if present. One slave is started on each machine specified. Machine names must be given as expected by the local name resolving method (such as `/etc/hosts`) or as a numeric internet address (`nnn.nnn.nnn.nnn`).

- `-I "`path1:path2:...`"`
  Overrides the path used to resolve `$include` statements in the .mi scene file. The default path contains the directories `.`, `{_MI_REG_INCLUDE}` (see page ), `/usr/local/mi/rayinc`, `/usr/include`, and `/usr/include/mi`. Note that only one `-I` option can be specified. It may contain a colon-separated ( Unix only) or semicolon-separated ( Unix and Windows NT) list of directory paths that are tried in sequence if a `$include` statement using angle brackets is used in the .mi scene file. Paths introduced with an exclamation point are special; they are applied to quoted `$include` paths too, and substitute the entire directory path. This can be used to force mental ray to use a specified path regardless of the path specified in the `$include` statement, for example because that path points to an obsolete (1.9) version of a declaration file. For example, `-I /a:/b:!/new` tries to find a path `<x/y/z>` first as `/a/x/y/z`, then `/b/x/y/z`, then `/new/z`.

- `-imgpipe` fd
  Normally mental ray prints connection information into the output image file that let programs like imf_disp connect and display images while being rendered. If `-imgpipe` is used, the relevant information is printed to the given file descriptor fd instead. This can be used for command lines such as ```ray -imgpipe 1 scene.mi | imf_disp -`''. The imf_disp program is a viewer provided by mental images that supports image piping.

- `-jitter` jitter
  The jittering factor introduces systematic variations into sample locations if jitter is set to 1.0. Jittering is turned off by default, or by specifying a jitter of 0.0.

- `-jobmemory` physical [ virtual ]
  The physical argument specifies the size of mental ray 3.x's cache memory, in megabytes. The default is unlimited for mental ray 3.0 and 512 for mental ray 3.1. (mental ray 3.1 supports fine microtriangle tessellation which depend on the ability to flush obsolete triangles from the cache.) The virtual number of megabytes limits the amount of virtual address space available for memory mapping, mostly for memory mapped textures; the default is 1024 (1 GB) on 32-bit machines and 0 (unlimited) on 64-bit machines.

- `-L "`path1:path2:...`"`
  This is an abbreviation for `-ld_path`.

- `-ld_libs "`libraries`"`
  The libraries string replaces the standard library options given to the linker. The defaults depend on the machine used, typically `"-lm -lc"`. Linker options are machine dependent and operating system dependent and cannot be changed.

- `-ld_path "`path1:path2:...`"`
  Supply a list of library search paths that mental ray searches for shader libraries containing shader code. The paths given here precede those that can be given by the environment variable `MI_LIBRARY_PATH` and the built-in search path (consisting of the directories `{_MI_REG_LIBRARY}`, `/usr/local/mi/lib`, and `.`; see page ).

- `-lens on|off`
  Ignore all lens shaders if set to `off`. The default is `on`.

- `-link "`filename`"` ... `-`
  Like the code command, the link command attaches external shaders to mental ray, which can then be used as shading functions. While the code command accepts ``.c'' files as filename, the link command expects either object files ending in ``.o'' or ``.obj'', or shader library files ending in ``.so'' or ``.dll''.

- `-merge on|off`
  Ignore all merge epsilons and all connections in the scene if set to `off`. The default is `on`.

- `-message` module class_list ... `-`
  Enable or disable individual message classes, per module. The module names are printed at the beginning of every message printed by mental ray; `all` can be used to modify the message classes of all modules. The class_list is a comma-separated list of classes to print. Supported message classes are `phase`, `progress`, `vprogress`, `time`, `scene`, `memory`, `render`, `vrender`, `resources`, `network`, `files`, and `debug`. The special words `default`, `all`, and `none` are also supported. A class can be inverted by prepending an exclamation point. For example, to print less verbose RC progress messages and make all modules report every file accessed, specify

- `-message rc default,!vprogress all default,files -`

- `-nomaster`3.1
  When rendering with multiple hosts, schedule all jobs on slaves only, if possible. For example, the master host will not render, tessellate, compute shadow maps, etc; but it will still load textures of the slaves, and will also collect and save rendered images. This is useful if the master host also runs front-end applications that must remain responsive even under heavy load.

- `-o "`filename`"`
  This is an abbreviation for `-file_name`.

- `-motion_steps` steps3.1
  Approximate instance motion transformations with steps segments. This results in a smooth motion path, as if a similar number of motion vectors had been specified. steps must be a number between 1 and 15; 1 is the default.

- `-offset` x y
  An offset for the rendered image6.8. The default is 0.0 for both x and y, which means that the image will be centered on the camera's Z axis. Positive values translate the image up and to the right. The offset is measured in pixel units.

- `-output on|off`
  Ignore all output shaders if set to `off`. The default is `on`. File output statements are not affected.

- `-photonmap_file "`filename`"`
  Use filename for the photon map, in all frames. If the photon map file does not exist, it is created and saved. If it exists, it is loaded and used. For multiple frames it is only created for the first frame and then loaded for the remaining frames, which can greatly speed up rendering in scenes where the illumination does not change much, such as camera flythroughs.

- `-photonvol_accuracy` nphotonsint`[`radius`]`
  Controls how global illumination or caustics in participating media are estimated by looking up the photon map during rendering. nphotons is the maximum number of photons to examine and radius the maximum radius to search. if nphotons is 0, all photons are examined up to the radius limit. A radius of 0 means that a scene size dependent radius will be used. The defaults are 30 and 0.0.

- `-photon_depth` reflect [refractint [sum]]
  `photon_depth` is similar to `trace_depth` except that it applies to photons. If set to 0, no photons will be reflected; if set to 1, one level is allowed but a photon cannot be reflected again, and so on. The defaults are 5 5 5.

- `-premultiply on|off`
  Premultiplication means that colors are stored with alpha multiplied to R, G, and B. This is the default. For example, white at 10% opacity is not stored as (1, 1, 1, 0.1) but as (0.1, 0.1, 0.1, 0.1). If turned off, mental ray writes the colors without premultiplication; in this case color clipping should also be switched to raw mode.

- `-raycl_memory` memory
  2.1This option sets the amount of memory to be used by the ray space subdivision algorithm for acceleration data structures to memory megabytes on each CPU.

- `-raycl_subdivision` subdiv subdiv_2d
  2.1Controls the ray space subdivision used by the ray classification2.1 rendering algorithm. The optimal subdivision is determined automatically; this option can be used to modify the result. Arguments of 0 leave the calculated subdivision unchanged, positive numbers increase and negative numbers reduce the subdivision. subdiv controls general subdivision; subdiv_2d controls primary and shadow rays.

- `-render` beginint [endint [incint]]
  Render only frames begin through end6.9. If end is omitted, begin and all following frames are rendered. If inc is given, only every inc-th frame is rendered. Frame 1 is considered the first `render` statement in the scene file; camera frame specifiers are not considered. For example, `4 8 2` will skip the first three frames, then render frame 4, 6, and 8, and omit the rest. It is not an error if the scene file has fewer frames than requested.

- `-resolution` x y
  Specifies the width and height of the output image in pixels. The default is 768 576.

- `-samplelock on|off`
  This option selects whether sampling of area light sources, motion blur, and depth-of-field is static or dependent on the frame number. The default is on (static).

- `-samples` min max
  This option determines the minimum and maximum sample rate. Each pixel is sampled at least (22 . min) and at most (22 . max) times in each direction. If min is 0, each pixel is sampled at least once. Positive values increase the minimum sample rate; negative numbers reduce the sample rate. The default is -2 0.

- `-samples` min max defmin defmax3.1
  mental ray 3.1.2 accepts two optional extra parameters that set the default object sample limits. In mental ray 3.1.2, objects may constrain sampling of the pixels they cover. The defmin and defmax parameters apply to pixels where no objects are seen, or all the objects that are seen have no `samples` limit. mental ray will never take fewer than 2min and more than 2max samples, and in areas with no object sample settings it will further reduce that range to 2defmin through 2defmax. The defaults are -2 0 -128 127; the latter two are markers for ``no further restrictions'' because they are outside the -2 0 range.

- `-scanline on|off|opengl`
  This statement allows turning off the scanline rendering algorithm to force mental ray to rely exclusively on ray tracing. This will slow down rendering in most cases. The `opengl` mode uses local OpenGL hardware to accelerate rendering, which sacrifice some accuracy for a large speed gain. If shadow mapping is also used, `-shadowmap opengl` should also be chosen. See page for more information. The default scanline mode is `on`.

- `-shadow off|on|sort|segments`
  Choose the shadow mode, or disable shadows. The default is `on`.

- `off` disables all shadows, including shadow maps.

- `on` enables standard shadows.

- `sort` enables shadows and sorts shadow intersections before calling shadow shaders. Some shadow shaders require this.

- `segments` enables shadows and traces shadow rays like visible rays. Some shadow shaders require this.

- `-shadowmap` [`on|off|opengl`] [`only`] [`rebuild`] [`reuse`] [`motion`] [`nomotion`] `-`
  This option can be used to control shadow maps. The allowed options are:

- `on` activates use of shadow maps.

- `off` disables use of shadow maps. This is the default.

- `opengl` enables use of shadow maps, and uses local OpenGL hardware to accelerate shadow map rendering, at a small accuracy loss. See also page and `-scanline opengl` above; it often makes sense to enable OpenGL in both options.

- `only` causes only shadow maps to be rendered, without rendering a color image. By default the color image is rendered also. This is useful to precompute shadow maps before the actual color rendering passes begin.

- `rebuild` causes all shadow maps to be recomputed, even if they exist in memory from a previous frame or are found on disk. By default shadow maps are computed only if they are found neither in memory nor on disk.

- `reuse` allow the reuse of shadowmaps. This is the default. If a shadowmap is found in memory or on disk it is used instead of recomputing it. This only works if object space mode is selected in the options block of the scene.

- `motion` activates motion blurred shadow maps. This is enabled by default if shadow maps are turned on.

- `nomotion` disables motion blurred shadow maps. This improves rendering speed.

- `-shutter` [ delay ] shutter
  This option contrils motion blurring. The camera shutter opens at time delay3.1 and closes at time shutter. The defaults are both 0.0. If shutter is equal to delay, motion blurring is disabled; if shutter is greater than delay, motion blurring is enabled. The normal range is (0, 1), which uses the full length of the motion vectors or motion vector paths3.1. It can be useful to set delay3.1 and shutter both to 0.5, which disables motion blurring but renders with an offset of one half frame, which allows bidirectional post-blurring in an output shader.

- `-T "`path1:path2:...`"`3.x
  Specifies a list of directories where texture files will be searched. The default is the current directory. The list is colon-separated ( Unix only) or semicolon-separated ( Unix and Windows NT). As with the `-I` option, paths introduced with an exclamation point are special: they substitute the entire directory path of the texture name and keep only the last component (the file name) when searching.

- `-task_size` task_size
  This option specifies the size of the image rectangles during rendering. Smaller task sizes are convenient for previewing, but also increase the overall rendering time and reduce the effectiveness of edge following. This option can also be used to optimize load balancing for parallel rendering. If the `task_size` is not specified, an appropriate default value such as 32 is used.

- `-threads` nthreadsint
  Normally, mental ray starts one thread for each processor in the system. The number of threads can be changed with this option.

- `-time_contrast` r g b [a]
  The time contrast controls temporal oversampling for motion blurred scenes. It works similar to the spatial contrast parameter explained above, but applies to motion blurring only. The default is 0.2 0.2 0.2 0.2. For fast motion blur, the time contrast must be set to 0 0 0 and minimum and maximum sampling must have the same value, such as 2 2.

- `-trace on|off`
  Normally, mental ray will use a combination of a scanline rendering algorithm and ray tracing to calculate samples of the scene. If `-trace off` is specified, ray tracing is disabled, and mental ray will rely exclusively on the scanline algorithm.

- `-trace_depth` reflect [refractint [sum]]
  reflect limits the number of recursive reflection rays. If it is set to 0, no reflection rays will be cast; if it is set to 1, one level is allowed but a reflection ray can not be reflected again, and so on. Similarly, refract controls the maximum depth of refraction and transparency rays. Additionally, it is possible to limit the sum of reflection and refraction rays with sum. The defaults are 2 2 4.

- `-v on|off|`level
  An abbreviation for `-verbose`.

- `-verbose on|off|`level
  This command controls verbose messages. There are seven levels: fatal errors (1), errors (2), warnings (3), progress reports (4), informational messages (5), debugging messages (6), and verbose debugging messages (7). All message categories numerically equal to or less than level are printed. Verbose `off` is equivalent to level 2 (fatal errors and errors); verbose `on` is equivalent to level 5 (everything except debugging messages).

- `-volume on|off`
  Ignore all volume shaders if set to `off`. The default is `on`.

- `-window` x_low y_low x_highint y_high
  Only the sub-rectangle of the image specified by the four bounds will be rendered. All pixels that fall outside the rectangle will be left black.

- `-xcolor` [`"`control`"`]
  Print colored messages. Error messages, for example, are printed in red, which makes them stand out much better in verbose reports. The control string allows customization.

#### Footnotes

... buffer6.1
  Color clipping control is available in mental ray 2.1 and up.
... signs6.2
  Option insertion is supported by mental ray 2.1 and up.
... mode6.3
  The -diagnostic bsp option requires mental ray 3.0 or higher.
... mode6.4
  All -diagnostic options require mental ray 2.1 or higher.
... `lanczos`6.5
  The Mitchell and Lanczos filters are supported only in mental ray 2.1 and up.
... gathering6.6
  Final gathering requires mental ray 2.1 or up.
... illumination6.7
  Global illumination requires mental ray 2.1 or later.
... image6.8
  Camera offsets are supported only in mental ray 2.1 and up.
...end6.9
  The -render option was introduced in mental ray 2.1.36.

Next: 6.2 Inventor mental ray Up: 6. Command Line Options Previous: 6. Command Line Options