Ryan C. Gordon
0ba20a58d2
thread: make SDL_CreateThreadWithStackSize() a public API.
2018-10-11 16:40:01 -04:00
Sam Lantinga
a9072159b2
Updated copyright for 2018
2018-01-03 10:03:25 -08:00
Sam Lantinga
57143a1183
Fixed bug 3745 - specify SDLCALL as the calling convention for API callbacks
...
Patches contributed by Ozkan Sezer
2017-08-14 06:28:21 -07:00
Sam Lantinga
d77ab77a7a
Updated copyright for 2017
2017-01-01 18:33:28 -08:00
Philipp Wiesemann
a85facd73d
Fixed empty parameter list in signatures of internal functions.
2016-11-16 22:08:51 +01:00
Ryan C. Gordon
5006582bed
threads: Move SDL's own thread creation to a new internal API.
...
This allows us to set an explicit stack size (overriding the system default
and the global hint an app might have set), and remove all the macro salsa
for dealing with _beginthreadex and such, as internal threads always set those
to NULL anyhow.
I've taken some guesses on reasonable (and tiny!) stack sizes for our
internal threads, but some of these might turn out to be too small in
practice and need an increase. Most of them are simple functions, though.
2016-04-12 16:45:10 -04:00
Ryan C. Gordon
9e9853847d
threads: Handle SDL_HINT_THREAD_STACK_SIZE at top level, implement elsewhere.
2016-04-12 14:38:50 -04:00
Sam Lantinga
255c182471
Updated copyright to 2016
2016-01-02 10:10:34 -08:00
Sam Lantinga
78f2198e6c
Updated the copyright year to 2015
2015-05-26 06:27:46 -07:00
Sam Lantinga
3289794117
Fixed bug 2556 - add compilation flag -Wshadow
...
Sylvain
here's the full patch for Blit + RLE.
2014-06-25 00:43:10 -07:00
Sam Lantinga
dba255c1e5
Fixed bug 2374 - Update copyright for 2014...
...
Is it that time already??
2014-02-02 00:53:27 -08:00
Ryan C. Gordon
3dfc14ade2
Implemented the Dynamic API magic.
2013-12-09 16:03:18 -05:00
Ryan C. Gordon
03d5719413
Make internal SDL sources include SDL_internal.h instead of SDL_config.h
...
The new header will include SDL_config.h, but allows for other global stuff.
2013-11-24 23:56:17 -05:00
Ryan C. Gordon
a71d349f7c
Added SDL_DetachThread() API.
2013-11-14 00:52:39 -05:00
Sam Lantinga
0a093f4eea
Fixed bug 2076 - OpenGL doesn't work with --disable-threads
...
stepik-777
Thread local storage is used to store current window and current opengl context. OpenGL worked before this changeset: 7596 (45e5c263c096)
2013-09-05 07:15:26 -07:00
Sam Lantinga
e66f593a02
Fixed crash if SDL_GetThreadName() is passed a NULL thread.
2013-08-08 12:21:26 -07:00
Ryan C. Gordon
89f836cacf
One more compiler warning.
2013-07-20 19:59:31 -04:00
Ryan C. Gordon
ee3cbb1fa6
Fixed some compiler warnings that Visual Studio reported.
2013-07-20 19:51:51 -04:00
Sam Lantinga
f5306d72d0
Added release/acquire memory barriers to the atomic API
...
* Added a destructor to clean up TLS memory at thread shutdown
* Refactored the TLS code to have platform independent code and a small platform dependent core with a fallback to generic code if platform dependent functions fail.
* Fixed recursion issues with SDL_GetErrBuf()
2013-07-10 18:31:17 -07:00
Sam Lantinga
9c0dea8e15
Implemented an API for thread-local storage: SDL_TLSCreate(), SDL_TLSSet(), SDL_TLSGet()
2013-07-10 02:32:04 -07:00
Sam Lantinga
0d9b661db8
File style cleanup for the SDL 2.0 release
2013-05-18 14:17:52 -07:00
Sam Lantinga
2952d9bf48
Changed the name of SDL_mutexP() SDL_mutexV()
2013-03-07 20:12:40 -08:00
Sam Lantinga
019c60c1e8
Happy New Year!
2013-02-15 08:47:44 -08:00
Sam Lantinga
b3d60cfcbb
Removed executable bit from source files
2012-09-27 14:35:28 -07:00
Sam Lantinga
e256711bb9
Happy New Year!
2011-12-31 09:28:07 -05:00
Sam Lantinga
6371c44a9e
Lots of fixes importing SDL source wholesale into a new iOS project
2011-10-31 05:56:58 -04:00
Ryan C. Gordon
2ef51927fe
1.3 API CHANGE: Add support for naming threads.
2011-10-02 00:29:16 -04:00
Sam Lantinga
6196aa221e
SDL 1.3 is now under the zlib license.
2011-04-08 13:03:26 -07:00
Sam Lantinga
73247db7d8
The API sets the priority for the current thread, not an arbitrary thread.
...
Implemented thread priority as the 'nice' value on Linux. High priority threads require root permissions (you shouldn't give your game root permissions though!)
2011-03-25 12:44:06 -07:00
Sam Lantinga
eeb5f362e4
Implemented SDL_SetThreadPriority()
2011-03-25 10:47:49 -07:00
Sam Lantinga
3d078dceac
Fixed compiler warning
2011-03-06 21:15:46 -08:00
Sam Lantinga
a2cdcf5486
Happy 2011! :)
2011-02-11 22:37:15 -08:00
Sam Lantinga
b90f3fea9c
Mostly cleaned up warnings with -Wmissing-prototypes
2010-06-26 08:56:48 -07:00
Sam Lantinga
b8da79e726
SDL_KillThread() is no longer supported - it was always dangerous! :)
2010-05-24 22:56:36 -07:00
Sam Lantinga
7052036491
Fixed bug #926
...
Updated copyright to LGPL version 2.1 and year 2010
2010-01-24 21:10:53 +00:00
Sam Lantinga
75e75ae0c3
Fixed bug #741
...
The thread ID is an unsigned long so it can hold pthread_t so people can do naughty things with it.
I'm going to be adding additional useful thread API functions, but this should prevent crashes in people's existing code on 64-bit architectures.
2009-12-16 04:48:11 +00:00
Sam Lantinga
1764e75bcc
Possibly fixed bug #601 , definitely fixed a potential issue with threads
...
stopping and starting in rapid succession.
2009-09-23 06:37:27 +00:00
Sam Lantinga
befb0f7f42
Updated copyright date
2008-12-08 00:27:32 +00:00
Sam Lantinga
825b0b08f1
Fixed Bugzilla bug #205
...
Removed SDL_KillThread() from the API, as it isn't safe on many platforms.
2008-11-24 00:18:42 +00:00
Sam Lantinga
6bc598ea61
SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
2006-07-10 21:04:37 +00:00
Sam Lantinga
1195dd8133
Fixed bug #215
...
The current SVN trunk is missing the SDLCALL specifier at numerous locations.
It has to be added for all (possibly user provided) callbacks.
I stumbled over this while creating a makefile for the OpenWatcom compiler for
Win32.
2006-05-07 03:40:06 +00:00
Sam Lantinga
63695e2f76
Fixed some ultra-pedantic gcc warnings
2006-03-24 06:10:24 +00:00
Sam Lantinga
870a0b4ab6
Fixed bug #150
...
memory leak in SDL_thread.c
2006-03-12 01:18:29 +00:00
Sam Lantinga
0fa63c4bba
Enabled libc support on Win32, so we don't break binary compatibility in 1.2
2006-03-06 07:42:36 +00:00
Sam Lantinga
190b425364
Use consistent identifiers for the various platforms we support.
...
Make sure every source file includes SDL_config.h, so the proper system
headers are chosen.
2006-02-21 08:46:50 +00:00
Sam Lantinga
769424426d
More header massaging... works great on Windows. ;-)
2006-02-10 06:48:43 +00:00
Sam Lantinga
1e037cc218
Removed uses of stdlib.h and string.h
2006-02-07 09:29:18 +00:00
Sam Lantinga
02cc6c0f11
Use SDL_ prefixed versions of C library functions.
...
FIXME:
Change #include <stdlib.h> to #include "SDL_stdlib.h"
Change #include <string.h> to #include "SDL_string.h"
Make sure nothing else broke because of this...
2006-02-07 06:59:48 +00:00
Sam Lantinga
82bfaee73a
It's now possible to build SDL without any C runtime at all on Windows,
...
using Visual C++ 2005
2006-02-06 08:28:51 +00:00
Sam Lantinga
808a16717c
Updated copyright information and removed rcs id lines (problematic in branch merges)
...
I batch edited these files, so please let me know if I've accidentally removed anybody's
credit here.
2006-02-01 06:32:25 +00:00