Skip to content

Commit

Permalink
rebuilt SDL2 from latest 2.0.14 release.
Browse files Browse the repository at this point in the history
Windows dlls are the same as libsdl.org releases.  OSX framework is
cross-compiled in-house on a Linux setup for x86 and x86_64.

# Conflicts:
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_assert.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_atomic.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_audio.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_bits.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_blendmode.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_clipboard.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_android.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_iphoneos.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_macosx.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_minimal.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_os2.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_pandora.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_psp.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_windows.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_winrt.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_config_wiz.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_copying.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_cpuinfo.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_egl.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_endian.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_error.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_events.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_filesystem.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_gamecontroller.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_gesture.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_haptic.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_hints.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_joystick.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_keyboard.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_keycode.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_loadso.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_log.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_main.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_messagebox.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_metal.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_mouse.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_mutex.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_name.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_opengl.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_opengles.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_opengles2.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_pixels.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_platform.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_power.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_quit.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_rect.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_render.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_revision.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_rwops.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_scancode.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_sensor.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_shape.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_stdinc.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_surface.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_system.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_syswm.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_thread.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_timer.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_touch.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_types.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_version.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_video.h
#	MacOSX/SDL2.framework/Versions/A/Headers/SDL_vulkan.h
#	MacOSX/SDL2.framework/Versions/A/Headers/begin_code.h
#	MacOSX/SDL2.framework/Versions/A/Headers/close_code.h
#	MacOSX/SDL2.framework/Versions/A/Resources/Info.plist
#	MacOSX/SDL2.framework/Versions/A/SDL2
#	Windows/SDL2/WhatsNew.txt
#	Windows/SDL2/bin/sdl2-config
#	Windows/SDL2/lib/SDL2.lib
#	Windows/SDL2/lib64/SDL2.lib
#	Windows/SDL2/watcom/SDL2.def
#	Windows/SDL2/watcom/SDL2.exp
#	Windows/SDL2/watcom/SDL2.lib
  • Loading branch information
sezero authored and Novum committed Jan 11, 2021
1 parent bf4d43b commit 7ec2ccb
Show file tree
Hide file tree
Showing 83 changed files with 1,350 additions and 235 deletions.
2 changes: 1 addition & 1 deletion Windows/SDL2/COPYING.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>

This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
137 changes: 137 additions & 0 deletions Windows/SDL2/WhatsNew.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,143 @@

This is a list of major changes in SDL's version history.

---------------------------------------------------------------------------
2.0.14:
---------------------------------------------------------------------------
General:
* Added support for PS5 DualSense and Xbox Series X controllers to the HIDAPI controller driver
* Added game controller button constants for paddles and new buttons
* Added game controller functions to get additional information:
* SDL_GameControllerGetSerial()
* SDL_GameControllerHasAxis()
* SDL_GameControllerHasButton()
* SDL_GameControllerGetNumTouchpads()
* SDL_GameControllerGetNumTouchpadFingers()
* SDL_GameControllerGetTouchpadFinger()
* SDL_GameControllerHasSensor()
* SDL_GameControllerSetSensorEnabled()
* SDL_GameControllerIsSensorEnabled()
* SDL_GameControllerGetSensorData()
* SDL_GameControllerRumbleTriggers()
* SDL_GameControllerHasLED()
* SDL_GameControllerSetLED()
* Added the hint SDL_HINT_JOYSTICK_HIDAPI_PS5 to control whether the HIDAPI driver for PS5 controllers should be used.
* Added joystick functions to get additional information:
* SDL_JoystickGetSerial()
* SDL_JoystickRumbleTriggers()
* SDL_JoystickHasLED()
* SDL_JoystickSetLED()
* Added an API to allow the application to create virtual joysticks:
* SDL_JoystickAttachVirtual()
* SDL_JoystickDetachVirtual()
* SDL_JoystickIsVirtual()
* SDL_JoystickSetVirtualAxis()
* SDL_JoystickSetVirtualButton()
* SDL_JoystickSetVirtualHat()
* Added SDL_LockSensors() and SDL_UnlockSensors() to guarantee exclusive access to the sensor list
* Added SDL_HAPTIC_STEERING_AXIS to play an effect on the steering wheel
* Added the hint SDL_HINT_MOUSE_RELATIVE_SCALING to control whether relative motion is scaled by the screen DPI or renderer logical size
* The default value for SDL_HINT_VIDEO_MINIMIZE_ON_FOCUS_LOSS is now false for better compatibility with modern window managers
* Added SDL_GetPreferredLocales() to get the application's current locale setting
* Added the hint SDL_HINT_PREFERRED_LOCALES to override your application's default locale setting
* Added SDL_OpenURL() to open a URL in the system's default browser
* Added SDL_HasSurfaceRLE() to tell whether a surface is currently using RLE encoding
* Added SDL_SIMDRealloc() to reallocate memory obtained from SDL_SIMDAlloc()
* Added SDL_GetErrorMsg() to get the last error in a thread-safe way
* Added SDL_crc32(), SDL_wcscasecmp(), SDL_wcsncasecmp(), SDL_trunc(), SDL_truncf()
* Added clearer names for RGB pixel formats, e.g. SDL_PIXELFORMAT_XRGB8888, SDL_PIXELFORMAT_XBGR8888, etc.

Windows:
* Added the RAWINPUT controller driver to support more than 4 Xbox controllers simultaneously
* Added the hint SDL_HINT_JOYSTICK_RAWINPUT to control whether the RAWINPUT driver should be used
* Added the hint SDL_HINT_JOYSTICK_HIDAPI_CORRELATE_XINPUT to control whether XInput and WGI should be used to for complete controller functionality with the RAWINPUT driver.

macOS:
* Added the SDL_WINDOW_METAL flag to specify that a window should be created with a Metal view
* Added SDL_Metal_GetLayer() to get the CAMetalLayer backing a Metal view
* Added SDL_Metal_GetDrawableSize() to get the size of a window's drawable, in pixels

Linux:
* Added the hint SDL_HINT_AUDIO_DEVICE_APP_NAME to specify the name that shows up in PulseAudio for your application
* Added the hint SDL_HINT_AUDIO_DEVICE_STREAM_NAME to specify the name that shows up in PulseAudio associated with your audio stream
* Added the hint SDL_HINT_LINUX_JOYSTICK_DEADZONES to control whether HID defined dead zones should be respected on Linux
* Added the hint SDL_HINT_THREAD_PRIORITY_POLICY to specify the thread scheduler policy
* Added the hint SDL_HINT_THREAD_FORCE_REALTIME_TIME_CRITICAL to allow time critical threads to use a realtime scheduling policy

Android:
* Added SDL_AndroidRequestPermission() to request a specific system permission
* Added the hint SDL_HINT_ANDROID_BLOCK_ON_PAUSE_PAUSEAUDIO to control whether audio will pause when the application goes intot he background

OS/2:
* Added support for OS/2, see docs/README-os2.md for details

Emscripten (running in a web browser):
* Added the hint SDL_HINT_EMSCRIPTEN_ASYNCIFY to control whether SDL should call emscripten_sleep internally


---------------------------------------------------------------------------
2.0.12:
---------------------------------------------------------------------------

General:
* Added SDL_GetTextureScaleMode() and SDL_SetTextureScaleMode() to get and set the scaling mode used for a texture
* Added SDL_LockTextureToSurface(), similar to SDL_LockTexture() but the locked area is exposed as a SDL surface.
* Added new blend mode, SDL_BLENDMODE_MUL, which does a modulate and blend operation
* Added the hint SDL_HINT_DISPLAY_USABLE_BOUNDS to override the results of SDL_GetDisplayUsableBounds() for display index 0.
* Added the window underneath the finger to the SDL_TouchFingerEvent
* Added SDL_GameControllerTypeForIndex(), SDL_GameControllerGetType() to return the type of a game controller (Xbox 360, Xbox One, PS3, PS4, or Nintendo Switch Pro)
* Added the hint SDL_HINT_GAMECONTROLLERTYPE to override the automatic game controller type detection
* Added SDL_JoystickFromPlayerIndex() and SDL_GameControllerFromPlayerIndex() to get the device associated with a player index
* Added SDL_JoystickSetPlayerIndex() and SDL_GameControllerSetPlayerIndex() to set the player index associated with a device
* Added the hint SDL_HINT_GAMECONTROLLER_USE_BUTTON_LABELS to specify whether Nintendo Switch Pro controllers should use the buttons as labeled or swapped to match positional layout. The default is to use the buttons as labeled.
* Added support for Nintendo GameCube controllers to the HIDAPI driver, and a hint SDL_HINT_JOYSTICK_HIDAPI_GAMECUBE to control whether this is used.
* Improved support for Xbox 360 and Xbox One controllers when using the HIDAPI driver
* Added support for many game controllers, including:
* 8BitDo FC30 Pro
* 8BitDo M30 GamePad
* BDA PS4 Fightpad
* HORI Fighting Commander
* Hyperkin Duke
* Hyperkin X91
* MOGA XP5-A Plus
* NACON GC-400ES
* NVIDIA Controller v01.04
* PDP Versus Fighting Pad
* Razer Raion Fightpad for PS4
* Razer Serval
* Stadia Controller
* SteelSeries Stratus Duo
* Victrix Pro Fight Stick for PS4
* Xbox One Elite Series 2
* Fixed blocking game controller rumble calls when using the HIDAPI driver
* Added SDL_zeroa() macro to zero an array of elements
* Added SDL_HasARMSIMD() which returns true if the CPU has ARM SIMD (ARMv6+) features

Windows:
* Fixed crash when using the release SDL DLL with applications built with gcc
* Fixed performance regression in event handling introduced in 2.0.10
* Added support for SDL_SetThreadPriority() for UWP applications

Linux:
* Added the hint SDL_HINT_VIDEO_X11_WINDOW_VISUALID to specify the visual chosen for new X11 windows
* Added the hint SDL_HINT_VIDEO_X11_FORCE_EGL to specify whether X11 should use GLX or EGL by default

iOS / tvOS / macOS:
* Added SDL_Metal_CreateView() and SDL_Metal_DestroyView() to create CAMetalLayer-backed NSView/UIView and attach it to the specified window.

iOS/ tvOS:
* Added support for Bluetooth Steam Controllers as game controllers

tvOS:
* Fixed support for surround sound on Apple TV

Android:
* Added SDL_GetAndroidSDKVersion() to return the API level of the current device
* Added support for audio capture using OpenSL-ES
* Added support for Bluetooth Steam Controllers as game controllers
* Fixed rare crashes when the app goes into the background or terminates


---------------------------------------------------------------------------
2.0.10:
---------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/bin/sdl2-config
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ while test $# -gt 0; do
lib_suffix=$optarg
;;
--version)
echo 2.0.10
echo 2.0.14
;;
--cflags)
echo -I${prefix}/include -Dmain=SDL_main
Expand Down
4 changes: 3 additions & 1 deletion Windows/SDL2/include/SDL.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down Expand Up @@ -59,6 +59,8 @@
#include "SDL_timer.h"
#include "SDL_version.h"
#include "SDL_video.h"
#include "SDL_locale.h"
#include "SDL_misc.h"

#include "begin_code.h"
/* Set up for C function definitions, even when using C++ */
Expand Down
4 changes: 3 additions & 1 deletion Windows/SDL2/include/SDL_assert.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down Expand Up @@ -53,6 +53,8 @@ assert can have unique static variables associated with it.
#define SDL_TriggerBreakpoint() __debugbreak()
#elif ( (!defined(__NACL__)) && ((defined(__GNUC__) || defined(__clang__)) && (defined(__i386__) || defined(__x86_64__))) )
#define SDL_TriggerBreakpoint() __asm__ __volatile__ ( "int $3\n\t" )
#elif ( defined(__APPLE__) && defined(__arm64__) ) /* this might work on other ARM targets, but this is a known quantity... */
#define SDL_TriggerBreakpoint() __asm__ __volatile__ ( "brk #22\n\t" )
#elif defined(__386__) && defined(__WATCOMC__)
#define SDL_TriggerBreakpoint() { _asm { int 0x03 } }
#elif defined(HAVE_SIGNAL_H) && !defined(__WATCOMC__)
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/include/SDL_atomic.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/include/SDL_audio.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/include/SDL_bits.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
5 changes: 4 additions & 1 deletion Windows/SDL2/include/SDL_blendmode.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down Expand Up @@ -50,6 +50,9 @@ typedef enum
SDL_BLENDMODE_MOD = 0x00000004, /**< color modulate
dstRGB = srcRGB * dstRGB
dstA = dstA */
SDL_BLENDMODE_MUL = 0x00000008, /**< color multiply
dstRGB = (srcRGB * dstRGB) + (dstRGB * (1-srcA))
dstA = (srcA * dstA) + (dstA * (1-srcA)) */
SDL_BLENDMODE_INVALID = 0x7FFFFFFF

/* Additional custom blend modes can be returned by SDL_ComposeCustomBlendMode() */
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/include/SDL_clipboard.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/include/SDL_config.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
9 changes: 6 additions & 3 deletions Windows/SDL2/include/SDL_config_android.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down Expand Up @@ -121,6 +121,8 @@
#define HAVE_SQRTF 1
#define HAVE_TAN 1
#define HAVE_TANF 1
#define HAVE_TRUNC 1
#define HAVE_TRUNCF 1
#define HAVE_SIGACTION 1
#define HAVE_SETJMP 1
#define HAVE_NANOSLEEP 1
Expand All @@ -136,8 +138,9 @@

/* Enable various input drivers */
#define SDL_JOYSTICK_ANDROID 1
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_HAPTIC_ANDROID 1
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_JOYSTICK_VIRTUAL 1
#define SDL_HAPTIC_ANDROID 1

/* Enable sensor driver */
#define SDL_SENSOR_ANDROID 1
Expand Down
21 changes: 11 additions & 10 deletions Windows/SDL2/include/SDL_config_iphoneos.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down Expand Up @@ -122,6 +122,8 @@
#define HAVE_SQRTF 1
#define HAVE_TAN 1
#define HAVE_TANF 1
#define HAVE_TRUNC 1
#define HAVE_TRUNCF 1
#define HAVE_SIGACTION 1
#define HAVE_SETJMP 1
#define HAVE_NANOSLEEP 1
Expand All @@ -136,9 +138,11 @@
/* Enable the stub haptic driver (src/haptic/dummy/\*.c) */
#define SDL_HAPTIC_DUMMY 1

/* Enable MFi joystick support */
#define SDL_JOYSTICK_MFI 1
/* Enable joystick support */
/* Only enable HIDAPI support if you want to support Steam Controllers on iOS and tvOS */
/*#define SDL_JOYSTICK_HIDAPI 1*/
#define SDL_JOYSTICK_MFI 1
#define SDL_JOYSTICK_VIRTUAL 1

#ifdef __TVOS__
#define SDL_SENSOR_DUMMY 1
Expand Down Expand Up @@ -167,8 +171,10 @@
#define SDL_VIDEO_RENDER_OGL_ES 1
#define SDL_VIDEO_RENDER_OGL_ES2 1

/* Metal supported on 64-bit devices running iOS 8.0 and tvOS 9.0 and newer */
#if !TARGET_OS_SIMULATOR && !TARGET_CPU_ARM && ((__IPHONE_OS_VERSION_MIN_REQUIRED >= 80000) || (__TV_OS_VERSION_MIN_REQUIRED >= 90000))
/* Metal supported on 64-bit devices running iOS 8.0 and tvOS 9.0 and newer
Also supported in simulator from iOS 13.0 and tvOS 13.0
*/
#if (TARGET_OS_SIMULATOR && ((__IPHONE_OS_VERSION_MIN_REQUIRED >= 130000) || (__TV_OS_VERSION_MIN_REQUIRED >= 130000))) || (!TARGET_CPU_ARM && ((__IPHONE_OS_VERSION_MIN_REQUIRED >= 80000) || (__TV_OS_VERSION_MIN_REQUIRED >= 90000)))
#define SDL_PLATFORM_SUPPORTS_METAL 1
#else
#define SDL_PLATFORM_SUPPORTS_METAL 0
Expand All @@ -195,11 +201,6 @@
/* enable iOS extended launch screen */
#define SDL_IPHONE_LAUNCHSCREEN 1

/* Set max recognized G-force from accelerometer
See src/joystick/uikit/SDL_sysjoystick.m for notes on why this is needed
*/
#define SDL_IPHONE_MAX_GFORCE 5.0

/* enable filesystem support */
#define SDL_FILESYSTEM_COCOA 1

Expand Down
14 changes: 11 additions & 3 deletions Windows/SDL2/include/SDL_config_macosx.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down Expand Up @@ -125,6 +125,8 @@
#define HAVE_SQRTF 1
#define HAVE_TAN 1
#define HAVE_TANF 1
#define HAVE_TRUNC 1
#define HAVE_TRUNCF 1
#define HAVE_SIGACTION 1
#define HAVE_SETJMP 1
#define HAVE_NANOSLEEP 1
Expand All @@ -139,10 +141,16 @@
#define SDL_AUDIO_DRIVER_DUMMY 1

/* Enable various input drivers */
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_JOYSTICK_IOKIT 1
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_JOYSTICK_VIRTUAL 1
#define SDL_HAPTIC_IOKIT 1

/* The MFI controller support requires ARC Objective C runtime */
#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1080 && !defined(__i386__)
#define SDL_JOYSTICK_MFI 1
#endif

/* Enable the dummy sensor driver */
#define SDL_SENSOR_DUMMY 1

Expand Down Expand Up @@ -195,7 +203,7 @@
#endif

/* Metal only supported on 64-bit architectures with 10.11+ */
#if TARGET_CPU_X86_64 && (MAC_OS_X_VERSION_MAX_ALLOWED >= 101100)
#if TARGET_RT_64_BIT && (MAC_OS_X_VERSION_MAX_ALLOWED >= 101100)
#define SDL_PLATFORM_SUPPORTS_METAL 1
#else
#define SDL_PLATFORM_SUPPORTS_METAL 0
Expand Down
2 changes: 1 addition & 1 deletion Windows/SDL2/include/SDL_config_minimal.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
Simple DirectMedia Layer
Copyright (C) 1997-2019 Sam Lantinga <[email protected]>
Copyright (C) 1997-2020 Sam Lantinga <[email protected]>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
Expand Down
Loading

0 comments on commit 7ec2ccb

Please sign in to comment.