Commit Graph

2483 Commits

Author SHA1 Message Date
Maia
0becdad392 Add missing includes to SDL_tray.h 2024-12-25 07:54:54 -08:00
Brody Eller
5bf742daa6 Fix documentation for SDL_sinf 2024-12-24 20:41:41 -08:00
SDL Wiki Bot
4c70aa33ae Sync SDL3 wiki -> header
[ci skip]
2024-12-24 18:50:21 +00:00
Semphriss
01b9b0edb7 Add system tray support (#10873) 2024-12-24 10:36:39 -08:00
SDL Wiki Bot
17a029502a Sync SDL3 wiki -> header
[ci skip]
2024-12-24 17:37:33 +00:00
Caleb Cornett
aa817a67d1 GPU: Document system requirements for each driver 2024-12-24 12:36:52 -05:00
Sam Lantinga
ed75d9d22a Document that the mouse ID is only valid in mouse relative mode
Fixes https://github.com/libsdl-org/SDL/issues/11259
2024-12-23 17:12:50 -08:00
SDL Wiki Bot
4d301b88d6 Sync SDL3 wiki -> header
[ci skip]
2024-12-24 00:54:10 +00:00
Sam Lantinga
969f03d9f0 Added SDL_PROP_RENDERER_GPU_DEVICE_POINTER
Fixes https://github.com/libsdl-org/SDL/issues/11600
2024-12-23 16:51:43 -08:00
SDL Wiki Bot
7a22076a7c Sync SDL3 wiki -> header
[ci skip]
2024-12-23 23:58:24 +00:00
SDL Wiki Bot
18115ef6bd Sync SDL3 wiki -> header
[ci skip]
2024-12-23 23:01:15 +00:00
Sam Lantinga
8691408baf Clarify that you shouldn't make any assumptions about the an SDL_FingerID value.
Fixes https://github.com/libsdl-org/SDL/issues/11667
2024-12-23 14:28:54 -08:00
Eduard Gushchin
3ac28bae6a Removed references to non-existent method SDL_GetAsyncIOTaskResult 2024-12-23 08:02:03 -08:00
SDL Wiki Bot
da37e1541b Sync SDL3 wiki -> header
[ci skip]
2024-12-23 05:32:13 +00:00
SDL Wiki Bot
ecea3471f6 Sync SDL3 wiki -> header
[ci skip]
2024-12-22 20:20:41 +00:00
Anonymous Maarten
f8d8bf8066 SDL_GetNumAllocations returns -1 when allocation counting is disabled 2024-12-22 12:20:04 -08:00
SDL Wiki Bot
478ac0b9bf Sync SDL3 wiki -> header
[ci skip]
2024-12-22 19:01:42 +00:00
SDL Wiki Bot
03d6e4b69e Sync SDL3 wiki -> header
[ci skip]
2024-12-22 18:53:26 +00:00
Maia
ca4ffc8a00 Fix missing parens in preprocessor defined op 2024-12-22 10:36:03 -05:00
Maia
8475c496b4 Fix typo 2024-12-22 10:35:35 -05:00
SDL Wiki Bot
56cf8d8dc9 Sync SDL3 wiki -> header
[ci skip]
2024-12-22 07:09:56 +00:00
Ryan C. Gordon
f0fad41f2c include: Filled in all remaining missing documentation! 2024-12-22 01:58:13 -05:00
SDL Wiki Bot
4d8f5758cf Sync SDL3 wiki -> header
[ci skip]
2024-12-22 06:18:11 +00:00
Sam Lantinga
f37eef948c Removed raw mouse events
It's too close the 3.2.0 release for an API change like this.

If/when we re-add these, some things for consideration:
* What use cases does this enable that aren't currently possible?
* What cross-platform API guarantees do we make about the availability of these events? e.g. do we try to simulate them where raw input isn't actually available?
* How is this different from the existing relative mode, and how do we clearly explain when you want these events vs wanting relative mode?

Notes from @expikr:
First observation: the reason I originally passed denominators instead of multipliers was because some rational values cannot be exactly represented by floats (e.g 1/120) so instead let the end-developer decide how to do the dividing themselves. It was the reason why it was using split values with an integer numerator to begin with, instead of having both as floats or even just normalize it in advance.

On the other hand, passing them as multipliers might have hypothetical uses for dynamically passing end-user controlled scaling in a transparent manner without coupling? (Though in that case why not just do that as additional fields appended to `motion` structs in an API-compatible layout?)

So it’s somewhat of a philosophical judgement of what this API of optional availability do we intend for it to present itself as:
- should it be a bit-perfect escape hatch with the absolute minimally-denominal abstraction over platform details just enough to be able to serve the full information (á la HIDPIAPI),
- or a renewed ergonomic API for splitting relative motion from cursor motion (in light of The Great Warping Purge) so that it is unburdened by legacy RelativeMode state machines, in which case it would be more appropriate to just call it `RELATIVE` instead of `RAW` and should be added alongside another new event purely for cursor events?

This alternate API stream was conceived in the context of preserving compatibility of the existing RelativeMode state machine by adding an escape hatch. So given the same context, my taste leans towards the former designation.

However, as The Great Warping Purge has made it potentially viable to do so, if I were allowed to break ABI by nuking the RelativeMode state machine entirely, I would prefer the latter designation unified as one of three separate components split from the old state machine, each independently controlled by platform-dependent availability without any state switching of a leaky melting pot:
- cursor visibility controls (if platform has cursor)
- cursor motion events (if platform has cursor)
- relative motion events (if the platform reports hardware motion)
2024-12-21 05:18:42 -08:00
Sam Lantinga
d07bb0e679 Removed raw key events
They weren't adding any value over the existing keyboard events
2024-12-21 05:18:42 -08:00
Sam Lantinga
c44fa5bb07 Updated raw input events to match SDL style
Also added raw keyboard events, and implemented raw input events on iOS, OpenBSD console, Linux console, and X11
2024-12-21 05:18:42 -08:00
SDL Wiki Bot
1025087c2e Sync SDL3 wiki -> header
[ci skip]
2024-12-21 13:15:56 +00:00
Ethan Lee
f7580374a1 include: Always declare SDL_GDKSuspendComplete.
This is always defined in the symbol table and the function safely does nothing
on non-GDK targets, so treat it like any other SDL_system function.
2024-12-20 13:14:55 -05:00
SDL Wiki Bot
232c2970d3 Sync SDL3 wiki -> header
[ci skip]
2024-12-20 15:57:39 +00:00
SDL Wiki Bot
b815123cf2 Sync SDL3 wiki -> header
[ci skip]
2024-12-20 07:48:16 +00:00
Ryan C. Gordon
819e1cc95b SDL_stdinc.h: A couple wikiheaders fixes. 2024-12-20 02:45:04 -05:00
Ryan C. Gordon
b2eb23a617 SDL_filesystem.h: Fill in missing documentation. 2024-12-20 02:39:28 -05:00
Ryan C. Gordon
0b401137d2 SDL_stdinc.h: Document more stuff.
There's only a handful of C runtime wrappers left in this header now!
2024-12-20 02:28:34 -05:00
Ryan C. Gordon
b83dd793fd SDL_stdinc.h: Tons of documentation updates.
Almost everything in this header is now documented! The remaining gaps are
literal C runtime wrappers like SDL_strdup, and the analyzer macros like
SDL_INOUT_Z_CAP.
2024-12-20 01:09:40 -05:00
SDL Wiki Bot
b2c15a8c2a Sync SDL3 wiki -> header
[ci skip]
2024-12-20 00:35:23 +00:00
SDL Wiki Bot
c9e22d4672 Sync SDL3 wiki -> header
[ci skip]
2024-12-20 00:13:34 +00:00
Ryan C. Gordon
ff366fba87 include: Move SDL_HAS_BUILTIN to SDL_begin_code.h, document it.
This macro fits better here, since most of the other macros in this file are
for testing similar compiler/target features, etc.
2024-12-19 19:12:56 -05:00
Ryan C. Gordon
401c8f8e4e SDL_timer.h: Fixed doxygen typo. 2024-12-19 16:46:42 -05:00
SDL Wiki Bot
2f9a45af60 Sync SDL3 wiki -> header
[ci skip]
2024-12-19 21:44:12 +00:00
Ryan C. Gordon
0c42891826 include: Filled in more documentation gaps. 2024-12-19 16:42:14 -05:00
SDL Wiki Bot
d6a95ae198 Sync SDL3 wiki -> header
[ci skip]
2024-12-19 18:54:59 +00:00
Sam Lantinga
42de2ac6a9 Fixed typo 2024-12-19 10:51:02 -08:00
Sam Lantinga
e08f34c3be Removed SDL_HINT_MOUSE_RELATIVE_MODE_WARP
This complicated mouse handling and is a rarely tested path. Real relative mode is much better performance and higher precision.
2024-12-19 10:33:02 -08:00
SDL Wiki Bot
519923ea80 Sync SDL3 wiki -> header
[ci skip]
2024-12-19 17:20:47 +00:00
Ryan C. Gordon
624a4d5f26 include: Documented important SDL_begin_code symbols. 2024-12-19 12:19:46 -05:00
expikr
5c0f8dc179 add alternate raw mouse motion events with windows implementation (#10042) 2024-12-18 17:29:27 -08:00
expikr
345cab1e36 streamline cursor clipping logic on windows (#11237)
This commit does the following:
- add logic in the `WM_MOUSEMOVE` case of the Window to conditionally call `WIN_UpdateClipCursor` upon receiving cursor motion if SDL is expecting the mouse to be clipped in some way (Fixes #7890)
- remove Windows-specific periodic refresh of cursor clipping and its `SDL_HINT_MOUSE_RELATIVE_CLIP_INTERVAL` hint (superceded by the above bullet point)
- streamline the processing logic within `WIN_UpdateClipCursor` for better readability of each branch, and avoid calling the Platform API until it is absolutely necessary.
- move `relative_mouse_center` field from Windows-specific per-window `SDL_WindowData` to the global `SDL_Mouse` struct, and the corresponding hint callbacks to `SDL_mouse.c` instead of `SDL_windowswindow.c`
2024-12-18 17:25:06 -08:00
SDL Wiki Bot
10f868abf4 Sync SDL3 wiki -> header
[ci skip]
2024-12-19 01:06:43 +00:00
Sam Lantinga
f81472d767 Document that you should read from processes before waiting for them to exit.
Fixes https://github.com/libsdl-org/SDL/issues/11645
2024-12-18 16:18:44 -08:00
Eduard Gushchin
da80b9bce5 Fixed an inaccuracy in the documentation for SDL_ConvertPixelsAndColorspace 2024-12-18 14:20:24 -08:00