Commit graph

325 commits

Author SHA1 Message Date
Hyper
d23e6d0e90 Implemented vibration option 2025-01-01 18:05:18 +00:00
Hyper
90cf22e586 cmake: fix dxil.dll location 2025-01-01 16:16:45 +00:00
Skyth
d6c2884f2e Look for mod loader .ini file in config folder. 2025-01-01 11:49:20 +03:00
Skyth (Asilkan)
a397a90551
Mod loader implementation. (#66)
* Initial mod loader implementation.

* Allow iterating in mod directories.

* Initial append archive implementation.

* Avoid calling function wrappers when loading append ARs.

For some reason they cause issues. Should investigate later.

* UMM merge archive support.

* Load merge archives without archive lists.

* Less thread locals.

I shouldn't worry about string allocations this much when the game itself spams them...

* Check for read-only UMM archives.

TODO: Skip merging as it's currently just doing duplicate loads.

* Skip loading merge archives if they are read-only.

* Merge only archives.

* Implement decompression.

* Fix append ARLs not loading.

* Initial save file redirection implementation.

* Slightly refactor resolved path usage.

* Implement save file redirection fallback.

* Set a default save file path if none is provided.

* Check for enabled option & replace backward slashes with forward ones in mod save file paths.

* Convert back slashes to forward ones when iterating directories.

* Make CSB limit dynamic.

* Cache append/merge archive lookups.

* Close stream after reading compressed ARL.

* Fix UMM/HMM ARL file path inconsistency.
2024-12-31 20:20:07 +03:00
Skyth
281535ad51 Stub out buggy render game scene function. 2024-12-30 14:20:21 +03:00
Hyper
31bb28d0fd message_window: fix mouse input issues
Addresses issues #25, #27 and #28.
2024-12-27 23:13:06 +00:00
Hyper
bab9705151
Fix auto controller icons breaking loading screen graphics (#64) 2024-12-27 20:58:41 +00:00
Hyper
c98f3942d6 hid: respect PlayStation touchpad button as back button 2024-12-27 20:34:58 +00:00
Skyth
8f4f1ea33e Handle the anisotropic filtering option in config. 2024-12-26 16:13:21 +03:00
Hyper
a1a05f83dc Implemented master volume slider 2024-12-25 21:17:40 +00:00
Skyth
0b5281d652 Prevent SDL events from getting flushed outside the main thread. 2024-12-25 22:15:01 +03:00
Skyth
b054e16461 Fix buffers getting copied with a closed command list. 2024-12-25 22:12:17 +03:00
Hyper
659f3700ee hid: implemented controller LED context 2024-12-25 17:47:57 +00:00
Skyth (Asilkan)
fd009bcada
Sync render thread present with main thread. (#62)
* Experimenting with syncing the render thread.

* Separate wait functions for swap chains.

* Sync render thread present to the main thread.

* Move present to main thread and frame limit after presenting.

* g_next -> s_next

* Fix Vulkan validation errors.

* Make max frame latency configurable.

* Fix loading thread breaking waitable swap chain order.
2024-12-25 16:29:15 +03:00
Dario
c1cafacf22 Add video driver to debugger panel. 2024-12-22 18:23:14 -03:00
Darío
02022c3a1d
Do not default to Wayland, add CLI option for choosing SDL video driver. (#61) 2024-12-23 00:07:27 +03:00
Skyth
d6444da62f Add custom implementation for semaphores. 2024-12-22 23:50:19 +03:00
Skyth (Asilkan)
f1416c85ba
Implement frame limiter. (#60)
* Implement audio timing with integer math.

* Add busy loop to audio thread.

* Implement a frame limiter.

* Implement implot.

* Add more stuff to the profiler window.

* Redo frame limiter logic to fix drifting.

* Move frame limiter, add limiters for SFD & loading screen.

* Update waiting logic for audio thread.

* Correct small delta time errors.

* Decrease delta time error threshold.

* Set busy wait threshold to 2ms.

* Change spin wait in D3D12 present to infinite wait.

* Replace FPS literals with constants.
2024-12-22 19:58:06 +03:00
Skyth
314a092747 Pass ALLOW_TEARING flag to D3D12 swap chains. 2024-12-22 00:25:50 +03:00
Hyper
552063fbd4 Update submodule script to pull current commit submodules 2024-12-21 02:57:56 +00:00
Skyth
4957fe0685 Update submodules. 2024-12-21 00:52:37 +03:00
Skyth (Asilkan)
67633917bf
Linux support. (#54)
* Initial Linux attempt.

* Add clang toolchain & make tools compile.

* vcpkg as submodule.

* First implementation of IO rewrite. (#31)

* Fix directory iteration resolving symlinks.

* Refactor kernel objects to be lock-free.

* Implement guest critical sections using std::atomic.

* Make D3D12 support optional. (#33)

* Make D3D12 support optional.

* Update ShaderRecomp, fix macros.

* Replace QueryPerformanceCounter. (#35)

* Add Linux home path for GetUserPath(). (#36)

* Cross-platform Sleep. (#37)

* Add mmap implementations for virtual allocation. (#38)

* Cross-platform TLS. (#34)

* Cross-platform TLS.

* Fix front() to back(), use Mutex.

* Fix global variable namings.

---------

Co-authored-by: Skyth <19259897+blueskythlikesclouds@users.noreply.github.com>

* Unicode support. (#39)

* Replace CreateDirectoryA with Unicode version.

* Cross platform thread implementation. (#41)

* Cross-platform thread implementation.

* Put set thread name calls behind a Win32 macro.

* Cross-platform semaphore implementation. (#43)

* xam: use SDL for keyboard input

* Cross-platform atomic operations. (#44)

* Cross-platform spin lock implementation.

* Cross-platform reference counting.

* Cross-platform event implementation. (#47)

* Compiling and running on Linux. (#49)

* Current work trying to get it to compile.

* Update vcpkg.json baseline.

* vcpkg, memory mapped file.

* Bitscan forward.

* Fix localtime_s.

* FPS patches high res clock.

* Rename Window to GameWindow. Fix guest pointers.

* GetCurrentThreadID gone.

* Code cache pointers, RenderWindow type.

* Add Linux stubs.

* Refactor Config.

* Fix paths.

* Add linux-release config.

* FS fixes.

* Fix Windows compilation errors & unicode converter crash.

* Rename physical memory allocation functions to not clash with X11.

* Fix NULL character being added on RtlMultiByteToUnicodeN.

* Use std::exit.

* Add protection to memory on Linux.

* Convert majority of dependencies to submodules. (#48)

* Convert majority of dependencies to submodules.

* Don't compile header-only libraries.

* Fix a few incorrect data types.

* Fix config directory.

* Unicode fixes & sizeof asserts.

* Change the exit function to not call static destructors.

* Fix files picker.

* Add RelWithDebInfo preset for Linux.

* Implement OS Restart on Linux. (#50)

---------

Co-authored-by: Dario <dariosamo@gmail.com>

* Update PowerRecomp.

* Add Env Var detection for VCPKG_ROOT, add DLC detection.

* Use error code version on DLC directory iterator.

* Set D3D12MA::ALLOCATOR_FLAG_DONT_PREFER_SMALL_BUFFERS_COMMITTED flag.

* Linux flatpak. (#51)

* Add flatpak support.

* Add game install directory override for flatpak.

* Flatpak'ing.

* Flatpak it some more.

* We flat it, we pak it.

* Flatpak'd.

* The Marvelous Misadventures of Flatpak.

* Attempt to change logic of NFD and show error.

* Flattenpakken.

* Use game install directory instead of current path.

* Attempt to fix line endings.

* Update io.github.hedge_dev.unleashedrecomp.json

* Fix system time query implementation.

* Add Present Wait to Vulkan to improve frame pacing and reduce latency. (#53)

* Add present wait support to Vulkan.

* Default to triple buffering if presentWait is supported.

* Bracey fellas.

* Update paths.h

* SDL2 audio (again). (#52)

* Implement SDL2 audio (again).

* Call timeBeginPeriod/timeEndPeriod.

* Replace miniaudio with SDL mixer.

* Queue audio samples in a separate thread.

* Enable CMake option override policy & fix compilation error.

* Fix compilation error on Linux.

* Fix but also trim shared strings.

* Wayland support. (#55)

* Make channel index a global variable in embedded player.

* Fix SDL Audio selection for OGG on Flatpak.

* Minor installer wizard fixes.

* Fix compilation error.

* Yield in model consumer and pipeline compiler threads.

* Special case Sleep(0) to yield on Linux.

* Add App Id hint.

* Correct implementation for auto reset events. (#57)

---------

Co-authored-by: Dario <dariosamo@gmail.com>
Co-authored-by: Hyper <34012267+hyperbx@users.noreply.github.com>
2024-12-21 00:44:05 +03:00
Hyper
f547c7ca6d window: implemented monitor switching 2024-12-16 19:07:21 +00:00
Skyth
74e6df96d4 Fix shared string memory leak. 2024-12-16 11:24:12 +03:00
Hyper
6c57221807
Implemented value thumbnails (#42)
* options_menu: implemented value thumbnails

* options_menu: use config ptrs as thumbnail keys, added named thumbnails

* options_menu_thumbnails: move header to cpp
2024-12-15 20:41:39 +00:00
Hyper
74ee0c2b2f
locale: move localised strings to cpp impl (#40) 2024-12-15 18:15:32 +03:00
Dario
c6e3d4e31f Fix toml parser failing on Unicode paths. 2024-12-15 01:27:50 -03:00
Dario
10c8858416 Reset end time for installer when installer is started. 2024-12-15 00:19:40 -03:00
Hyper
587b222483 Implemented D-Pad player input
This is mainly beneficial for 2D sections with PlayStation controllers where the D-Pad may be more preferable, but it also works in 3D too.
2024-12-15 01:44:01 +00:00
Skyth
578d9d052b Move first party tools to tools folder. 2024-12-13 21:21:58 +03:00
Skyth
611454126e Update pipeline cache. 2024-12-13 21:07:12 +03:00
Skyth
4b728f4a2b Downgrade to C++20 & switch to fmtlib. 2024-12-13 18:54:05 +03:00
Skyth
1ab25d5b41 Update recompiler submodules. 2024-12-13 18:33:51 +03:00
Skyth
6d1d5ff33a Add RelWithDebInfo configuration. 2024-12-13 15:17:23 +03:00
Skyth
1631a27a4e Enable LTO for release targets. 2024-12-13 15:10:40 +03:00
Skyth
417805ae38 Fix inconsistent static/inline usage. 2024-12-13 14:51:13 +03:00
Skyth
87e3602f41 Update DoF quality thresholds. 2024-12-13 11:27:24 +03:00
Hyper
e79d2edc2d
Merge pull request #30 from hedge-dev/logger
Implemented cross-platform logger framework
2024-12-12 22:50:05 +00:00
Hyper
3e21a26f6a logger: make thread safe, use std::string_view with std::println 2024-12-12 22:46:54 +00:00
Hyper
e7d7431b58 logger: stub out utility logs for Release in the macros 2024-12-12 22:31:37 +00:00
Hyper
0813be2acf Implemented cross-platform logger framework (and clean-up) 2024-12-12 22:12:29 +00:00
Hyper
b9bd137659 achievement_menu: replace erroneous quotation marks with apostrophes 2024-12-12 22:06:22 +00:00
Darío
27eab0af66
Installer sounds and embedded player. (#29)
* Embedded player implementation.

* Rework embedded sound player to support simultaneous playback.

* Add more embedded sounds.

* Update submodule.

* Update.

* Move engine initialization.

* Use guest audio configuration values in embedded player.

* Miniaudio submodule on dev branch.

* Implement libvorbis.

* Update resources submodule.

---------

Co-authored-by: Skyth <19259897+blueskythlikesclouds@users.noreply.github.com>
2024-12-12 22:17:12 +03:00
Hyper
a56aca27be config: move future HMM codes to temporary Exports section
Export implementation can be sorted later, will probably just toggle bools in a global struct.
2024-12-12 04:26:49 +00:00
Hyper
099dde82a2 hid: clean-up 2024-12-11 23:06:20 +00:00
Hyper
86c60e7bbe app: move config saving to App::Exit 2024-12-11 23:05:37 +00:00
Hyper
05ec19874e achievement_menu: fix locked shadow and marquee width 2024-12-11 23:03:08 +00:00
Hyper
4f26d0b263 hid: stop vibrating controllers on focus lost 2024-12-11 22:32:39 +00:00
Hyper
38c275632b config_locale: revised some descriptions 2024-12-11 21:17:20 +00:00
Hyper
59551d8875 hid: implemented controller type auto detection 2024-12-11 20:53:00 +00:00