|
49f846f1
|
2017-07-11T19:27:50
|
|
Added support for an XBox One wired controller for Leo L?nnenm?ki
|
|
74ca1654
|
2017-07-11T08:16:00
|
|
Fixed bug 3699 - Shaped windows are distorted unless width is divisible by 8
Bogomancer
On X11, windows created using the shaped window API appear distorted unless the width of the shape surface is divisible by 8.
Steps to reproduce:
1) Use your favorite image editor to resize one of the images in test/shapes/ to a width that's not a multiple of 8.
2) Compile and run test/testshape.c on the image you edited.
3) The shaped window will appear twisted and distorted.
It appears the bug was not caught sooner because all the test images are either 640 or 256 pixels wide.
I tracked down the bug to SDL_CalculateShapeBitmap() in SDL_shape.c. The shape surface is reduced to a 1-bit-per-pixel mask, but the original code doesn't take into account that X11 apparently wants each scanline to begin on a new byte.
|
|
3c09265d
|
2017-07-10T18:31:28
|
|
Fixed bug 3609 - Windows build fails due to conflicting types for 'XINPUT_GAMEPAD_EX'
Ozkan Sezer
(In reply to Ryan C. Gordon from comment #9)
> I've put this patch in as https://hg.libsdl.org/SDL/rev/7213ae46e870 ...can
> you verify this works on the latest MinGW?
>
> Thanks,
> --ryan.
This patch is wrong: the structure in question has nothing to do with any
gcc version in use. I suggest reverting this adding a conigury check for
it, instead. Something like the following should do it: (configure needs
regenerating.)
|
|
cd79d8cc
|
2017-07-10T17:16:12
|
|
Fixed bug 3696 - SDL_ShowMessageBox displays different error from intended
Mark Callow
SDL_ShowMessageBox calls SDL_CaptureMouse which, in the UIKit driver, raises a ?That operation is not supported? error, overwriting the SDL error that an application may be trying to report.
This is because UIKit SDL_CaptureMouse returns SDL_Unsupported() which ends up calling SDL_SetError() which has the following code:
/* If we are in debug mode, print out an error message */
SDL_LogDebug(SDL_LOG_CATEGORY_ERROR, "%s", SDL_GetError());
The SDL_GetError call here overwrites the static buffer?..
Although an application can avoid this by using SDL_GetErrorMsg(char* errstr, int maxlen) to avoid the static buffer, SDL should be fixed.
The fix is simple. In SDL_SetError change
SDL_LogDebug(SDL_LOG_CATEGORY_ERROR, "%s", SDL_GetError());
to
SDL_LogDebug(SDL_LOG_CATEGORY_ERROR, "%s", error);
where error is the pointer to the buffer where it assembled the message.
|
|
37722d01
|
2017-07-10T17:07:19
|
|
Fixed bug 3697 - Main thread gets stuck on left mouse down
Amruth Raj
- My app runs in full screen to play video(I use SDL_WINDOW_FULLSCREEN_DESKTOP)
- Cmd-tab to go out of full screen to another app
- Cmd-tab again to get back to my app
- Press left mouse button at one of the edges of the screen, don't release yet.
After this point the main thread is stuck until I release the left mouse button and hence video rendering doesn't happen anymore.
On debugging more, I see that thread 0 is stuck as shown below with sendEvent processing left mouse down. It comes out only after it receives a left mouse up. There are some frames below which show NSWindowResizing, but my window flag doesn't have SDL_WINDOW_RESIZABLE set.
Thread 0:: CrBrowserMain Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x00007fffbe13d34a mach_msg_trap + 10
1 libsystem_kernel.dylib 0x00007fffbe13c797 mach_msg + 55
2 com.apple.CoreFoundation 0x00007fffa889d434 __CFRunLoopServiceMachPort + 212
3 com.apple.CoreFoundation 0x00007fffa889c8c1 __CFRunLoopRun + 1361
4 com.apple.CoreFoundation 0x00007fffa889c114 CFRunLoopRunSpecific + 420
5 com.apple.HIToolbox 0x00007fffa7dfdebc RunCurrentEventLoopInMode + 240
6 com.apple.HIToolbox 0x00007fffa7dfdcf1 ReceiveNextEventCommon + 432
7 com.apple.HIToolbox 0x00007fffa7dfdb26 _BlockUntilNextEventMatchingListInModeWithFilter + 71
8 com.apple.AppKit 0x00007fffa6396a54 _DPSNextEvent + 1120
9 com.apple.AppKit 0x00007fffa6b127ee -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 2796
10 com.apple.AppKit 0x00007fffa66f568d +[NSWindow(NSWindowResizing) _mouseHysteresisCheck:withExpiration:andDistance:finalMouseLocation:] + 525
11 com.apple.AppKit 0x00007fffa65eedb5 -[NSWindow(NSWindowResizing) _hitTestWithHysteresisCheck:forEvent:allowWindowDragging:] + 394
12 com.apple.AppKit 0x00007fffa6c8f0db -[NSWindow(NSEventRouting) _handleMouseDownEvent:isDelayedEvent:] + 1873
13 com.apple.AppKit 0x00007fffa6c8ca6c -[NSWindow(NSEventRouting) _reallySendEvent:isDelayedEvent:] + 1942
14 com.apple.AppKit 0x00007fffa6c8bf0a -[NSWindow(NSEventRouting) sendEvent:] + 541
15 org.libsdl.SDL2 0x000000010d46d74a -[SDLWindow sendEvent:] + 90
16 com.apple.AppKit 0x00007fffa6b10681 -[NSApplication(NSEvent) sendEvent:] + 1145
17 org.libsdl.SDL2 0x000000010d46532b -[SDLApplication sendEvent:] + 139
18 org.libsdl.SDL2 0x000000010d466b2f Cocoa_PumpEvents + 495
19 org.libsdl.SDL2 0x000000010d44c1d5 SDL_PumpEvents_REAL + 53
20 org.libsdl.SDL2 0x000000010d44c2f5 SDL_WaitEventTimeout_REAL + 53
21 org.libsdl.SDL2 0x000000010d44c2b7 SDL_PollEvent_REAL + 23
22 org.libsdl.SDL2 0x000000010d51bb24 SDL_PollEvent + 36
23 libTest.dylib 0x000000010cf3e0e8 SDLEventProcessor::processEvents(int) + 568
24 Test 0x000000010cde6bba BrowserApp::RunAppMessageLoop(BAInstData*, CefStringBase, CefStringBase) + 810
25 Test 0x000000010ce04bbc main + 17980
26 libdyld.dylib 0x00007fffbe016235 start + 1
I further noticed that while entering full screen in SDL_cocoawindow.m NSResizableWindowMask is set. If I clear it inside windowDidEnterFullScreen, then, the issue doesn't repro.
This is discussed at https://discourse.libsdl.org/t/main-thread-gets-stuck-on-left-mouse-down/22753/3 and thanks to Eric for the pointers.
|
|
44246cda
|
2017-07-09T23:00:25
|
|
Fixed compiler warning about redundant declaration.
SDL_RecordGesture() is already in the gesture header with additional specifiers.
|
|
c3bf69ca
|
2017-07-07T23:00:22
|
|
haiku: Fixed compiling without OpenGL support.
|
|
fb9c2939
|
2017-07-07T23:00:10
|
|
qnx: Fixed setting a field twice.
|
|
1683a0c1
|
2017-07-05T12:04:37
|
|
audio: trying to pacify static analysis.
|
|
c80c3419
|
2017-07-04T20:44:07
|
|
x11: pass a long to XChangeProperty, not an int.
The Xlib documentation demands that 32-bit values here be passed in a long,
even when long itself isn't a 32-bit value. Otherwise libx11 might read
memory incorrectly.
Fixes Bugzilla #3692.
|
|
b36755a3
|
2017-07-03T16:45:12
|
|
power: whoops, that should be "==" not "!=".
|
|
c27dc514
|
2017-07-03T16:38:37
|
|
power: Linux /sys/class testing should skip "device" scopes.
(the PS4 game controllers report their batteries through this interface, which
is cool, but not helpful for powering the rest of the system. :) )
|
|
9f99b3d7
|
2017-07-02T22:46:49
|
|
aix: Fixed audio debug output.
DEBUG_AUDIO is checked with #ifdef not #if.
|
|
e6583300
|
2017-07-02T22:46:23
|
|
haiku: Fixed using wrong constant for internal error handling.
SDL_CreateWindow() worked because ENOMEM is negative on Haiku.
|
|
4366721b
|
2017-07-02T22:46:00
|
|
qnx: Removed unused bootstrap declaration.
QNX_bootstrap is the VideoBootStrap. QSAAUDIO_bootstrap is still there.
|
|
200f782c
|
2017-07-01T19:52:12
|
|
qnx: fixed potential buffer overflow.
|
|
22241ed0
|
2017-07-01T17:50:47
|
|
Support for QNX 7.0 (thanks, Elad!).
Fixes Bugzilla #3686.
|
|
b1fbab50
|
2017-07-01T23:01:57
|
|
haiku: Fixed memory leak if destroying window.
|
|
380e0693
|
2017-07-01T23:01:49
|
|
aix: Fixed compile error.
|
|
4c190ce5
|
2017-07-01T23:00:07
|
|
netbsd: Fixed comment.
|
|
4c48260c
|
2017-06-29T23:00:18
|
|
netbsd: Removed unused field.
|
|
7bb6b402
|
2017-06-29T23:00:09
|
|
netbsd: Fixed compile error.
|
|
944e06e6
|
2017-06-24T23:45:44
|
|
winrt: Fixed SDL include.
|
|
d96419c9
|
2017-06-21T01:22:00
|
|
xinput: use the full range of the haptic motors (thanks, Trent!).
XInput goes from 0 to 64k; we were feeding it values in the range of 0 to 32k.
Fixes Bugzilla #3002.
|
|
267dca13
|
2017-06-18T23:00:42
|
|
haiku: Removed unused internal function.
Its functionality is already in SDL_GL_GetAttribute().
|
|
90488d6c
|
2017-06-17T22:30:28
|
|
haiku: Added support for some values set with SDL_GL_SetAttribute().
|
|
6086e8d3
|
2017-06-17T22:30:09
|
|
haiku: Fixed missing slash in path from SDL_GetPrefPath().
|
|
0b750cd9
|
2017-06-16T23:30:38
|
|
pandora: Fixed compile error.
|
|
fa73685d
|
2017-06-16T23:30:30
|
|
directfb: Fixed quitting keyboard twice.
SDL_VideoQuit() already calls SDL_KeyboardQuit().
|
|
a4db3dbe
|
2017-06-16T23:30:13
|
|
nacl: Fixed unnecessary large input text array.
|
|
9085c7b3
|
2017-06-16T11:14:08
|
|
Get the parent of non-SDL-created windows, for completeness
|
|
1b5614b3
|
2017-06-16T10:50:29
|
|
Clean up parent window when destroying a window
|
|
0a75192d
|
2017-06-16T09:10:13
|
|
Implemented SDL_WINDOW_SKIP_TASKBAR on Windows
|
|
a725efa4
|
2017-06-15T23:30:50
|
|
linux: Fixed using wrong constant for input text size.
|
|
60c0f7e2
|
2017-06-15T23:30:29
|
|
Fixed SDL_GetWindowWMInfo() returning success on three unsupported platforms.
|
|
a509719f
|
2017-06-12T21:35:24
|
|
audio: Converter now checks a strict list of channels and formats we support.
|
|
553b3286
|
2017-06-12T16:39:15
|
|
Fixed bug 3668 - Overflow of SDL_AudioCVT.filters with some downmixes
Simon Hug
There's a chance that an audio conversion from many channels to a few can use more than 9 audio filters. SDL_AudioCVT has 10 SDL_AudioFilter pointers of which one has to be the terminating NULL pointer. The SDL code has no checks for this limit. If it overflows there can be stack or heap corruption or a call to 0xa.
Attached patch adds a function that checks for this limit and throws an error if it is reached. Also adds some documentation.
Test parameters that trigger this issue:
AUDIO_U16MSB with 224 channels at 46359 Hz
V
AUDIO_S16MSB with 6 channels at 27463 Hz
The fuzzer program I uploaded in bug 3667 has more of them.
|
|
22c221f3
|
2017-06-11T22:30:58
|
|
linux: Changed internal functions to be static.
|
|
5b75e903
|
2017-06-11T22:30:49
|
|
directfb: Fixed comment.
|
|
fbd30c36
|
2017-06-11T22:30:39
|
|
Fixed missing error messages for SDL_GetWindowWMInfo().
|
|
c609d856
|
2017-06-11T22:30:24
|
|
directfb: Fixed crash if creating renderer.
SDL_GetWindowWMInfo() currently expects SDL to be 2.0.6 but SDL is still 2.0.5.
|
|
3c955d05
|
2017-06-11T00:50:26
|
|
syswm: prevent buffer overflow if SDL and app have different config headers.
This only affects Wayland and DirectFB, as a Unix system generally has X11
support. Other platforms also have different sizes for the C union in
question, but are likely the only target for that platform, etc.
Apps that might run on Wayland or DirectFB will need to be compiled against
new headers from an official 2.0.6 release, or be prepared to force the x11
target, or not use SDL_GetWindowWMInfo().
Fixes Bugzilla #3428.
|
|
bb100d3b
|
2017-06-10T21:29:37
|
|
Expose display refresh rate on iOS/tvOS 10.3+.
|
|
325330ef
|
2017-06-09T17:37:43
|
|
jack: removed accidental copy/paste.
|
|
58f08af4
|
2017-06-09T00:47:47
|
|
jack: added capture support.
|
|
c39fd577
|
2017-06-09T00:14:50
|
|
jack: Move jack_client_t into the audio device instead a global variable.
|
|
b65e0777
|
2017-06-08T22:20:49
|
|
jack: Remove BROKEN_MULTI_DEVICE code.
|
|
871d43a8
|
2017-06-08T22:40:09
|
|
Removed unused hint includes.
|
|
d9039f23
|
2017-06-08T13:27:58
|
|
jack: Initial shot at a JACK audio target.
http://jackaudio.org/
Fixes Bugzilla #2163.
(with several more commits following to improve this code.)
|
|
92889836
|
2017-06-06T14:06:40
|
|
Merged Eric Wing's overscan patch.
Fixes Bugzilla #2799.
|
|
6d661cab
|
2017-06-06T13:12:43
|
|
windows: Change the default on SDL_HINT_WINDOWS_DISABLE_THREAD_NAMING.
It's easier for Visual Studio users that want this information to turn it on
or live without it, than it is to explain why every debugger that isn't Visual
Studio crashes out here. Eventually SetThreadDescription() will be the thing
everyone uses anyhow.
Fixes Bugzilla #3645.
(and several others).
|
|
d8444877
|
2017-06-06T12:35:35
|
|
windows: Fix compiling of XInput code on newer MinGW installs.
Fixes Bugzilla #3609.
|
|
599d9ba1
|
2017-06-05T21:30:25
|
|
emscripten: listen for pointerlockchange events on the #document specifically.
|
|
4b47fa38
|
2017-06-04T23:15:47
|
|
Removed duplicate includes.
|
|
52b7d0eb
|
2017-06-04T23:15:27
|
|
android: Fixed missing error message for SDL_GetBasePath().
|
|
248410dd
|
2017-06-04T23:15:13
|
|
Fixed SDL_GL_SetSwapInterval() returning success on two unsupported platforms.
|
|
11289b76
|
2017-06-04T21:25:57
|
|
Android cmake build fixed to work with the official android gradle plugin
|
|
2113208d
|
2017-06-03T23:00:50
|
|
haiku: Fixed missing title bar for windows with decorations.
B_BORDERED_WINDOW_LOOK has a border but no title bar.
|
|
fc436a3a
|
2017-06-03T23:00:40
|
|
android: Moved internal function to new position.
It was grouped with functions for the public system header.
|
|
63b3e06f
|
2017-06-03T23:00:15
|
|
Corrected names of header file guards.
|
|
07b0df0a
|
2017-06-02T22:15:37
|
|
haiku: Changed internal variable to be static.
|
|
00394996
|
2017-06-02T22:15:12
|
|
Fixed crash if calling SDL_CreateShapedWindow() on unsupported platforms.
|
|
d4086e4a
|
2017-05-29T03:01:05
|
|
stdlib: added SDL_utf8strlen().
|
|
b135557d
|
2017-05-29T02:48:51
|
|
linux: Don't crash if fcitx support is requested but unavailable.
Fixes Bugzilla #3642.
|
|
a1faea98
|
2017-05-29T00:54:08
|
|
fcitx: removed incompatibly-licensed code.
|
|
29a047df
|
2017-05-29T00:51:38
|
|
Fixed whitespace code style.
|
|
1c5f483a
|
2017-05-29T00:51:02
|
|
linux: removed IBus_utf8_strlen(), use SDL_utf8strlen() instead.
|
|
fc510bd7
|
2017-05-28T21:50:47
|
|
nacl: Fixed crash if allocating memory for audio device failed.
|
|
7c5078d8
|
2017-05-28T21:50:37
|
|
qnx: Removed unnecessary check for available audio devices.
|
|
1e60ea76
|
2017-05-28T21:50:27
|
|
qnx: Removed unnecessary call to SDL_zerop() after SDL_calloc().
|
|
1b9dc599
|
2017-05-28T21:50:11
|
|
haiku: Fixed SDL_SetClipboardText() putting random data in clipboard.
|
|
de52dc29
|
2017-05-28T15:36:09
|
|
haiku: Correctly set keyboard focus (thanks, Kai!).
The message sent upon the window being activated or deactivated, to trigger
the call to SDL_SetKeyboardFocus was missing a mandatory parameter. So
keyboard focus was never properly set.
Fixes Bugzilla #3658.
|
|
643f1cb7
|
2017-05-28T07:14:11
|
|
power: Add Linux org.freedesktop.UPower D-Bus implementation.
Fixes Bugzilla #3485.
(I think.)
|
|
b3f94acb
|
2017-05-28T07:11:52
|
|
linux: Simplify D-Bus interface, remove lots of boilerplate.
|
|
191f578b
|
2017-05-28T07:08:10
|
|
linux: Make system D-Bus connection available (in addition to session).
|
|
e5918acf
|
2017-05-28T00:41:55
|
|
wasapi: properly report init failure if on pre-Vista version of Windows.
We really should change the Init interface to return 0 on success and -1 on
error, like everything else, to avoid this sort of confusion.
|
|
604a4b1b
|
2017-05-27T23:30:21
|
|
haiku: Fixed SDL_SetClipboardText() allocating too much memory and cutting text.
It allocated pointers instead of chars and passed a wrong size to SDL_strlcpy().
|
|
3639895e
|
2017-05-27T23:30:07
|
|
Removed unused errno includes.
|
|
6fbde875
|
2017-05-27T00:33:26
|
|
code style: wrap a single-statement if in braces.
|
|
3fbd21ce
|
2017-05-27T00:30:06
|
|
windows: msgboxes should specify a parent HWND if possible (thanks, Ismael!).
This lets them be properly modal.
Fixes Bugzilla #3650.
|
|
90ed3daa
|
2017-05-26T22:45:52
|
|
Changed messages about not recognized keys to include discourse link.
|
|
75931972
|
2017-05-26T22:45:40
|
|
emscripten: Fixed compiling on C89 compilers.
|
|
1e13d93f
|
2017-05-25T23:01:34
|
|
directfb: Changed internal function to be static.
|
|
189b5851
|
2017-05-25T23:01:16
|
|
android: Fixed parameter list in function definitions.
|
|
6c0aea42
|
2017-05-25T23:00:58
|
|
wayland: Fixed freeing memory of SDL_malloc() with plain free().
|
|
c66f0471
|
2017-05-25T23:00:43
|
|
Removed unused internal window shape functions.
|
|
a7fc2822
|
2017-05-24T19:56:59
|
|
audio: rename bsd target to netbsd.
Apparently this is no longer a generic BSD audio target, and hasn't been for
years, so rename it for NetBSD.
|
|
6844d92c
|
2017-05-24T13:28:13
|
|
coreaudio: we don't need to track number of allocated audio buffers anymore.
CoreAudio takes care of iterating through the buffers and freeing them now,
so we don't have to manage this ourselves.
|
|
fc4402e5
|
2017-05-24T13:25:31
|
|
coreaudio: Better handling of audio buffer queue management.
We don't fill buffers just to throw them away during shutdown now, we let the
AudioQueue free its own buffers during disposal (which fixes possible warnings
getting printed to stderr by CoreAudio), and we stop the queue after running
any queued audio during shutdown, which prevents dropping the end of the
audio playback if you opened the device with an enormous sample buffer.
Fixes Bugzilla #3555.
|
|
126e5a1d
|
2017-05-24T14:04:39
|
|
Emscripten: Prevent default on arrow keys
|
|
f839b209
|
2017-05-24T14:04:25
|
|
Emscripten: fixed incorrect conversion of touch motion events to mouse motion events
|
|
3fd35f6b
|
2017-05-24T01:28:03
|
|
coreaudio: looks like we need more like a 10ms buffer minimum, not 50ms.
|
|
793c788b
|
2017-05-24T00:12:22
|
|
coreaudio: dynamically allocate AudioQueueBuffers.
We need more than two buffers to flip between if they are small, or CoreAudio
won't make any sound; apparently it needs X milliseconds of audio queued when
it needs to play more or it drops any queued buffers. We are currently
guessing 50 milliseconds as a minimum, but there's probably a more proper
way to get the minimum time period from the system.
Fixes Bugzilla #3656.
|
|
bf8ccf08
|
2017-05-19T23:30:59
|
|
Removed redundant mouse clean up on quit for some platforms.
SDL_MouseQuit() already frees cursors and sets fields to NULL.
|
|
e889757b
|
2017-05-19T14:51:03
|
|
assert: Better Emscripten support.
(Better than nothing, that is.)
Fixes Bugzilla #3459.
|
|
8917f863
|
2017-05-19T12:54:17
|
|
assert: allow assertions to work on platforms without threads.
Partially fixes Bugzilla #3459.
|
|
91e6054b
|
2017-05-19T12:40:55
|
|
wasapi: don't mark capture devices as failed for AUDCLNT_S_BUFFER_EMPTY.
Fixes Bugzilla #3633.
|
|
02773811
|
2017-05-18T21:00:11
|
|
render: GL_DestroyRender() should activate first.
Otherwise, we might destroy a different GL context's resources.
|
|
cff9e5a8
|
2017-05-18T16:29:10
|
|
test: info now reports usable display bounds and DPI (thanks, Eric!).
Fixes Bugzilla #3652.
|
|
81ab6c98
|
2017-05-18T16:27:36
|
|
Patched to compile on Windows.
|