Initializes the neig filter for an input.
GSErrCode ACAPI_Interface (
APIIo_InitNeigFilterID,
API_NeigFilter* neigFilter,
API_InitNeigFilterID initNeigFilterID
);
Parameters
- neigFilter
- [in] The neig filter.
- initNeigFilterID
-
[in] Type of the filter initialization. The possible values:
-
APIInitNeigFilter_FullFilter all neig types
APIInitNeigFilter_EmptyFilter nothing
APIInitNeigFilter_OnFilter line type neigs only
APIInitNeigFilter_NodeFilter node type neigs only
-
Return Values
NoError- The function has completed with success.
APIERR_BADPARSneigFilteris nullptr orinitNeigFilterIDis not a valid API_InitNeigFilterID value
For other common API errors see the API Errors document.
Remarks
This function is used to initialize the neig filter for an input process. Use neig filtering if you want to control the default behavior of the cursor sensitivity above a certain set of neig types. During a filtered input the cursor gravity works only for those neig types that are set in the neig filter, all the other neigs will be ignored.
To change certain filters in the API_NeigFilter structure use the the APIIo_SetNeigFilterID and APIIo_ClearNeigFilterID functions.
Note that the changeFilter field of the API_NeigFilter structure must be set to true, in order to have the neig filter effect.
Example
See APIIo_DrawRubberLineID for example of using input neig filters.
Requirements
- Version: API 2.1 or later
- Header: APIdefs_Interface.h
See Also
API_InitNeigFilterID, API_NeigFilter,
APIIo_SetNeigFilterID, APIIo_ClearNeigFilterID, APIIo_DrawRubberLineID, ACAPI_Interface, API Functions