![]() |
![]() |
![]() |
![]() |
GDpick_process
Synopsis
define a module to process the pick information attached to the object
group GDpick_obj_notify_templ {
group pick_info {
int npicked;
};
};group GDpick_process_notify_templ {
GDpick_obj_notify_templ+IPort2 &obj_in<NEcolor0=0xff0000>;
method+notify_val upd_func = "GDpick_process_update";
};GDpick_process_notify_templ GDpick_process_templ {
int use_pick_data;
group &field_id {
int+opt nspace;
int+opt nnode_data;
Data_Array+opt node_data[nnode_data];
};
float &coord_id[];
group &node_data_array_id[];
int+OPort2 vert_index;
Cell_Set &cell_set_id;
int &conn_id[];
int conn_index;
group &cell_data_array_id[];
int cell_index;
/* picked point for ease of use. */
float+OPort2+nres point[1][field_id.nspace] => coord_id[vert_index];
/* node data values array and picked value for ease of use. */
int nnode_data = 0;
prim+OPort2+nres values_array[] => field_id.node_data[nnode_data].values;
prim+OPort2+nres value[] => values_array[vert_index];
};GDpick_process_templ GDpick_process;
Description
These templates define a module that processes the Graphic Display Kit pick information.GDpick_process is connected to any GDobject that is part of the hierarchy of objects attached to a view. Whenever a pick takes place, the module runs. If a pick did not occur on the object or any of the object's children, the module returns immediately. Otherwise, the pick information attached to the object that is picked is interrogated and the output information in this group is written.This module: only outputs when a pick in the hierarchy it is attached to occurs converts the pick information and pick data that is several levels down into a more useful form can provide a mapping from the input field to the source field from which that field was generated if the module provided node or cell pick data
Input
GDpick_obj_notify_templ. The input object to check for pick on. This template requires the input connection to have a subobject of type GDpick_info. This template also restricts execution of the module to when the pick information changes.
Parameters
This parameter enables/disables the usage of pick node or cell data if it exists: 0 disables usage; 1 enables usage. Some modules provide pick data that can be used to map the pick on the field back to the source field from which it is created.
The OM object id of the array of node data in the picked field. Note that the id of each entry in the array needs to be retrieved.
The OM object id of the array of cell data in the picked field. Note that the id of each entry in the array needs to be retrieved.
Example
File
See also related modules
![]() |
![]() |
![]() |
![]() |