Commit graph

29750 commits

Author SHA1 Message Date
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
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
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
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
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
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
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