Commit graph

30106 commits

Author SHA1 Message Date
Tilka
ce895f1205
Merge pull request #12255 from jordan-woyak/sdl-360
ControllerInterface/SDL: Remove Xbox 360 controller disabling hack.
2023-10-28 02:10:46 +01:00
Rairii
c9cd0b626b
JIT64: for twx instruction, raise exception with correct SRR0 2023-10-27 13:27:36 +01:00
sowens99
cddc75c28b Core: Fix UI slowdown for savestate timestamp reads 2023-10-26 22:32:47 -04:00
Jordan Woyak
30ce1f2ec2 ControllerInterface/SDL: Remove Xbox 360 controller disabling hack. 2023-10-26 18:04:11 -05:00
Admiral H. Curtiss
4f0c8b1657
VideoCommon: Don't swap on state load when there's no XFB.
This triggers an assert in TCacheEntry::SetXfbCopy() otherwise if you load a savestate that was made before the first XFB has been rendered.
2023-10-25 18:24:42 +02:00
TellowKrinkle
4f2a79058a VideoBackends:OGL: Handle when SSBOs are only supported in some shader stages 2023-10-25 17:47:04 +02:00
TellowKrinkle
323aea60d6 VideoCommon: Fix VS point/line on older GLSL 2023-10-24 23:18:01 -05:00
Sintendo
171f76ae07 Jit_LoadStore: Another minor dcbx optimization
The multiplication needs the value from RSCRATCH2, but shouldn't
overwrite it as it is still needed later. The original code solved this
by copying RSCRATCH2 to another register first.

As it turns out, the other register involved in the multiplication can
safely be overwritten, so we can swap the operands around and use
RSCRATCH2 directly without making a copy.

Before:
33 D2                xor         edx,edx
8B 45 64             mov         eax,dword ptr [rbp+64h]
85 C0                test        eax,eax
7E 30                jle         000002D4DF373F6B
44 8B B5 D4 02 00 00 mov         r14d,dword ptr [rbp+2D4h]
44 8B E8             mov         r13d,eax
BF 07 00 00 00       mov         edi,7
F7 F7                div         eax,edi
41 8D 56 FF          lea         edx,[r14-1]
3B C2                cmp         eax,edx
0F 42 D0             cmovb       edx,eax
44 2B F2             sub         r14d,edx
44 89 B5 D4 02 00 00 mov         dword ptr [rbp+2D4h],r14d
8B C2                mov         eax,edx
0F AF C7             imul        eax,edi
44 2B E8             sub         r13d,eax
44 89 6D 64          mov         dword ptr [rbp+64h],r13d
44 8D 72 01          lea         r14d,[rdx+1]

After:
33 D2                xor         edx,edx
8B 45 64             mov         eax,dword ptr [rbp+64h]
85 C0                test        eax,eax
7E 2E                jle         0000021C01013F69
44 8B B5 D4 02 00 00 mov         r14d,dword ptr [rbp+2D4h]
44 8B E8             mov         r13d,eax
BF 07 00 00 00       mov         edi,7
F7 F7                div         eax,edi
41 8D 56 FF          lea         edx,[r14-1]
3B C2                cmp         eax,edx
0F 42 D0             cmovb       edx,eax
44 2B F2             sub         r14d,edx
44 89 B5 D4 02 00 00 mov         dword ptr [rbp+2D4h],r14d
0F AF FA             imul        edi,edx
44 2B EF             sub         r13d,edi
44 89 6D 64          mov         dword ptr [rbp+64h],r13d
44 8D 72 01          lea         r14d,[rdx+1]
2023-10-24 00:42:35 +02:00
Dentomologist
3ba5cd30ff SkylanderPortal: Make protected variables private
SkylanderPortal is final, so having member variables be protected
instead of private is just misleading.
2023-10-22 12:00:49 -07:00
Sintendo
dd58a8d65e Jit_LoadStore: Minor dcbx register optimization
Instructions referencing registers r8-r15 take an additional byte to
encode. `reg_downcount` may be assigned to one of these registers, so it
is a small size win to store the downcount value in `RSCRATCH` first.

Before:
33 D2                xor         edx,edx
44 8B 6D 64          mov         r13d,dword ptr [rbp+64h]
45 85 ED             test        r13d,r13d
7E 30                jle         0000023546B43F6D
44 8B B5 D4 02 00 00 mov         r14d,dword ptr [rbp+2D4h]
41 8B C5             mov         eax,r13d
BF 07 00 00 00       mov         edi,7
F7 F7                div         eax,edi

After:
33 D2                xor         edx,edx
8B 45 64             mov         eax,dword ptr [rbp+64h]
85 C0                test        eax,eax
7E 30                jle         000001AFBBAE359D
44 8B B5 D4 02 00 00 mov         r14d,dword ptr [rbp+2D4h]
44 8B E8             mov         r13d,eax
BF 07 00 00 00       mov         edi,7
F7 F7                div         eax,edi
2023-10-22 15:13:52 +02:00
Sintendo
3c3168706c PowerPC: Negate m_dec values in frsqrte table
This value is used in a multiplication. The result of this
multiplication is then subtracted from m_base. By negating m_dec, we are
free to use an addition instead.

On x64, this saves an instruction.
2023-10-21 21:08:21 +02:00
Dentomologist
c5a8a3fd4a CheatSearch: Use std comparison function objects 2023-10-20 16:05:47 -07:00
LillyJadeKatrin
db78437498
Refactored welcome message to render after game start
Split the "welcome" messages letting players know achievements are active into a separate method that gets called (currently) after a number of frames to ensure that the emulator has started properly and has somewhere to display the messages.
2023-10-19 19:21:12 +02:00
LillyJadeKatrin
a3d561fdff
Add badges to achievement messages
Updated OSD::AddMessage calls for achievements and game start to pass in the badges intended to be shown.
2023-10-19 19:13:20 +02:00
Admiral H. Curtiss
c87b2e46b4
Merge pull request #12242 from AdmiralCurtiss/osd-icons
VideoCommon: Add support for icons in OSD messages.
2023-10-17 12:46:36 +02:00
Admiral H. Curtiss
53ea7aee1b
Merge pull request #12239 from AdmiralCurtiss/achievementprogresswidget-clearlayout
DolphinQt/AchievementProgressWidget: Use ClearLayoutRecursively() to clear layout.
2023-10-17 12:45:40 +02:00
Admiral H. Curtiss
cb13ad7a5f
VideoCommon: Add support for icons in OSD messages. 2023-10-17 02:47:29 +02:00
iwubcode
b292022bc7 VideoCommon: use ToLower function in assets when parsing json, for proper locale independent behavior 2023-10-16 19:23:00 -05:00
iwubcode
fec2a8af8c VideoCommon: add additional properties to ShaderAsset to support custom shader uniforms 2023-10-16 19:02:27 -05:00
Admiral H. Curtiss
3873664143
DolphinQt/AchievementProgressWidget: Use ClearLayoutRecursively() to clear layout. 2023-10-15 22:54:40 +02:00
LillyJadeKatrin
b824d55093
Add Leaderboards tab to Achievement dialog
A new tab is added to the Achievements dialog to chart out the leaderboards in a table. Each row of the table contains the leaderboard information and up to four relevant entries, varying based on how many entries are in the leaderboard, whether or not the player has a submitted score, and where in the leaderboard the player's score is.
2023-10-15 21:28:40 +02:00
LillyJadeKatrin
04df930e0d
Added FetchBoardInfo to AchievementManager
FetchBoardInfo is called (via the work queue asynchronously) on a leaderboard every time it is activated or submitted to. It makes two calls to the RetroAchievements API for fetching leaderboard info, one that requests the top four entries in the leaderboard and another that requests the player's entry, the two entries above the player and the two entries below. All of these are inserted into a single map (resolving any overlaps) so the result can be exposed to the UI.
2023-10-15 21:28:40 +02:00
LillyJadeKatrin
61dded7043
Added Leaderboard info map to AchievementManager
The leaderboard map created here contains information useful to displaying leaderboard stats in the Achievement dialog, including each leaderboard's name and description and a partial list of entries for display. The entire map is exposed to the UI in a single call for simplicity.
2023-10-15 21:28:40 +02:00
Admiral H. Curtiss
daf9ff012a
Merge pull request #12229 from AdmiralCurtiss/achievement-load-async-lock
AchievementManager: Call ActivateDeactivateLeaderboards() and ActivateDeactivateRichPresence() under lock.
2023-10-15 21:27:41 +02:00
Admiral H. Curtiss
1645b1ed62
AchievementManager: Call ActivateDeactivateLeaderboards() and ActivateDeactivateRichPresence() under lock.
Both of these functions access `m_game_data` and don't lock themselves, so they must be called in a way that guarantees that `m_game_data` is not modified during the call.
2023-10-15 18:59:36 +02:00
Admiral H. Curtiss
ab562553f6
DolphinQt/AchievementHeaderWidget: Remove unused member variables. 2023-10-15 18:56:28 +02:00
Admiral H. Curtiss
923fc00777
DolphinQt/AchievementHeaderWidget: Fix wrong label for hard unlock count. 2023-10-15 18:42:03 +02:00
Admiral H. Curtiss
4b2dad074a
DolphinQt: Move GraphicsModListWidget::ClearLayoutRecursively() to QtUtils. 2023-10-15 18:39:05 +02:00
Admiral H. Curtiss
2677fd9a8e
Merge pull request #12185 from iwubcode/custom_shader_uniform_backend_support
VideoBackends / VideoCommon: add support for custom shader uniforms to D3D, Vulkan, OGL
2023-10-15 00:21:56 +02:00
Dentomologist
b2a8f7e276 IOS: Convert ObjectSubType to enum class 2023-10-11 14:21:29 -07:00
Admiral H. Curtiss
111c1ab531
AchievementManager: Don't store pointer to rc_runtime_event_t in lambda.
Scope issue in the event callback from `rc_runtime_do_frame()`. The pointer points to a variable on the stack from inside `rc_runtime_do_frame()`, so that's a race condition between the thread calling `rc_runtime_do_frame()` and the event queue thread.
2023-10-11 10:32:11 +02:00
iwubcode
b251194a7e VideoCommon: wait for the GPU to be finished doing any work before invalidating pipelines when graphic config changes 2023-10-10 18:17:24 -05:00
Admiral H. Curtiss
6aadfd522b
Merge pull request #12225 from AdmiralCurtiss/resolution-dropdown-fix
Qt/EnhancementsWidget: Fix size of resolution dropdown.
2023-10-10 19:29:22 +02:00
iwubcode
0e8f8ea930 VideoCommon: instead of using 'CustomTextureData' directly, use 'TextureData' for texture assets, this allows us to provide additional metadata for textures. Such as a sampler or type information (to distinguish cube maps) 2023-10-10 09:58:14 -05:00
Admiral H. Curtiss
7b32530de6
Qt/EnhancementsWidget: Fix size of resolution dropdown. 2023-10-10 15:03:49 +02:00
Admiral H. Curtiss
1b7a590b4b
Merge pull request #12209 from JosJuice/frsqrte-exp-lsb
PowerPC: Flip the order of frsqrte_expected
2023-10-10 10:38:07 +02:00
Admiral H. Curtiss
410ec83575
Merge pull request #12213 from dreamsyntax/128_CODE_SIZE_AND_FARCODE_SIZE
Jit64: Increase farcode & nearcode cache size
2023-10-10 10:35:23 +02:00
Admiral H. Curtiss
9ebb52537e
Merge pull request #12217 from malleoz/savestate_lz4
Savestates: Use LZ4 algorithm for faster decompression
2023-10-10 10:34:38 +02:00
sowens99
1eaa9380dd Savestates: Use LZ4 algorithm for faster decompression 2023-10-08 20:45:49 -04:00
Nicola Vella
b506bdc401
Fix heap buffer overflow in GCMemcardRaw 2023-10-08 15:13:41 +02:00
Nicola Vella
31dfb53152 Fix heap buffer overflow in GCMemcardRaw 2023-10-06 19:30:03 +02:00
iwubcode
713454b7d7 Metal: update binding mapping for SPRV due to change for custom shader uniforms in other backends (Metal is still not supported)
Co-authored-by: TellowKrinkle <tellowkrinkle@gmail.com>
2023-10-06 02:17:43 -05:00
iwubcode
a099f4f41b VideoCommon: given the changes to pipeline interaction, update the global version variable to reflect those changes and force pipelines to be rebuilt 2023-10-06 02:17:43 -05:00
iwubcode
751356af47 VideoCommon: avoid Vulkan validation errors when custom shader ubo isn't set up
Co-authored-by: TellowKrinkle <tellowkrinkle@gmail.com>
2023-10-06 02:17:43 -05:00
iwubcode
b6d321bfb1 VideoBackends / VideoCommon: add new uniform buffer object for custom shader materials (slot 3, geometry shader buffer moves to slot 4 if available) 2023-10-06 02:17:42 -05:00
iwubcode
92accc3ef7 VideoCommon: add custom pixel shader constants as a buffer of data to be passed to all backends 2023-10-05 21:20:16 -05:00
Filoppi
8027c88e58 Video: add support for 12x resolution multiplier 2023-10-06 01:12:10 +03:00
dreamsyntax
219610d8a0 Jit64: Increase nearcode/farcode size 2023-10-04 13:05:09 -07:00
Admiral H. Curtiss
beebe0a200
Core/BBA/BuiltIn: Replace IP_PROTOCOL with IPV4_ETHERTYPE to avoid conflict with Linux headers. 2023-10-04 16:13:16 +02:00
Admiral H. Curtiss
68c9362449
Merge pull request #12089 from stblr/gamecube-zelda-hle-in-wii-mode
GameCube Zelda HLE in Wii mode
2023-10-04 06:57:01 +02:00
sowens99
69ec239a1f Add lz4 submodule 2023-10-02 17:28:23 -04:00
Admiral H. Curtiss
da6339a722
Merge pull request #12026 from LillyJadeKatrin/retroachievements-measured
RetroAchievements - Progress Notifications
2023-10-01 19:25:02 +02:00
JosJuice
d6c0f8e749 Android: Get profile name from core
To avoid duplicating information between Kotlin and C++.
2023-10-01 18:47:49 +02:00
JMC47
cd366c4f46
Merge pull request #12036 from LillyJadeKatrin/deep-copy-volume
Added CopyReader to BlobReader and all subclasses
2023-10-01 11:39:37 -04:00
LillyJadeKatrin
6b110bb6fe Added Progress switch to Achievements dialog
Added a switch for the progress messages to the settings tab of the Achievements dialog.
2023-10-01 11:24:48 -04:00
LillyJadeKatrin
6d96b7173e Handle Achievement Progress Event
Added handling to Achievement Progress Events, which are generated when an achievement with a Measured field updates in value. For example, an achievement for collecting 120 stars will throw this event when the player collects each star, and with this handling, the player will get a message on screen informing them of this progress. This message will only appear if the newly added RA_PROGRESS_ENABLED setting is true.
2023-10-01 11:24:48 -04:00
LillyJadeKatrin
c8b1379113 Added error checking and logging to AchievementManager::GetAchievementProgress. 2023-10-01 10:27:57 -04:00
Admiral H. Curtiss
404a47af77
Merge pull request #12025 from LillyJadeKatrin/retroachievements-badges
RetroAchievements - Badges
2023-10-01 15:55:13 +02:00
LillyJadeKatrin
335cf4f2db Added CopyReader to BlobReader and all subclasses
A deep-copy method CopyReader has been added to BlobReader (virtual) and all of its subclasses (override). This should create a second BlobReader to open the same set of data but with an independent read pointer so that it doesn't interfere with any reads done on the original Reader.

As part of this, IOFile has added code to create a deep copy IOFile pointer onto the same file, with code based on the platform in question to find the file ID from the file pointer and open a new one. There has also been a small piece added to FileInfo to enable a deep copy, but its only subclass at this time already had a copy constructor so this was relatively minor.
2023-10-01 09:04:06 -04:00
LillyJadeKatrin
63c407ad7c Add toggle button for badges to achievement settings
Button toggles whether badges are downloaded. When turned on, makes a call to AchievementManager to download badges.
2023-09-30 23:29:02 -04:00
LillyJadeKatrin
80d77cfdad Added colored borders to badges in achievements dialog
The achievement badges will now have a blue or gold border to identify whether they have been unlocked in softcore or hardcore mode. Similarly, the game badge will have a blue border if all achievements have been unlocked in either mode or a gold border if all achievements have been unlocked in hardcore mode.
2023-09-30 23:29:02 -04:00
LillyJadeKatrin
ba83efded6 Added badges to achievement progress tab
Provided the badges are turned on in the settings, each achievement will have a badge next to it on the progress tab. There are different badges for locked and unlocked (usually locked is grayscale while unlocked is in color but not necessarily) and the badge chosen depends on the player's current unlock and hardcore status.
2023-09-30 23:29:02 -04:00
LillyJadeKatrin
0715da2d68 Added player and game badges to Achievements dialog header
Provided badges are turned on, if there's a player logged in their RetroAchievements icon will appear next to their player info in the header of the Achievements dialog. If they're playing a game, so will the icon for the game. Also performed some refactoring and reorganizing to the header as a whole so that it looks consistent whether a game is running or not.
2023-09-30 23:29:02 -04:00
LillyJadeKatrin
fd50b1fda6 Added FetchBadges to AchievementManager
FetchBadges fetches all available badges (player, game, achievements) and stores them in AchievementManager's memory. New fields and accessors have been added as necessary. Badges for individual achievements are stored in the UnlockStatus map. The method is public so that the settings dialog can call it if badges are turned on after a game is started. Badges are deleted at game close and logout.
2023-09-30 14:18:15 -04:00
JosJuice
02d76ba2a0 Jit: Fix fastmem initialization order
When evaluating whether jo.fastmem should be set to true, we check the
value of jo.fastmem_arena. However, due to a change made in 28e8117b90,
jo.fastmem_arena wasn't set until after the first time we set
jo.fastmem, so jo.fastmem would end up always being false until the next
time RefreshConfig was called.

Fixes https://bugs.dolphin-emu.org/issues/13364.
2023-09-30 16:16:54 +02:00
JosJuice
9e0fea8fc7 PowerPC: Flip the order of frsqrte_expected
This makes the the frsqrte routines one instruction shorter.
2023-09-30 11:41:27 +02:00
Pablo Stebler
cc403c1044
DSPHLE: handle offsets to a different memory region 2023-09-29 20:48:10 +02:00
Pablo Stebler
8cdad9ce8c
DSPHLE: map memory based on console mode 2023-09-29 20:48:10 +02:00
Admiral H. Curtiss
7c995000ae
Merge pull request #12206 from malleoz/ppc_reg_location_assert_improvement
PowerPC: reduce location assert cost
2023-09-29 20:08:05 +02:00
LillyJadeKatrin
6541aa206d Added RequestImage to AchievementManager
Image requests from RetroAchievements have a slightly different format from other requests, on account of being GET calls that return strings of image data, so this is a separate function that makes such calls. To handle this, I create a BadgeStatus object that ties each badge to a boolean flag for whether it is loaded and thus usable.
2023-09-28 22:47:15 -04:00
sowens99
60e331e2e1 PowerPC: reduce location assert cost 2023-09-28 19:57:03 -04:00
Admiral H. Curtiss
a310b32525
Merge pull request #12207 from malleoz/decrease_emulation_speed_rollover_fix
DolphinQt: Fix decrease emulation speed hotkey rollover
2023-09-28 21:55:15 +02:00
Admiral H. Curtiss
908f90191d
Merge pull request #12204 from LillyJadeKatrin/retroachievements-bugfix
Retroachievements bugfix
2023-09-28 21:31:43 +02:00
LillyJadeKatrin
50f04ea456 Refactored FetchGameData to incorporate the request directly instead of a different method, so that game_data can be processed directly under a lock. 2023-09-28 00:57:22 -04:00
LillyJadeKatrin
6036a6db55 Updated AchievementManager StartRASession to properly lock inputs and outputs without locking during the network call. 2023-09-28 00:55:58 -04:00
LillyJadeKatrin
7153284e9f Updated AchievementManager ResolveHash to properly lock inputs and outputs without locking during the network call. 2023-09-28 00:55:58 -04:00
LillyJadeKatrin
a29ec7d956 Updated AchievementManager VerifyCredentials to properly lock inputs and outputs without locking during the network call. 2023-09-28 00:55:58 -04:00
LillyJadeKatrin
3c564078cd Added AchievementManager ResponseType EXPIRED_CONTEXT for when operation inputs change between when an operation is queued and executed, and MALFORMED_OBJECT for when an rcheevos process method goes wrong. 2023-09-28 00:55:58 -04:00
LillyJadeKatrin
31091fc975 Added GameLoaded check to AchievementProgressWidget. 2023-09-28 00:55:58 -04:00
LillyJadeKatrin
b53962fd23 Cleaned up some issues with AchievementManager::CloseGame. 2023-09-28 00:55:57 -04:00
Admiral H. Curtiss
45c8597082
Merge pull request #12201 from fabricecaruso/master
SaveStates : Fix MainWindow.m_state_slot is not restored from Qt.ini Emulation/StateSlot.
2023-09-28 05:30:48 +02:00
Admiral H. Curtiss
5b6844901f
Merge pull request #12205 from LillyJadeKatrin/retroachievements-bugfix-2
AchievementsWindow: Fix rapid popups on initial opening.
2023-09-28 04:21:48 +02:00
Admiral H. Curtiss
a7c5f2fd14
Merge pull request #12200 from itsmattkc/pipe-fifo-fix
FileUtil: Don't try to retrieve size for FIFO pipe
2023-09-28 04:14:41 +02:00
Fabrice CARUSO
2b2fd4217e
SaveStates: Fix MainWindow.m_state_slot is not restored from Qt.ini Emulation/StateSlot.
Select slot 2 and exit & launch Dolphin again. Slot 2 is selected in the menu, but saving from selected slot saves to slot 1.
2023-09-28 04:12:49 +02:00
Admiral H. Curtiss
53df01f7d8
Merge pull request #12172 from ArcaneNibble/sd
Steam Deck: Periodically reenable gyro
2023-09-28 04:10:27 +02:00
sowens99
eac318a1d8 DolphinQt: Fix decrease emulation speed hotkey rollover 2023-09-27 21:40:16 -04:00
LillyJadeKatrin
2a9121b66f Reorganized the first-round AchievementsWindow startup to prevent items from being visible before their parents, thus getting rid of the rapid popups. 2023-09-26 23:31:04 -04:00
deReeperJosh
d0de837efd HIDv4: Check Device Not Null Before Attaching 2023-09-26 18:10:29 +01:00
MattKC
e16753472c
FileUtil: Don't try to retrieve size for FIFO pipe 2023-09-24 19:36:15 -07:00
Sketch
def6cb0155 IOS/KD: Fix crash with KD Scheduler 2023-09-24 20:37:20 -04:00
Admiral H. Curtiss
15f42eb5d8
Merge pull request #12195 from LillyJadeKatrin/retroachievements-logging
Added log statements across AchievementManager.
2023-09-24 17:13:36 +02:00
Admiral H. Curtiss
c67cd65b53
Merge pull request #12190 from AdmiralCurtiss/fmt10
Update fmt to 10.1.1
2023-09-24 00:05:00 +02:00
LillyJadeKatrin
da00191eb6 Added log statements across AchievementManager. 2023-09-23 01:32:43 -04:00
sowens99
98dd10a716 Debugger/Memory: Fix unable to search mem2 2023-09-21 23:54:07 -04:00
JosJuice
24950ce0e0 JitArm64: Check packed NaNs without using extra register
A small optimization for AccurateNaNs.
2023-09-21 18:19:12 +02:00
JosJuice
8dbbae76de Jit64: Optimize ps_merge01 with Rd == Rb 2023-09-21 18:03:39 +02:00
get
63467559b2
fmt 10.0.0-10.1.1 compile fixes
Implicit conversion operators and enums was removed for parity with std::format (fce74caa15).
2023-09-21 01:19:23 +02:00
Admiral H. Curtiss
579ccb0710
Merge pull request #12160 from AdmiralCurtiss/achievement-log
Common/LogManager: Add logging category for Achievements.
2023-09-19 22:01:15 +02:00
JosJuice
9862ba4548
Merge pull request #12155 from krnlyng/jit_block_map_msr_fast
JitArm64/Jit64: Extend the fast lookup mmap-ed segment further to avoid needing to check the msr bits.
2023-09-17 15:13:53 +02:00
JosJuice
a79fe768e3 Jit64: Simplify ps_sum1 2023-09-17 11:04:37 +02:00
Admiral H. Curtiss
cc7fadfa4b
Merge pull request #12181 from JosJuice/curl-response-code-long
Common: Fix HttpRequest::GetLastResponseCode stack corruption
2023-09-16 16:48:47 +02:00
JosJuice
aa4de6516f Common: Fix HttpRequest::GetLastResponseCode stack corruption
Should fix https://bugs.dolphin-emu.org/issues/13353.
2023-09-16 16:01:28 +02:00
Frajo Haider
fd9c970621 JitArm64/Jit64: Extend the fast lookup mmap-ed segment further to avoid needing to check the msr bits.
And in order to avoid a double dereference in the dispatcher, directly store
the normalEntry in the map.

The index to the block map becomes ((((DR<<1) | IR) << 30) | (address >> 2)).
This has been chosen since the msr bits change less often than the address,
thus we keep nearby entries together.

Also do not call the C dispatcher in case the assembly dispatcher didn't
find a block, since it wouldn't find a block either due to the 1:1 mapping,
except when falling back to the non shm segment lookup table.
2023-09-15 19:46:15 +03:00
Admiral H. Curtiss
1a821465f4
Merge pull request #12166 from iwubcode/cubemap_shader_texture_integration
VideoCommon: add cubemap to ShaderAsset and TextureAsset
2023-09-12 16:56:26 +02:00
Admiral H. Curtiss
308a52a782
Merge pull request #12165 from noahpistilli/scheduler-downloader
IOS/KD: Implement Download Scheduler
2023-09-12 16:22:23 +02:00
Admiral H. Curtiss
3dada564bf
Merge pull request #12177 from AdmiralCurtiss/noreserve
Common/MemArena: Set MAP_NORESERVE in LazyMemoryRegion on Linux.
2023-09-12 16:21:59 +02:00
JosJuice
392dfbe05f JitArm64: Deduplicate the gather pipe exception check
We had two nearly identical copies of the gather pipe exception checking
code right next to each other, with the only difference being the
register used. Let's unify them, like in Jit64.
2023-09-10 16:34:10 +02:00
Admiral H. Curtiss
d16bedd5c4
Merge pull request #12178 from JosJuice/jit-gp-pc
Jit: Use correct address when checking fifoWriteAddresses
2023-09-10 15:58:23 +02:00
Admiral H. Curtiss
92d67df4e9
Merge pull request #12138 from JosJuice/jit-gp-check-discard
Jit: Don't discard before gather pipe interrupt check
2023-09-10 15:10:37 +02:00
Admiral H. Curtiss
7869abf0e6
Common/MemArena: Set MAP_NORESERVE in LazyMemoryRegion on Linux. 2023-09-10 14:52:34 +02:00
Sketch
3f6a976e0f IOS/KD: Implement Download Scheduler 2023-09-10 07:47:15 -04:00
JosJuice
34b0a6ea90 Jit: Check for discarded registers when flushing
This adds a check for the bug addressed by the previous commit.
2023-09-10 12:54:52 +02:00
JosJuice
5902b5b113 PPCAnalyst: Don't discard before gather pipe interrupt check
This bug has been lurking in the code ever since I added the discard
functionality. It doesn't seem to be triggered all that often,
and on top of that the emitted code only runs conditionally, so I'm not
sure if people have been affected by this bug in practice or not.
2023-09-10 12:54:52 +02:00
JosJuice
f7f4da2be8 Jit: Use correct address when checking fifoWriteAddresses
We need to check for the address of the *previous* instruction, because
checking fifoWriteAddresses happens not at the end of the instruction
that triggered it but at the start of the next instruction.
2023-09-10 12:54:18 +02:00
Admiral H. Curtiss
1a0f0e7e96
Merge pull request #12081 from JosJuice/jitarm64-debug-exit-pc
JitArm64: Store PC on debug exit
2023-09-10 02:10:29 +02:00
Admiral H. Curtiss
5e0cf795e3
Merge pull request #12169 from jordan-woyak/widescreen-heuristic-gameini
VideoCommon: Expose the widescreen heuristic's standard and widescreen values in onion config.
2023-09-09 16:51:11 +02:00
Admiral H. Curtiss
911c469cf5
Common/LogManager: Add logging category for Achievements. 2023-09-09 14:47:20 +02:00
R
860acfb15d Steam Deck: Periodically reenable gyro 2023-09-07 19:56:58 +01:00
JosJuice
57e56f4bc2
Merge pull request #12174 from AdmiralCurtiss/jitcache-32bit
Core/JitCache: Don't try to allocate the fast block map on 32-bit builds.
2023-09-07 19:29:04 +02:00
Admiral H. Curtiss
cf2a1f29b7
Core/JitCache: Don't try to allocate the fast block map on 32-bit builds. 2023-09-07 14:48:57 +02:00
Admiral H. Curtiss
422bc7a627
Common/MemArena: A zero-byte allocation is invalid. 2023-09-07 14:41:24 +02:00
Admiral H. Curtiss
c14bc6ea4c
Common/MemArena: mmap returns MAP_FAILED on error, not nullptr. 2023-09-07 13:59:33 +02:00
Admiral H. Curtiss
a20bb3e05b
Common/MemArena: Assert return value of LazyMemoryRegion::Clear()'s mmap() call. 2023-09-07 04:00:22 +02:00
Jordan Woyak
7cc4304918 VideoCommon: Expose the widescreen heuristic's standard and widescreen ratio values in onion config. 2023-09-06 18:45:28 -05:00
JMC47
c0440df288
Merge pull request #12029 from LillyJadeKatrin/retroachievements-bugfix-2
RetroAchievements - Rearranged startup process
2023-09-06 12:23:52 -04:00
JMC47
3b5b9e0fc0
Merge pull request #12028 from LillyJadeKatrin/retroachievements-bugfix
RetroAchievements - Add Rich Presence to Achievement Dialog Header
2023-09-06 12:20:20 -04:00
LillyJadeKatrin
38bd04c439 Add Rich Presence to Achievement Dialog Header
This refactors the Rich Presence generation to store to a member field that can be exposed to the UI to display the Rich Presence in the achievement header. It still updates at its original rate of once per two minutes, but calls an update on the dialog when that ticks.
2023-09-06 10:01:33 -04:00
iwubcode
589834f562 VideoCommon: add cubemap as a sampler target for shaders, add cubemap as a valid texture asset 2023-09-05 21:11:19 -05:00
JMC47
76a00551d1
Merge pull request #11419 from OatmealDome/widescreen
VideoCommon: Allow widescreen heuristic's constants to be overridden by onion config
2023-09-05 13:25:07 -04:00
OatmealDome
4938b99600 VertexManagerBase: Allow widecreen heuristic constants to be overriden by onion config 2023-09-05 11:50:49 -04:00
OatmealDome
de781a6fa7 RenderBase: Allow widescreen heuristic's transition threshold to be overridden by onion config 2023-09-05 11:49:22 -04:00
JMC47
9419d92446
Merge pull request #12139 from iwubcode/more_shader_texture_properties
VideoCommon: add additional texture sampler types to ShaderAsset
2023-09-04 22:45:56 -04:00
JMC47
82ea4f4c70
Merge pull request #12137 from iwubcode/custom_pipeline_more_error_checking
VideoCommon: additional error checking for CustomPipelineAction
2023-09-04 22:43:41 -04:00
JMC47
627282473b
Merge pull request #12136 from iwubcode/texture_metadata_struct
VideoCommon: add TextureData structure with metadata
2023-09-04 22:40:50 -04:00
Pokechu22
d0afe36269 Disable Arbitrary Mipmap Detection checkbox when GPU Texture Decoding is enabled
See https://bugs.dolphin-emu.org/issues/13049
2023-09-04 13:24:05 -07:00
Pokechu22
b969d89103 Disable Texture Filtering dropdown when Manual Texture Sampling is checked
See https://bugs.dolphin-emu.org/issues/13049
2023-09-04 13:24:03 -07:00
JMC47
efabcaf6ea
Merge pull request #12159 from noahpistilli/evc+rgnsel
Add Everybody Votes Channel and Region Select to WiiLink config
2023-09-04 12:00:02 -04:00
LillyJadeKatrin
348e60cd3f Rearranged RetroAchievements startup process
Moved AchievementManager Init further down in the MainWindow constructor; its original position was because it had an impact on the contents of the menu bar, and this is no longer the case.
2023-09-04 09:32:13 -04:00
OatmealDome
3e9c9a3e8d
Merge pull request #12004 from TellowKrinkle/MetalMultiTarget
VideoBackends:Metal: Multi render target support
2023-09-03 23:31:38 -04:00
JMC47
900439ea0d
Merge pull request #12102 from iwubcode/cubemap_custom_texture
VideoCommon: add ability to load cube maps into custom texture data
2023-09-03 18:29:00 -04:00
Sketch
fb852a5062 VideoCommon: Deinit Graphics Mod Manager implicitly 2023-09-03 16:06:08 -04:00
Sketch
fdaa82f96d Add Everybody Votes Channel and Region Select to WiiLink config 2023-09-03 15:56:02 -04:00
Admiral H. Curtiss
143a13622f
Merge pull request #12108 from noahpistilli/kd-check-mail
IOS/KD: Implement NWC24_CHECK_MAIL_NOW
2023-09-03 19:52:26 +02:00
Sketch
2154941c2c IOS/KD: Implement NWC24_CHECK_MAIL_NOW 2023-09-03 13:05:58 -04:00
Admiral H. Curtiss
f063fb31b3
Merge pull request #12149 from noahpistilli/no-response-header-rsa
IOS/KD: Check if a file has an RSA signature
2023-09-03 03:50:18 +02:00
Sketch
fa2bc535f1 IOS/KD: Check if a file has an RSA signature 2023-09-02 21:39:54 -04:00
Admiral H. Curtiss
46a596c0d3
Merge pull request #12148 from Dentomologist/fifo_convert_memoryupdate_type_to_enum_class
Fifo: Convert MemoryUpdate::Type to enum class
2023-09-03 03:34:35 +02:00
iwubcode
62fee2f3b6 VideoCommon: add loading cube maps from DDS files and loading it into our custom texture object. Custom texture object now has the concept of slices in addition to levels. Traditional custom textures have a single slice 2023-09-02 20:20:09 -05:00
Dentomologist
9cabf20aaa Fifo: Convert MemoryUpdate::Type to enum class 2023-09-02 18:19:26 -07:00
Admiral H. Curtiss
6d04618921
Merge pull request #12157 from Dentomologist/texturecachebase_add_m_prefix
TextureCacheBase: Add m_ prefix to member variables
2023-09-03 03:10:57 +02:00
JMC47
bd57d17dee
Merge pull request #12079 from JosJuice/blr-no-fastmem
Jit: Allow BLR optimization without fastmem
2023-09-02 12:45:39 -04:00
Dentomologist
d5d3eb5025 TextureCacheBase: Add m_ prefix to member variables 2023-09-01 22:52:17 -07:00
Admiral H. Curtiss
f1c1c6ded6
JitCache: Fix potentially dangling pointer to fast block map.
Whenever JitBaseBlockCache::Clear() got called, it threw away the memory mapping for the fast block map and created a new one. This new mapping typically got mapped at the same address at the old one, but this is not guaranteed. The pointer to the mapping gets embedded in the generated dispatcher code in Jit64AsmRoutineManager::Generate(), which is only called once on game boot, so if the new mapping ended up at a different address than the old one, the pointer in the ASM pointed at garbage, leading to a crash.

This fixes the issue by guaranteeing that the new mapping is mapped at the same address.
2023-09-02 04:03:22 +02:00
Admiral H. Curtiss
5bd7756064
Common/MemArena: Add LazyMemoryRegion to represent a zero-initialized memory region whose pages are only allocated on first access. 2023-09-02 04:02:10 +02:00
JosJuice
4131dffae9 Jit: Allow BLR optimization without fastmem
While both fastmem and the BLR optimization depend on fault handling,
the BLR optimization doesn't depend on fastmem, and there are cases
where you might want the BLR optimization but not fastmem. For me
personally, it's useful when I try to use a debugger on Android and have
to disable fastmem so I don't get SIGSEGVs all the time, but it would be
especially useful for iOS users.
2023-08-29 22:55:29 +02:00
JosJuice
af2c32635a Jit: Add more error checking to ProtectStack 2023-08-29 22:46:50 +02:00
JMC47
1b2d0c0507
Merge pull request #10575 from JosJuice/jitbase-auto-clear
Jit: Automatically clear cache when JIT settings are updated
2023-08-29 15:56:25 -04:00
JosJuice
8c2c665af3 Jit: Check MSR state in BLR optimization
When we execute a JIT block, we have to make sure that both the PC and
the DR/IR bits of MSR are the same as they were when the block was
compiled. When jumping to a block from the dispatcher, this is done in
the way you would expect: By checking the PC and the relevant MSR bits.
However, when returning to a block using the BLR optimization, we only
check the PC. Checking the MSR bits is done by instead resetting the
stack when the MSR changes, making PC checks afterwards fail.

Except... We were only resetting the stack on rfi instructions. There
are actually many more ways for the MSR to change, and we weren't
covering those at all. I looked into resetting the stack on all of them,
but it would be pretty cumbersome both in terms of writing the code and
in terms of how often at runtime we'd have to reset the stack, so I
think the better option would be to check the MSR bits along with the
PC. That's what this commit implements.
2023-08-29 19:05:26 +02:00
Admiral H. Curtiss
69db8a615f
Merge pull request #12145 from JosJuice/ubershaderpixel-uint
VideoCommon: Fix GLSL uint handling in UberShaderPixel
2023-08-29 12:33:54 +02:00
Admiral H. Curtiss
df120b0630
Merge pull request #12000 from Filoppi/window_res_fix
Video: Fix issues with the window presentation
2023-08-28 23:50:50 +02:00
Admiral H. Curtiss
357db03fc8
Merge pull request #12030 from LillyJadeKatrin/retroachievements-bugfix-3
RetroAchievements - Fixed Leaderboard Scored message format
2023-08-28 23:28:37 +02:00
JosJuice
5b112dbf2c VideoCommon: Fix GLSL uint handling in UberShaderPixel 2023-08-28 21:17:01 +02:00
JosJuice
b922f4baa6 JitArm64: Write PC when calling MMU.cpp
This functionality was in Jit64 but not JitArm64.
2023-08-27 18:45:34 +02:00
JosJuice
58f247290f Use latest resolution value for resolution hotkey OSD
Because CPU thread config changed callbacks are no longer instant,
g_Config.iEFBScale doesn't yet contain the new value when the hotkey OSD
code tries to read it.

Should fix https://bugs.dolphin-emu.org/issues/13343.
2023-08-27 15:38:00 +02:00
iwubcode
f982c556b5 VideoCommon: add additional texture sampler types to ShaderAsset 2023-08-26 12:12:37 -05:00
Frajo Haider
7daa19f40d JitArm64: Avoid loading compilerPC multiple times if it's already in a register. 2023-08-26 18:14:07 +03:00
JosJuice
85281e76ee Jit: Remove unnecessary member variables 2023-08-26 17:05:04 +02:00
JosJuice
07d70db46b DolphinQt: Allow toggling most JIT debug settings at any time
There's no reason not to allow this now that these settings are
cleanly integrated into the new config system. (Actually, maybe
we could even have done this before the previous commit...)
2023-08-26 17:05:04 +02:00
JosJuice
28e8117b90 Jit: Automatically clear cache when JIT settings are updated
This fixes a problem where changing the JIT debug settings on
Android while a game was running wouldn't cause the changed settings
to apply to code blocks that already had been compiled.
2023-08-26 17:04:56 +02:00
JosJuice
cd31da97d6
Merge pull request #11191 from JosJuice/jitarm64-no-checked-entry
JitArm64: Never check downcount on block entry
2023-08-26 17:00:08 +02:00
Admiral H. Curtiss
799ce0dc9d
Merge pull request #12097 from Dentomologist/ios_remove_unused_member_variables
IOS: Remove unused member variable from SharedContentMap and UIDSys
2023-08-26 16:41:45 +02:00
Admiral H. Curtiss
2502e412b3
Merge pull request #12117 from JosJuice/config-callback-cpu
Don't call RunAsCPUThread in config callbacks
2023-08-26 16:34:46 +02:00
Admiral H. Curtiss
d8e35438bd
Merge pull request #12127 from sepalani/ascii_
MemoryViewWidget: Fix some characters being truncated
2023-08-26 14:56:26 +02:00
Admiral H. Curtiss
65a9be581f
Merge pull request #12121 from JosJuice/discscrubber-volume-ptr
DiscIO: Don't keep volume pointer in DiscScrubber
2023-08-26 14:31:15 +02:00
Admiral H. Curtiss
dec2990053
Merge pull request #12128 from Dentomologist/gcc_suppress_ppcstate_off_warning_spam
GCC: Suppress PPCSTATE_OFF invalid-offsetof warnings
2023-08-26 14:22:04 +02:00
Admiral H. Curtiss
e876045e56
Merge pull request #12135 from Dentomologist/jitarm64_resolve_deprecated_enum_conversion_warning
JitArm64: Resolve deprecated enum conversion warning
2023-08-26 14:18:58 +02:00
Admiral H. Curtiss
5c4671f573
Merge pull request #12126 from JosJuice/small-vector
Move SmallVector to Common
2023-08-26 14:15:18 +02:00
iwubcode
9223540bf4 VideoCommon: additional error checking for CustomPipelineAction and move the pixel shader asset cache time back to being calculated during texture creation 2023-08-24 00:47:48 -05:00
iwubcode
7c52a52440 VideoCommon: add TextureData structure that contains the raw texture data, a sampler, and the type of texture information 2023-08-24 00:35:31 -05:00
Dentomologist
a650a16f4c JitArm64: Resolve deprecated enum conversion warning
Resolve warning caused by using values from two different enums in a
conditional expression which was deprecated in c++20.

The warning in question is clang -Wdeprecated-anon-enum-enum-conversion
and gcc -Wenum-compare.
2023-08-23 14:38:52 -07:00
JosJuice
ba99d17ac0 VideoCommon: Fix custom shader constants on GLES 2023-08-22 19:38:18 +02:00
Admiral H. Curtiss
4223cd0264
Merge pull request #12130 from JosJuice/translation-fixes
Fixes to translatable strings
2023-08-22 16:44:36 +02:00
JosJuice
6e88c44d5d Move SmallVector to Common
We had one implementation of this type of data structure in Arm64Emitter
and one in VideoCommon. This moves the Arm64Emitter implementation to
its own file and adds begin and end functions to it, so that VideoCommon
can use it.

You may notice that the license header for the new file is CC0. I wrote
the Arm64Emitter implementation of SmallVector, so this should be no
problem.
2023-08-22 13:19:49 +02:00
iwubcode
55fba7c0ed
VideoCommon/GraphicsModAsset: Error out if config key is not a string. 2023-08-22 02:40:08 +02:00
Dentomologist
58ab94c30c GCC: Suppress PPCSTATE_OFF invalid-offsetof warnings
Modify PPCSTATE_OFF and PPCSTATE_OFF_ARRAY macros when using GCC to
avoid useless log spam. Specifically, use a consteval lambda with gcc
_Pragma statements to disable the -Winvalid-offsetof warning inside the
macros.

Each successful build (and many failing ones) on the Android buildbot
generates almost 300 cases of -Winvalid-offsetof, resulting in thousands
of lines of log spam per build. In addition to bloating the log filesize
these spurious warnings make it harder to find actual warnings.

These warnings are generated by calls to the macros PPCSTATE_OFF and
PPCSTATE_OFF_ARRAY, which in turn are used by many other macros used by
the JIT. The ultimate cause is that offsetof is only conditionally
supported on non-standard-layout types, which includes the PowerPCState
struct.

To address potential questions of whether there's a better way to handle
this:

The obvious solution would be to modify PowerPCState so that it does
have a standard layout. This is unfortunately impractical.

To have a standard layout a type can only contain other types with
standard layouts. None of the stl containers are guaranteed to have
standard layouts, and PowerPCState contains a std::tuple and std::array.
PowerPCState also contains a PowerPC::Cache and InstructionCache which
themselves contain std:arrays and std::vectors.

Furthermore InstructionCache derives from Cache, and a derived class can
only have standard layout if at most one class in its hierarchy has a
non-static data member, but both classes have such members. Making
InstructionCache have a standard layout would require duplicating all
the functionality of Cache so it no longer derived from it, as well as
replacing the stl containers. This might require having a raw pointer to
said containers, with the manual memory management that implies.

All of that would be much more disruptive than would be justified to get
rid of some warnings (however annoying they might be). This is
compounded by the fact that PowerPCState hasn't had a standard layout
for a long time, if ever, and if the PPCSTATE_OFF macros weren't working
reliably it would have become obvious a long time ago.

As to why I picked the lambda solution over other potential changes:

- Keeping the define as-is and wrapping some gcc #pragmas around it
  doesn't work because the pragmas don't get included when the define is
  substituted to the call site.

- Keeping the define as a non-lambda expression and using inline
  _Pragma() statements would ideally be better and works fine for msvc,
  but fails for GCC with "'#pragma' is not allowed here".

- Turning off -Winvalid-offsetof globally for gcc would work, but there
  might be other contexts where offsetof is problematic and GCC seems to
  be the only compiler warning about it.
2023-08-21 14:01:11 -07:00
Sepalani
573863703a MemoryViewWidget: Fix some characters being truncated 2023-08-21 22:02:44 +04:00
JosJuice
e7c2133160 Fixes to translatable strings 2023-08-21 16:29:52 +02:00
iwubcode
5506121685 VideoCommon: add support to graphics mod manager to load in assets and pass it to graphics actions 2023-08-20 18:53:27 -05:00
iwubcode
6ea0d17802 VideoCommon: when graphics settings change, trigger a reload of all custom shaders 2023-08-20 18:53:27 -05:00
iwubcode
931a8aa413 VideoCommon: add milliseconds elapsed time value to pixel shaders as a uniform to be able to support animation effects in custom shaders 2023-08-20 18:53:27 -05:00
iwubcode
c7191382be VideoCommon: add custom pipeline action 2023-08-20 18:53:27 -05:00
iwubcode
d320366954 VideoCommon: add custom shader cache to VertexManagerBase, supporting custom pixel shaders by replacing the existing pipeline with a modified one 2023-08-20 18:53:27 -05:00
iwubcode
bedbf2b8c6 VideoCommon: add custom shader cache 2023-08-20 18:53:27 -05:00
iwubcode
dbaf24ef09 VideoCommon: add data needed to support custom pixel shaders to graphics mod actions 2023-08-20 18:53:27 -05:00
iwubcode
4283d76718 VideoCommon: uber pixel shader gen changes needed to support custom pixel shaders in graphics mods 2023-08-20 18:53:27 -05:00
iwubcode
e704385fce VideoCommon: pixel shader gen changes needed to support custom pixel shaders in graphics mods 2023-08-20 18:53:27 -05:00
iwubcode
c3a370839a VideoCommon: add helper functions to handle generating custom lighting code for a custom pixel shader 2023-08-20 18:53:27 -05:00
iwubcode
0da5cf60a8 VideoCommon: add custom pixel shader definition and custom shader header to shadergen common as it will be used by both the special and uber shader variant of pixel shaders 2023-08-20 18:53:27 -05:00
Admiral H. Curtiss
f19651e49b
Merge pull request #11025 from AdmiralCurtiss/hle-printf
HLE_OS: Manually handle printfs from emulated software to prevent emulated software from crashing Dolphin with an invalid printf formatting string.
2023-08-20 01:31:49 +02:00
JosJuice
d34d3bd513 JitArm64: Optimize mfsrin/mtsrin address calculations
This does require another register, but we skip having to use shifted
ADD, which takes two cycles on some CPUs, and we gain instruction-level
parallelism.
2023-08-19 21:37:06 +02:00
JosJuice
c70dcf99dd Jit: Some mcrxr optimizations 2023-08-19 21:13:56 +02:00
JosJuice
5ea1cc5406 JitArm64: Fix mcrxr
Likely an incorrect translation of Jit64's LEA with SCALE_2.
2023-08-19 20:57:32 +02:00
JosJuice
5931d74d52 JitArm64: Remove unnecessary BindToRegister calls
BindToRegister is only needed when writing to a register.
2023-08-19 19:46:53 +02:00
JosJuice
9192128c50 Jit: Handle imm msr in EmitStoreMembase
This makes Jit64::mtmsr more optimized in particular.
2023-08-19 19:45:35 +02:00
JosJuice
0f64df3e3e DiscIO: Don't keep volume pointer in DiscScrubber
Keeping the pointer creates use-after-free opportunities, and we don't
have much reason to keep it around anyway.
2023-08-19 17:30:22 +02:00
Admiral H. Curtiss
d36f0fff4c
Jit64: Actually update membase register after GlobalAdvance(). 2023-08-19 17:00:01 +02:00
JosJuice
ed7894924c
Merge pull request #12048 from krnlyng/someothertest
Jit: Load the memory register only when the msr bits have changed and do not use jumps to load it.
2023-08-19 09:49:29 +02:00
Admiral H. Curtiss
b6bfa10ace
Merge pull request #11996 from Dentomologist/remove_pointless_pauseandlock_functions
EXI: Remove pointless PauseAndLock functions
2023-08-18 21:35:56 +02:00
Admiral H. Curtiss
bb4ed1c450
Merge pull request #12118 from AdmiralCurtiss/tas-window-translatable
DolphinQt/TASInputWindow: Make 'Enable Controller Input' translatable.
2023-08-18 21:33:23 +02:00
Admiral H. Curtiss
8a96ce73f6
Merge pull request #12044 from jmlee337/upnpport
Do not try portmapping when using traversal server
2023-08-18 21:28:52 +02:00
Admiral H. Curtiss
9a51215af3
Merge pull request #12083 from JosJuice/android-controlled-by-gamepad
InputConfig: Update IsControllerControlledByGamepadDevice for Android input overhaul
2023-08-18 21:27:26 +02:00
xujibbs
b3902397cb
DolphinQt/TASInputWindow: Make 'Enable Controller Input' translatable. 2023-08-18 21:02:30 +02:00
Admiral H. Curtiss
3441fe6efc
Merge pull request #11999 from Filoppi/post_process_fixes
Video: implement output resampling (upscaling/downscaling) methods
2023-08-18 20:33:09 +02:00
JosJuice
a9ec2a6e41
Merge pull request #12116 from AdmiralCurtiss/log-colors
DolphinQt/LogWidget: Restore log window colors.
2023-08-18 09:00:43 +02:00
Filoppi
8bca9a864f Video: The Auto internal resolution scaling wasn't working correctly if the window weird aspect ratios (e.g. 32:9), beacuse it would account for the the portion of the image that will show black bars into the calcuations to find the best matching resolution 2023-08-18 02:14:00 +03:00
Filoppi
6c7f34d5da Video: The Auto-Adjust Window Size setting was calculating the window size based on the resolution of the window in the previous frame if we used the "stretch" aspect ratio setting, so it's result would be self influence in a loop and behave unreliably (e.g. when changing resolution between Auto/Native/2x the automatic window scaling would behave randomly) 2023-08-18 02:14:00 +03:00
Filoppi
cb34d1aafe Video: There was always a black line around one of the 4 edges (top/left/bottom/right) of the window because the final output size wasn't calculated right (unless the aspect ratio was set to stretch) 2023-08-18 02:14:00 +03:00
Filoppi
fae3aee9e0 Video: The % 4 that was done on the rendering resolution was only meant to be done when recording videos (due to encoding limitations) but one case was missed (this had no consequences really, as it was just in the code that automatically resizes the window). The hardcoded 4 has been replaced with VIDEO_ENCODER_LMC for clarity. 2023-08-18 02:14:00 +03:00
Filoppi
80b453082d Video: fix post process shaders with parameters failing to build on OpenGL
This was because the shader uniforms between the pixel and vertex shaders
were willingly left different, to avoid filling the vertex shader with unnecessary
params. Turns out all backends are fine with this except OGL.
The new behaviour is now much more consistent and well explained,
the "default" shaders are the ones that always run, and the non default
ones are the user selected ones (if any).
2023-08-18 02:00:56 +03:00
Sam Belliveau
39d96a21a8 Video: Improved Tooltips & Bicubic (#5)
Edited by Filoppi
2023-08-18 02:00:56 +03:00
Sam Belliveau
ca93a5191f Video: Added Box Resampling
Edited by Filoppi
2023-08-18 02:00:56 +03:00
Filoppi
2edf81cdb0 Video: implement output resampling (upscaling/downscaling) methods 2023-08-18 02:00:55 +03:00
Admiral H. Curtiss
1854ff0142
Merge pull request #12003 from Filoppi/auto_hdr
Add AutoHDR post process shader
2023-08-18 00:20:08 +02:00
Admiral H. Curtiss
ecf5870a91
Merge pull request #12115 from AdmiralCurtiss/advanced-config
DolphinQt/AdvancedPane: UI improvements.
2023-08-18 00:16:59 +02:00
Admiral H. Curtiss
42e893d6be
Merge pull request #12114 from AdmiralCurtiss/color-correction-button
DolphinQt/EnhancementsWidget: Use custom tooltip for Color Correction button.
2023-08-18 00:16:47 +02:00
Admiral H. Curtiss
a08792033a
Merge pull request #12103 from iwubcode/asset_load_system_time
VideoCommon: asset load time is now stored as a chrono system_clock time
2023-08-18 00:14:29 +02:00
JosJuice
b62c25864f CPUThreadConfigCallback: Remove some CPU thread asserts
Turns out that we have two subsystems that want to register CPU thread
callbacks from a different thread than the CPU thread: FreeLookConfig
and VideoConfig. Both seem to happen from the host thread before the CPU
thread starts, so there's no thread safety issue. But ideally, if we
want to allow registering callbacks from threads other than the CPU
thread, we should make registering callbacks actually thread-safe. This
is an unsolved problem for the regular Config system, so I would like to
leave it outside the scope of this PR.
2023-08-17 19:19:26 +02:00
JosJuice
7197e3abd0 Use structs for config callback IDs
This way you can't mix up regular config callback IDs and CPU thread
config callback IDs. (It would be rather bad if you did!)
2023-08-17 19:19:26 +02:00
JosJuice
2b17e89336 Config: Don't clear callbacks on shutdown
This fixes a problem that started happening in CoreTimingTest after the
previous commit. CPUThreadConfigCallback registers a Config callback
only once per run of the process, but CoreTimingTest calls
Config::Shutdown after each test, and Config::Shutdown was clearing all
callbacks, preventing the callback from running after that.
2023-08-17 19:19:25 +02:00
JosJuice
71ce8bb6f0 Don't call RunAsCPUThread in config callbacks
In theory, our config system supports calling Set from any thread. But
because we have config callbacks that call RunAsCPUThread, it's a lot
more restricted in practice. Calling Set from any thread other than the
host thread or the CPU thread is formally thread unsafe, and calling Set
on the host thread while the CPU thread is showing a panic alert causes
a deadlock. This is especially a problem because 04072f0 made the
"Ignore for this session" button in panic alerts call Set.

Because so many of our config callbacks want their code to run on the
CPU thread, I thought it would make sense to have a centralized way to
move execution to the CPU thread for config callbacks. To solve the
deadlock problem, this new way is non-blocking. This means that threads
other than the CPU thread might continue executing before the CPU thread
is informed of the new config, but I don't think there's any problem
with that.

Intends to fix https://bugs.dolphin-emu.org/issues/13108.
2023-08-17 19:19:25 +02:00
Admiral H. Curtiss
a9cba9be36
DolphinQt/LogWidget: Restore log window colors. 2023-08-16 19:55:18 +02:00
Admiral H. Curtiss
a34f221782
Core/PowerPC: Return AvailableCPUCores() as a std::span. 2023-08-16 19:25:03 +02:00
Admiral H. Curtiss
51f807b63a
DolphinQt/AdvancedPane: Update all GUI elements from config in Update(). 2023-08-16 19:25:03 +02:00
Admiral H. Curtiss
ccee66dc80
DolphinQt/AdvancedPane: Use ConfigBool for MMU, Pause on Panic, and Write-Back Cache. 2023-08-16 19:25:03 +02:00
Admiral H. Curtiss
23ae8c439c
Merge pull request #12112 from JosJuice/hires-texture-encoding
VideoCommon: Fix std::filesystem::path encoding conversion
2023-08-16 18:39:18 +02:00
JosJuice
86910f406e VideoCommon: Fix std::filesystem::path encoding conversion
In std::string, you can store strings using any encoding, but in Dolphin
we have decided to use UTF-8. The problem is that if you convert between
std::string and std::filesystem::path using the built-in methods, the
standard library will make up its own assumption of what encoding you're
using in the std::string. On most OSes this is UTF-8, but on Windows
it's whatever the user's code page is.

What I believe is the C++ standard authors' intended solution to this is
to use std::u8string instead of std::string, but that's a big hassle to
move over to, because there's no convenient way to convert between
std::string and std::u8string. Instead, in Dolphin, we have added helper
functions that convert between std::string and std::filesystem::path in
the manner we want. You *always* have to use these when converting
between std::string and std::filesystem::path, otherwise we get these
kinds of encoding problems that we've been having with custom textures.

Fixes https://bugs.dolphin-emu.org/issues/13328.
2023-08-16 09:56:56 +02:00
JosJuice
177ac0cd44
Merge pull request #12111 from OatmealDome/old-amd-bug
Remove `BUG_BROKEN_FRAGMENT_SHADER_INDEX_DECORATION`
2023-08-16 09:20:49 +02:00
Pokechu22
10c5da6f62
Merge pull request #12107 from MikeIsAStar/retrieve-page-table-information-from-data-cache
Retrieve page table information from the data cache
2023-08-15 22:01:01 -07:00
takayhan-AMD
b969282b72 Remove out-dated hack of AMD driver issue WRT dual-source blending output index. 2023-08-15 23:58:29 -04:00
iwubcode
eeb73460ab VideoCommon: asset load time is now stored as a chrono system_clock time, so that times can be fabricated in a future feature (without creating a file to do so) 2023-08-15 22:02:28 -05:00
Admiral H. Curtiss
a10d768c63
Merge pull request #12104 from iwubcode/descriptor_sample_size_constant_dx12
VideoBackends: update SRVDescriptorTable size in DX12 to use pixel sampler constant
2023-08-15 23:15:19 +02:00
Admiral H. Curtiss
a44606692a
Merge pull request #12096 from Dentomologist/nandpaths_resolve_android_warning
NandPaths: Resolve Android tautological comparison warning
2023-08-15 22:23:57 +02:00
Admiral H. Curtiss
2cbc1e6f3e
Merge pull request #12109 from JosJuice/android-adddevice-null
ControllerInterface/Android: Add null check to AddDevice
2023-08-15 22:22:45 +02:00
MikeIsAStar
0bb5c88a22 Retrieve page table information from the data cache
Thanks to @mkwcat for identifying the problematic code.
2023-08-15 12:44:55 -04:00
JosJuice
1d77bddc3b ControllerInterface/Android: Add null check to AddDevice
The Google Play Console is showing some users getting a crash here,
and indeed, InputDevice.getDevice can return null.
2023-08-15 13:31:18 +02:00
iwubcode
89e2fc1dd3 VideoBackends: update SRVDescriptorTable size in DX12 to use pixel sampler constant 2023-08-13 17:23:26 -05:00
Admiral H. Curtiss
5635a0bdef
DolphinQt/EnhancementsWidget: Use custom tooltip for Color Correction button. 2023-08-13 22:46:46 +02:00
Admiral H. Curtiss
2537f4db91
Merge pull request #12100 from AdmiralCurtiss/tooltip-pushbutton
DolphinQt: Add ToolTipPushButton.
2023-08-13 21:44:24 +02:00
JMC47
4549091f56
Merge pull request #12090 from mandar1jn/figures-split
Skylanders: expand and improve character list
2023-08-13 14:29:46 -04:00
Mandar1jn
31d6aa5117 Skylanders: expand and improve character list
The previous list had some issues. A lot of variant id's were set to 0x0000. Althought this works for some figures, on a technicallity implemented into the games, they are technically wrong and don't result in exactly the same experience as the real figures. For example, the previous small fry got a "series 1" text in the summon screen. The real small fry does not have this. I also added figure types so I can add seperate generation logic later.
The Kaos element only applies to 3 items. So, I decided to throw it under others since it's not listed as an element in the manual and you can easily search for Kaos
2023-08-13 19:55:10 +02:00