The DEFINITION section contains definitions of all the entities that will be "instanced" later in the MODEL section, similar to declaring variables before using them in traditional programming languages.
The DEFINITION section is the place for definitions of:
The background and atmospheric effects are defined in the ENVIRONMENT section.
The DEFINITION section begins with the word DEFINITION in all caps on a separate line with no punctuation. The section ends where the next section begins.
The DEFINITION section contains declarations of data items (see below for data types and syntax). The order in which items are defined is significant: declarations can only refer to variables that were defined previously in the text file.
A large percentage of the SDL file is taken up by the DEFINITION section. See the section on the C Pre-Processor and #include statements for ways to reduce the bulk of the SDL file and increase clarity.
The renderer is controlled by parameters in the SDL file. You many parameters you can override many of these parameters, or supply parameters not given in the SDL file, with command-line options. These parameters are included in the DEFINITION section.
Most of the parame-ters are available as System Defined Variables for use in other parts of SDL.
The name of the output file can be specified on the command line or included in the camera definition (since each camera outputs its own view of the scene). See the description of Camera data types for more information.
DEFINITION section variable |
command line equivalent |
|---|---|
small_features (obsolete function) | |
0 to 6. If a different value is specified, the system will use the next highest valid number, or 6 if the number input is too large. No message is given.
Determines the maximum number of subdivisions of a pixel.
This limits the maximum number of subdivisions (rays), but does not determine the actual number used. That number depends upon aathreshold and upon the actual scene being rendered. That is, the anti-aliasing is performed adaptively, and only the rays (subdivisions) required to meet the specified criteria are cre-ated.
Set aalevelmax to 0 for no anti-aliasing, and to 4 for a production level.
aalevelmax = 4;
0 to 6. If a different value is specified, the system will use the next highest valid number, or 6 if the number input is too large. No message is given.
Determines the minimum number of subdivisions of a pixel.
This limits the minimum number of subdivisions (rays), but does not determine the actual number used. That number depends upon aathreshold and upon the actual scene being rendered. That is, the anti-aliasing is performed adaptively, and only the rays (subdivisions) required to meet the specified criteria are cre-ated.
A setting of 0 prevents subdivision and generates 1 ray for each pixel. A setting of 1 also prevents subdivision, but generates 4 rays for each pixel. A setting of 2 allows 1 subdivision and up to 9 rays for each pixel. A setting of 4 allows 2 sub-divisions and up to 25 rays for each pixel. A setting of 8 allows 3 subdivisions and up to 81 rays for each pixel.
aalevelmin = 2;
0 to 1. Values less than 0 are adjusted up to 0. Values greater than 1 are ad-justed down to 1. No messages are given when adjusting.
This statement determines the threshold for anti-aliasing.
Set it to 0.5 for production-level anti-aliasing, especially when working with sub-tle differences in shading. Set it to 1 if the picture shows high contrast. When set to a high threshold, less anti-aliasing is performed, resulting in quicker ren-dering. A set-ting of 0 forces maximum pixel subdivision everywhere.
aathreshold = 60;
To allow output of frame extensions on file names, even when only a single frame is being rendered.
animation = TRUE;
Rounded down integer from byframe, and if that value is 0, byextension is set to 1.
To determine the pix file skip extension factor.
This is used in conjunction with startextension and extensionsize to label the output pix files with a different extension from the frame number. If the value given to byextension is a float, it is rounded to the nearest lower integer.
byextension = 2;
This determines the frame skip factor.
This is used in conjunction with startframe and endframe to determine the tem-poral extent of the rendering. If the skip factor is set to 1, every frame is rendered. If it is set to 2, every second frame is rendered. If it is set to -1, frames will be ren-dered in re-verse order.
byframe = -0.5;
composite_rendering = <boolean>;
To create images that are not anti-aliased against a background.
If set to ON, objects that are rendered will not be anti-aliased against the background. For example, a pixel on the edge of an object will not be mixed with black; only the subsamples actually striking the object will be used to compute the color of the pixel. In TIFF terms, this button generates unassociated alpha.
composite_rendering = OFF;
To set a threshold of subsamples required for the pixel as a whole to be considered part of the object and not part of the background.
For example, if coverage threshold is set to 0.5 (50%) then at least half of the subsamples must strike the object, or it will be considered as a "missed ray" determined by the mask generated by the renderer. This actually lets you control the "bleed" around the edges of a sprite.
Used only if composite_rendering = ON.
coverage_threshold = 0.5
create [shader|light|texture] (model = <name>, filename = "<filename>.o" );
After the create statement is placed in an SDL file, the OpenRender model specified by the create statement can be used just like an Alias model.
See the OpenRender document for more details.
create shader ( model = new_shader, filename = "new_shader.o" );
.
.
.
shader grey (
model = new_shader,
lcolor = (150, 150, 150),
ldiffuse = 0.8,
glow = (20, 20, 180)
);
This determines the last frame to be rendered.
This is used in conjunction with startframe and byframe to determine the tempo-ral extent of the rendering.
endframe = 50;
To allow individual control over the rendering of the even fields of an animation. This will be useful if the animation has already been rendered on frames and the user wishes to improve the quality of the animation, but does not wish to re-render those fields which are already rendered as part of the frames.
These values are not animatable. They may not be overridden.
even = TRUE;
This determines the minimum number of digits in the pix file extension.
This is used in conjunction with startextension and byextension to label the files output by the renderer when animating with a different extension from the frame number. If the value given to extensionsize is a float, it is rounded to the nearest lower integer.
extensionsize = 3;
will create <pixfile>.001 for the first frame of an animation.
fast_shading is obsolete, and ignored in V7.5.
To turn on the rendering on fields option of the renderer (raycast or raytrace only at the moment). If this component is TRUE, the output image files will be of the form: <filename>.<frame>[oe] where the "o" extension stands for odd (the field containing the first scanline of the frame) and the "e" extension stands for even (the field con-taining the second scanline of the frame).
This component is not animatable. It may not be overridden.
fields = TRUE
To reduce the amount of memory being used by the RayTracer, at the expense of some evenspeed. With all of the recursive subdivision in the RayTracer, a large amount of memory can be used up in storing grids which undergo heavy use at the start of a ray trace, but are not used at all later on in the process. These grids and their associated memory may be reused to reduce the amount of memory required by the ray tracer.
The ray tracer keeps an time ordered list of all the grids in the scene, based on a Least Recently Used criteria. If grid_cache is set to some small integer (say 600), then after 600 grids have been allocated, the Least Recently used grid will be freed and that memory will be reused to store the next grid created. This is not a data destructive process; the triangles in the freed grid are simply placed back into the larger voxel which held the grid. That voxel may be subdivided again should another ray enter that voxel in the future of the ray trace.
This option is ignored by the PowerTracer, RayCaster, and PowerCaster.
The hidden_line flag is used when hidden line rendering is desired.
hline_from_global lets you set the hline_fill_color, hline_line_color, and number of patch lines (hline_isoparam_U, hline_isoparam_V) for all surfaces in a hidden line rendering. In order to use them, both hidden_line and hline_from_global must be set to ON.
hline_to_fill_color = <boolean>
Use hline_to_fill_color to fill all surfaces in the scene with the hline_fill_color. When set to OFF, hline_to_fill_color fills all surfaces in the scene with the background color, as though the surfaces were transparent.
effectively, 0-255 for R, G, B.
Defines the color of the filled regions for all surfaces in the scene, if hline_to_fill_color is set to ON.
effectively, 0-255 for R, G, B.
Defines the color of the lines for all surfaces in the scene.
Controls the number of lines shown in the U direction of each surface in the scene. When set to 0, no lines are drawn on the surface other than edges.
Controls the number of lines shown in the V direction of each surface in the scene. When set to 0, no lines are drawn on the surface other than edges.
If there is a mismatch in the filmback aspect ratio and the rendering aspect ratio, there can be a region outside the filmback in the rendered image . When ignore_filmgate is OFF, this region is rendered black. If not, this region is rendered with the usual geometry as if the boundary did not exist.
ignore_filmgate = OFF;
One of ALIAS|TIFF|TIFF16|RLA|FIDO|HARRY||SGI
To specify output format of generated images. In addition to the ALIAS file format, we support TIFF and TIFF16, where the latter format contains 16 bits of information per red, green, blue and alpha. Furthermore, we support Wavefront's RLA, Harry Quantel (HARRY), Fido Cineon (FIDO), and SGI.
image_format = ALIAS;
This specifies the amount of randomizing of each ray's direction.
jitter allows for randomizing (or "jittering") the ray direction by some amount, determined by the value of the scalar. It is useful for eliminating Moire patterns and other high frequency aliasing problems. It also helps hide precision problems when looking along an axis. jitter should be set on to avoid the precision problems mentioned ear-lier. With jitter, higher anti-aliasing levels should be used to make sure the aliasing due to jitter is turned into noise.
jitter = 0;
This determines the name of the output matte file created by the renderer.
Each camera in the model is capable of producing output. Therefore, each such cam-era must have the destination of that output specified. That is done by means of the pix and mask components of each camera. Setting the output destination with the matte parameter will apply only to the first camera. Subsequent cameras must have the components specified. The matte parameter is included simply for compatibility with previous versions of SDL. Users are encouraged to use the camera components instead. See the description of those components for the de-faults used, and for the order of priority among the command line option, the components, and the matte pa-rameter.
The matte file specifies how the image must be weighted when compositing. When using a matte for compositing against another image, the scene should be rendered with composite_rendering = TRUE..
The <filename> can be a full or relative UNIX pathname. Relative path names are applied with respect to the current working directory when the renderer is in-voked.
When animating several frames in an animated sequence from a single SDL file, the number of files (and their names) depends upon the renderer.
For the Raycaster or the Raytracer, a series of files with names in the form <filename>.<integer> are created. Note that this extension is in addition to (and ap-plied after) any other extension that may exist as a result of using a filename variable.
matte output is ignored when using the wireframer.
matte = "mask/blue_screen", frame;
This limits the number of reflection rays that may be created.
Ray tracing is a recursive process. Each ray bounces off of reflective objects. This parameter allows the user to limit the number of bounces a ray may take on a global basis. The global limit is pro-vided so that users may produce a quick and dirty image to check the layout and/or texturing of the scene without having to do a major edit of the SDL file. The global limit will only take effect if it is LESS than the limit for the relevant shader, otherwise the shader's limit will be respected. The parameter is only use-ful, therefore, for reducing image quality, not increasing it.
A user wants to RayTrace an SDL file that has highly reflective surfaces with a re-flec-tion limit of 6. He is not sure, however, of the placement of the objects and wishes to do a quick test. So, the user sets the max_reflections = 1. When a ray hits a surface with a reflection limit of 6, a reflection ray will be traced only if the ray is a primary ray (i.e., its level is less than the value of max_reflections).
If, on the other hand, a primary ray hits an object with a reflection limit of 0, no re-flected ray will be traced. This is because although the parameter max_reflections specifies that a ray of level 0 may bounce off of a surface, the surface itself does not allow ANY rays to bounce off of it.
This limits the number of refraction rays that may be created.
RayTracing is a recursive process. Each ray refracts through transparent objects. This parameter allows the user to limit the propagation of such rays on a global basis. The global limit is provided so that users may produce a quick image to check the layout and/or texturing of the scene without having to do a major edit of the SDL file. The global limit will only take effect if it is LESS than the limit for the relevant shader, otherwise the shader's limit will be respected. The parameter is only useful, therefore, for reducing image quality, not increas-ing it.
max_refractions = 2;
This limits the number of shadow rays that may be created.
RayTracing is a recursive process. Each ray creates bundles of shadow rays (one for each shadow casting light). The user can control whether or not these rays are created on a global basis. The global limit is provided so that users may produce a quick image to check the lay-out and/or texturing of the scene with out having to do a major edit of the SDL file. The global limit will only take effect if it is LESS than the limit for the relevant shader, otherwise the shader's limit will be respected. The parameter is therefore only useful for reducing image quality, not increasing it.
Shadow rays are defined to have the same level as the incident ray. Setting max_shadow_level = 0, for example, will only trace shadow rays from primary ray intersections (which by definition are level 0 rays).
max_shadow_level = 0;
To blur visible parts of moving objects across the film plane. Note that if this global flag is FALSE, no motion blur will take place, regardless of whether specific objects or cameras have motion_blur set ON.
motion_blur_on= TRUE;
To allow individual control over the rendering of the odd fields of an ani-mation. This will be useful if the animation has already been rendered on frames and the user wishes to improve the quality of the animation, but does not wish to re-ren-der those fields which are already rendered as part of the frames.
These values are not animatable. They may not be overridden.
odd = FALSE;
This parameter is only relevant when fields rendering is turned on. Once turned on, there needs to be the knowledge as to which frame should come first (time-wise), be it odd or even scanlines.
These values are not animatable. They may not be overridden.
odd_field_first = FALSE;
This determines the name of the output image file created by the renderer.
Each camera in the model is capable of producing output. Therefore, each such cam-era must have the destination of that output specified. That is done by means of the pix and mask components of each camera. Setting the output destination with the output parameter will apply only to the first camera. Subsequent cameras must have the components specified. The output parameter is included simply for compatibility with previous versions of SDL. Users are encouraged to use the camera components instead. See the description of those Camera Data Type components for the defaults used, and for the order of priority among the command line option, the components, and the output parameter.
The <filename> can be a full or relative UNIX pathname. Relative path names are applied with respect to the current working directory when the renderer is invoked.
When animating several frames in an animated sequence from a single SDL file, the number of files (and their names) depends upon the renderer.
For the Raycaster or the Raytracer, a series of files with names in the form <filename>.<integer> are created. Note that this extension is in addition to (and ap-plied after) any other extension that may exist as a result of using a filename variable.
For the wireframer a single file is produced containing all frames.
output = ("pix/bike") ;
The value in this slider represents the edge pixel weights for a 3 by 3 pixel post-process Bartlet filter.
post_adjacent = 1;
The value in this slider represents the center pixel weight for a 3 by 3 pixel post-process Bartlet filter.
post_center = 8;
The value in this slider represents the corner pixel weights for a 3 by 3 pixel post-process Bartlet filter.
post_diagonal = 1;
Executes a 3x3 filter of image after it has been rendered.
post_filter= TRUE;
To generate a sample postage stamp-sized RayTrace of the image (100 by 100 pixels). This preview will generate time and memory estimates for the RayTrace.
This allows control of the message output from the renderer.
When quiet = FALSE is specified, the renderer produces normal message (error, warning and information) output directed to "stderr". When quiet = TRUE is speci-fied, the renderer does not produce diagnostic output.
quiet = TRUE;
resolution = <scalar> <scalar>;
To specify the size of the defined image (not necessarily what is rendered). Necessary so that backgrounds, image planes, etc. can be matched.
With the new camera controls (such as film back offset), the viewport need not always be the same size (or even shape) as the image being defined. Other controls (xleft, yhigh, and so on) can direct the renderer to only render a portion of the whole image. The resolution statement defines the image. Numbers are in pixels.
resolution = 645 486;
To indicate whether or not to render particles.
show_particles = TRUE;
shutter_angle= <floating_point>
To determine the shutter angle size (in degrees) when motion_blur_on is true.
The greater the number of degrees, the more motion blur is applied. For example, setting the shutter angle to 180 degrees will sample the objects over half of the frame step time.
When set to OFF, motion blur is not calculated, regardless of whether or not motion blur is turned on for objects and cameras.
Motion blur is available only with the RayCaster and PowerCaster. World space texture mapping will not work with motion blur.
shutter_angle = 144;
simulation_substeps = <integer>
To control the accuracy of the particle simulation, most notably when particle collisions are being calculated. If this number is small, particles may fail to detect collisions with moving objects, or appear to bounce off objects at the wrong time. Increasing the number of substeps will produce a more accurate animation, but will also increase the amount of time needed to render each frame.
simulation_substeps = 5
simulation_frames_per_second = <integer>
To specify how fast the images will be displayed from the final animation. This value is used to calculate the correct amount of force and gravity to apply to particles during the simulation.
simulation_frames_per_second = 15
Note that small_features has been obsolete since V5.1. Its presence in SDL is ignored.
Rounded down integer from startframe.
To specify the starting extension number of the output pix file for an animation.
Useful for occasions when the byframe and/or startframe of an animation are non-integer and you want the files to be numbered as integers when output by the renderer.
startextension = 4;
This determines the first frame to be rendered.
This is used in conjunction with endframe and byframe to determine the tempo-ral extent of the rendering.
startframe = 300;
The stereo flag specifies if all the cameras in the SDL file are to render a stereo pair of images.
This value may not be animated. This can be used in conjunction with fields. See also stereo_eye_offset.
Note: this will cause two sets of files to be output for each camera. The output file names will be suffixed with "_LEFT" and "_RIGHT".
stereo = TRUE;
To specify the eye separation between the eye points of two cameras that will be used to render the stereo pair. The offset is in world coordinates and specifies the eye's off-set in X. See "Creating Rendered Stereo Pairs" tutorial for a more detailed description.
This component is animatable. Although this component has a default, it is wise to specify it since the magnitude of the offset depends on the scale of the scene. See the Stereo tutorial for a more detailed description.
stereo_eye_offset = 3.0
subdivision_control = ( ( <scalar> ,<triple> ), (<scalar> , <triple> ),
This controls how spatial subdivision will function for the RayTracer.
This is probably the most complicated control for the user to understand, but it allows the sophisticated user to experiment with different types of spatial subdi-vision for RayTracing his model.
The RayTracer subdivides world space into voxels. Each voxel is a parallelpiped ori-ented parallel to the modeling space axes. All of space is initially contained in one large voxel. When triangles are created to approximate the geometry of the scene, they are stored in the voxel. After all the geometry is defined, the number of triangles in the voxel is used to determine if the voxel should be subdivided or not. If the voxel should be subdivided, how should the subdivision be per-formed? These issues of when and how for subdivision are specified by the sub-division_control parameter.
The control is in the form of a list of entries. Each entry contains two parts - a <scalar> and a <triple>.
The <scalar> part controls when to subdivide, the <triple> part controls how. The list may have any number of entries. The first entry in the list defines a range from zero to the value of the <scalar>. If the number of triangles in the voxel is in this range, then the voxel is not subdivided. The second entry in the list also defines a range, this time from the end of the previ-ous range to the value of this entry's <scalar>. If the number of triangles in the voxel is in this second range, then the voxel is subdivided by using the <triple> of the previous (first) entry.
The subdi-vision is performed by simply dividing the voxel into equal sized pieces, where the number of pieces in each of the x,y & z dimensions is given by the <triple>. Thus, the <scalar> defines the high end of a range, with the first range starting at zero and sub-sequent ranges starting where their predecessor left off. The <triple> defines the number of subdivisions to be made in each dimension when the number of triangles falls in the range follow-ing that defined by the <scalar>. The <triple> for the last en-try, therefore, is used when the number of triangles exceeds the last <scalar> given. Conversely, if the number of triangles is less than the first <scalar> given, then no subdivision is performed.
The process of subdivision is recursively applied to each voxel created by the subdi-vision of the initial voxel until no further such subdivision is possible.
subdivision_control = ( ( 8, (3,3,3) ), ( 30, (4,4,4) ), ( 100, (6,6,5) ), ( 500, (6,6,8) ), ( 1000, (10,10,10) ), ( 2000, (20,20,20) ), ( 5000, (10,10,10) ) ) ;
subdivision_recursion_limit = <scalar> ;
Useful 1, 2, 3; actual 0 to infinity
The subdivision_recursion_limit limits the number of times the subdivision_control criteria may be applied to a voxel.
It limits, indirectly, the amount of machine resources used. If there is a very small volume with many, many triangles in it, then this will prevent the RayTracer from recursing too much.
subdivision_recursion_limit = 2;
If set to TRUE, all textures are used. If set to FALSE, no textures are used.
textures_active = TRUE;
To make use of the coordinate system used in the modeler. yaxis is the standard coordinate pointing up for video animators, while industrial designers tend to use zaxis.
use_wavefront_depth = <scalar>;
This parameter is only relevant if depth files are written out during rendering. If turned to FALSE, then the depth file is the same Alias depth file it has always been. If this is set to TRUE, then a depth file that is suitable for Composer is written. This depth file is different from the standard Alias depth file, in that the depth is an unsigned short value that is normalized between the near and far clipping planes.
use_saved_geometry = <scalar>;
-G# Turn saved geometry on (non-zero `#') or off(0).
Saved geometry is useful for animations with complicated geometries that take a long time to subdivide, such as trimmed surfaces, displacement mapped geometry, or anything with a high subdivision. If use_saved_geometry is TRUE, these surfaces are tesselated (subdivided into triangles) only once, and then these triangles will be kept in memory and re-used next frame. Since the triangles are saved, animation of some surface properties necessarily disallows the saving of geometry. Metamorphosis is a prime example; since the geometry changes from frame to frame, there is no point storing the geometry from frame to frame. (See below for a complete list of operations that will invalidate saved geometry.)
Saved geometry will NOT be applied on:
You MAY save geometry for an object with a displacement map shader on it, however, if the user animates the displacement map, the saved geometry will not change, and neither will the appearance of the object in the image.
You cannot stop and start a render process that uses Saved Geometry and retain the saved geometry.
Saved Geometry uses a significant amount of memory. You should have at least 100 megabytes of swap space available before attempting to use it.
Identifies the Alias version that created this SDL file. Note that the default changes every release.
version = 3.2.1;
0 to 8190 (Must be less than xright). Interpreted as an integer.
Determines the left edge of the image on the screen.
The xleft, xright, yhigh and ylow parameters determine the actual pixels to be ren-dered. They do not affect the scene or the view being rendered in any way, but are used to render a rectangular portion of the view.
The rectangle selected must be valid.
That is: 0 <= xleft < xright, and 0 <= ylow < yhigh.
xleft = 128;
1 to 8191. Interpreted as an integer.
Determines the right edge of the image on the screen.
The xleft, xright, yhigh and ylow parameters determine the actual pixels to be ren-dered. They do not affect the scene or the view being rendered in any way, but rather, are used to render a rectangular portion of the view.
The rectangle selected must be valid. That is: 0 <= xleft <xright, and 0 <= ylow < yhigh.
Note that when specified in SDL, xright is an absolute number, but when speci-fied on the command line, <wide> is the number of pixels of width of the image (i.e., xright - xleft). This is so SDL retains the same sense as previous versions and the same sense as the interactive package, while the command line behavior is consistent with all the framebuffer standalones.
xright = 256;
1 to 8191. Interpreted as an integer.
Determines the top of the image on the screen.
The xleft, xright, yhigh and ylow parameters determine the actual pixels to be ren-dered. They do not affect the scene or the view being rendered in any way, but are used to render a rectangular portion of the view.
The rectangle selected must be valid. That is: 0 <= xleft <xright, and 0 <= ylow <yhigh.
When specified in SDL, yhigh is an absolute number, but when speci-fied on the command line, <high> is the number of pixels of height of the image (i.e., yhigh - ylow). This is so SDL retains the same sense as previous versions and the same sense as the interactive package, while the command line behavior is consistent with all the framebuffer standalones.
yhigh = 256;
0 to 8190. Interpreted as an integer.
Determines the bottom of the image on the screen.
The xleft, xright, yhigh and ylow parameters determine the actual pixels to be ren-dered. They do not affect the scene or the view being rendered in any way, but are used to render a rectangular portion of the view.
The rectangle selected must be valid.
That is: 0 <= xleft <xright, and 0 <= ylow < yhigh.
ylow = 128;