Commit Graph

3357 Commits

Author SHA1 Message Date
Valdis Bogdāns
f9ab6c48e3 Ime fixes (#3399)
* Changes
-Added support for OrbisImeParamExtended (extended IME parameters) in ImeHandler, ImeState, and ImeUi
-Updated all relevant constructors and logic to propagate and store the extended parameter
- Now fully supports passing extended options from sceImeOpen to the IME UI and backend

* Potential CUSA00434 [Debug] <Critical> assert.cpp:30 assert_fail_debug_msg: Assertion Failed!
buf_len + 1 <= buf_size && "Is your input buffer properly zero-terminated?" at C:/VS/shadPS4-ime-fixes/externals/dear_imgui/imgui_widgets.cpp:4601 fix

* Attempting to resolve an assertion failure in Diablo III:
- Adjusted buffer sizes
- Updated the calculation of text‑length values

* ime-lib another hotfix

Fixed incorrect param->title validation, which caused the IME dialog to fail to appear in Stardew Valley. Need to be checked.

* Clang fix

* FF9 ImeDialog Hotfix

* Removed the validation that disallowed null text and null placeholder, since using null values is valid in `ImeDialog`.
* Added additional debug logs to aid troubleshooting.

* IME Fixes
- Add missing flags to `OrbisImeExtOption`
- Improve debug logging
- Resolve nonstop `sceImeKeyboardOpen` calls in Stardew Valley (MonoGame engine) for `userId = 254`

---------

Co-authored-by: w1naenator <valdis.bogdans@hotmail.com>
2025-08-07 19:24:14 +03:00
marecl
f83619e313 Fixed green artifacts in movies/animations (ffmpeg) (#3398)
* Fixed green artifacts in movies/animations (ffmpeg)

* cleanup&clang

* Avoid for-loop when source and target widths are equal
2025-08-06 22:08:59 +03:00
kalaposfos13
5b46216bae Make libSceRtc fully HLE (#3330)
* Add stubbed libkernel time functions

* Implement remaining stubbed Rtc functions

* Move Rtc from the optionally HLE loading part to the always loaded part

* Remove Rtc from the README list of LLE modules

* Mfw last second hotfix I noticed while double checking that everything's good before opening the PR
2025-08-06 20:08:26 +03:00
Lander Gallastegi
841aa9e43d video_core: garbage collector (part 1) (#3350)
* Memory information

* Buffer cache GC

* Texture cache GC

* Fix ChangeRegister

* Better image touching

* Buffer async download on GC destroy

* Handle image download, SKIP NON-LINEAR WORKAROUND

* Only download when not dirty

* Correctly handle BDA pagefile update

* Restructure ChangeRegistration
2025-08-06 12:30:13 +02:00
Marcin Mikołajczyk
2f701311f2 Sockets fixes (#3392)
* Print errnos as decimal

* SetSocketOptions: prevent setting SO_TYPE

* Extract net error handler

* Change the local IP retrieval method

* Fix windows
2025-08-06 08:00:29 +03:00
Stephen Miller
074dfe2571 Update file_system.cpp (#3388) 2025-08-05 19:58:23 +03:00
Valdis Bogdāns
7dd64f889f FF9 ImeDialog Hotfix (#3386)
* Changes
-Added support for OrbisImeParamExtended (extended IME parameters) in ImeHandler, ImeState, and ImeUi
-Updated all relevant constructors and logic to propagate and store the extended parameter
- Now fully supports passing extended options from sceImeOpen to the IME UI and backend

* Potential CUSA00434 [Debug] <Critical> assert.cpp:30 assert_fail_debug_msg: Assertion Failed!
buf_len + 1 <= buf_size && "Is your input buffer properly zero-terminated?" at C:/VS/shadPS4-ime-fixes/externals/dear_imgui/imgui_widgets.cpp:4601 fix

* Attempting to resolve an assertion failure in Diablo III:
- Adjusted buffer sizes
- Updated the calculation of text‑length values

* ime-lib another hotfix

Fixed incorrect param->title validation, which caused the IME dialog to fail to appear in Stardew Valley. Need to be checked.

* Clang fix

* FF9 ImeDialog Hotfix

* Removed the validation that disallowed null text and null placeholder, since using null values is valid in `ImeDialog`.
* Added additional debug logs to aid troubleshooting.

---------

Co-authored-by: w1naenator <valdis.bogdans@hotmail.com>
2025-08-05 19:57:31 +03:00
Stephen Miller
7ec3a38b89 libSceAppContent: Use last 16 characters of DLC folder to determine entitlement label (#3375)
* Use last 16 characters of DLC folder name to determine entitlement label

Code comments and commit name say it all.

* Clang

* Adjust comment

ftpdump appends -ac at the end of the entitlement label, so my comment was partially incorrect.
2025-08-05 11:52:53 +03:00
psucien
afb9e220aa libkernel: more network functions for OpenOrbis compatibility (#3373) 2025-08-05 11:25:18 +03:00
Vinicius Rangel
0044a27c1f Simple IPC for external control (#3345)
* add simple IPC protocol

to allow communication via stdin/stdout

* ipc: add PATCH_MEMORY command

enables patches & cheates
2025-08-04 20:32:50 -03:00
Marcin Mikołajczyk
77410fd228 Stub remaining netctl properties (#3385) 2025-08-04 23:20:39 +03:00
Marcin Mikołajczyk
b53bda852d Fix get/setsockopt levels (#3384) 2025-08-04 22:48:56 +03:00
georgemoralis
339081d08f [ci skip] Qt GUI: Update Translation. (#3378)
Co-authored-by: georgemoralis <4313123+georgemoralis@users.noreply.github.com>
2025-08-04 13:20:21 +03:00
georgemoralis
7f4183eb27 New Crowdin updates (#3358)
* New translations en_us.ts (Turkish)

* New translations en_us.ts (Spanish)

* New translations en_us.ts (Polish)

* New translations en_us.ts (Albanian)

* New translations en_us.ts (Ukrainian)

* New translations en_us.ts (German)

* New translations en_us.ts (Greek)

* New translations en_us.ts (Vietnamese)

* New translations en_us.ts (Indonesian)

* New translations en_us.ts (Romanian)

* New translations en_us.ts (French)

* New translations en_us.ts (Arabic)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Danish)

* New translations en_us.ts (Finnish)

* New translations en_us.ts (Hungarian)

* New translations en_us.ts (Italian)

* New translations en_us.ts (Japanese)

* New translations en_us.ts (Korean)

* New translations en_us.ts (Lithuanian)

* New translations en_us.ts (Dutch)

* New translations en_us.ts (Portuguese)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Slovenian)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Chinese Simplified)

* New translations en_us.ts (Chinese Traditional)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Persian)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Italian)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Arabic)

* New translations en_us.ts (Arabic)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Spanish)

* New translations en_us.ts (Chinese Simplified)
2025-08-04 13:20:06 +03:00
DanielSvoboda
42e3ce9465 Fix Play Time (#3377) 2025-08-03 23:13:30 +03:00
Valdis Bogdāns
012b01d81f Another ImeDialog hotfix (#3371)
* Changes
-Added support for OrbisImeParamExtended (extended IME parameters) in ImeHandler, ImeState, and ImeUi
-Updated all relevant constructors and logic to propagate and store the extended parameter
- Now fully supports passing extended options from sceImeOpen to the IME UI and backend

* Potential CUSA00434 [Debug] <Critical> assert.cpp:30 assert_fail_debug_msg: Assertion Failed!
buf_len + 1 <= buf_size && "Is your input buffer properly zero-terminated?" at C:/VS/shadPS4-ime-fixes/externals/dear_imgui/imgui_widgets.cpp:4601 fix

* Attempting to resolve an assertion failure in Diablo III:
- Adjusted buffer sizes
- Updated the calculation of text‑length values

* ime-lib another hotfix

Fixed incorrect param->title validation, which caused the IME dialog to fail to appear in Stardew Valley. Need to be checked.

* Clang fix

---------

Co-authored-by: w1naenator <valdis.bogdans@hotmail.com>
2025-08-03 12:51:26 +03:00
rainmakerv2
e56232134f Minor fixes (#3370) 2025-08-03 12:25:08 +03:00
rainmakerv2
c7f1c66b82 Qt: add customizable controller hotkeys (#3369)
* customizable controller hotkeys - initial

* Update input_handler.h
2025-08-03 11:59:12 +03:00
kalaposfos13
a362f20dae Implement ORBIS_NET_CTL_INFO_HTTP_PROXY_CONFIG (#3366) 2025-08-03 11:15:13 +03:00
Valdis Bogdāns
1e7c4bb69c ime-changes (#3348)
* Changes
-Added support for OrbisImeParamExtended (extended IME parameters) in ImeHandler, ImeState, and ImeUi
-Updated all relevant constructors and logic to propagate and store the extended parameter
- Now fully supports passing extended options from sceImeOpen to the IME UI and backend

* Potential CUSA00434 [Debug] <Critical> assert.cpp:30 assert_fail_debug_msg: Assertion Failed!
buf_len + 1 <= buf_size && "Is your input buffer properly zero-terminated?" at C:/VS/shadPS4-ime-fixes/externals/dear_imgui/imgui_widgets.cpp:4601 fix

* Attempting to resolve an assertion failure in Diablo III:
- Adjusted buffer sizes
- Updated the calculation of text‑length values

---------

Co-authored-by: w1naenator <valdis.bogdans@hotmail.com>
2025-07-31 12:24:36 +03:00
rainmakerv2
1b195c9613 controller select crash fix + minor changes (#3355)
* fix crash and ingame controller check

* performance issue fix

* add change controller event to imgui
2025-07-31 09:12:06 +03:00
georgemoralis
ecc924791d [ci skip] Qt GUI: Update Translation. (#3357)
Co-authored-by: georgemoralis <4313123+georgemoralis@users.noreply.github.com>
2025-07-31 09:11:53 +03:00
Marcin Mikołajczyk
78936f31fc sys_getpeername (#3354) 2025-07-31 00:28:09 +03:00
Stephen Miller
6c34b86add Net: Fix various socket-related issues (#3347)
* Store platform-specific level in a separate variable

So the level logged in the getsockopt/setsockopt unreachable is actually useful in cases where the level is unknown.

* Define ORBIS_NET_IPPROTO_IPV6

Not implemented yet, but since it's known we might as well add it.

* Fix error codes

Our libSceNet code expects accurate ORBIS_NET_E* errors, while the sys_net code returns ORBIS_NET_ERROR_* errors.

* Remove duplicate getsockname implementation

* Use separate mutex for ReceivePacket calls

Calls to ReceivePacket shouldn't block other socket functions, and allowing them to block these functions frequently causes deadlocks in games that use multiple threads for socket behaviors.
That said, concurrent receives are still a potential issue, so the function should still have a mutex.

* Add missing error codes

* Clang

* Minor nit

Not sure why these were left separate from the rest of the net errnos

* Set __Error() in ConvertReturnErrorCode

Because the new error values are positive, the logic of "negative return is an error" doesn't work anymore. The easiest fix, while retaining corrected error values, is to just set __Error() in ConvertReturnErrorCode, and have that return -1 instead.
I also added some formatting fixes here too.

* Set errno on stubbed P2P socket error returns.

Otherwise the errno is just whatever was set by a previous failing function, which may cause issues in some games.
I used EAGAIN here since it appears to be valid for all three of these functions, but this can be changed if requested.

* Fix missed error returns

* Fix socket methods in file_system

Missed these
2025-07-30 21:54:28 +03:00
georgemoralis
f685233401 New Crowdin updates (#3321)
* New translations en_us.ts (Catalan)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Italian)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Ukrainian)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Chinese Simplified)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Turkish)
2025-07-30 21:53:09 +03:00
rainmakerv2
c924c20575 Multiple controllers: Select active controller and set default controller (#3169)
* initial commit - not cleanup yet, not usable with imGUI

* Ugly solution to working with ImGUI

* Populate the default controller labels

* Add remove default button

* missing tr calls

* edit imgui flag after updating

* Refactor

* Update sirit
2025-07-30 21:37:45 +03:00
DanielSvoboda
35132d9fdc fix patches - Different AppVer (#3344)
* fix patches

* fix linux?

* + mask, mask_jump32 |  - insideMetadata
2025-07-29 10:37:03 +03:00
Marcin Mikołajczyk
26a92d97fa Sockets are now files (#3319)
* Socket support for read/write/fstat

* Sockets are now files

* Fix ssize_t for windows

* Return posix error codes in net functions
2025-07-29 00:20:10 +03:00
TheTurtle
93767ae31b shader_recompiler: Rework sharp tracking for robustness (#3327)
* shader_recompiler: Remove remnants of old discard

Also constant propagate conditional discard if condition is constant

* resource_tracking_pass: Rework sharp tracking for robustness

* resource_tracking_pass: Add source dominance analysis

When reachability is not enough to prune source list, check if a source dominates all other sources

* resource_tracking_pass: Fix immediate check

How did this work before

* resource_tracking_pass: Remove unused template type

* readlane_elimination_pass: Don't add phi when all args are the same

New sharp tracking exposed some bad sources coming on sampler sharps with aniso disable pattern that also were part of readlane pattern, fix tracking by removing the unnecessary phis inbetween

* resource_tracking_pass: Allow phi in disable aniso pattern

* resource_tracking_pass: Handle not valid buffer sharp and more phi in aniso pattern
2025-07-28 13:32:16 -07:00
marecl
d286631798 Patch is enabled only when game version matches patch version (#3336)
Removed redundancies from CheatsPatches::onSaveButtonClicked()
2025-07-28 16:52:23 +03:00
kalaposfos13
968cfe1180 Reset orientation on scePadOpen call (#3341) 2025-07-28 00:27:49 -07:00
baggins183
116554e425 V_ALIGNBYTE_B32 and V_ALIGNBIT_B32 (#3316)
* implement V_ALIGNBYTE_B32 and V_ALIGNBIT_B32

* fix mask

* uncomment alignbit
2025-07-28 00:27:13 -07:00
georgemoralis
df85efde7c fixed RetrieveNetmask for windows (#3338)
* fixed RetrieveNetmask for windows

* clang..
2025-07-27 19:14:11 +03:00
marecl
e3fe6e2809 Fixed missing hint (#3334) 2025-07-27 11:25:47 +03:00
Marcin Mikołajczyk
ee3816ffd6 Fix sceAudioOutOutputs (#3335) 2025-07-26 16:05:01 -07:00
DanielSvoboda
2e237051e3 scePadResetOrientation (#3332) 2025-07-26 15:48:30 -07:00
Marcin Mikołajczyk
c863b350b2 Return an error before a pad is opened (#3323) 2025-07-25 16:23:57 -07:00
Marcin Mikołajczyk
446426224e Return the number of samples enqueued in AudioOut (#3324) 2025-07-25 16:23:10 -07:00
squidbus
d62d65af62 texture_cache: Do not modify mip height for copy in volume texture. (#3326) 2025-07-25 16:21:20 -07:00
Stephen Miller
90705cbe51 Return error if dmem query address is too high (#3325)
Also adjusts the log message to align with how we log error returns in sceKernelVirtualQuery.
2025-07-25 21:40:14 +03:00
Marcin Mikołajczyk
8b1b0fa0dc Implement simple DNS name resolution (#3318)
* Implement simple DNS name resolution

* Remove conversion of getaddrinfo errors to string

---------

Co-authored-by: georgemoralis <giorgosmrls@gmail.com>
2025-07-25 19:05:28 +03:00
Marcin Mikołajczyk
923c5f3ef5 Include epoll-shim library (#3312) 2025-07-25 16:53:46 +03:00
Marcin Mikołajczyk
d46792da94 Extract netmask and default gateway from host system (#3294)
* Retrieve correct netmask in netctl

* Retrieve correct default route in netctl (Linux)

* Retrieve default gateway on mac

* added default gateway for windows

---------

Co-authored-by: georgemoralis <giorgosmrls@gmail.com>
2025-07-25 13:20:23 +03:00
Marcin Mikołajczyk
61ce393673 inet_ntop and inet_pton (#3317) 2025-07-25 09:53:41 +03:00
georgemoralis
4c22137255 New Crowdin updates (#3298)
* New translations en_us.ts (Turkish)

* New translations en_us.ts (Spanish)

* New translations en_us.ts (Polish)

* New translations en_us.ts (Albanian)

* New translations en_us.ts (Ukrainian)

* New translations en_us.ts (German)

* New translations en_us.ts (Greek)

* New translations en_us.ts (Vietnamese)

* New translations en_us.ts (Indonesian)

* New translations en_us.ts (Romanian)

* New translations en_us.ts (French)

* New translations en_us.ts (Arabic)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Danish)

* New translations en_us.ts (Finnish)

* New translations en_us.ts (Hungarian)

* New translations en_us.ts (Italian)

* New translations en_us.ts (Japanese)

* New translations en_us.ts (Korean)

* New translations en_us.ts (Lithuanian)

* New translations en_us.ts (Dutch)

* New translations en_us.ts (Portuguese)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Slovenian)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Chinese Simplified)

* New translations en_us.ts (Chinese Traditional)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Persian)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Chinese Simplified)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Ukrainian)

* New translations en_us.ts (French)

* New translations en_us.ts (Persian)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Turkish)

* New translations en_us.ts (Spanish)

* New translations en_us.ts (Polish)

* New translations en_us.ts (Albanian)

* New translations en_us.ts (Ukrainian)

* New translations en_us.ts (German)

* New translations en_us.ts (Greek)

* New translations en_us.ts (Vietnamese)

* New translations en_us.ts (Indonesian)

* New translations en_us.ts (Romanian)

* New translations en_us.ts (French)

* New translations en_us.ts (Arabic)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Danish)

* New translations en_us.ts (Finnish)

* New translations en_us.ts (Hungarian)

* New translations en_us.ts (Italian)

* New translations en_us.ts (Japanese)

* New translations en_us.ts (Korean)

* New translations en_us.ts (Lithuanian)

* New translations en_us.ts (Dutch)

* New translations en_us.ts (Portuguese)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Slovenian)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Chinese Simplified)

* New translations en_us.ts (Chinese Traditional)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Persian)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Serbian (Latin))

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Italian)

* New translations en_us.ts (Turkish)

* New translations en_us.ts (Spanish)

* New translations en_us.ts (Polish)

* New translations en_us.ts (Albanian)

* New translations en_us.ts (Ukrainian)

* New translations en_us.ts (German)

* New translations en_us.ts (Greek)

* New translations en_us.ts (Vietnamese)

* New translations en_us.ts (Indonesian)

* New translations en_us.ts (Romanian)

* New translations en_us.ts (French)

* New translations en_us.ts (Arabic)

* New translations en_us.ts (Catalan)

* New translations en_us.ts (Danish)

* New translations en_us.ts (Finnish)

* New translations en_us.ts (Hungarian)

* New translations en_us.ts (Italian)

* New translations en_us.ts (Japanese)

* New translations en_us.ts (Korean)

* New translations en_us.ts (Lithuanian)

* New translations en_us.ts (Dutch)

* New translations en_us.ts (Portuguese)

* New translations en_us.ts (Russian)

* New translations en_us.ts (Slovenian)

* New translations en_us.ts (Swedish)

* New translations en_us.ts (Chinese Simplified)

* New translations en_us.ts (Chinese Traditional)

* New translations en_us.ts (Portuguese, Brazilian)

* New translations en_us.ts (Persian)

* New translations en_us.ts (Norwegian Bokmal)

* New translations en_us.ts (Serbian (Latin))
2025-07-25 08:52:03 +03:00
georgemoralis
2cd42aaba9 [ci skip] Qt GUI: Update Translation. (#3320)
Co-authored-by: georgemoralis <4313123+georgemoralis@users.noreply.github.com>
2025-07-25 07:09:35 +03:00
tomboylover93
6a476fdb42 qt: Add toggle in the settings window for readbacks (#3305)
* Add readback and readback linear image toggles to the settings window

* reuse and crowdin

* clang-format... my worst enemy...

* Experimental group box (#3)

* New Groupbox

* adjustments

* revised warning on experimental group box

---------

Co-authored-by: rainmakerv2 <30595646+rainmakerv3@users.noreply.github.com>
2025-07-24 14:02:29 +03:00
Valdis Bogdāns
7ef0cc0698 ime-fixes-hotfix (#3304)
* ime-fixes-hotfix
- Fixed incorrect validation of internal errors causing the keyboard GUI to not close on call to sceImeClose.
- Removed nonstop spam when ImeDialog is opened.
- Fixed text and data decoding for logs.
- Fixed incorrect validation of internal errors in sceImeKeyboardClose.
- Added partial implementation of sceImeKeyboardGetResourceId (always returns that the USB keyboard is disconnected); used in CUSA33782.

* fix clang in ime.cpp

* Update ime_dialog.cpp

Remove unnecessary Log spam

* Update ime.cpp

- use brackets for loops
- removed duplicated Log

* Update ime_dialog_ui.cpp

- fixed comment style code removal

* Update ime.cpp

- more brackets

---------

Co-authored-by: w1naenator <valdis.bogdans@hotmail.com>
2025-07-24 13:20:39 +03:00
Marcin Mikołajczyk
539b1b91a8 Define NetEpoll structures (#3311) 2025-07-24 10:57:55 +03:00
Marcin Mikołajczyk
fb5ac912cd Wiring misc functions (#3293)
* Register some posix functions

* Stub sceKernelIsAddressSanitizerEnabled

* Wire more pthread_attr functions

* Register sys_getsockopt to libScePosix

* Register sys_getpeername to libScePosix

* getpid() returns tid now

* Log sceKernelIsAddressSanitizerEnabled
2025-07-24 00:34:13 +03:00