formZ SDK | 5.0 API Reference | Project | Modeling | Selection (Pick)

# fz_model_pick_find

Description

Searches for a particular item in the pick buffer. This function can be used to test, whether a group, object, or any other topological entity of an object is picked. The search may be limited to just a portion of the pick buffer by specifying the optional start_indx and end_indx arguments. If they are set to NULL, the entire pick buffer is searched. To check, whether a particular topological level of an object is picked, the kind argument must be used and the object, and entity index must be passed in. For example, to check whether the 3rd point of a given object is picked the api call would look like this :
pindx = 2;
(windex,NULL,NULL, FZ_MODEL_PICK_PNT,NULL,obj,pindx,&pick_indx);
If the point is found, pick_indx will be returned with the index of the entry in the pick buffer. If the point is not picked, pick_indx will be -1.
Although the grup and obj arguments are optional, one of them should always be passed in. If the kind argument is passed as NULL and obj is passed in, the first picked topological entity of the given object is found.

Plugin Prototype

fzrt_error_td fz_model_pick_find(

fzrt_int | windex,
fzrt_int * | start_indx,
fzrt_int * | end_indx,
fz_model_pick_enum * | kind,
fz_grup_ptr * | grup,
fz_objt_ptr * | obj,
fzrt_int * | indx,
fzrt_int * | pick_indx )

Parameters

windex [Input]

project window index

start_indx [Input, Optional]

start search indx\

Range: start_indx >= 0

Range: start_indx < ()

end_indx [Input, Optional]

end search index

Range: end_indx >= 0

Range: end_indx < ()

kind [Input, Optional]

kind of entity to search for

grup [Input, Optional]

grup picked

obj [Input, Optional]

object picked

indx [Input, Optional]

index of object part picked

pick_indx [Result]

index of first found item in pick buffer.

Range: pick_indx >= 0

Range: pick_indx < ()

Returns

Error codes

Availability

5.0.0.0

Function Set

fz_model_fset

Defined in

fz_objt_api.h