![]() |
![]() |
![]() |
![]() |
DefaultProps
Synopsis
Define the Graphics Display Kit properties
group+OPort GDprops_templ {
float+read col<animate=1>[3];
float hi1_col<animate=1>[3];
float hi2_col<animate=1>[3];
float material<animate=1>[4];
float spec_col<animate=1>[3];
float trans<animate=1>;
enum draw_mode {
choices = {"Copy", "XOR"};
};
int line_width<animate=1>;
enum line_style {
choices = {"Solid", "Dashed", "Dotted", "DashDot"};
};
int line_aa;
float dir_pt_size<animate=1>;
int subdiv<animate=1>;
int jitter<animate=1>;
enum cull {
choices = {"Normal", "Back", "Front", "Flip Normals"};
};
enum voxel_interp {
choices = {"Point", "Trilinear"};
};
enum ray_algo {
choices = {"Direct Composite", "Average", "Maximum",
"Distance to Max", "SFP"};
};
enum ray_norm {
choices = {"Global", "View", "Ray"};
};
int fat_ray;
float sfp_absorb;
float sfp_emit;
string font;
int inherit;
ptr+nonotify local_ptr<NEvisible=0>;
};GDprops_templ GDprops<cxx_name="GDXprops"> {
local_ptr+write;
method+notify_inst+notify_val upd_func = "GDprops_update";
method+notify_deinst del_func = "GDprops_delete";
};GDprops DefaultProps {
col = { GD_DEFAULT_RED, GD_DEFAULT_GREEN, GD_DEFAULT_BLUE };
hi1_col = { GD_DEFAULT_RED, GD_DEFAULT_GREEN, GD_DEFAULT_BLUE };
hi2_col = { GD_DEFAULT_RED, 0.0, 0.0 };
material = { GD_DEFAULT_AMBIENT, GD_DEFAULT_DIFFUSE,
GD_DEFAULT_SPECULAR, GD_DEFAULT_SPEC_EXP };
spec_col = { GD_DEFAULT_RED, GD_DEFAULT_GREEN, GD_DEFAULT_BLUE };
trans = GD_DEFAULT_TRANS;
draw_mode = GD_DEFAULT_DRAW_MODE;
line_width = GD_DEFAULT_LINE_WIDTH;
line_style = GD_DEFAULT_LINE_STYLE;
line_aa = GD_DEFAULT_LINE_AA;
dir_pt_size = GD_DEFAULT_DIR_PT_SIZE;
subdiv = GD_DEFAULT_SUBDIV;
jitter = GD_DEFAULT_JITTER;
cull = GD_DEFAULT_CULL;
voxel_interp = GD_DEFAULT_VOX_INTERP;
ray_algo = GD_DEFAULT_RAY_ALGO;
ray_norm = GD_DEFAULT_RAY_NORM;
fat_ray = GD_DEFAULT_FAT_RAY;
sfp_absorb = GD_DEFAULT_SFP_ABSORB;
sfp_emit = GD_DEFAULT_SFP_EMIT;
font = GD_DEFAULT_FONT;
inherit = 1;
};Description
These templates define the Graphics Display Kit properties. GDprops_templ defines the elements that cause the properties methods to execute. GDprops defines an instanceable version without default values. DefaultProps defines an instanceable version with default values.
Input
Parameters
This parameter controls the primary color for a primitive, in terms of RGB. This color is used when no node data or cell data is supplied.
These parameters control the colors for a primitive, in terms of RGB, when rendering lines and/or points in addition to a surface.
The lines are rendered in the vertex color, if any, or the primary color. The points are rendered in the hi1 color.
Ambient light reflectance controls the proportion of the available ambient light that the object reflects. Ambient light is non-directional, affecting all parts of all surfaces equally.Diffuse light reflectance controls the proportion of the available non-ambient light that the object reflects equally in all directions. Non-ambient light emanates from the directional and point light sources.Specular highlights of a particular color and brightness are created when the direction of incoming light (from a directional or point light source) is "sufficiently close" to the viewing direction. The specular reflection coefficient determines the brightness of such highlights. The specular exponent determines what "sufficiently close" means. The greater the sharpness, the smaller (more focused) the size of the specular highlight.
This parameter controls the transparency value, between 0 and 1. As trans approaches 0, the object's surface gets more transparent. As trans approaches 1, the object's surface gets more opaque.
Use copy mode. This means that the object is drawn over the background. Anything under the object must be rerendered when line is moved.
Use xor mode. This means that the object is drawn by performing, at each point, an xor operation on the background color. You typically use this for interactive objects, line drawing.
This parameter controls the anti-aliasing of lines. 0 disables anti-aliasing; 1 enables anti-aliasing. This option is supported in the OpenGL and XGL renderers.
This parameter controls the length of the normal lines rendered in Directed Points mode, but can also affect the length and radius of tubes, cones, and arrows in special modes within the OpenGL renderer.
This parameter controls the number of units that the object is offset. A positive value moves the object forward jitter units in the camera. A negative value moves the object backward jitter units in the camera. Offsetting an object is useful when multiple objects are rendered at the same depth. Note that when an object is locked, its coordinates are not transformed, thus they are not jittered.
The parameter controls the volume rendering interpolation method; that is, how voxel values are mapped to rays or pixels.
The parameter controls how data or spatial values are mapped to the ray and how the ray values are mapped to the final color for the pixel.
At each step along the ray, the interpolated value is composited with the current value using standard alpha blending equations.
The ray maintains a distance measure and the maximum value. The distance is updated only when a new maximum value is found.
The ray ranges are normalized to the depth of the current view. This depth is the maximum extent of the data volume projected onto the viewing direction.
The ray maintains a distance measure and the maximum value. The distance is updated only when a new maximum value is found.
This parameter enables a super-sampling method that traces a single ray through a 4x4 block of pixels. The resulting image is faster to render, but of lower resolution.
This parameter controls the absorption of the exciting radiation when the ray algorithm is GD_ALGO_SFP.
This parameter controls the emmittance of fluorescence radiation in the direction of the observer when the ray algorithm is GD_ALGO_SFP.
Output Port
Example
Libraries.Graphics_Display.Objects.DataObject
File
See also related modules
![]() |
![]() |
![]() |
![]() |