mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
is_true_threads() on win32 case
This commit is contained in:
parent
2b855884a0
commit
c489fbeefc
@ -40,6 +40,7 @@ typedef void ContextFunction(struct ThreadContext *from_context, void *);
|
||||
typedef void ThreadFunction(void *);
|
||||
|
||||
extern const int needs_stack_prealloc;
|
||||
extern const int is_os_threads;
|
||||
|
||||
/* Call this to fill in the appropriate values in context. If
|
||||
needs_stack_prealloc (above) is true, the stack must already have
|
||||
|
@ -17,6 +17,7 @@
|
||||
which is necessary if setcontext() is not available. */
|
||||
|
||||
const int needs_stack_prealloc = 1;
|
||||
const int is_os_threads = 0;
|
||||
|
||||
#if defined(_M_IX86) || defined(__i386__)
|
||||
/* Maybe we can implement our own setjmp/longjmp in assembly code.
|
||||
|
@ -24,6 +24,7 @@
|
||||
#endif
|
||||
|
||||
const int needs_stack_prealloc = 1;
|
||||
const int is_os_threads = 0;
|
||||
|
||||
struct ThreadContext {
|
||||
ucontext_t _ucontext;
|
||||
|
@ -26,6 +26,7 @@
|
||||
|
||||
/* The Windows implementation doesn't use the stack pointer. */
|
||||
const int needs_stack_prealloc = 0;
|
||||
const int is_os_threads = 1;
|
||||
|
||||
static struct ThreadContext *current_context = NULL;
|
||||
|
||||
|
@ -69,7 +69,7 @@ is_threading_supported() {
|
||||
////////////////////////////////////////////////////////////////////
|
||||
INLINE bool ThreadSimpleImpl::
|
||||
is_true_threads() {
|
||||
return false;
|
||||
return (is_os_threads != 0);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
Loading…
x
Reference in New Issue
Block a user