imaqSetWindowThreadPolicy
Usage
int imaqSetWindowThreadPolicy(WindowThreadPolicy policy);
Purpose
Determines the thread in which NI Vision creates windows. By default, NI Vision uses IMAQ_CALLING_THREAD. This policy creates windows in the thread that makes the first display function call for a given window number. If that thread does not process messages, set the window thread policy to IMAQ_SEPARATE_THREAD. Using this policy, NI Vision creates windows in a separate thread and processes messages for the windows automatically.
Parameters
Name
|
Type
|
Description
|
---|---|---|
policy | WindowThreadPolicy | The thread policy. |
Return Value
Type |
Description |
---|---|
int | On success, this function returns a non-zero value. On failure, this function returns 0. To get extended error information, call imaqGetLastError(). |