Commit graph

9892 commits

Author SHA1 Message Date
Sam Lantinga
73ca40b566 Fixed WinRT build after changing the header guard preprocessor symbol 2017-08-28 01:59:53 -07:00
Sam Lantinga
0722e9415a Fixed build when Wayland is dynamically loaded 2017-08-28 01:42:18 -07:00
Sam Lantinga
23e5cb1879 Fixed analyzer warning "Call to 'calloc' has an allocation size of 0 bytes" 2017-08-28 00:54:02 -07:00
Sam Lantinga
66ee57e4ca Fixed redefinition of typedef warnings and errors on BSD 2017-08-28 00:51:14 -07:00
Sam Lantinga
56dd9f257b Fixed mingw Windows build, since SDL_vulkan_internal.h includes windows.h 2017-08-28 00:43:14 -07:00
Sam Lantinga
f1e9abdefb Renaming of guard header names to quiet -Wreserved-id-macro 2017-08-28 00:22:23 -07:00
Sam Lantinga
15cb6b4932 Be clear that disabling Vulkan surface support disables the entire SDL Vulkan integration 2017-08-28 00:11:38 -07:00
Sam Lantinga
0d34d231b9 Fixed Android build with Vulkan support 2017-08-27 23:53:09 -07:00
Sam Lantinga
6cd49b2c22 Fixed code style for new Vulkan API functions 2017-08-27 23:39:55 -07:00
Sam Lantinga
9e1b2d83f3 Fixed Android ABI check to match vulkan/vk_platform.h 2017-08-27 23:39:38 -07:00
Sam Lantinga
8da41824a7 Make the androidbuildlibs.sh script executable 2017-08-27 23:31:31 -07:00
Sam Lantinga
eb767f3e1b Fixed typedef redefinition errors when including both SDL_vulkan.h and vulkan.h
You should always include vulkan/vulkan.h first, then include SDL_vulkan.h
2017-08-27 23:13:15 -07:00
Sam Lantinga
288267a066 Fixed Windows warning 2017-08-27 22:36:03 -07:00
Sam Lantinga
20d3636821 Fixed Android build 2017-08-27 22:34:15 -07:00
Sam Lantinga
06cb4018c7 Don't define Vulkan types if vulkan.h has already been included 2017-08-27 22:27:45 -07:00
Sam Lantinga
24c5115ef6 Added Vulkan support to the Visual Studio 2010 solution 2017-08-27 22:20:17 -07:00
Sam Lantinga
ca8b7d1e11 Don't need the Vulkan SDK for the Visual Studio 2008 project anymore 2017-08-27 21:55:31 -07:00
Sam Lantinga
22149e8112 Fixed crash at shutdown if the window couldn't be created 2017-08-27 21:05:18 -07:00
Sam Lantinga
4989a01939 We use the SDL Vulkan headers 2017-08-27 20:41:48 -07:00
Sam Lantinga
27e5963b8f Added the new Vulkan API functions to exported functions 2017-08-27 20:41:29 -07:00
Ryan C. Gordon
f4b87c2bcb vulkan: Include a copy of vulkan.h and vk_platform.h.
Now we can provide Vulkan support in the build even if the build box doesn't
have a Vulkan SDK, since we dynamically link to the library anyhow.

--HG--
extra : rebase_source : f4972489a15b276f65ea65c077172fdcbbe3420a
2017-08-27 23:25:12 -04:00
Sam Lantinga
3db6496688 Use SDL_Vulkan_GetDrawableSize() instead of SDL_GL_GetDrawableSize() 2017-08-27 19:32:08 -07:00
Ryan C. Gordon
a566435db1 vulkan: Initial Vulkan support!
This work was done by Jacob Lifshay and Mark Callow; I'm just merging it
into revision control.

--HG--
extra : rebase_source : cb3bb332146125366b5242c0d7444f44638733d9
extra : amend_source : c72ebb6d3a92efc3fdd085ce3b6d4b1d7f573cc9
2017-08-27 22:15:57 -04:00
Sam Lantinga
0ff15ac41b Fixed bug 3710 - SDL_OpenAudio(desired, obtained) doesn't update desired's size when obtained is NULL
David Ludwig

I've created a new set of patches.  I am happy to create more, if it would help.

One version only copies 'size'.

A second version copies both 'size' and 'silence'.  When looking over the documentation for SDL_OpenAudio in SDL_audio.h, it mentioned that both 'size' and 'silence' were things that SDL_OpenAudio would calculate.

Regarding *both* patches, I did notice that SDL 1.2 appears to have always modified desired's size and silence fields.  The SDL wiki, at https://wiki.libsdl.org/SDL_OpenAudio#Remarks , does note:
2017-08-27 19:10:30 -07:00
Sam Lantinga
b964d759ca Fixed bug 3724 - Allow Angle Static Link
Carlos

We would like to add a switch (define) that allows us to compile Angle statically with SDL. That is, getting rid of the OpenGL DLL. Usually you need OpenGL to be loaded dynamically as DLL because implementation is provided by the system but no need with Angle.

Only 2 files need modification and it shouldn't affect current behaivor:
include/SDL_egl.h and src/video/SDL_egl.c, as in here

https://github.com/native-toolkit/sdl/pull/10/files

The flag name could be SDL_VIDEO_STATIC_ANGLE (instead of NATIVE_TOOLKIT_STATIC_ANGLE) as discussed here https://github.com/native-toolkit/sdl/pull/10

We have tested this with both Windows and UWP, using NME engine (https://github.com/haxenme/nme).

Releated issue: https://bugzilla.libsdl.org/show_bug.cgi?id=1820
2017-08-27 19:05:57 -07:00
Sam Lantinga
7f84fc46a4 Fixed bug 3740 - atexit() in test/testime.c 2017-08-27 19:00:03 -07:00
Sam Lantinga
1bf8d4ca37 SDL_dynapi.c: add missing SDLCALL to macros. 2017-08-27 18:53:30 -07:00
Sam Lantinga
af31e7aab5 Swapped conditional arguments for standard SDL readability 2017-08-27 18:52:43 -07:00
Sam Lantinga
279b03e2c4 SDL_dynapi.h: revert commit a6da0a386f68 in order to enable dynapi
[ optional ]
2017-08-27 18:49:36 -07:00
Sam Lantinga
c51aa7eba0 SDL_dynapi_procs.h: adjust SDL_CreateThread for os/2 2017-08-27 18:49:11 -07:00
Sam Lantinga
e667b081cd SDL_thread.h: fix os/2 defines (rev 11340:97cd834a843e was a missing patch) 2017-08-27 18:48:51 -07:00
Sam Lantinga
c29d430656 Fixed bug 2266 - please add notifications for clipboard updates on Android
Sylvain

Hi! here's a patch for that with two class loaded regarding API level.
Test both case : before API 11 and after.

I also remove now unused GetSystemServiceFromUIThread() and minor clean-up (haptic warning prototype).
2017-08-27 18:43:52 -07:00
Sam Lantinga
1a4bd233da Fixed bug 2265 - Voice to text feature on Android repeats some text via SDL_TEXTINPUT
Sylvain

Small patch for this issue. I tested it and it seems to work.

- it can send several backspaces (instead of only 1).
- it calls directly "sendKeyEvent()" instead of "super.sendKeyEvent()".
  otherwise, it would go through the android internals, calling again "onKey()".
  and then the "backspace" would arrive after the next "commitText()".
2017-08-27 18:36:54 -07:00
Sam Lantinga
80c0e01dbd Fixed bug 3774 - Cmake build fails for Android
sfalexrog

Android haptic code was not added to CMakeLists.txt, leading to build failures when targeting Android platform.

Attached patch adds Android haptic driver to source sets and adds configuration parameter to SDL_config.h.cmake.
2017-08-26 21:17:12 -07:00
Patrice Mandin
0b51b163ee Add support for GameSir G4s 2017-08-26 21:20:20 +02:00
Ryan C. Gordon
dd32ce4d69 windows: Attempt to make Visual Studio not hardcode a call to memset(). 2017-08-25 15:16:39 -04:00
Ryan C. Gordon
ae2ce839f8 x11: Patched to compile with DEBUG_XEVENTS defined. 2017-08-25 12:51:42 -04:00
Ryan C. Gordon
e1c35f01fb OS/2: fixed inverted logic bug (thanks, Ozkan!). 2017-08-25 12:27:18 -04:00
Ryan C. Gordon
abe59c0808 OS/2: proper fix for dynapi (thanks, Ozkan!). 2017-08-25 11:31:12 -04:00
Ethan Lee
6fb747472a Fix KHR_no_error support 2017-08-24 22:57:42 -04:00
Ryan C. Gordon
b82bd0bd37 opengl: add support for GL_KHR_no_error.
This is completely untested!

Fixes Bugzilla #3721.
2017-08-24 21:30:53 -04:00
Ryan C. Gordon
28e9e6c28f dynapi: fill in OS/2 loading code (thanks, Ozkan!).
Partially fixes Bugzilla #3765.
2017-08-22 15:50:39 -04:00
Brandon Schaefer
d4564ef4f5 x11: Move screen_w/h inside the only ifdef they are referenced in to avoid compiler warnings 2017-08-21 23:44:46 -07:00
Brandon Schaefer
0e04e04c4d kmsdrm: Remove moved file 2017-08-21 17:22:00 -07:00
Brandon Schaefer
1b70bac91f kmsdrm: Cleanup unused headers, rename SDL_kmsdrmevents_c.h -> SDL_kmsdrmevents.h
--HG--
rename : src/video/kmsdrm/SDL_kmsdrmevents_c.h => src/video/kmsdrm/SDL_kmsdrmevents.h
2017-08-21 17:20:50 -07:00
Sam Lantinga
897ce9c889 Fixed bug 3768 - provide a quick copysign() solution for watcom
Ozkan Sezer

The following patch provides a quick copysign solution for Watcom/x86
2017-08-21 16:30:24 -07:00
Sam Lantinga
6a65551e8d SDL_thread.h: add missing os/2 defines.
(essentially replicates the windows case || SDL1.2 case.)
2017-08-21 13:01:22 -07:00
Sam Lantinga
4c41e57f57 SDL_dynapi.h: disable dynapi for os/2. 2017-08-21 13:00:58 -07:00
Sam Lantinga
fd5eb6d1f0 SDL_cpuinfo.c: add os/2 support to SDL_GetCPUCount() and SDL_GetSystemRAM(). 2017-08-21 13:00:40 -07:00
Sam Lantinga
1e2f295236 Fixed bug 3761 - Windows non-MinGW cmake build defines HAVE_WCSLCPY and HAVE_WCSLCAT
Tom Seddon

0f0ad62237 (git head at the time of writing); Visual Studio 2015, toolset v140, Platform 10.0.14393.0, building for x64

Windows non-MinGW cmake build sets defines implying wcslcpy and wcslcat are available, but Windows doesn't have these functions.

Ryan C. Gordon

That's weird, these are the exact two functions that Emscripten incorrectly believed it had until we upgraded the buildbot's emsdk install.

Not sure what's up with this, but it's possibly not a MingW-specific thing!
2017-08-21 11:25:04 -07:00