Tao.Glfw SDK Documentation

Glfw.glfwCreateThread Method 

The function creates a new thread, which executes within the same address space as the calling process. The thread entry point is specified with the fun argument.

[Visual Basic]
Public Shared Function glfwCreateThread( _
   ByVal fun As GLFWthreadfun, _
   ByVal arg As IntPtr _
) As Integer
[C#]
public static int glfwCreateThread(
   GLFWthreadfun fun,
   IntPtr arg
);

Parameters

fun
A pointer to a function that acts as the entry point for the new thread.
arg
An arbitrary argument for the thread. arg will be passed as the argument to the thread function pointed to by fun. For instance, arg can point to data that is to be processed by the thread.

Return Value

The function returns a thread identification number if the thread was created successfully. This number is always positive. If the function fails, a negative number is returned.

Remarks

Once the thread function fun returns, the thread dies.

Even if the function returns a positive thread ID, indicating that the thread was created successfully, the thread may be unable to execute, for instance if the thread start address is not a valid thread entry point.

See Also

Glfw Class | Tao.Glfw Namespace