calculate data values at a given location based upon a node map
group DVnmap {
Node_Data+Iparam &in {
nnodes+req;
};
NParam_Data+Iparam &nparam {
nnodes+req;
};
int+Iparam map_comp[];
Node_Data+Oparam out;
method+notify_val+notify_inst upd_nmap = "nmap";
};
DVnmap is an optimization utility. It uses a data structure called NParam_Data (aka "node map") to quickly calculate the data value at a point that is between two real nodes in a Node_Data using linear interpolation. The DViso and DVisotrace base modules output this NParam_Data node map.
This input is a reference to any object with Node_Data.
This input is a reference to an NParam_Data object, which is defined as follows in v/fld.v:
dgroup NParam_Data {
int nnodes;
int min_node[nnodes];
int max_node[nnodes];
float tpar[nnodes];
};
The DViso base module outputs this NParam_Data object.
This "node map" is a table that lists which pairs of nodes a sampling surface (such as an isosurface) crossed, and a parametric value from between 0.0 and 1.0 that tells where the where the surface crossed between the nodes. DVnmap, can take this nparam data and quickly calculate interpolated values for any component in the Node_Data.
The nparam structure output by DViso would look like this:
|
|
|
That is, between the node that is the nval = 1 index into the component's Data_Array and node that is the nval = 4 index, the pressure component isosurface mesh crosses at .5. Thus, when DVnmap is trying to figure out what numeric value to produce for a temperature at that location, it knows that all it has to do is use the temperature component's nval = 1 and nval = 4 index node values and calculate ((nval[4] - nval[1]) * tpar).
An integer array. Specifies which component will be mapped onto the isosurface (for example, map pressure value onto a density isosurface). Each array value is the number (from 0 up) of a component to map. For example:
(a, b, c, [e, f, g]) --> set map_comp = {0, 2} --> (a, b) in the output field
Note that this array is not explicitly dimensioned. It is a variable-length array that will have as many values as you assign to it with the = { n, n, n,...n} notation. The supplied AVS/Express modules that use DVnmap implicitly set the dimension to 1 by specifying map_comp = {0}, i.e., the user can specify any one component to map to the isosurface, and the default is the first (0th) component.
The output is a new Node_Data containing the computed values.
Libraries.Main.Mappers.isosurface
Libraries.Main.Mappers.slice