Commit graph

500 commits

Author SHA1 Message Date
lat9nq
4ce53ffe6a game_list: Remove global instances of Core::System 2021-10-07 13:50:13 -04:00
lat9nq
fb66a455c4 yuzu qt: Remove global system instances from config, WaitTree, main 2021-10-07 13:50:13 -04:00
bunnei
e209fff374
Merge pull request #7111 from lat9nq/no-title-bar-version
main: Don't add an extra separator when the title version is absent
2021-10-03 00:27:08 -07:00
Morph
282bdfd1bf yuzu: main: Register a callback for Exit 2021-10-01 23:39:54 -04:00
lat9nq
596323f89f main: Don't add an extra separator when the title version is absent
Some titles, such as homebrew, do not have any version string. Because
yuzu hard codes the title bar string assuming a version string is
preset, booting homebrew causes yuzu to add an extra separator with no
content between.

This uses a lambda expression to prevent that from happening.
2021-09-30 18:57:37 -04:00
german77
75d8ec1e9f UI: Relocate tas menu and add brief description 2021-09-18 23:23:03 +02:00
german77
5401cf6eb5 input_common/tas: new update method 2021-09-18 23:22:57 +02:00
german77
e6c4bf52f0 input_common/tas: Add swap controller 2021-09-18 23:22:42 +02:00
german77
9bb6580d89 input_common/tas: overwrite file dialog 2021-09-18 23:22:42 +02:00
MonsterDruide1
f078b15565 input_common/tas: Fallback to simple update 2021-09-18 23:22:30 +02:00
german77
c01a872c8e config: Move TAS options to it's own menu 2021-09-18 23:22:30 +02:00
MonsterDruide1
4297d2fea2 core: Hacky TAS syncing & load pausing
To keep the TAS inputs synced to the game speed even through lag spikes and loading zones, deeper access is required.

First, the `TAS::UpdateThread` has to be executed exactly once per frame. This is done by connecting it to the service method the game calls to pass parameters to the GPU: `Service::VI::QueueBuffer`.

Second, the loading time of new subareas and/or kingdoms (SMO) can vary. To counteract that, the `CPU_BOOST_MODE` can be detected: In the `APM`-interface, the call to enabling/disabling the boost mode can be caught and forwarded to the TASing system, which can pause the script execution if neccessary and enabled in the settings.
2021-09-18 23:22:20 +02:00
MonsterDruide1
3a7b37238b main: TAS Playback state label
During script playback/recording, the user has to see what happens currently. For that, a new label has been added to the bottom-left corner, always displaying the current state of the TASing system.
2021-09-18 23:22:12 +02:00
MonsterDruide1
f25d6ebc45 settings: File selector & other settings
First of all, TASing requires a script to play back. The user can select the parent directory at `System -> Filesystem`, next to an option to pause TAS during loads: This requires a "hacky" setup deeper in the code and will be added in the last commit.

Also, Hotkeys are being introduced: CTRL+F5 for playback start/stop, CTRL+F6 for re-reading the script and CTRL+F7 for recording a new script.
2021-09-18 23:22:11 +02:00
MonsterDruide1
b42c3ce21d input_common/tas: Base playback & recording system
The base playback system supports up to 8 controllers (specified by `PLAYER_NUMBER` in `tas_input.h`), which all change their inputs simulataneously when `TAS::UpdateThread` is called.

The recording system uses the controller debugger to read the state of the first controller and forwards that data to the TASing system for recording. Currently, this process sadly is not frame-perfect and pixel-accurate.

Co-authored-by: Naii-the-Baf <sfabian200@gmail.com>
Co-authored-by: Narr-the-Reg <juangerman-13@hotmail.com>
2021-09-18 23:22:00 +02:00
bunnei
6d7801deb7
Merge pull request #6950 from german77/multiplay
input_common: Add advanced setting for 8 player support
2021-09-17 17:25:51 -07:00
ameerj
188cf1aed2 main: Apply confirm exit setting in exit locked scenarios
Some titles set an exit lock through HLE, which prompts an exit confirmation when stopping emulation if the system is locked.
This change allows bypassing this confirmation if the setting to confirm exits has been disabled by the user.
2021-09-12 00:31:32 -04:00
german77
5798537ce4 input_common: Enable steam controllers and 8 player support 2021-09-10 00:58:12 -05:00
ameerj
84b4ac5729 logging: Fix log filter during initialization
The log filter was being ignored on initialization due to the logging instance being initialized before the config instance, so the log filter was set to its default value.

This fixes that oversight, along with using descriptive exceptions instead of abort() calls.
2021-08-24 01:32:38 -04:00
yzct12345
001675dced
logging: Simplify and make thread-safe
This simplifies the logging system.

This also fixes some lost messages on startup.

The simplification is simple. I removed unused functions and moved most things in the .h to the .cpp. I replaced the unnecessary linked list with its contents laid out as three member variables. Anything that went through the linked list now directly accesses the backends. Generic functions are replaced with those for each specific use case and there aren't many. This change increases coupling but we gain back more KISS and encapsulation.

With those changes it was easy to make it thread-safe. I just removed the mutex and turned a boolean atomic. I was planning to use this thread-safety in my next PR about stacktraces. It was actually async-signal-safety at first but I ended up using a different approach. Anyway getting rid of the linked list is important for that because have the list of backends constantly changing complicates things.
2021-08-13 18:39:45 +00:00
german77
acce512ae8 main: Avoid stopping emulation when taking a screenshot 2021-08-07 15:45:29 -05:00
bunnei
d05e6003f0
Merge pull request #6700 from lat9nq/fullscreen-enum
general: Implement FullscreenMode enumeration
2021-07-28 11:36:42 -07:00
bunnei
d6c799494c
Merge pull request #6696 from ameerj/speed-limit-rename
general: Rename "Frame Limit" references to "Speed Limit"
2021-07-26 18:51:00 -07:00
bunnei
c09557acd8
Merge pull request #6697 from ameerj/fps-cap
config, nvflinger: Add FPS cap setting
2021-07-25 16:23:44 -07:00
lat9nq
09d6cc9943
Merge branch 'master' into fullscreen-enum 2021-07-25 15:31:33 -04:00
bunnei
7e272d3cd8
Merge pull request #6575 from FernandoS27/new_settings
Settings: Eliminate ASYNC & MULTICORE Toggles and add GPU Accuracy to  status bar
2021-07-25 11:45:45 -07:00
Morph
b5c3cb8763
Merge pull request #6709 from ameerj/screenshot-path
main: Fix screenshot filepath construction
2021-07-25 14:41:38 -04:00
ameerj
9dd35b7b66 main: Fix screenshot filepath construction
The screenshot directory path returned does not have a trailing directory separator character. This caused screenshots to be saved in the parent directory of the configured screenshot directory.

This fixes that behavior
2021-07-25 14:24:08 -04:00
ameerj
9dfbc9bdce general: Rename "Frame Limit" references to "Speed Limit"
This setting is best referred to as a speed limit, as it involves the limits of all timing based aspects of the emulator, not only framerate.
This allows us to differentiate it from the fps unlocker setting.
2021-07-23 22:10:01 -04:00
ameerj
2c6e274b39 config, nvflinger: Add FPS cap setting
Allows finer tuning of the FPS limit.
2021-07-23 22:04:36 -04:00
lat9nq
b11c81cc13 general: Implement FullscreenMode enumeration
Prevents us from using an unclear 0 or 1 to describe the fullscreen
mode.
2021-07-23 10:14:37 -04:00
ameerj
4e4b8775b5 main: Update Shader Cache menu options
This change adds two new context menu items to remove either the OpenGL or the Vulkan shader caches individually, and the provides the option to remove all caches for the selected title.
This also changes the behavior of the open shader cache option. Now it creates the shader cache directory for the title if it does not yet exist.
2021-07-22 21:51:40 -04:00
ameerj
5445799260 main: Fix Open Transferable Shader Cache context item
Opens the new shader cache directory location for the specified title, if it exists.
2021-07-22 21:51:35 -04:00
ReinUsesLisp
cffd4716c5 vk_pipeline_cache,shader_notify: Add shader notifications 2021-07-22 21:51:35 -04:00
Feng Chen
07073734ed
file_sys: Support load game collection (#6582)
Adds support for loading games with multiple programs embedded within such as the Dragon Quest 1+2+3 Collection
2021-07-20 01:10:05 -04:00
Morph
9a48f252ae applets: Append qt_ prefix to Qt frontend applets 2021-07-14 01:07:09 -04:00
bunnei
00ce8eff65
Merge pull request #6574 from lioncash/i18n
qt/main: Make title string more i18n-friendly
2021-07-12 22:12:09 -07:00
ameerj
58219d1f36 settings: Disable FPS unlimit setting between title launches
Some titles crash if the FPS limit is disabled when launching. This change ensures that titles launch with the limit in-place to avoid issues.
In order to simplify the change, the UI toggle was removed as it will always be overridden at launch to be disabled.
The setting can still be toggled during gameplay with the hotkey, and indicated by the fps label in the status bar.
2021-07-10 15:11:17 -04:00
Fernando S
598d154f69
Update src/yuzu/main.cpp
Co-authored-by: Morph <39850852+Morph1984@users.noreply.github.com>
2021-07-09 12:28:51 +02:00
Fernando Sahmkow
fd09be5496 Settings: Eliminate ASYNC & MULTICORE Toggles and add GPU Accuracy Toggle. 2021-07-09 02:08:08 +02:00
Lioncash
5c541b0b42 qt/main: Make title string more i18n-friendly
Currently, whether or not the title is 32-bit or 64-bit was being
appended as a suffix to the title, which is fine for left-to-right
languages, but may not always fly so smoothly with some right-to-left
languages.

We also weren't marking that portion of the string as translatable,
which prevents translators from translating part of the title string.
2021-07-08 15:06:16 -04:00
Ameer J
5edc96f4a4
Merge pull request #6539 from lat9nq/default-setting
general: Move most settings' defaults and labels into their definition
2021-07-08 14:46:31 -04:00
Morph
39be4c3026
Merge pull request #6471 from lat9nq/dump-as-mod
yuzu qt, core: Support LayeredFS mods from SDMC directory
2021-06-29 00:10:31 -04:00
lat9nq
7a8de138df yuzu qt: Make most UISettings a BasicSetting
For simple primitive settings, moves their defaults and labels to
definition time.

Also fixes typo and clang-format

yuzu qt: config: Fix rng_seed
2021-06-28 19:13:53 -04:00
lat9nq
b91b76df4f general: Make most settings a BasicSetting
Creates a new BasicSettings class in common/settings, and forces setting
a default and label for each setting that uses it in common/settings.
Moves defaults and labels from both frontends into common settings.
Creates a helper function in each frontend to facillitate reading the
settings now with the new default and label properties.

Settings::Setting is also now a subclass of Settings::BasicSetting. Also
adds documentation for both Setting and BasicSetting.
2021-06-28 17:32:17 -04:00
Morph
ec68cba440
Merge pull request #6502 from ameerj/vendor-title
main: Add GPU Vendor name to running title bar
2021-06-28 14:51:49 -04:00
Morph
511ee03a21 patch_manager: Do not apply LayeredFS mods when dumping
We should not apply any mods when dumping a game's RomFS.
2021-06-28 10:14:36 -04:00
lat9nq
bfecd395d4 yuzu qt: Add option to dump to SDMC directory
Enables dumping the RomFS to SDMC directory, specifically '[yuzu data
directory]/sdmc/atmosphere/contents/[title_id]/romfs'.
2021-06-28 10:08:07 -04:00
ameerj
4cee25281f main: Display the instruction set of the running title in the window name
Displays whether the currently running title uses 64-bit instructions or only 32-bit instructions.
2021-06-28 00:37:24 -04:00
Lioncash
d0b1f2bd05 General: Resolve fmt specifiers to adhere to 8.0.0 API where applicable
Also removes some deprecated API usages.
2021-06-23 13:48:21 -04:00