mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-06 11:28:15 +00:00
Compare commits
19 Commits
SDL2
...
release-2.
Author | SHA1 | Date | |
---|---|---|---|
![]() |
f17058b562 | ||
![]() |
2879f2aeba | ||
![]() |
45c7d838d4 | ||
![]() |
79373c5a5c | ||
![]() |
f4080637c4 | ||
![]() |
92057e683e | ||
![]() |
5edd6846db | ||
![]() |
859cb13ef8 | ||
![]() |
b97d2ed6c5 | ||
![]() |
c76a31341c | ||
![]() |
00731eb011 | ||
![]() |
bf70a37606 | ||
![]() |
da1bddd27c | ||
![]() |
9925ee52d7 | ||
![]() |
66620bd108 | ||
![]() |
72823dd0cd | ||
![]() |
479e972e56 | ||
![]() |
3bf150e900 | ||
![]() |
a8dd7a10fa |
@@ -12,7 +12,7 @@ LOCAL_MODULE := SDL2
|
|||||||
|
|
||||||
LOCAL_C_INCLUDES := $(LOCAL_PATH)/include
|
LOCAL_C_INCLUDES := $(LOCAL_PATH)/include
|
||||||
|
|
||||||
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_C_INCLUDES)/include
|
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_C_INCLUDES)
|
||||||
|
|
||||||
LOCAL_SRC_FILES := \
|
LOCAL_SRC_FILES := \
|
||||||
$(subst $(LOCAL_PATH)/,, \
|
$(subst $(LOCAL_PATH)/,, \
|
||||||
|
@@ -86,7 +86,7 @@ endif()
|
|||||||
# See docs/release_checklist.md
|
# See docs/release_checklist.md
|
||||||
set(SDL_MAJOR_VERSION 2)
|
set(SDL_MAJOR_VERSION 2)
|
||||||
set(SDL_MINOR_VERSION 26)
|
set(SDL_MINOR_VERSION 26)
|
||||||
set(SDL_MICRO_VERSION 0)
|
set(SDL_MICRO_VERSION 1)
|
||||||
set(SDL_VERSION "${SDL_MAJOR_VERSION}.${SDL_MINOR_VERSION}.${SDL_MICRO_VERSION}")
|
set(SDL_VERSION "${SDL_MAJOR_VERSION}.${SDL_MINOR_VERSION}.${SDL_MICRO_VERSION}")
|
||||||
|
|
||||||
# Set defaults preventing destination file conflicts
|
# Set defaults preventing destination file conflicts
|
||||||
@@ -3241,11 +3241,10 @@ if(NOT WINDOWS_STORE AND NOT SDL2_DISABLE_SDL2MAIN)
|
|||||||
target_link_libraries(SDL2main PRIVATE shell32)
|
target_link_libraries(SDL2main PRIVATE shell32)
|
||||||
endif()
|
endif()
|
||||||
if(MINGW OR CYGWIN)
|
if(MINGW OR CYGWIN)
|
||||||
cmake_minimum_required(VERSION 3.13)
|
|
||||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||||
target_link_options(SDL2main PUBLIC "$<$<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>:-Wl,--undefined=_WinMain@16>")
|
target_link_libraries(SDL2main PUBLIC "$<$<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>:-Wl,--undefined=_WinMain@16>")
|
||||||
else()
|
else()
|
||||||
target_link_options(SDL2main PUBLIC "$<$<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>:-Wl,--undefined=WinMain>")
|
target_link_libraries(SDL2main PUBLIC "$<$<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>:-Wl,--undefined=WinMain>")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
if (NOT ANDROID)
|
if (NOT ANDROID)
|
||||||
|
@@ -15,7 +15,7 @@
|
|||||||
LIBNAME = SDL2
|
LIBNAME = SDL2
|
||||||
MAJOR_VERSION = 2
|
MAJOR_VERSION = 2
|
||||||
MINOR_VERSION = 26
|
MINOR_VERSION = 26
|
||||||
MICRO_VERSION = 0
|
MICRO_VERSION = 1
|
||||||
VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(MICRO_VERSION)
|
VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(MICRO_VERSION)
|
||||||
DESCRIPTION = Simple DirectMedia Layer 2
|
DESCRIPTION = Simple DirectMedia Layer 2
|
||||||
|
|
||||||
|
@@ -6,7 +6,7 @@
|
|||||||
LIBNAME = SDL2
|
LIBNAME = SDL2
|
||||||
MAJOR_VERSION = 2
|
MAJOR_VERSION = 2
|
||||||
MINOR_VERSION = 26
|
MINOR_VERSION = 26
|
||||||
MICRO_VERSION = 0
|
MICRO_VERSION = 1
|
||||||
VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(MICRO_VERSION)
|
VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(MICRO_VERSION)
|
||||||
|
|
||||||
LIBHOME = .
|
LIBHOME = .
|
||||||
|
@@ -19,10 +19,10 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>FMWK</string>
|
<string>FMWK</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>2.26.0</string>
|
<string>2.26.1</string>
|
||||||
<key>CFBundleSignature</key>
|
<key>CFBundleSignature</key>
|
||||||
<string>SDLX</string>
|
<string>SDLX</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>2.26.0</string>
|
<string>2.26.1</string>
|
||||||
</dict>
|
</dict>
|
||||||
</plist>
|
</plist>
|
||||||
|
@@ -9529,7 +9529,7 @@
|
|||||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||||
DEPLOYMENT_POSTPROCESSING = YES;
|
DEPLOYMENT_POSTPROCESSING = YES;
|
||||||
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
||||||
DYLIB_CURRENT_VERSION = 2601.0.0;
|
DYLIB_CURRENT_VERSION = 2601.1.0;
|
||||||
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||||
GCC_ALTIVEC_EXTENSIONS = YES;
|
GCC_ALTIVEC_EXTENSIONS = YES;
|
||||||
@@ -9614,7 +9614,7 @@
|
|||||||
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
||||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||||
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
||||||
DYLIB_CURRENT_VERSION = 2601.0.0;
|
DYLIB_CURRENT_VERSION = 2601.1.0;
|
||||||
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||||
ENABLE_TESTABILITY = YES;
|
ENABLE_TESTABILITY = YES;
|
||||||
@@ -9863,7 +9863,7 @@
|
|||||||
DEFINES_MODULE = YES;
|
DEFINES_MODULE = YES;
|
||||||
DEVELOPMENT_TEAM = "";
|
DEVELOPMENT_TEAM = "";
|
||||||
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
||||||
DYLIB_CURRENT_VERSION = 2601.0.0;
|
DYLIB_CURRENT_VERSION = 2601.1.0;
|
||||||
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
GCC_DYNAMIC_NO_PIC = NO;
|
GCC_DYNAMIC_NO_PIC = NO;
|
||||||
@@ -9915,7 +9915,7 @@
|
|||||||
DEFINES_MODULE = YES;
|
DEFINES_MODULE = YES;
|
||||||
DEVELOPMENT_TEAM = "";
|
DEVELOPMENT_TEAM = "";
|
||||||
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
DYLIB_COMPATIBILITY_VERSION = 2601.0.0;
|
||||||
DYLIB_CURRENT_VERSION = 2601.0.0;
|
DYLIB_CURRENT_VERSION = 2601.1.0;
|
||||||
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
||||||
ENABLE_NS_ASSERTIONS = NO;
|
ENABLE_NS_ASSERTIONS = NO;
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
|
@@ -61,7 +61,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
|||||||
private static final String TAG = "SDL";
|
private static final String TAG = "SDL";
|
||||||
private static final int SDL_MAJOR_VERSION = 2;
|
private static final int SDL_MAJOR_VERSION = 2;
|
||||||
private static final int SDL_MINOR_VERSION = 26;
|
private static final int SDL_MINOR_VERSION = 26;
|
||||||
private static final int SDL_MICRO_VERSION = 0;
|
private static final int SDL_MICRO_VERSION = 1;
|
||||||
/*
|
/*
|
||||||
// Display InputType.SOURCE/CLASS of events and devices
|
// Display InputType.SOURCE/CLASS of events and devices
|
||||||
//
|
//
|
||||||
|
@@ -400,6 +400,7 @@ endmacro()
|
|||||||
# - SDL_X11_SHARED opt
|
# - SDL_X11_SHARED opt
|
||||||
# - HAVE_SDL_LOADSO opt
|
# - HAVE_SDL_LOADSO opt
|
||||||
macro(CheckX11)
|
macro(CheckX11)
|
||||||
|
cmake_push_check_state(RESET)
|
||||||
if(SDL_X11)
|
if(SDL_X11)
|
||||||
foreach(_LIB X11 Xext Xcursor Xi Xfixes Xrandr Xrender Xss)
|
foreach(_LIB X11 Xext Xcursor Xi Xfixes Xrandr Xrender Xss)
|
||||||
FindLibraryAndSONAME("${_LIB}")
|
FindLibraryAndSONAME("${_LIB}")
|
||||||
@@ -422,6 +423,7 @@ macro(CheckX11)
|
|||||||
|
|
||||||
if(X_INCLUDEDIR)
|
if(X_INCLUDEDIR)
|
||||||
list(APPEND EXTRA_CFLAGS "-I${X_INCLUDEDIR}")
|
list(APPEND EXTRA_CFLAGS "-I${X_INCLUDEDIR}")
|
||||||
|
list(APPEND CMAKE_REQUIRED_INCLUDES ${X_INCLUDEDIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
find_file(HAVE_XCURSOR_H NAMES "X11/Xcursor/Xcursor.h" HINTS "${X_INCLUDEDIR}")
|
find_file(HAVE_XCURSOR_H NAMES "X11/Xcursor/Xcursor.h" HINTS "${X_INCLUDEDIR}")
|
||||||
@@ -597,6 +599,7 @@ macro(CheckX11)
|
|||||||
# Prevent Mesa from including X11 headers
|
# Prevent Mesa from including X11 headers
|
||||||
list(APPEND EXTRA_CFLAGS "-DMESA_EGL_NO_X11_HEADERS -DEGL_NO_X11")
|
list(APPEND EXTRA_CFLAGS "-DMESA_EGL_NO_X11_HEADERS -DEGL_NO_X11")
|
||||||
endif()
|
endif()
|
||||||
|
cmake_pop_check_state()
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
macro(WaylandProtocolGen _SCANNER _CODE_MODE _XML _PROTL)
|
macro(WaylandProtocolGen _SCANNER _CODE_MODE _XML _PROTL)
|
||||||
|
2
configure
vendored
2
configure
vendored
@@ -3454,7 +3454,7 @@ orig_CFLAGS="$CFLAGS"
|
|||||||
# See docs/release_checklist.md
|
# See docs/release_checklist.md
|
||||||
SDL_MAJOR_VERSION=2
|
SDL_MAJOR_VERSION=2
|
||||||
SDL_MINOR_VERSION=26
|
SDL_MINOR_VERSION=26
|
||||||
SDL_MICRO_VERSION=0
|
SDL_MICRO_VERSION=1
|
||||||
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION
|
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION
|
||||||
|
|
||||||
SDL_BINARY_AGE=`expr $SDL_MINOR_VERSION \* 100 + $SDL_MICRO_VERSION`
|
SDL_BINARY_AGE=`expr $SDL_MINOR_VERSION \* 100 + $SDL_MICRO_VERSION`
|
||||||
|
@@ -13,7 +13,7 @@ dnl Set various version strings - taken gratefully from the GTk sources
|
|||||||
# See docs/release_checklist.md
|
# See docs/release_checklist.md
|
||||||
SDL_MAJOR_VERSION=2
|
SDL_MAJOR_VERSION=2
|
||||||
SDL_MINOR_VERSION=26
|
SDL_MINOR_VERSION=26
|
||||||
SDL_MICRO_VERSION=0
|
SDL_MICRO_VERSION=1
|
||||||
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION
|
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION
|
||||||
|
|
||||||
SDL_BINARY_AGE=`expr $SDL_MINOR_VERSION \* 100 + $SDL_MICRO_VERSION`
|
SDL_BINARY_AGE=`expr $SDL_MINOR_VERSION \* 100 + $SDL_MICRO_VERSION`
|
||||||
|
@@ -59,7 +59,7 @@ typedef struct SDL_version
|
|||||||
*/
|
*/
|
||||||
#define SDL_MAJOR_VERSION 2
|
#define SDL_MAJOR_VERSION 2
|
||||||
#define SDL_MINOR_VERSION 26
|
#define SDL_MINOR_VERSION 26
|
||||||
#define SDL_PATCHLEVEL 0
|
#define SDL_PATCHLEVEL 1
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Macro to determine SDL version program was compiled against.
|
* Macro to determine SDL version program was compiled against.
|
||||||
|
10
src/SDL.c
10
src/SDL.c
@@ -519,13 +519,21 @@ SDL_Quit(void)
|
|||||||
void
|
void
|
||||||
SDL_GetVersion(SDL_version * ver)
|
SDL_GetVersion(SDL_version * ver)
|
||||||
{
|
{
|
||||||
|
static SDL_bool check_hint = SDL_TRUE;
|
||||||
|
static SDL_bool legacy_version = SDL_FALSE;
|
||||||
|
|
||||||
if (!ver) {
|
if (!ver) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
SDL_VERSION(ver);
|
SDL_VERSION(ver);
|
||||||
|
|
||||||
if (SDL_GetHintBoolean("SDL_LEGACY_VERSION", SDL_FALSE)) {
|
if (check_hint) {
|
||||||
|
check_hint = SDL_FALSE;
|
||||||
|
legacy_version = SDL_GetHintBoolean("SDL_LEGACY_VERSION", SDL_FALSE);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (legacy_version) {
|
||||||
/* Prior to SDL 2.24.0, the patch version was incremented with every release */
|
/* Prior to SDL 2.24.0, the patch version was incremented with every release */
|
||||||
ver->patch = ver->minor;
|
ver->patch = ver->minor;
|
||||||
ver->minor = 0;
|
ver->minor = 0;
|
||||||
|
@@ -202,7 +202,6 @@ SDL_ResampleAudio(const int chans, const int inrate, const int outrate,
|
|||||||
typedef float ResampleFloatType;
|
typedef float ResampleFloatType;
|
||||||
|
|
||||||
const ResampleFloatType finrate = (ResampleFloatType) inrate;
|
const ResampleFloatType finrate = (ResampleFloatType) inrate;
|
||||||
const ResampleFloatType outtimeincr = ((ResampleFloatType) 1.0f) / ((ResampleFloatType) outrate);
|
|
||||||
const ResampleFloatType ratio = ((float) outrate) / ((float) inrate);
|
const ResampleFloatType ratio = ((float) outrate) / ((float) inrate);
|
||||||
const int paddinglen = ResamplerPadding(inrate, outrate);
|
const int paddinglen = ResamplerPadding(inrate, outrate);
|
||||||
const int framelen = chans * (int)sizeof (float);
|
const int framelen = chans * (int)sizeof (float);
|
||||||
@@ -247,7 +246,7 @@ SDL_ResampleAudio(const int chans, const int inrate, const int outrate,
|
|||||||
*(dst++) = outsample;
|
*(dst++) = outsample;
|
||||||
}
|
}
|
||||||
|
|
||||||
outtime = outtimeincr * i;
|
outtime = ((ResampleFloatType) i) / ((ResampleFloatType) outrate);
|
||||||
}
|
}
|
||||||
|
|
||||||
return outframes * chans * sizeof (float);
|
return outframes * chans * sizeof (float);
|
||||||
|
@@ -654,8 +654,6 @@ static const char *s_ControllerMappings [] =
|
|||||||
"030000006d0400001ec2000020200000,Logitech F510 Gamepad (XInput),a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,",
|
"030000006d0400001ec2000020200000,Logitech F510 Gamepad (XInput),a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,",
|
||||||
"030000006d04000019c2000011010000,Logitech F710 Gamepad (DInput),a:b1,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b4,leftstick:b10,lefttrigger:b6,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b11,righttrigger:b7,rightx:a2,righty:a3,start:b9,x:b0,y:b3,", /* Guide button doesn't seem to be sent in DInput mode. */
|
"030000006d04000019c2000011010000,Logitech F710 Gamepad (DInput),a:b1,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b4,leftstick:b10,lefttrigger:b6,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b11,righttrigger:b7,rightx:a2,righty:a3,start:b9,x:b0,y:b3,", /* Guide button doesn't seem to be sent in DInput mode. */
|
||||||
"030000006d0400001fc2000005030000,Logitech F710 Gamepad (XInput),a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,",
|
"030000006d0400001fc2000005030000,Logitech F710 Gamepad (XInput),a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,",
|
||||||
"030000006d0400004fc2000011010000,Logitech G29 Racing Wheel,a:b0,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b24,leftshoulder:b5,leftstick:b11,lefttrigger:b7,rightshoulder:b4,rightstick:b10,righttrigger:b6,start:b9,x:b1,y:b3,",
|
|
||||||
"030000006d04000060c2000010010000,Logitech G29 Racing Wheel,a:b1,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b12,leftshoulder:b4,leftstick:b10,lefttrigger:b6,rightshoulder:b5,rightstick:b11,righttrigger:b7,start:b9,x:b0,y:b3,",
|
|
||||||
"030000006d04000018c2000010010000,Logitech RumblePad 2,a:b1,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b4,leftstick:b10,lefttrigger:b6,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b11,righttrigger:b7,rightx:a2,righty:a3,start:b9,x:b0,y:b3,",
|
"030000006d04000018c2000010010000,Logitech RumblePad 2,a:b1,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b4,leftstick:b10,lefttrigger:b6,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b11,righttrigger:b7,rightx:a2,righty:a3,start:b9,x:b0,y:b3,",
|
||||||
"030000006d04000011c2000010010000,Logitech WingMan Cordless RumblePad,a:b0,b:b1,back:b2,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b5,leftshoulder:b6,lefttrigger:b9,leftx:a0,lefty:a1,rightshoulder:b7,righttrigger:b10,rightx:a3,righty:a4,start:b8,x:b3,y:b4,",
|
"030000006d04000011c2000010010000,Logitech WingMan Cordless RumblePad,a:b0,b:b1,back:b2,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b5,leftshoulder:b6,lefttrigger:b9,leftx:a0,lefty:a1,rightshoulder:b7,righttrigger:b10,rightx:a3,righty:a4,start:b8,x:b3,y:b4,",
|
||||||
"03000000c62400002b89000011010000,MOGA XP5-A Plus,a:b0,b:b1,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b12,leftshoulder:b6,leftstick:b13,lefttrigger:a5,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:a4,rightx:a2,righty:a3,start:b11,x:b3,y:b4,",
|
"03000000c62400002b89000011010000,MOGA XP5-A Plus,a:b0,b:b1,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b12,leftshoulder:b6,leftstick:b13,lefttrigger:a5,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:a4,rightx:a2,righty:a3,start:b11,x:b3,y:b4,",
|
||||||
|
@@ -32,7 +32,7 @@ static const ControllerDescription_t arrControllers[] = {
|
|||||||
{ MAKE_CONTROLLER_ID( 0x0079, 0x1844 ), k_eControllerType_PS3Controller, NULL }, // From SDL
|
{ MAKE_CONTROLLER_ID( 0x0079, 0x1844 ), k_eControllerType_PS3Controller, NULL }, // From SDL
|
||||||
{ MAKE_CONTROLLER_ID( 0x044f, 0xb315 ), k_eControllerType_PS3Controller, NULL }, // Firestorm Dual Analog 3
|
{ MAKE_CONTROLLER_ID( 0x044f, 0xb315 ), k_eControllerType_PS3Controller, NULL }, // Firestorm Dual Analog 3
|
||||||
{ MAKE_CONTROLLER_ID( 0x044f, 0xd007 ), k_eControllerType_PS3Controller, NULL }, // Thrustmaster wireless 3-1
|
{ MAKE_CONTROLLER_ID( 0x044f, 0xd007 ), k_eControllerType_PS3Controller, NULL }, // Thrustmaster wireless 3-1
|
||||||
{ MAKE_CONTROLLER_ID( 0x046d, 0xc24f ), k_eControllerType_PS3Controller, NULL }, // Logitech G29 (PS3)
|
//{ MAKE_CONTROLLER_ID( 0x046d, 0xc24f ), k_eControllerType_PS3Controller, NULL }, // Logitech G29 (PS3)
|
||||||
{ MAKE_CONTROLLER_ID( 0x054c, 0x0268 ), k_eControllerType_PS3Controller, NULL }, // Sony PS3 Controller
|
{ MAKE_CONTROLLER_ID( 0x054c, 0x0268 ), k_eControllerType_PS3Controller, NULL }, // Sony PS3 Controller
|
||||||
{ MAKE_CONTROLLER_ID( 0x056e, 0x200f ), k_eControllerType_PS3Controller, NULL }, // From SDL
|
{ MAKE_CONTROLLER_ID( 0x056e, 0x200f ), k_eControllerType_PS3Controller, NULL }, // From SDL
|
||||||
{ MAKE_CONTROLLER_ID( 0x056e, 0x2013 ), k_eControllerType_PS3Controller, NULL }, // JC-U4113SBK
|
{ MAKE_CONTROLLER_ID( 0x056e, 0x2013 ), k_eControllerType_PS3Controller, NULL }, // JC-U4113SBK
|
||||||
@@ -87,7 +87,7 @@ static const ControllerDescription_t arrControllers[] = {
|
|||||||
{ MAKE_CONTROLLER_ID( 0x8888, 0x0308 ), k_eControllerType_PS3Controller, NULL }, // Sony PS3 Controller
|
{ MAKE_CONTROLLER_ID( 0x8888, 0x0308 ), k_eControllerType_PS3Controller, NULL }, // Sony PS3 Controller
|
||||||
|
|
||||||
{ MAKE_CONTROLLER_ID( 0x0079, 0x181b ), k_eControllerType_PS4Controller, NULL }, // Venom Arcade Stick - XXX:this may not work and may need to be called a ps3 controller
|
{ MAKE_CONTROLLER_ID( 0x0079, 0x181b ), k_eControllerType_PS4Controller, NULL }, // Venom Arcade Stick - XXX:this may not work and may need to be called a ps3 controller
|
||||||
{ MAKE_CONTROLLER_ID( 0x046d, 0xc260 ), k_eControllerType_PS4Controller, NULL }, // Logitech G29 (PS4)
|
//{ MAKE_CONTROLLER_ID( 0x046d, 0xc260 ), k_eControllerType_PS4Controller, NULL }, // Logitech G29 (PS4)
|
||||||
{ MAKE_CONTROLLER_ID( 0x054c, 0x05c4 ), k_eControllerType_PS4Controller, NULL }, // Sony PS4 Controller
|
{ MAKE_CONTROLLER_ID( 0x054c, 0x05c4 ), k_eControllerType_PS4Controller, NULL }, // Sony PS4 Controller
|
||||||
{ MAKE_CONTROLLER_ID( 0x054c, 0x05c5 ), k_eControllerType_PS4Controller, NULL }, // STRIKEPAD PS4 Grip Add-on
|
{ MAKE_CONTROLLER_ID( 0x054c, 0x05c5 ), k_eControllerType_PS4Controller, NULL }, // STRIKEPAD PS4 Grip Add-on
|
||||||
{ MAKE_CONTROLLER_ID( 0x054c, 0x09cc ), k_eControllerType_PS4Controller, NULL }, // Sony PS4 Slim Controller
|
{ MAKE_CONTROLLER_ID( 0x054c, 0x09cc ), k_eControllerType_PS4Controller, NULL }, // Sony PS4 Slim Controller
|
||||||
|
@@ -639,11 +639,16 @@ static int
|
|||||||
IOS_JoystickInit(void)
|
IOS_JoystickInit(void)
|
||||||
{
|
{
|
||||||
#if defined(__MACOSX__)
|
#if defined(__MACOSX__)
|
||||||
|
#if _SDL_HAS_BUILTIN(__builtin_available)
|
||||||
if (@available(macOS 10.16, *)) {
|
if (@available(macOS 10.16, *)) {
|
||||||
/* Continue with initialization on macOS 11+ */
|
/* Continue with initialization on macOS 11+ */
|
||||||
} else {
|
} else {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
/* No @available, must be an older macOS version */
|
||||||
|
return 0;
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@autoreleasepool {
|
@autoreleasepool {
|
||||||
@@ -951,6 +956,7 @@ IOS_MFIJoystickUpdate(SDL_Joystick *joystick)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (controller.extendedGamepad) {
|
if (controller.extendedGamepad) {
|
||||||
|
SDL_bool isstack;
|
||||||
GCExtendedGamepad *gamepad = controller.extendedGamepad;
|
GCExtendedGamepad *gamepad = controller.extendedGamepad;
|
||||||
|
|
||||||
/* Axis order matches the XInput Windows mappings. */
|
/* Axis order matches the XInput Windows mappings. */
|
||||||
@@ -964,9 +970,14 @@ IOS_MFIJoystickUpdate(SDL_Joystick *joystick)
|
|||||||
};
|
};
|
||||||
|
|
||||||
/* Button order matches the XInput Windows mappings. */
|
/* Button order matches the XInput Windows mappings. */
|
||||||
Uint8 buttons[joystick->nbuttons];
|
Uint8 *buttons = SDL_small_alloc(Uint8, joystick->nbuttons, &isstack);
|
||||||
int button_count = 0;
|
int button_count = 0;
|
||||||
|
|
||||||
|
if (buttons == NULL) {
|
||||||
|
SDL_OutOfMemory();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
/* These buttons are part of the original MFi spec */
|
/* These buttons are part of the original MFi spec */
|
||||||
buttons[button_count++] = gamepad.buttonA.isPressed;
|
buttons[button_count++] = gamepad.buttonA.isPressed;
|
||||||
buttons[button_count++] = gamepad.buttonB.isPressed;
|
buttons[button_count++] = gamepad.buttonB.isPressed;
|
||||||
@@ -1083,12 +1094,20 @@ IOS_MFIJoystickUpdate(SDL_Joystick *joystick)
|
|||||||
}
|
}
|
||||||
#endif /* ENABLE_MFI_SENSORS */
|
#endif /* ENABLE_MFI_SENSORS */
|
||||||
|
|
||||||
|
SDL_small_free(buttons, isstack);
|
||||||
} else if (controller.gamepad) {
|
} else if (controller.gamepad) {
|
||||||
|
SDL_bool isstack;
|
||||||
GCGamepad *gamepad = controller.gamepad;
|
GCGamepad *gamepad = controller.gamepad;
|
||||||
|
|
||||||
/* Button order matches the XInput Windows mappings. */
|
/* Button order matches the XInput Windows mappings. */
|
||||||
Uint8 buttons[joystick->nbuttons];
|
Uint8 *buttons = SDL_small_alloc(Uint8, joystick->nbuttons, &isstack);
|
||||||
int button_count = 0;
|
int button_count = 0;
|
||||||
|
|
||||||
|
if (buttons == NULL) {
|
||||||
|
SDL_OutOfMemory();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
buttons[button_count++] = gamepad.buttonA.isPressed;
|
buttons[button_count++] = gamepad.buttonA.isPressed;
|
||||||
buttons[button_count++] = gamepad.buttonB.isPressed;
|
buttons[button_count++] = gamepad.buttonB.isPressed;
|
||||||
buttons[button_count++] = gamepad.buttonX.isPressed;
|
buttons[button_count++] = gamepad.buttonX.isPressed;
|
||||||
@@ -1103,6 +1122,8 @@ IOS_MFIJoystickUpdate(SDL_Joystick *joystick)
|
|||||||
for (i = 0; i < button_count; i++) {
|
for (i = 0; i < button_count; i++) {
|
||||||
SDL_PrivateJoystickButton(joystick, i, buttons[i]);
|
SDL_PrivateJoystickButton(joystick, i, buttons[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SDL_small_free(buttons, isstack);
|
||||||
}
|
}
|
||||||
#if TARGET_OS_TV
|
#if TARGET_OS_TV
|
||||||
else if (controller.microGamepad) {
|
else if (controller.microGamepad) {
|
||||||
|
@@ -9,8 +9,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
|||||||
//
|
//
|
||||||
|
|
||||||
VS_VERSION_INFO VERSIONINFO
|
VS_VERSION_INFO VERSIONINFO
|
||||||
FILEVERSION 2,26,0,0
|
FILEVERSION 2,26,1,0
|
||||||
PRODUCTVERSION 2,26,0,0
|
PRODUCTVERSION 2,26,1,0
|
||||||
FILEFLAGSMASK 0x3fL
|
FILEFLAGSMASK 0x3fL
|
||||||
FILEFLAGS 0x0L
|
FILEFLAGS 0x0L
|
||||||
FILEOS 0x40004L
|
FILEOS 0x40004L
|
||||||
@@ -23,12 +23,12 @@ BEGIN
|
|||||||
BEGIN
|
BEGIN
|
||||||
VALUE "CompanyName", "\0"
|
VALUE "CompanyName", "\0"
|
||||||
VALUE "FileDescription", "SDL\0"
|
VALUE "FileDescription", "SDL\0"
|
||||||
VALUE "FileVersion", "2, 26, 0, 0\0"
|
VALUE "FileVersion", "2, 26, 1, 0\0"
|
||||||
VALUE "InternalName", "SDL\0"
|
VALUE "InternalName", "SDL\0"
|
||||||
VALUE "LegalCopyright", "Copyright (C) 2022 Sam Lantinga\0"
|
VALUE "LegalCopyright", "Copyright (C) 2022 Sam Lantinga\0"
|
||||||
VALUE "OriginalFilename", "SDL2.dll\0"
|
VALUE "OriginalFilename", "SDL2.dll\0"
|
||||||
VALUE "ProductName", "Simple DirectMedia Layer\0"
|
VALUE "ProductName", "Simple DirectMedia Layer\0"
|
||||||
VALUE "ProductVersion", "2, 26, 0, 0\0"
|
VALUE "ProductVersion", "2, 26, 1, 0\0"
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
BLOCK "VarFileInfo"
|
BLOCK "VarFileInfo"
|
||||||
|
@@ -1157,25 +1157,27 @@ GetRectDisplayIndex(int x, int y, int w, int h)
|
|||||||
center.x = x + w / 2;
|
center.x = x + w / 2;
|
||||||
center.y = y + h / 2;
|
center.y = y + h / 2;
|
||||||
|
|
||||||
for (i = 0; i < _this->num_displays; ++i) {
|
if (_this) {
|
||||||
SDL_Rect display_rect;
|
for (i = 0; i < _this->num_displays; ++i) {
|
||||||
SDL_GetDisplayBounds(i, &display_rect);
|
SDL_Rect display_rect;
|
||||||
|
SDL_GetDisplayBounds(i, &display_rect);
|
||||||
|
|
||||||
/* Check if the window is fully enclosed */
|
/* Check if the window is fully enclosed */
|
||||||
if (SDL_EnclosePoints(¢er, 1, &display_rect, NULL)) {
|
if (SDL_EnclosePoints(¢er, 1, &display_rect, NULL)) {
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Snap window center to the display rect */
|
/* Snap window center to the display rect */
|
||||||
closest_point_on_display = center;
|
closest_point_on_display = center;
|
||||||
SDL_GetClosestPointOnRect(&display_rect, &closest_point_on_display);
|
SDL_GetClosestPointOnRect(&display_rect, &closest_point_on_display);
|
||||||
|
|
||||||
delta.x = center.x - closest_point_on_display.x;
|
delta.x = center.x - closest_point_on_display.x;
|
||||||
delta.y = center.y - closest_point_on_display.y;
|
delta.y = center.y - closest_point_on_display.y;
|
||||||
dist = (delta.x*delta.x + delta.y*delta.y);
|
dist = (delta.x * delta.x + delta.y * delta.y);
|
||||||
if (dist < closest_dist) {
|
if (dist < closest_dist) {
|
||||||
closest = i;
|
closest = i;
|
||||||
closest_dist = dist;
|
closest_dist = dist;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -333,6 +333,7 @@ GetApplicationName(void)
|
|||||||
static bool
|
static bool
|
||||||
LoadMainMenuNibIfAvailable(void)
|
LoadMainMenuNibIfAvailable(void)
|
||||||
{
|
{
|
||||||
|
#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1080
|
||||||
NSDictionary *infoDict;
|
NSDictionary *infoDict;
|
||||||
NSString *mainNibFileName;
|
NSString *mainNibFileName;
|
||||||
bool success = false;
|
bool success = false;
|
||||||
@@ -350,6 +351,9 @@ LoadMainMenuNibIfAvailable(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return success;
|
return success;
|
||||||
|
#else
|
||||||
|
return false;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@@ -27,6 +27,7 @@
|
|||||||
|
|
||||||
#include "SDL_atomic.h"
|
#include "SDL_atomic.h"
|
||||||
#import <Cocoa/Cocoa.h>
|
#import <Cocoa/Cocoa.h>
|
||||||
|
#import <QuartzCore/CVDisplayLink.h>
|
||||||
|
|
||||||
/* We still support OpenGL as long as Apple offers it, deprecated or not, so disable deprecation warnings about it. */
|
/* We still support OpenGL as long as Apple offers it, deprecated or not, so disable deprecation warnings about it. */
|
||||||
#ifdef __clang__
|
#ifdef __clang__
|
||||||
@@ -58,6 +59,9 @@ struct SDL_GLDriverData
|
|||||||
- (SDL_Window*)window;
|
- (SDL_Window*)window;
|
||||||
- (void)explicitUpdate;
|
- (void)explicitUpdate;
|
||||||
- (void)dealloc;
|
- (void)dealloc;
|
||||||
|
|
||||||
|
@property (retain, nonatomic) NSOpenGLPixelFormat* openglPixelFormat; // macOS 10.10 has -[NSOpenGLContext pixelFormat] but this handles older OS releases.
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
/* OpenGL functions */
|
/* OpenGL functions */
|
||||||
|
@@ -44,6 +44,16 @@
|
|||||||
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* _Nullable is available starting Xcode 7 */
|
||||||
|
#ifdef __has_feature
|
||||||
|
#if __has_feature(nullability)
|
||||||
|
#define HAS_FEATURE_NULLABLE
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
#ifndef HAS_FEATURE_NULLABLE
|
||||||
|
#define _Nullable
|
||||||
|
#endif
|
||||||
|
|
||||||
static SDL_bool SDL_opengl_async_dispatch = SDL_FALSE;
|
static SDL_bool SDL_opengl_async_dispatch = SDL_FALSE;
|
||||||
|
|
||||||
static void SDLCALL
|
static void SDLCALL
|
||||||
@@ -76,6 +86,7 @@ DisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTimeStamp* now, const
|
|||||||
{
|
{
|
||||||
self = [super initWithFormat:format shareContext:share];
|
self = [super initWithFormat:format shareContext:share];
|
||||||
if (self) {
|
if (self) {
|
||||||
|
self.openglPixelFormat = format;
|
||||||
SDL_AtomicSet(&self->dirty, 0);
|
SDL_AtomicSet(&self->dirty, 0);
|
||||||
self->window = NULL;
|
self->window = NULL;
|
||||||
SDL_AtomicSet(&self->swapIntervalSetting, 0);
|
SDL_AtomicSet(&self->swapIntervalSetting, 0);
|
||||||
@@ -100,7 +111,7 @@ DisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTimeStamp* now, const
|
|||||||
- (void)movedToNewScreen
|
- (void)movedToNewScreen
|
||||||
{
|
{
|
||||||
if (self->displayLink) {
|
if (self->displayLink) {
|
||||||
CVDisplayLinkSetCurrentCGDisplayFromOpenGLContext(self->displayLink, [self CGLContextObj], [[self pixelFormat] CGLPixelFormatObj]);
|
CVDisplayLinkSetCurrentCGDisplayFromOpenGLContext(self->displayLink, [self CGLContextObj], [[self openglPixelFormat] CGLPixelFormatObj]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -26,6 +26,14 @@ extern "C" {
|
|||||||
typedef void CAMetalLayer;
|
typedef void CAMetalLayer;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define SDL_UNSAFE_UNRETAINED
|
||||||
|
#if defined(__OBJC__) && defined(__has_feature)
|
||||||
|
#if __has_feature(objc_arc)
|
||||||
|
#undef SDL_UNSAFE_UNRETAINED
|
||||||
|
#define SDL_UNSAFE_UNRETAINED __unsafe_unretained
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#define VK_EXT_METAL_SURFACE_SPEC_VERSION 1
|
#define VK_EXT_METAL_SURFACE_SPEC_VERSION 1
|
||||||
#define VK_EXT_METAL_SURFACE_EXTENSION_NAME "VK_EXT_metal_surface"
|
#define VK_EXT_METAL_SURFACE_EXTENSION_NAME "VK_EXT_metal_surface"
|
||||||
typedef VkFlags VkMetalSurfaceCreateFlagsEXT;
|
typedef VkFlags VkMetalSurfaceCreateFlagsEXT;
|
||||||
@@ -33,7 +41,7 @@ typedef struct VkMetalSurfaceCreateInfoEXT {
|
|||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
VkMetalSurfaceCreateFlagsEXT flags;
|
VkMetalSurfaceCreateFlagsEXT flags;
|
||||||
const CAMetalLayer* pLayer;
|
const CAMetalLayer SDL_UNSAFE_UNRETAINED *pLayer;
|
||||||
} VkMetalSurfaceCreateInfoEXT;
|
} VkMetalSurfaceCreateInfoEXT;
|
||||||
|
|
||||||
typedef VkResult (VKAPI_PTR *PFN_vkCreateMetalSurfaceEXT)(VkInstance instance, const VkMetalSurfaceCreateInfoEXT* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
|
typedef VkResult (VKAPI_PTR *PFN_vkCreateMetalSurfaceEXT)(VkInstance instance, const VkMetalSurfaceCreateInfoEXT* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
|
||||||
@@ -111,27 +119,27 @@ typedef struct VkExportMetalObjectsInfoEXT {
|
|||||||
typedef struct VkExportMetalDeviceInfoEXT {
|
typedef struct VkExportMetalDeviceInfoEXT {
|
||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
MTLDevice_id mtlDevice;
|
MTLDevice_id SDL_UNSAFE_UNRETAINED mtlDevice;
|
||||||
} VkExportMetalDeviceInfoEXT;
|
} VkExportMetalDeviceInfoEXT;
|
||||||
|
|
||||||
typedef struct VkExportMetalCommandQueueInfoEXT {
|
typedef struct VkExportMetalCommandQueueInfoEXT {
|
||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
VkQueue queue;
|
VkQueue queue;
|
||||||
MTLCommandQueue_id mtlCommandQueue;
|
MTLCommandQueue_id SDL_UNSAFE_UNRETAINED mtlCommandQueue;
|
||||||
} VkExportMetalCommandQueueInfoEXT;
|
} VkExportMetalCommandQueueInfoEXT;
|
||||||
|
|
||||||
typedef struct VkExportMetalBufferInfoEXT {
|
typedef struct VkExportMetalBufferInfoEXT {
|
||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
VkDeviceMemory memory;
|
VkDeviceMemory memory;
|
||||||
MTLBuffer_id mtlBuffer;
|
MTLBuffer_id SDL_UNSAFE_UNRETAINED mtlBuffer;
|
||||||
} VkExportMetalBufferInfoEXT;
|
} VkExportMetalBufferInfoEXT;
|
||||||
|
|
||||||
typedef struct VkImportMetalBufferInfoEXT {
|
typedef struct VkImportMetalBufferInfoEXT {
|
||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
MTLBuffer_id mtlBuffer;
|
MTLBuffer_id SDL_UNSAFE_UNRETAINED mtlBuffer;
|
||||||
} VkImportMetalBufferInfoEXT;
|
} VkImportMetalBufferInfoEXT;
|
||||||
|
|
||||||
typedef struct VkExportMetalTextureInfoEXT {
|
typedef struct VkExportMetalTextureInfoEXT {
|
||||||
@@ -141,14 +149,14 @@ typedef struct VkExportMetalTextureInfoEXT {
|
|||||||
VkImageView imageView;
|
VkImageView imageView;
|
||||||
VkBufferView bufferView;
|
VkBufferView bufferView;
|
||||||
VkImageAspectFlagBits plane;
|
VkImageAspectFlagBits plane;
|
||||||
MTLTexture_id mtlTexture;
|
MTLTexture_id SDL_UNSAFE_UNRETAINED mtlTexture;
|
||||||
} VkExportMetalTextureInfoEXT;
|
} VkExportMetalTextureInfoEXT;
|
||||||
|
|
||||||
typedef struct VkImportMetalTextureInfoEXT {
|
typedef struct VkImportMetalTextureInfoEXT {
|
||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
VkImageAspectFlagBits plane;
|
VkImageAspectFlagBits plane;
|
||||||
MTLTexture_id mtlTexture;
|
MTLTexture_id SDL_UNSAFE_UNRETAINED mtlTexture;
|
||||||
} VkImportMetalTextureInfoEXT;
|
} VkImportMetalTextureInfoEXT;
|
||||||
|
|
||||||
typedef struct VkExportMetalIOSurfaceInfoEXT {
|
typedef struct VkExportMetalIOSurfaceInfoEXT {
|
||||||
@@ -169,13 +177,13 @@ typedef struct VkExportMetalSharedEventInfoEXT {
|
|||||||
const void* pNext;
|
const void* pNext;
|
||||||
VkSemaphore semaphore;
|
VkSemaphore semaphore;
|
||||||
VkEvent event;
|
VkEvent event;
|
||||||
MTLSharedEvent_id mtlSharedEvent;
|
MTLSharedEvent_id SDL_UNSAFE_UNRETAINED mtlSharedEvent;
|
||||||
} VkExportMetalSharedEventInfoEXT;
|
} VkExportMetalSharedEventInfoEXT;
|
||||||
|
|
||||||
typedef struct VkImportMetalSharedEventInfoEXT {
|
typedef struct VkImportMetalSharedEventInfoEXT {
|
||||||
VkStructureType sType;
|
VkStructureType sType;
|
||||||
const void* pNext;
|
const void* pNext;
|
||||||
MTLSharedEvent_id mtlSharedEvent;
|
MTLSharedEvent_id SDL_UNSAFE_UNRETAINED mtlSharedEvent;
|
||||||
} VkImportMetalSharedEventInfoEXT;
|
} VkImportMetalSharedEventInfoEXT;
|
||||||
|
|
||||||
typedef void (VKAPI_PTR *PFN_vkExportMetalObjectsEXT)(VkDevice device, VkExportMetalObjectsInfoEXT* pMetalObjectsInfo);
|
typedef void (VKAPI_PTR *PFN_vkExportMetalObjectsEXT)(VkDevice device, VkExportMetalObjectsInfoEXT* pMetalObjectsInfo);
|
||||||
|
@@ -30,16 +30,7 @@
|
|||||||
#include <e32svr.h>
|
#include <e32svr.h>
|
||||||
#include <bitdev.h>
|
#include <bitdev.h>
|
||||||
#include <w32std.h>
|
#include <w32std.h>
|
||||||
|
#include "bitdraw.h" // CFbsDrawDevice
|
||||||
class CFbsDrawDevice : public CBase
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
public:
|
|
||||||
IMPORT_C static CFbsDrawDevice* NewScreenDeviceL(TScreenInfoV01 aInfo,TDisplayMode aDispMode);
|
|
||||||
public:
|
|
||||||
virtual void Update() {}
|
|
||||||
virtual void UpdateRegion(const TRect&) {}
|
|
||||||
};
|
|
||||||
|
|
||||||
#define _THIS SDL_VideoDevice *_this
|
#define _THIS SDL_VideoDevice *_this
|
||||||
|
|
||||||
|
@@ -166,6 +166,13 @@ void SDL_WAYLAND_UnloadSymbols(void);
|
|||||||
|
|
||||||
#else /* SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC */
|
#else /* SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC */
|
||||||
|
|
||||||
|
/*
|
||||||
|
* These must be included before libdecor.h, otherwise the libdecor header
|
||||||
|
* pulls in the system Wayland protocol headers instead of ours.
|
||||||
|
*/
|
||||||
|
#include "wayland-client-protocol.h"
|
||||||
|
#include "wayland-egl.h"
|
||||||
|
|
||||||
#ifdef HAVE_LIBDECOR_H
|
#ifdef HAVE_LIBDECOR_H
|
||||||
#include <libdecor.h>
|
#include <libdecor.h>
|
||||||
#endif
|
#endif
|
||||||
|
@@ -211,7 +211,7 @@ SDL_WAYLAND_SYM(bool, libdecor_configuration_get_content_size, (struct libdecor_
|
|||||||
int *))
|
int *))
|
||||||
SDL_WAYLAND_SYM(bool, libdecor_configuration_get_window_state, (struct libdecor_configuration *,\
|
SDL_WAYLAND_SYM(bool, libdecor_configuration_get_window_state, (struct libdecor_configuration *,\
|
||||||
enum libdecor_window_state *))
|
enum libdecor_window_state *))
|
||||||
SDL_WAYLAND_SYM(bool, libdecor_dispatch, (struct libdecor *, int))
|
SDL_WAYLAND_SYM(int, libdecor_dispatch, (struct libdecor *, int))
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#undef SDL_WAYLAND_MODULE
|
#undef SDL_WAYLAND_MODULE
|
||||||
|
Reference in New Issue
Block a user