|
0d987936
|
2021-11-09T22:03:42
|
|
testwm2: Fix video modes menu hit detection when highdpi or logical size used (#4936)
* SDLTest_CommonDrawWindowInfo: log SDL_RenderGetScale, SDL_RenderGetLogicalSize
* testwm2: fix video modes menu hit detection in High DPI cases
- also when logical size is specified, e.g.
`--logical 640x480 --resizable --allow-highdpi`
* add function to determine logical coordinates of renderer point when given window point
* change since to the targeted milestone
* fix typo
* rename for consistency
* Change logical coordinate type to float, since we can render with floating point precision.
* add function to convert logical to window coordinates
* testwm2: use new SDL_RenderWindowToLogical
* SDL_render.c: alternate SDL_RenderWindowToLogical/SDL_RenderLogicalToWindow
Co-authored-by: John Blat <johnblat64@protonmail.com>
Co-authored-by: John Blat <47202511+johnblat64@users.noreply.github.com>
|
|
04f42e04
|
2021-11-09T11:50:49
|
|
metal: Deal better with -[CAMetalLayer nextDrawable] returning nil.
Fixes #4863.
|
|
fd79607e
|
2021-11-08T21:34:48
|
|
Added SDL_GetWindowMouseRect()
Also guarantee that we won't get mouse movement outside the confining area, even if the OS implementation allows it (e.g. macOS)
|
|
4b42c05b
|
2021-11-08T13:52:48
|
|
video: Add SDL_SetWindowMouseRect.
This API and implementation comes from the Unreal Engine branch of SDL, which
originally called this "SDL_ConfineCursor".
Some minor cleanup and changes for consistency with the rest of SDL_video, but
there are two major changes:
1. The coordinate system has been changed so that `rect` is _window_ relative
and not _screen_ relative, making it easier to implement without having
global access to the display.
2. The UE version unset all rects when passing `NULL` as a parameter for
`window`, this has been removed as it was an unused feature anyhow.
Currently this is only implemented for X, but can be supported on Wayland and
Windows at minimum too.
|
|
1a98dcb6
|
2021-11-08T15:16:18
|
|
Revert "include: Updated SDL_config_emscripten.h from emscripten-ports."
Apparently we already had the newer version, sorry!
This reverts commit 6657cbce8dcea9abe4501c8bbf85f2b40e6c927a.
Reference issue #4623.
|
|
84138b77
|
2021-11-08T21:15:04
|
|
minor update to os2 config file.
|
|
5dbbc8e6
|
2021-11-08T09:44:31
|
|
Added mouse wheel deltas with floating point precision
Fixes https://github.com/libsdl-org/SDL/issues/4888
|
|
b8327a4a
|
2021-11-08T07:19:45
|
|
Added SDL_HIDAPI_DISABLED so it can be disabled like other SDL subsystems
|
|
2a904aa1
|
2021-11-08T17:00:28
|
|
os2: remove SDL_hidapi duplications in makefile, disable it in config.
|
|
5b646cd1
|
2021-11-07T22:58:44
|
|
Build hidapi code into SDL as a new public API
This prevents conflicts with hidapi linked with applications, as well as allowing applications to make use of HIDAPI on Android and other platforms that might not normally have an implementation available.
|
|
6657cbce
|
2021-11-07T20:43:49
|
|
include: Updated SDL_config_emscripten.h from emscripten-ports.
Reference issue #4623.
|
|
74f35a7c
|
2021-11-07T14:10:04
|
|
Fixed documentation
|
|
e1435826
|
2021-11-07T11:16:48
|
|
Cleanup sfSymbolName support and add them to the dynamic API functions
|
|
149e5c65
|
2021-10-03T12:49:36
|
|
Support returning sfSymbolsName for gamepad controls on macOS / iOS / tvOS
|
|
a0e055a7
|
2021-11-07T02:48:29
|
|
testwm2: add mode menu, click on a mode to call SDL_SetWindowDisplayMode
|
|
5de72374
|
2021-11-05T21:06:58
|
|
SDL_config_windows.h: detect winsdkver.h using __has_include()
__has_include() was added in VS 2017 15.3, so this works out to essentially
the same _MSC_VER >= 1911 check we had before for MSVC but works for non-MSVC
compilers also.
|
|
6cbee063
|
2021-11-05T01:17:29
|
|
include: Swap parameter names in atan2 functions
|
|
d8b53e82
|
2021-11-03T19:51:18
|
|
direct3d11: fix SDK version requirement for non-CMake build
The D3D11 renderer requires Direct3D 11.1 (d3d11_1.h), not Direct3D 11.0
(d3d11.h). In terms of SDKs, that's the Windows 8 SDK or later.
We should probably rename HAVE_D3D11_H...
|
|
802e17aa
|
2021-11-03T20:35:20
|
|
autotools: added windows.gaming.input.h (and SDL_JOYSTICK_WGI) detection
|
|
2371b247
|
2021-10-31T18:27:51
|
|
windows: improve feature detection consistency between CMake and non-CMake builds
|
|
c948b936
|
2021-11-02T15:57:24
|
|
Added note for Android 12 API level
|
|
43ddc59f
|
2021-11-02T16:56:14
|
|
Export SDL_LinuxSetThreadPriorityAndPolicy() function (#4877)
It's marked as being a public symbol internally, however, it was missing from the header files and not visible in the shared library. This adds it to the necessary headers and to the DynAPI list to expose it for use by applications.
Co-authored-by: Frank Praznik <frank.praznik@oh.rr.com>
|
|
228219dc
|
2021-10-23T15:30:45
|
|
include: Improved SDL_GetTicks*() documentation a little.
|
|
99c9727d
|
2021-10-23T15:00:31
|
|
timer: Added SDL_GetTicks64(), for a timer that doesn't wrap every ~49 days.
Note that this removes the timeGetTime() fallback on Windows; it is a
32-bit counter and SDL2 should never choose to use it, as it only is needed
if QueryPerformanceCounter() isn't available, and QPC is _always_ available
on Windows XP and later.
OS/2 has a similar situation, but since it isn't clear to me that similar
promises can be made about DosTmrQueryTime() even in modern times, I decided
to leave the fallback in, with some heroic measures added to try to provide a
true 64-bit tick counter despite the 49-day wraparound. That approach can
migrate to Windows too, if we discover some truly broken install that doesn't
have QPC and still depends on timeGetTime().
Fixes #4870.
|
|
25c71748
|
2020-02-13T21:55:08
|
|
Add a barebones RISC OS video driver
|
|
81fe2ccb
|
2021-10-31T02:54:20
|
|
cmake: Add missing SDL_JOYSTICK_WGI in config step
SDL_config.h *can* define SDL_JOYSTICK_WGI. On builds with the Windows
10 SDK available, this allow implementing trigger rumbling on Xbox One
controllers. The files included in the Visual Studio Solution in
VisualC\SDL.sln *do* have this define set.
fix #4859
|
|
c7dafb15
|
2021-10-27T01:36:05
|
|
Sync wiki -> header
|
|
1c641460
|
2021-10-26T15:30:06
|
|
Sync wiki -> header
|
|
dbe55350
|
2021-10-23T14:38:32
|
|
include: Improve doxygen text on SDL_GetRevisionNumber().
|
|
8f58bb9c
|
2021-10-21T20:48:08
|
|
Added SDL_USE_BUILTIN_OPENGL_DEFINITIONS to avoid system OpenGL headers
|
|
6c134cf1
|
2021-10-22T00:39:04
|
|
Sync wiki -> header
|
|
19dee1cd
|
2021-10-22T06:37:20
|
|
Add SDL_GetWindowICCProfile(). (#4314)
* Add SDL_GetWindowICCProfile
* Add new SDL display events
* Implement ICC profile change event for macOS
* Implement ICC profile notification for Windows
* Fix SDL_GetWindowICCProfile() for X11
* Fix compile errors
|
|
8b1a2fe8
|
2021-10-17T23:47:59
|
|
backout SDL_AndroidSetInputType()
|
|
ccb12457
|
2021-10-17T23:17:54
|
|
Fixed bug #4843 - Can not get the ime candidatelist like chinese/japaness input method
|
|
7f728f3e
|
2021-10-15T08:51:02
|
|
enabled os2 joystick code (if anyone has actually a use for it...)
|
|
8a48ce00
|
2021-10-15T05:28:04
|
|
Sync wiki -> header
|
|
8bf32e12
|
2021-10-15T06:26:10
|
|
Improved SDL_PollEvent usage (#4794)
* Avoid unnecessary SDL_PumpEvents calls in SDL_WaitEventTimeout
* Add a sentinel event to avoid infinite poll loops
* Move SDL_POLLSENTINEL to new internal event category
* Tweak documentation to indicate SDL_PumpEvents isn't always called
* Avoid shadowing event variable
* Ignore poll sentinel if more (user) events have been added after
Co-authored-by: Sam Lantinga <slouken@libsdl.org>
|
|
43da35b5
|
2021-10-14T22:22:59
|
|
Back out documentation changes in favor of https://github.com/libsdl-org/SDL/pull/4794
|
|
0dc57b0f
|
2021-10-14T19:42:36
|
|
Remove slightly misleading comment in the example code
|
|
ddf1d5c5
|
2021-10-14T19:10:30
|
|
Update documentation to reflect that a single SDL_PumpEvents() each frame is the recommended way to handle events
|
|
0789610c
|
2021-10-14T00:52:05
|
|
Add SDL_HINT_WINDOW_NO_ACTIVATION_WHEN_SHOWN
|
|
227c33b8
|
2021-10-13T09:33:57
|
|
Add note about SDL_TICKS_PASSED hitting int overflow problems with large timeouts
|
|
3db898c5
|
2020-02-13T22:32:35
|
|
riscos: Implement SDL_GetPrefPath()
|
|
1b49f092
|
2021-10-08T20:22:48
|
|
include: manually ran wikiheaders.pl and cleaned up the obvious issues.
|
|
194657a2
|
2021-10-08T15:57:18
|
|
include: Fix indentation on SDL_SoftStretch doxygen comment.
Otherwise wikiheaders.pl doesn't think it's valid.
|
|
2f93fbbb
|
2021-09-30T10:04:09
|
|
include: Fix markdown in a doxygen comment.
|
|
8b23029d
|
2021-09-28T17:03:06
|
|
Sync wiki -> header
|
|
b592e78f
|
2021-09-25T12:55:41
|
|
wayland: Expose xdg_toplevel to SysWM
|
|
7a1690eb
|
2021-09-26T02:32:05
|
|
Sync wiki -> header
|
|
7becc414
|
2021-09-25T17:36:04
|
|
Sync wiki -> header
|
|
25a614bc
|
2021-09-14T20:37:35
|
|
Add SDL_asprintf and SDL_vasprintf
|
|
b687c0ff
|
2021-09-21T18:15:10
|
|
Integrate fix for Source 2's Win32 build that does '#define __i386__ 1' which causes it to hit the __i386__ case instead of the _MSC_VER case.
|
|
f5e636a6
|
2021-09-20T20:43:39
|
|
config: Try to use stdint.h with Borland C.
(This probably isn't right on truly ancient versions of Borland C, but it
should cover things from the last decade or so, I hope.)
(possibly) Fixes #1673.
|
|
478f9eed
|
2021-09-20T10:20:04
|
|
x11: Don't include X11/extensions/extutil.h
We don't use it, it was a leftover from 1.2, I think, and it doesn't exist
on Solaris, so this should hopefully fix the build there.
This also means we don't need the configure/cmake checks for
SDL_VIDEO_DRIVER_X11_CONST_PARAM_XEXTADDDISPLAY, so that was removed also.
Fixes #1666.
|
|
b8da02e6
|
2021-09-18T10:44:32
|
|
include: Fix triggering of Clang's -Wexpansion-to-defined in SDL_endian.h
It doesn't like #if statements that uses a macro that uses defined(x).
|
|
8f414123
|
2021-09-18T10:35:36
|
|
cmake: Patched to compile.
Too fast on the git push!!
|
|
bf1d7a3a
|
2021-09-18T10:31:37
|
|
cmake: Don't trust the HAVE_IMMINTRIN_H check on Apple targets.
Otherwise universal builds might try to include an Intel-specific header
on ARM builds, etc.
Fixes #4753.
|
|
ba9e2299
|
2021-09-18T14:19:04
|
|
Sync wiki -> header
|
|
2d44bf7d
|
2021-09-17T20:24:10
|
|
Update description of SDL_SetWindowAlwaysOnTop
|
|
5dccffd7
|
2021-08-23T21:16:58
|
|
Allow usage of the new Condition Variable code with Critical Sections
Vista and later provide the SleepConditionVariableCS() function for this.
Since SDL_syscond_srw.c doesn't require SRW locks anymore, rename it to
SDL_syscond_cv.c which better reflects the implementation of condition
variables rather than the implementation of mutexes.
Fixes #4051.
|
|
44ab04fc
|
2021-09-17T19:19:06
|
|
Sync wiki -> header
|
|
4d0c3cb2
|
2021-09-17T19:17:05
|
|
Sync wiki -> header
|
|
19253835
|
2021-09-17T19:14:05
|
|
Sync wiki -> header
|
|
d856478f
|
2021-09-17T19:12:05
|
|
Sync wiki -> header
|
|
74a1eb21
|
2021-09-17T19:10:07
|
|
Sync wiki -> header
|
|
eb8f332c
|
2021-09-17T02:34:49
|
|
fix: allow builtins for all archs (#4756)
* fix: allow builtins for all archs
* fix: typo
|
|
4a994733
|
2021-09-14T15:51:17
|
|
`SDL_RenderSetVSync()`: Restrict `vsync` to 0 or 1
In the future, we might want to support special swap intervals. To
prevent applications from expecting nonzero values of vsync to be the
same as "on", fail with SDL_Unsupported() if the value passed is neither
0 nor 1.
|
|
4549769d
|
2021-03-07T15:20:45
|
|
Add `SDL_RenderSetVSync()`
Currently, if an application wants to toggle VSync, they'd have to tear
down the renderer and recreate it. This patch fixes that by letting
applications call SDL_RenderSetVSync().
This is the same as the patch in #3673, except it applies to all
renderers (including PSP, even thought it seems that the VSync flag is
disabled for that renderer). Furthermore, the renderer flags also change
as well, which #3673 didn't do. It is also an API instead of using hint
callbacks (which could be potentially dangerous).
Closes #3673.
|
|
67aacfe5
|
2021-09-09T17:59:47
|
|
cmake: Retrieve the git revision on platforms without bash
|
|
134dd468
|
2021-08-16T19:08:12
|
|
Add pvr gles/gles2 context support
|
|
6f972052
|
2021-08-30T12:21:05
|
|
Added: Support for showing the IME Candidate Window on Windows
|
|
e260c804
|
2021-08-30T23:46:54
|
|
Fix the wiki/headers bridge.
I'm tweaking this manually to remove some whitespace that confused it, but
if this happens again I'll make improvements to wikiheaders.pl instead.
|
|
a1ffeda0
|
2021-08-28T22:52:13
|
|
Add SDL_HINT_APP_NAME and DBUS inhibition hint
See SDL bug #4703. This implements two new hints:
- SDL_APP_NAME
- SDL_SCREENSAVER_INHIBIT_ACTIVITY_NAME
The former is the successor to SDL_HINT_AUDIO_DEVICE_APP_NAME, and acts
as a generic "application name" used both by audio drivers and DBUS
screensaver inhibition. If SDL_AUDIO_DEVICE_APP_NAME is set, it will
still take priority over SDL_APP_NAME.
The second allows the "activity name" used by
org.freedesktop.ScreenSavver's Inhibit method, which are often shown in
the UI as the reason the screensaver (and/or suspend/other
power-managment features) are disabled.
|
|
b9bf7ffe
|
2021-08-28T18:17:05
|
|
Sync wiki -> header
|
|
503ea8e8
|
2021-08-25T14:41:58
|
|
Don't modify the Nintendo Switch home LED state by default
|
|
524964f9
|
2021-08-14T12:09:13
|
|
Add SDL_HINT_VIDEO_EGL_ALLOW_TRANSPARENCY
|
|
ca39f6d6
|
2021-08-18T22:13:05
|
|
Sync wiki -> header
|
|
93fb5a22
|
2021-08-18T23:54:37
|
|
Remove '\brief' markup in header 'SDL_render.h'
|
|
a8f89a01
|
2021-04-23T12:00:14
|
|
Change 'size_indice' to 'size_indices'
|
|
cc37c38e
|
2021-04-01T09:55:00
|
|
Add SDL_RenderGeometry based on SDL_RenderGeometryRaw
|
|
e4812611
|
2021-04-01T09:49:16
|
|
Move to SDL_RenderGeometryRaw prototype with separate xy/uv/color pointer parameters
|
|
f73c1eff
|
2021-03-17T09:58:49
|
|
Use normalized texture coordinates
|
|
f22fc4ca
|
2021-03-16T15:07:44
|
|
Add API: SDL_Vertex type and SDL_RenderGeometry
|
|
bfbab536
|
2021-08-16T23:07:30
|
|
remove warnings from Wundef in SDL_config.h.cmake
|
|
966728db
|
2021-08-16T06:43:37
|
|
include/SDL_video.h: Remove a comma at end of enumerator list
|
|
83bb1366
|
2021-08-15T12:41:27
|
|
Restore KMOD_RESERVED for backward compatibility
Some applications check for KMOD_RESERVED but it was replaced with
KMOD_SCROLL in https://github.com/libsdl-org/SDL/commit/cb1e20b058f1de55b98f32b7d16cff1f896f88dd.
|
|
72f41d1f
|
2021-08-14T21:11:17
|
|
Added missing parenthesis around SDL_clamp
|
|
0a870756
|
2021-07-08T12:47:57
|
|
Update SDL_config_emscripten.h for upstream
|
|
d4488962
|
2021-05-19T08:24:33
|
|
Add SDL_config_emscripten.h
Currently we maintain a config file in the emscripten
repo, but this seems like what other embedded/cross
platforms do.
|
|
35c1bbfa
|
2021-08-13T21:43:00
|
|
SDL_stdinc.h: Add an SDL_clamp() function
Add a function to clamp a value to a range.
SDL_clamp(x, a, b) is equivalent to SDL_min(a, SDL_max(x, b)): it
ensures that x is not smaller than a, nor larger than b.
While, as best I can tell, this isn't actually standardised anywhere,
it's a very useful function/macro to have.
|
|
9bf65575
|
2021-08-13T06:36:49
|
|
Correctly check for bswap builtins before using
The __clang_major__ and __clang_minor__ macros provide a marketing
version, which is not necessarily comparable for clang distributions
from different vendors[1]. In practice, the versioning scheme for
Apple's clang is indeed completely different to that of the llvm.org
releases. It is thus preferable to check for features directly rather
than comparing versions.
In this specific case, __builtin_bswap16 was being used with older
Apple clang versions that don't support it.
[1] https://clang.llvm.org/docs/LanguageExtensions.html#builtin-macros
|
|
cb1e20b0
|
2021-08-10T17:50:17
|
|
Added KMOD_SCROLL to track the scroll lock state
Fixes https://github.com/libsdl-org/SDL/issues/4566
|
|
609cea1e
|
2021-08-10T17:14:06
|
|
Enable SSE3 intrinsics when building with Visual Studio
Fixes https://github.com/libsdl-org/SDL/issues/4530
|
|
d5ad6f6e
|
2021-08-10T16:51:03
|
|
Clarified that you should never have side-effects in the parameters to SDL_min/SDL_max
|
|
056a42f1
|
2021-08-10T22:20:06
|
|
Sync wiki -> header
|
|
f5794f9e
|
2021-08-10T15:17:59
|
|
Added SDL_SetTextureUserData() and SDL_GetTextureUserData() to associate a user-specified pointer with an SDL texture
|
|
3f6ebfff
|
2021-08-10T15:02:36
|
|
Updated to version 2.0.17 for development
|
|
68103993
|
2021-08-10T14:50:43
|
|
Enable AAUDIO driver for Android
I thought this was already enabled for 2.0.16, but apparently not.
Fixes https://github.com/libsdl-org/SDL/issues/3710
|
|
77c8d111
|
2021-08-10T20:55:50
|
|
configuration updates for dlopen:
- cmake, configure (CheckDLOPEN): --enable-sdl-dlopen is now history..
detach the dl api discovery from SDL_LOADSO_DLOPEN functionality.
define HAVE_DLOPEN. also define DYNAPI_NEEDS_DLOPEN (CheckDLOPEN is
called only for relevant platforms.)
- update SDL_config.in and SDL_config.cmake accordingly.
- SDL_dynapi.h: set SDL_DYNAMIC_API to 0 if DYNAPI_NEEDS_DLOPEN is
defined, but HAVE_DLOPEN is not.
- pthread/SDL_systhread.c: conditionalize dl api use to HAVE_DLOPEN
- SDL_x11opengl.c, SDL_DirectFB_opengl.c, SDL_naclopengles.c: rely
on HAVE_DLOPEN, not SDL_LOADSO_DLOPEN.
- SDL_config_android.h, SDL_config_iphoneos.h, SDL_config_macosx.h,
SDL_config_pandora.h, and SDL_config_wiz.h: define HAVE_DLOPEN.
Closes: https://github.com/libsdl-org/SDL/pull/4351
|
|
2e6dac87
|
2021-08-09T01:47:42
|
|
wayland: Add a hint to allow disabling libdecor use
Useful for testing xdg-shell path with compositors like Weston.
|