-
-
Notifications
You must be signed in to change notification settings - Fork 386
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update PS Vita touchpad ID after it has changed in SDL2 v2.30.7 #9307
Conversation
I've compiled a PS Vita build on my WSL using latest VitaSDK and tested on Vita3K emulator and touch (emulation) works good. |
Hi, @kazenoyouni! |
Pønytail from Discord has successfully tested this build on his PS Vita hardware. |
Also Pønytail has reported that he has about 40 seconds hang when he wants to start a new game for the first time after fheroes2 has launched - in Russian:
But I could not reproduce such hand on Vita3K emulator. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. The only change I made was to use a different device id value depending on the SDL version, so that everything works correctly with older SDL versions, if someone decides to use them.
Hi, @Districh-ru ! |
Well, it's hard to say what this is specifically related to. Apparently, I/O on a real device is much slower than on an emulator running on modern hardware, but it's hard to tell without a real device what exactly is so slow - whether getting a list of files via And how long did it take to get a list of maps before 1.1.3? |
I've asked Pønytail this question and he'll answer a little later. On my emulator I've disabled all CPU optimizations (adventure map scrolling with many objects on map gives maximum 15 FPS) and did not notice any lags in opening STANDARD GAME dialog. |
@Districh-ru , thank you very much for the fix! |
I/O becomes INCREDIBLY slow on Vita if there are 100+ files in one folder (and maps folder can have hundreds of them). The main bottleneck was in the I can make a PR that restores the optimization (if maintainers don't mind some platform specific code there), but I'll have to dust off my Vita first.. |
Hi @Northfear
I don't know how exactly
I just did this in #9310, so, if it builds, we can try :) |
Should be same as on other platforms (std::filesystem is implemented by gcc's libstdc++ and we don't touch that (yet). This, sadly, yields some issues with absolute/relative paths. This shouldn't be an issue for fheroes2, though) |
It appears, however, that enumerating directory entries using |
fix #9305
In SDL2 v.2.30.7 the touchpads IDs for PS Vita have been changed: libsdl-org/SDL#10537
Unfortunately, the change was done not in all the code and the front touch do not work in the current release version of SDL2 yet. :(
But a fix has already been made for the future version of SDL2: libsdl-org/SDL#11442
It's good that the VitaSDK developers forced the specified fix: vitasdk/packages#324
and everything should work fine after we update the ID for touchpad.