Commit Graph

386 Commits

Author SHA1 Message Date
Serena
070194ef92 fix on other platforms 2023-02-06 22:34:27 +03:00
Serena
6d474ac59d macOS bar button items 2023-02-06 22:17:27 +03:00
Henrik Rydgård
ce40744cdd
Merge pull request #16874 from SerenaKit/serena/darwin-browse-button
Browse button on Darwin platforms, rename some classes/functions
2023-02-01 17:21:53 +01:00
Serena
482e989cd7 convert to System_SendMessage insanity 2023-02-01 19:03:12 +03:00
Henrik Rydgård
c8dce81ff0
Merge pull request #16156 from hrydgard/opengl-thread-refactor
OpenGL threading refactor
2023-01-31 11:14:01 +01:00
Henrik Rydgård
b97749d623 Assorted initialization cleanup and similar, found by valgrind and warnings 2023-01-30 18:31:49 +01:00
Henrik Rydgård
cb16f193ec Fix the problem. Still need to leave the loop with SDL even if we supply a swap function. 2023-01-30 15:45:05 +01:00
Henrik Rydgård
b62572a78f Refactor the framedata/GPU thread management. 2023-01-30 11:49:31 +01:00
Henrik Rydgård
ece6edfe83 SDL audio: Let's try 256 for fmt.samples. See issue #12705 2023-01-17 11:45:35 +01:00
Henrik Rydgård
7fcd8a254f
Merge pull request #16506 from xuzhen/master
Fix the Qt/SDL window icon path
2022-12-09 11:56:35 +01:00
iota97
d5d0e2c920 Fix SDL fullscreen 2022-12-09 09:28:28 +01:00
Xu Zhen
abb4aa92f1 Fix window icon path 2022-12-06 23:17:35 +08:00
Henrik Rydgård
4af4b0dddc
Merge pull request #16255 from catsout/fix-gl-wayalnd
SDL: fix glew on wayland by ignore glx
2022-10-18 15:42:08 +02:00
catsout
83fccd0835 SDL: fix glew on wayland by ignore glx
glXGetProcAddress works on wayland if linking with x11.
As long as we don't use glx related funcs,
no_glx_error can be ignored.
SDL should handle the no_glx_error brefore glewInit.
Glew is only used to init gl funcs.

related:
https://github.com/nigels-com/glew/issues/172
2022-10-18 20:49:27 +08:00
catsout
b0ceeede79 Vulkan: fix wayland swapchain size 1x1
From Vulkan spec,
surfaceCapabilities.currentExtent can be 0xFFFFFFFF(-1)

Define a callback to get drawsize from window creator

relate:
https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkSurfaceCapabilitiesKHR.html
https://github.com/KhronosGroup/Vulkan-Docs/issues/590#issuecomment-347932321
2022-10-15 19:02:42 +08:00
Henrik Rydgård
b0cf97cf4d Touchpad/mousewheel scrolling acted very weirdly on Mac due to 0 deltas. Make it work better.
Ignoring the 0 deltas helps a lot for the feel, even though it still isn't that smooth feel yet.
2022-10-11 14:00:46 +02:00
Henrik Rydgård
6f703128ec Experimentally revert "Delete some misguided FPU control code, that we definitely don't want"
This reverts commit d52d383c22.
2022-10-10 18:35:29 +02:00
Henrik Rydgård
d52d383c22 Delete some misguided FPU control code, that we definitely don't want 2022-10-10 10:46:51 +02:00
Henrik Rydgård
242efba6f7 Remove splitSubmit setting. Now we submit init commands before the acquire. 2022-09-17 01:07:30 +02:00
fp64
5b6a14edeb Add a newline to "Leaving main" message.
Also implement SYSPROP_DISPLAY_XRES/SYSPROP_DISPLAY_YRES for SDL.
Also fix couple of warnings.
2022-08-16 18:29:14 -04:00
Henrik Rydgård
a831cab14c
Remove unmotivated check preventing texture ini creation on mobile. (#15647)
* Remove unmotivated check preventing  texture ini creation on mobile.

Fixes #15644

* Show a "toast" message on platforms that don't support opening a text editor, when you try to create/open a texture ini file.

* Avoid the need to ifdef around calls to SystemToast

* UWP buildfix (and some warning fixes).

And possibly libretro fix

* Rename for a bit more consistency
2022-07-10 22:34:44 +02:00
Unknown W. Brackets
536c050943 Core: Track names of connected pad devices.
Rather than just that it's a pad.  This tries to get the identifier if
possible.
2022-07-04 19:14:04 -07:00
Unknown W. Brackets
3edf6ab0fa Config: Don't save --fullscreen unless changed.
This makes --fullscreen and --windowed temporary by using a separate
setting.  If the setting is changed explicitly, it begins saving it again.
2022-05-28 15:47:12 -07:00
Henrik Rydgård
0eea0acf13
Merge pull request #15468 from unknownbrackets/switch-merge
Cleanup Switch ignoring of Vulkan
2022-04-08 14:48:04 +02:00
Unknown W. Brackets
170441313c Net: Ignore SIGPIPE errors on POSIX systems.
This should work on BSD/macOS/Linux/iOS/similar.
2022-04-03 06:57:45 -07:00
Unknown W. Brackets
b71f17586e Switch: Avoid loading Vulkan. 2022-04-02 16:34:13 -07:00
Unknown W. Brackets
2479d52202 Global: Reduce includes of common headers.
In many places, string, map, or Common.h were included but not needed.
2022-01-30 16:35:33 -08:00
Cameron Cawley
26203552b4 Use System_GetPropertyInt to report the keyboard layout 2022-01-10 00:11:08 +00:00
Unknown W. Brackets
7e578b31f5 Build: Remove old-style android/assets/.
We now read everything directly from assets/, so there's no need for
outdated duplicates.

Also cleanup some outdated files/instructions.
2021-12-11 09:01:15 -08:00
Unknown W. Brackets
f8e50b1dc7 SDL: Respect inflight frames setting in GL. 2021-11-27 06:57:26 -08:00
vit9696
1066224b6f SDL: Read assets from Resources on macOS like on iOS
closes #15041
2021-11-06 09:22:08 +03:00
Unknown W. Brackets
690c6b6765 macOS: Correct open memstick with space. 2021-10-19 21:26:37 -07:00
Unknown W. Brackets
8d29aa6590 Windows: Switch to preferred file selection method.
It seems like the previous may not support long paths.
2021-10-19 10:01:27 -07:00
Unknown W. Brackets
08a55d19d5 macOS: Allow opening game folder. 2021-10-19 10:01:27 -07:00
vit9696
82249ce9a7 Update SDL and try faster commit history fetch 2021-09-17 00:33:11 +03:00
vit9696
e1cb1c9a67 Switch to submodules and fix release version generation 2021-09-16 10:40:39 +03:00
vit9696
5fc7344271 Drop bundled SDL2 for macOS 2021-09-16 10:17:59 +03:00
vit9696
14c2231500 Add FAT support for macOS with automatic GitHub releases
closes #11799
closes #13708
closes #14815
2021-09-13 02:01:22 +03:00
Yifan Gu
633a6f612b Refactor and unify analog input settings 2021-07-05 12:38:46 +02:00
Unknown W. Brackets
af3d699d5e SDL: Ignore commas in joystick names.
Otherwise default mapping will break and parse wrong.
2021-05-21 09:13:15 -07:00
Henrik Rydgård
f4a6d291e1 Common: Capitalize setCurrentThreadName(). 2021-04-30 23:02:36 -07:00
Henrik Rydgård
6a3856674c SDL: Fix use after free on shutdown 2021-03-11 23:13:57 +01:00
Unknown W. Brackets
13ec384dbe Build: Explicitly include ppsspp_config.h.
This adds it to all files that use it.  Not all our builds include the
file.
2021-03-02 21:04:03 -08:00
Henrik Rydgård
bd7b283399 Add iOS version detection, turn off JIT on bootup if >= 14.3. 2021-02-22 09:16:51 +01:00
Unknown W. Brackets
8f452fee23 SDL: Init profiler on SDL/Qt. 2021-02-18 22:59:56 -08:00
Henrik Rydgård
6d0315eaf9 Fix copy/paste typo causing crash getting tempdirs if an env var had no value 2021-01-10 20:33:17 +01:00
Unknown W. Brackets
eee529c6c9 UI: Cleanup Windows header in MainScreen.cpp.
Better to have this come from System, probably.  It's mainly for Windows
anyway, to alert people their save data isn't permanent.
2021-01-09 14:45:49 -08:00
Henrik Rydgård
1c753e4a22 Use hacky methods to retrieve SD card directory if available.
This will disappear in future Android versions but can be useful for
older devices.

Fixes (or at least tries to) #10199, at least for some devices.

Might help #13827 ?

Tested on Pocophone F1.
2021-01-07 00:55:35 +01:00
Henrik Rydgård
f0ea814107
Merge pull request #13515 from dos1/touch
SDL: Implement multitouch support
2020-10-06 20:47:11 +02:00
Henrik Rydgård
44a93f98ed SDL: Apply patch from issue #13516, fixing issue with Wacom tablets with readonly flags set. 2020-10-06 16:58:32 +02:00
Sebastian Krzyszkowiak
99d0df0784
SDL: Implement multitouch support
Pass proper touch events instead of merely emulating a mouse. Also,
disable SDL's built-in mouse emulation (added in SDL 2.0.10).

Signed-off-by: Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>
2020-10-06 04:51:36 +02:00
Henrik Rydgård
0e3a84b4a8 Move most GPU things to Common.
It works after the move, on Windows and Android at least.

Deletes the D3DX9 shader compiler loader, which was not used.
2020-10-04 23:39:02 +02:00
Henrik Rydgård
4f43cff5ca
Move fileutil, net, image loaders, ui to Common. (#13506)
* Move and rename file_util/fd_util to Common/File/FileUtil and DirListing

Let's also move net while we're at it.

Move the ZIM/PNG loaders over to Common.

Move the UI framework into Common

iOS buildfix

* Buildfix

* Buildfixes

* Apple buildfix

* This typo again..

* UWP buildfix

* Fix build of PPSSPPQt, such as it is (it's not in good condition...)

* Guess what? Another buildfix.
2020-10-04 20:48:47 +02:00
Henrik Rydgård
f01ba6dc84 Move NativeApp.h to Common/System, split into NativeApp.h and System.h
Buildfix
2020-10-04 11:42:16 +02:00
Henrik Rydgård
b7edf75437 Move Display.cpp/h to Common. 2020-10-04 11:42:16 +02:00
Henrik Rydgård
9e41fafd0d Move math and some file and data conversion files out from native to Common.
Buildfixing

Move some file util files

Buildfix

Move KeyMap.cpp/h to Core where they belong better.

libretro buildfix attempt

Move ini_file

More buildfixes
2020-10-04 09:12:46 +02:00
Henrik Rydgård
ff8148dd92 Move native/util, native/data and native/i18 to Common/Data.
Also move colorutil.cpp/h

linking build fix experiment

Delete a bunch of unused CMakeLists.txt files

CMakeLists.txt linking fix

Don't include NativeApp.h from any headers.

Android.mk buildfix

Half of the UWP fix

Buildfix

Minor project file cleanup

Buildfixes

Guess what? More buildfixes!
2020-10-04 07:28:29 +02:00
Henrik Rydgård
342ed97291 Move input utilities from native to Common/Input. 2020-10-01 09:42:32 +02:00
Henrik Rydgård
15382d5f94 Move threading utils from native to Common 2020-10-01 09:27:25 +02:00
Henrik Rydgård
0d3a5a27aa
Merge pull request #13485 from unknownbrackets/minor
Adjust locale parsing for Ubuntu and fix memory assert
2020-09-27 23:31:26 +02:00
Unknown W. Brackets
ab953603d8 SDL: Adjust locale parsing for Ubuntu.
Technically, the format of this value is unspecified, but we are just
trying to guess the user's locale.

See #13042.
2020-09-27 12:55:02 -07:00
Henrik Rydgård
054acf768c Don't cache time in a variable.
A little weirdness in the code that has stuck around for a long, long
time. It's really not necessary and mostly just confusing.
2020-09-24 23:52:43 +02:00
Henrik Rydgård
5d64fc5ff1 Switch to PPSSPP's assert functions (don't use the system's) 2020-08-16 10:01:10 +02:00
Henrik Rydgård
ccc0331279 Move timeutil to Common. (Experiment to see how much work it is to move these). 2020-08-15 20:53:08 +02:00
Henrik Rydgård
80e0f85332 Getting really close to getting rid of base/logging.h now.
Qt buildfix
2020-08-15 19:09:01 +02:00
Henrik Rydgård
b22083e7a6 Even more base/logging.h removal and fixes 2020-08-15 19:09:01 +02:00
Henrik Rydgård
c41f875df4 Remove base/logging.h in a whole lot more places. 2020-08-15 19:09:00 +02:00
Henrik Rydgård
14532847c7 Fix some minor issues found by address-sanitizer on Linux 2020-08-11 22:28:36 +02:00
Henrik Rydgård
6560192d8e Support full VSync control in SDL OpenGL.
(Not yet Qt).

Forgot about iOS

SDL headless buildfix

Additional iOS buildfix
2020-07-19 12:07:16 +02:00
Henrik Rydgård
49d9caeb0d SDL: Avoid destroying the surface on resize. 2020-07-18 20:40:20 +02:00
Henrik Rydgård
697c3b8b36 Cleanup log output on swapchain/surface recreation. 2020-07-18 20:35:39 +02:00
Henrik Rydgård
3691cc990f
Merge pull request #13052 from hrydgard/sdl-resize-fixes
Partly clean up SDL resize code, should help #11974
2020-06-24 01:36:38 +02:00
Henrik Rydgård
f9cef5b6b2 Partly clean up SDL resize code, should help #11974 2020-06-24 01:06:01 +02:00
Henrik Rydgård
7180c2a4c2 Enable Vulkan validation in SDL debug builds 2020-06-23 21:57:02 +02:00
Henrik Rydgård
8b98047502 Finish the Linux part of this change 2020-06-22 00:54:51 +02:00
Henrik Rydgård
3d743a5ae7 Buildfixes 2020-06-22 00:01:31 +02:00
Henrik Rydgård
6532c345c8 Simplify the validation interface code, bugfixes 2020-06-21 23:04:51 +02:00
Unknown W. Brackets
b46bf8e4e7 SDL: Try to continue if EGL init fails.
Probably we should just stop using EGL on SDL2, but I'm not sure if
that's making things work for some users.  But if EGL init fails, try
to avoid a segfault and skip EGL.

Should help #12474.
2020-05-23 16:26:47 -07:00
Henrik Rydgård
2b605f1370
Merge pull request #11876 from AreaScout/master
Fix: touchscreen evens on upcomming SDL2 versions which includes the …
2020-05-17 18:35:39 +02:00
Henrik Rydgård
3f74ffbdf5 Reduce the SDL audio buffer size, 2048 is a bit excessive. Port the changes to the Qt SDL code. 2020-05-17 11:50:34 +02:00
Henrik Rydgård
06c22497b7 SDL: If we get an audio device with a different freq than 44100, that's actually OK. 2020-05-17 10:21:02 +02:00
Henrik Rydgård
b6a051dd49 Fix comment 2020-05-16 19:47:12 +02:00
Henrik Rydgård
caf8e5496d SDL: Show the actually used sample rate in system info.
Right now it'll always be the requested 44100 though anyway.
2020-05-16 17:46:21 +02:00
Florin9doi
bc948b9b94 iOS/macOS : set bundle version 2020-05-01 21:36:55 +03:00
AreaScout
e673d74646 Fix: touchscreen evens on upcomming SDL2 versions which includes the same functionality but inside the library 2020-04-27 10:31:21 +00:00
Unknown W. Brackets
fd0bf21215 Windows: Prevent applying -1 as inset space. 2020-04-05 17:06:36 -07:00
M4xw
fe32ad88fb Core: Add some libnx calls for Switch. 2020-03-15 07:56:38 -07:00
Henrik Rydgård
875d53a485
Merge pull request #12612 from iota97/sdl-mouse
SDL analog mouse input
2020-03-05 17:23:08 +01:00
iota97
80effb6b68 Let's wait 5 frames 2020-03-05 16:36:26 +01:00
iota97
b8ce079829 Fix wheel up/down and additional mouse button 2020-03-05 15:57:45 +01:00
Unknown W. Brackets
cb1b7b1e43 Core: Bring over some file related Switch changes.
Reducing the distance from the Switch port code.
2020-03-03 22:53:03 -08:00
iota97
b0307301e3 Better smoothing and added missing break on MOUSE_WHEEL 2020-03-03 17:17:58 +01:00
iota97
fc1b83fd93 Fixes 2020-02-04 09:54:01 +01:00
iota97
3248d58c4d Switch mode only if needed 2020-02-04 07:47:02 +01:00
iota97
4b28482479 SDL analog mouse input 2020-02-04 05:11:07 +01:00
李通洲
55bb58e13e
NativeApp: add System_GetPropertyFloat all the places 2020-02-04 09:20:34 +08:00
Florin9doi
c824fabd53 Update macOS system name 2020-01-25 16:54:45 +02:00
Henrik Rydgård
1d6d66ac43
Merge pull request #12582 from Florin9doi/sdl_app_icon
SDL app icon
2020-01-24 15:27:10 +01:00
李通洲
a34d35d705
Add support for iOS ( completely untested ) 2020-01-20 14:43:08 +08:00
李通洲
7cd60549dd
Initial support for vulkan on macOS ( MoltenVK ) 2020-01-20 14:42:40 +08:00
Florin9doi
24a8077616 SDL app icon 2020-01-17 21:05:59 +02:00
Unknown W. Brackets
9989c51f21 SDL: Ignore audio switch events in first second.
We get new device events right on start, which makes auto switch away from
the preferred / most recent device otherwise.  Fixes #12536.
2020-01-01 07:47:26 -08:00
Unknown W. Brackets
a1ee226c39 SDL: Switch audio device when plugged in. 2019-10-07 20:16:20 -07:00
Unknown W. Brackets
c30bc4ee7d SDL: Add UI to reset audio device at runtime. 2019-10-07 20:16:19 -07:00
Unknown W. Brackets
8751316051 SDL: Use a configurable output device. 2019-10-07 20:15:25 -07:00
Unknown W. Brackets
141258c366 SDL: Use SDL2 audio API for output. 2019-10-07 20:15:25 -07:00
Unknown W. Brackets
daf07032a6 cmake: Ignore if madbundle.sh fails. 2019-10-07 20:15:25 -07:00
Conn O'Griofa
18edfefa0a SDL: ensure swap interval is set correctly for SDL2 kmsdrm driver
It appears that SDL2's kmsdrm driver ignores the swap interval setting
if the SDL context has not yet been created. Moving the call to after context
creation allows it to work as expected.

Fixes vsync when running ppsspp in a KMS context using the SDL2 kmsdrm driver
(which is especially useful for Raspberry Pi 4 B, but is also needed for other
systems including Raspberry Pi 3B via firmware KMS & Intel Haswell i965 via
KMS on x64).
2019-10-03 07:40:19 +01:00
Henrik Rydgård
63305d5248 SDL: Add back a couple of lines that should have been copied, not deleted. Thanks [Unknown] 2019-09-01 23:00:53 +02:00
Henrik Rydgård
7610220b30 Vulkan: Prepare for adding a second init path for VulkanContext.
Will eventually be used for libretro.
2019-09-01 22:21:19 +02:00
Henrik Rydgård
1d46f40634 SDL/Vulkan: Fix scale problems when maximizing/restoring the window. 2019-09-01 16:22:29 +02:00
Cameron Cawley
ba7ea39a1c Move NKCodeFrom*.h into the relevant platform folders 2019-08-06 16:12:19 +01:00
Unknown W. Brackets
54a393386f SDL: Use whatever display SDL gives us for EGL. 2019-07-06 12:33:37 -07:00
hissingshark
58b473a64c Fix build error 2019-06-11 12:52:05 +01:00
Unknown W. Brackets
edbefa8ee2 SDL: Adjust EGL config choice heuristics.
See #12049:
 * Require EGL_WINDOW_BIT more strongly.
 * Allow EGL_NON_CONFORMANT_CONFIG (but still not EGL_SLOW_CONFIG.)
2019-06-10 17:43:16 -07:00
Silent
bb2ba8086b
Improved Show in Folder:
- Not spawning cmd.exe anymore, rather using the same way Chromium does to spawn a shell window with a file focused
- Hid a nonfunctional "Show In Folder" button for UWP builds
2019-05-23 19:59:08 +02:00
Cameron Cawley
427d5f821e SDL: Implement clipboard support 2019-05-15 22:29:40 +01:00
Unknown W. Brackets
f042dc1773 SDL: Make it clear Vulkan check is not an error. 2019-03-23 08:32:51 -07:00
Unknown W. Brackets
3e4faea6ad cmake: Automatically disable Wayland for Raspbian.
Also add a shortcut to b.sh since it has its own toolchain file.
2019-03-23 08:25:39 -07:00
Unknown W. Brackets
ff9911deb5 SDL: Fix compile error when not using FBDEV. 2019-03-23 07:26:47 -07:00
Henrik Rydgård
d7f3f15b85 Add missing line to SDL EGL init (no way this path could have worked anywhere?) 2019-02-27 11:26:31 +01:00
Henrik Rydgård
e715fe0382 EGL errors should cause us to bail. Also downweight alpha in the EGL config chooser. See #11839 2019-02-27 10:33:36 +01:00
Henrik Rydgård
b8e56b361e EGL: Avoid HDR mode. Uses unknownbrackets' changes from #11839. 2019-02-26 08:57:51 +01:00
Henrik Rydgård
58c240045e Make window resize work with Vulkan. Seems more stable now. 2019-02-23 15:53:05 +01:00
Henrik Rydgård
4c83d30b59
Merge pull request #11831 from vit9696/macbuild
Bundle libSDL inside app on macOS, fixes #11830
2019-02-23 14:32:56 +01:00
vit9696
2ccd0156f5 Bundle libSDL inside app on macOS, fixes #11830 2019-02-23 14:15:17 +03:00
Henrik Rydgård
24510b8187 SDL/Qt: At least quit properly when switching backends 2019-02-23 11:55:34 +01:00
Unknown W. Brackets
556b17503b SDL: Allow PauseWhenMinimized to work.
Essentially fixes #6276, see also #10445 and its fix.
2019-02-18 05:29:38 -08:00
Unknown W. Brackets
bba008f162 Qt: Cleanup indentation.
Also some NULL -> nullptr.  No actual code changes.
2019-02-18 05:00:28 -08:00
Henrik Rydgård
aa47db846c
Merge pull request #11806 from unknownbrackets/sdl-fbdev
SDL: Force fullscreen desktop for USING_FBDEV
2019-02-17 17:14:14 +00:00
Unknown W. Brackets
555a8db335 SDL: Force fullscreen desktop for USING_FBDEV. 2019-02-17 06:27:41 -08:00
Unknown W. Brackets
dfc75e8c34 SDL: Prevent mouse capture on macbook trackpad. 2019-02-17 04:54:21 -08:00
Henrik Rydgård
7ccf23542d Fix SDL build 2019-01-26 12:03:20 +01:00
Unknown W. Brackets
adeca2c3ba GLES: Move some vendor bug checks to Draw. 2018-12-23 20:27:22 -08:00
orbea
2bbe0d7e65 SDL: Allow toggling fullscreen for GLES2 on desktops.
Fixes https://github.com/hrydgard/ppsspp/issues/11627
2018-12-02 20:03:54 -08:00
AreaScout
57bf9e3048 Add: allow touch screen events on fullscreen 2018-09-16 07:11:15 +00:00
AreaScout
1fb111c2bb Add: Touchscreen event support for SDL2 2018-09-08 07:15:31 +00:00
AreaScout
c6c66e7608 Add: Get user-preferred locale from OS (linux only) 2018-09-01 16:43:37 +00:00
Unknown W. Brackets
b4496f1975 Core: Move config enums to separate file.
These are a bit strewn about and there are constants that aren't
consistently used, which just adds confusion.
2018-06-23 10:59:18 -07:00
Unknown W. Brackets
1b41759051 SDL: Avoid alpha on Mali/ARM devices using GLES.
See #10534.
2018-06-16 16:19:17 -07:00
hissingshark
84273ff5eb SDL: Buildfixes for EGL lookup. 2018-06-16 16:12:43 -07:00
Unknown W. Brackets
3b8a847654 SDL: Allow more EGL configs.
This attempts to choose the "best" config using weights.
2018-06-16 16:12:43 -07:00
Unknown W. Brackets
9be20323ef SDL: Start with window hidden.
This fixes start in fullscreen on Mac.  Otherwise, it animates to
fullscreen and back for every GL init attempt.
2018-06-09 16:57:00 -07:00
Unknown W. Brackets
34cef82ea3 SDL: Use UpdateScreenScale(). 2018-06-09 16:50:31 -07:00
Unknown W. Brackets
0345750500 SDL: Fix EGL build. 2018-06-06 05:36:01 -07:00
Unknown W. Brackets
a7023ac542 SDL: Move EGL init code into SDLGLGraphicsContext.
It should really be cleaned up, but I'm not sure if EGL_Open can be
moved later and don't currently have a setup to test, so I'm just
cargo culting.
2018-06-05 23:02:50 -07:00
Unknown W. Brackets
78a41980df SDL: Use fullscreen for mobile/GLES.
Also, allow resize for Vulkan outside mobile.

Thanks go to hissingshark.
2018-06-05 20:40:58 -07:00
Unknown W. Brackets
f2a75719d8 SDL: Properly try multiple GL versions.
Thanks go to hissingshark.
2018-06-05 20:40:50 -07:00
vnctdj
3f4bfddafc Allow showing version only for SDL 2018-05-09 21:22:47 +02:00
Henrik Rydgård
0130e75852
Merge pull request #10801 from unknownbrackets/sdl-shutdown
Fix shutdown segfault in SDL, fix headless
2018-03-26 21:10:48 +02:00
Unknown W. Brackets
0d10bb8515 SDL: Fix shutdown ordering.
This fixes the segfault on quit.
2018-03-25 14:19:02 -07:00
Unknown W. Brackets
7abf9baf38 SDL: Use wstrings in Windows API calls. 2018-03-25 14:18:31 -07:00
Henrik Rydgård
043ba41b08 PPSSPPSDL: Throttle refresh rate when in menu. Fixes #10445 2018-03-25 15:34:01 +02:00
aliaspider
54d9406713 fix mingw and msvc cmake builds. 2018-03-23 03:18:13 +01:00
Henrik Rydgård
4b4a2a4096 Buildfixes 2018-02-25 11:25:16 +01:00
Unknown W. Brackets
cdf378d20c GLES: Prevent race condition on shutdown.
emuThreadState might become STOPPED before the last frame has been run,
which can cause WaitUntilQueueIdle to hang.

It's simpler just to wait until StopThread() is called, since it now is.
This will line up properly with run_.
2018-02-11 11:40:11 -08:00
Unknown W. Brackets
a85a88e112 SDL: Apply shutdown race condition fix. 2018-02-10 16:55:50 -08:00
Henrik Rydgård
d9af90e016 SDL: Fix issue with vulkan-to-opengl fallback 2018-02-10 09:09:13 +01:00
Henrik Rydgård
4d6c0cfb32 Buildfix 2018-02-08 01:11:51 +01:00
Henrik Rydgård
ae19c48138 Cleanup the Windows thread stuff to work like the other platforms. Not quite perfect yet. 2018-02-07 16:00:29 +01:00
Henrik Rydgård
b3a09791b1 SDL: Fix emuthread management to exit cleanly without hanging. 2018-02-07 12:22:19 +01:00
Henrik Rydgård
020eb9d86c Fix further memory leaks 2018-02-04 13:42:04 +01:00
Henrik Rydgård
79d1610148 Move SDLGLGraphicsContext.h to the correct location. Minor cleanup 2018-02-04 13:42:04 +01:00
Henrik Rydgård
99386da01e Minor cleanups 2018-02-04 13:42:04 +01:00
Henrik Rydgård
85446d6c51 Split the SDL graphics contexts into their own files. 2018-02-04 13:42:04 +01:00
Henrik Rydgård
c16e397fc6 SDL: NativeInitGraphics/NativeShutdownGraphics should run on the emu thread. 2018-02-04 13:42:04 +01:00
Henrik Rydgård
583c20991f Qt: Some cleanup and fixes. Still not working correctly with gl-render-manager. 2018-02-04 13:42:04 +01:00
Unknown W. Brackets
56a18907dd SDL: Oops, only start the emu thread for GLES.
Probably would've caused issues (at least weird vsync) for Vulkan.
2018-01-27 15:10:17 +01:00
Unknown W. Brackets
062566b67c Core: Set thread names when possible.
This doesn't seem to be working for lldb, though.
2018-01-27 15:10:17 +01:00
Unknown W. Brackets
59904c316b SDL: Allow running GL on thread.
Tested on a Mac.
2018-01-27 15:10:17 +01:00
Unknown W. Brackets
766b40aad8 GPU: Reset GPUBackend on graphics init.
This way, when using a port that doesn't support Vulkan, it doesn't just
silently use upside down GL, etc.
2017-12-26 16:02:55 -08:00
Unknown W. Brackets
d6da758ed3 GPU: Remove duplicate BACKEND constants. 2017-12-26 15:55:24 -08:00
Greg V
f3783bdb44 Add support for Vulkan on Wayland 2017-12-26 16:09:27 +03:00
Jan Beich
d4984ab991 SDL: unbreak on more non-Vulkan platforms
SDL/SDLMain.cpp:160:2: error: unknown type name 'SDL_SysWMinfo'; did you mean 'SDL_SysWMmsg'?
        SDL_SysWMinfo sysInfo; //Will hold our Window information
        ^~~~~~~~~~~~~
        SDL_SysWMmsg

SDL/SDLMain.cpp:433:2: error: unknown type name 'SDL_SysWMinfo'; did you mean 'SDL_SysWMmsg'?
        SDL_SysWMinfo sys_info{};
        ^~~~~~~~~~~~~
        SDL_SysWMmsg

SDL/SDLMain.cpp:440:2: warning: expression result unused [-Wunused-value]
        Window x11_window = sys_info.info.x11.window;
        ^~~~~~
2017-12-21 21:31:26 +00:00
Henrik Rydgård
fe45a059b5 SDL: Fix OpenGL init again. Fixes #10424 2017-12-21 17:36:00 +01:00
Henrik Rydgård
f73ec4608e Build Vulkan on all platforms, won't be used if not supported. 2017-12-21 14:13:55 +01:00
Henrik Rydgård
9007abddbf Get Vulkan going on Linux 2017-12-21 11:02:11 +01:00
Henrik Rydgård
7f758d52dc Statically link a vulkan loader on Linux. Use to to init vulkan on X11. Unfortunately, it's broken. 2017-12-21 11:02:11 +01:00
Henrik Rydgård
6d6ad3ed14 Cleanups in PCMain.cpp 2017-12-21 10:52:48 +01:00
Henrik Rydgård
ea387b2a48 WIP vulkan on linux stuff 2017-12-21 10:48:00 +01:00
Conn O'Griofa
d67d201681 SDL: really try lower GL profiles & add GLES context support
* When compiled with USING_GLES2, attempt to use only valid ES context
  versions.
* Ensure that lower profiles are attempted correctly rather than
  prematurely returning from the function after the first failure.

Needed for Raspberry Pi to successfully launch.
2017-12-20 16:28:53 +00:00
Henrik Rydgård
740d0504ad Move QtMain.cpp and PCMain.cpp to more sensible locations. Native isn't standalone anymore... 2017-12-19 18:04:26 +01:00
Neil Munday
ac0052c6af Added default control pad mapping for control pads not found in SDL's game controller database file. 2017-10-03 22:08:29 +01:00
Henrik Rydgård
4491c7e2ca Quick hack to enable analog stick sensitivity on non-windows platforms.
See #8028
2017-05-18 15:15:10 +02:00
Henrik Rydgård
1b699363ca Load SDL's gamecontrollerdb from assets directory, not relative to exe. Fixes #9460.
Also remove support for that env variable.
2017-03-21 15:54:39 +01:00
ASL97
14187f9311 Allow background joystick input on SDL 2017-02-23 05:18:21 +08:00
zhyk
0629054783 Do not create thread to handle SDL joystick events in Qt build.
Caused crashes on MacOS Sierra (10.12).
2017-02-01 14:37:36 +08:00
Henrik Rydgård
052660bc8c Merge pull request #9260 from neilmunday/master
Added ability for the user to override the location of the SDL game controller db file
2017-01-31 08:52:55 +01:00
Neil Munday
b058b987ad Added ability for the user to override the location of the SDL game controller db file. 2017-01-30 20:26:24 +00:00
Bigpet
d6b8123662 add left and right thumbstick button handling in SDL gamepad. 2016-11-20 18:50:06 +01:00
Neil Munday
182b9e0fda Various improvements including finding the assets directory properly. 2016-09-20 21:50:45 +01:00
Neil Munday
e4a0a3cea3 Updated SDL2 game controller mods following feedback from PPSSPP authors. 2016-09-20 00:28:28 +01:00
Neil Munday
db2cc49e0d Modified SDL2 code to make full use of SDL2's Game Controller API. 2016-09-18 23:23:36 +01:00
Neil Munday
67425d7d47 Initial attempt at adding SDL's game controller database to PPSSPP. 2016-09-18 00:33:28 +01:00
Kelly Youngblood
5adaa12260 Adds auto-detection for PS3 cocntroller. 2016-09-03 21:14:44 -05:00
Kelly Youngblood
06d594b3ff Code cleanup 2016-09-03 00:20:18 -05:00
Kelly Youngblood
7d191ccc11 Adds --PS3 flag for PS3 controllr support on SDL. 2016-09-03 00:15:25 -05:00
chrisbrasington
988e082478 fix indentation 2015-12-21 16:27:33 -07:00
chrisbrasington
ea809425b6 split SDLJoyButtonMap for MacOSX and linux. Mapping in else statement was tested on linux with a X360 and wii-u pro controller 2015-12-21 15:48:22 -07:00
chrisbrasington
cbda8cf957 adds missing button for wii-u pro gamepad, right-DPAD. NKCODEs are still mismatched in linux (360 controller and wii-u pro gamepad), but they were not changed to so that a user's controls.ini will load correctly. 2015-12-21 15:03:14 -07:00