From c2a2445897af17adb56a32dcf111312763a575d4 Mon Sep 17 00:00:00 2001 From: Toni Uhlig Date: Mon, 2 Jul 2018 01:06:39 +0200 Subject: initial commit Signed-off-by: Toni Uhlig --- .../CSFML-2.1/doc/html/Thread_8h.htm | 212 +++++++++++++++++++++ 1 file changed, 212 insertions(+) create mode 100755 libghack/CSFML-2.1-windows-64bits/CSFML-2.1/doc/html/Thread_8h.htm (limited to 'libghack/CSFML-2.1-windows-64bits/CSFML-2.1/doc/html/Thread_8h.htm') diff --git a/libghack/CSFML-2.1-windows-64bits/CSFML-2.1/doc/html/Thread_8h.htm b/libghack/CSFML-2.1-windows-64bits/CSFML-2.1/doc/html/Thread_8h.htm new file mode 100755 index 0000000..530f357 --- /dev/null +++ b/libghack/CSFML-2.1-windows-64bits/CSFML-2.1/doc/html/Thread_8h.htm @@ -0,0 +1,212 @@ + + + + CSFML - C binding of the Simple and Fast Multimedia Library + + + + + + + +
+ +
+
Thread.h File Reference
+
+
+
#include <SFML/System/Export.h>
+#include <SFML/System/Types.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + + + + +

+Functions

CSFML_SYSTEM_API sfThreadsfThread_create (void(*function)(void *), void *userData)
 Create a new thread from a function pointer.
 
CSFML_SYSTEM_API void sfThread_destroy (sfThread *thread)
 Destroy a thread.
 
CSFML_SYSTEM_API void sfThread_launch (sfThread *thread)
 Run a thread.
 
CSFML_SYSTEM_API void sfThread_wait (sfThread *thread)
 Wait until a thread finishes.
 
CSFML_SYSTEM_API void sfThread_terminate (sfThread *thread)
 Terminate a thread.
 
+

Function Documentation

+ +
+
+ + + + + + + + + + + + + + + + + + +
CSFML_SYSTEM_API sfThread* sfThread_create (void(*)(void *) function,
void * userData 
)
+
+ +

Create a new thread from a function pointer.

+

Note: this does not run the thread, use sfThread_launch.

+
Parameters
+ + + +
functionEntry point of the thread
userDataCustom data to pass to the thread function
+
+
+
Returns
A new sfThread object
+ +
+
+ +
+
+ + + + + + + + +
CSFML_SYSTEM_API void sfThread_destroy (sfThreadthread)
+
+ +

Destroy a thread.

+

This function calls sfThread_wait, so that the internal thread cannot survive after the sfThread object is destroyed.

+
Parameters
+ + +
threadThread to destroy
+
+
+ +
+
+ +
+
+ + + + + + + + +
CSFML_SYSTEM_API void sfThread_launch (sfThreadthread)
+
+ +

Run a thread.

+

This function starts the entry point passed to the thread's constructor, and returns immediately. After this function returns, the thread's function is running in parallel to the calling code.

+
Parameters
+ + +
threadThread object
+
+
+ +
+
+ +
+
+ + + + + + + + +
CSFML_SYSTEM_API void sfThread_terminate (sfThreadthread)
+
+ +

Terminate a thread.

+

This function immediately stops the thread, without waiting for its function to finish. Terminating a thread with this function is not safe, and can lead to local variables not being destroyed on some operating systems. You should rather try to make the thread function terminate by itself.

+
Parameters
+ + +
threadThread object
+
+
+ +
+
+ +
+
+ + + + + + + + +
CSFML_SYSTEM_API void sfThread_wait (sfThreadthread)
+
+ +

Wait until a thread finishes.

+

This function will block the execution until the thread's function ends. Warning: if the thread function never ends, the calling thread will block forever. If this function is called from its owner thread, it returns without doing anything.

+
Parameters
+ + +
threadThread object
+
+
+ +
+
+
+ + + + -- cgit v1.2.3