Commit Graph

9871 Commits (3d3cc35ee76c4cfda01865ef1ed68d83969d6df1)
 

Author SHA1 Message Date
Lioncash 9dcc229dfe common/assert: Add UNIMPLEMENTED_IF and UNIMPLEMENTED_IF_MSG for conditional assertions
Currently, there's no way to specify if an assertion should
conditionally occur due to unimplemented behavior. This is useful when
something is only partially implemented (e.g. due to ongoing RE work).
In particular, this would be useful within the graphics code.

The rationale behind this is it allows a dev to disable unimplemented
feature assertions (which can occur in an unrelated work area), while
still enabling regular assertions, which act as behavior guards for
conditions or states which must not occur. Previously, the only way a
dev could temporarily disable asserts, was to disable the regular
assertion macros, which has the downside of also disabling, well, the
regular assertions which hold more sanitizing value, as opposed to
unimplemented feature assertions.
6 years ago
Lioncash aaec85df9e common/assert: Make the UNIMPLEMENTED macro properly assert
Currently, this was only performing a logging call, which doesn't
actually invoke any assertion behavior. This is unlike
UNIMPLEMENTED_MSG, which *does* assert.

This makes the expected behavior uniform across both macros.
6 years ago
Zach Hilman da6d4cde56 patch_manager: Apply LayeredExeFS patches
This will scan the <mod>/exefs dir for all files and then layer those on top of the game's exefs and use this as the new exefs. This allows for overriding of the compressed NSOs or adding new files. This does use the same dir as IPS/IPSwitch patch, but since the loader will not look for those they are ignored.
6 years ago
Zach Hilman 17d8e25cbf settings: Add option to dump ExeFS of games upon launch
When enabled, all exefs(es) will be copied to yuzu/dump/<title_id>/exefs.
6 years ago
Lioncash 31d1e06eb1 kernel/process: Move <random> include to the cpp file
<random> isn't necesary directly within the header and can be placed in
the cpp file where its needed. Avoids propagating random generation
utilities via a header file.
6 years ago
Markus Wick cfbae58b2b shader_cache: Only lock covered instructions. 6 years ago
Lioncash 73b7748984 am/applets: Make the applet data broker part of the applet itself.
The accessor should be doing just that, accessing, rather than retaining
the lifetime of the data broker as well.
6 years ago
Lioncash 8b4b560df5 am/applets: Replace includes with forward declarations where applicable
Also resolve places where includes should have been provided, but
weren't.
6 years ago
Lioncash dd254c603d am/applets: Relocate comments above the relevant data member in AppletDataBroker
Avoids wonky wrapping and makes it nicer to read.
6 years ago
Lioncash 4dcdd3a837 yuzu/applets/software_keyboard: Override accept() and reject() instead of providing own differently named member functions
Uses Qt's built-in interface instead of rolling our own separate one on
top of it. This also fixes a bug in reject() where we were calling
accept() instead of reject().
6 years ago
Lioncash 3fa2b218ac yuzu/applets/software_keyboard: std::move std::function instances where applicable
std::function instances can potentially allocate. std::moveing them
prevents an avoidable allocation in that case.
6 years ago
Lioncash fe2609cb77 yuzu/applets/software_keyboard: Make slots private functions
These aren't required to be public.
6 years ago
bunnei b6d2c64f4d
Merge pull request #1667 from DarkLordZach/swkbd
am: Implement HLE software keyboard applet
6 years ago
bunnei e9265ac598
Merge pull request #1739 from lioncash/lm
lm: Implement SetDestination by doing nothing
6 years ago
bunnei 2caac4a395
Merge pull request #1738 from lioncash/res-limit
kernel/resource_limit: Clean up interface
6 years ago
FernandoS27 eb36463e03 Implemented Fast Layered Copy 6 years ago
Lioncash 5d46038c5c kernel/resource_limit: Clean up interface
Cleans out the citra/3DS-specific implementation details that don't
apply to the Switch. Sets the stage for implementing ResourceLimit
instances properly.

While we're at it, remove the erroneous checks within CreateThread() and
SetThreadPriority(). While these are indeed checked in some capacity,
they are not checked via a ResourceLimit instance.

In the process of moving out Citra-specifics, this also replaces the
system ResourceLimit instance's values with ones from the Switch.
6 years ago
Lioncash 34e4aaddd9 lm: Implement SetDestination by doing nothing
This service function was likely intended to be a way to redirect where
the output of a log went. e.g. Firing a log over a network, dumping over
a tunneling session, etc.

Given we always want to see the log and not change its output. It's one
of the lucky service functions where the easiest implementation is to
just do nothing at all and return success.
6 years ago
Zach Hilman a9fa890f14 software_keyboard: Fix erroneous extra PushNormalData 6 years ago
Zach Hilman d68795c665 software_keyboard: Return correct result code on user cancel operation 6 years ago
Zach Hilman 32775125b7 applet: Add AppletDataBroker to manage HLE to AM service interaction
This cleans up most of the callbacks and such in the Applets::Applet interface, while also properly implementing all four data channels.
6 years ago
bunnei 048da7240d
Merge pull request #1634 from DarkLordZach/better-hid-2
hid: Add support for multiplayer and multilayout controllers
6 years ago
Zach Hilman 96535c13a5 software_keyboard: Use correct offset for inital text string 6 years ago
Lioncash 233e495c14 kernel/shared_memory: Make Map() and Unmap() take the target process by reference rather than as a pointer
Both member functions assume the passed in target process will not be
null. Instead of making this assumption implicit, we can change the
functions to be references and enforce this at the type-system level.
6 years ago
Lioncash fb5d4b17de kernel/shared_memory: Add a const qualified member function overload for GetPointer()
Given this doesn't mutate instance state, we can provide a
const-qualified variant as well.
6 years ago
Lioncash 2d37ca3726 kernel/shared_memory: Use 64-bit types for offset and size in CreateForApplet
Keeps the interface consistent with the regular Create() function.
6 years ago
Lioncash 76ac234bf6 kernel/shared_memory: Make GetPointer() take a std::size_t instead of a u32
Makes the interface nicer to use in terms of 64-bit code, as it makes it
less likely for one to get truncation warnings (and also makes sense in
the context of the rest of the interface where 64-bit types are used for
sizes and offsets
6 years ago
Lioncash f472232705 kernel/shared_memory: Make data members private
Rather than allow unfettered access to the class internals, we hide all
members by default and create and API that other code can operate
against.
6 years ago
Lioncash 43e7c6cf49 ldr: Clean up error codes
The separate enum isn't particularly necessary here, and the values can
just be directly put into the ResultCode instances, given the names are
also self-documenting here.
6 years ago
Zach Hilman c3becdbca7 filesystem: Clear registered union paths on factory creation 6 years ago
Zach Hilman aef0d88165 configure_input: Use Joycons Docked instead of Connected as label 6 years ago
Zach Hilman 312ef596a5 configure_input_player: Set minimum width on controls 6 years ago
Zach Hilman dd92db3fb0 configure_input: Properly update UI components on removal of player 6 years ago
Zach Hilman e58c951a59 configure_input: Make None a controller option instead of checkbox 6 years ago
Zach Hilman 3a6cd5b3c8 hid: Use player-defined controller type as PREFERRED_CONTROLLER 6 years ago
Zach Hilman 3d1a221893 qt: Move controller button config to separate dialog
Handles button configuration for all controller layouts and debug pads. Configurable at construction.
6 years ago
Zach Hilman afe8df5020 qt: Add UI to configure touchscreen parameters
This allows adjusting the finger, diameter, and angle of the emulated touchscreen. It also provides a warning to the user about what changing these parameters can do.
6 years ago
Zach Hilman 2e1dd9c649 qt: Add UI to configure mouse buttons
Supports setting the five mouse buttons to any valid controller button/keyboard key (Left, Right, Middle, Foward, Back)
6 years ago
Zach Hilman f1aec256d7 configure_input: Add support for multiplayer and controller types
This moves the actual button configuration to a separate dialog and only has the enabled and type controls in the tab.
6 years ago
Zach Hilman 55ded706d6 hid/npad: Update NPad to use player controller bindings and type 6 years ago
Zach Hilman e9145c3e16 hid/touchscreen: Update Touchscreen to use advanced parameters
Including finger ID, diamater x/y, and angle. Additionally, checks if the touchscreen is enabled.
6 years ago
Zach Hilman 3b25426bd9 hid: Add controller bindings for Mouse controller 6 years ago
Zach Hilman 0fd45e78f4 hid: Add keyboard bindings for Keyboard controller 6 years ago
Zach Hilman 06cf050c0a hid: Add controller bindings for DebugPad controller
Used by developers to test games, not present on retail systems. Some games are known to respond to DebugPad input though, for example Kirby Star Allies.
6 years ago
Zach Hilman d1b7c65b9e yuzu/config: Add (de-)serialization for multiplayer
Defaults to full keyboard for keyboard -- It did not seem to be necessary to make the keyboard configurable (besides enabled/disabled).
6 years ago
Zach Hilman b8f7f9651e yuzu_cmd/config: Add config deserialization for multiplayer 6 years ago
Zach Hilman c77454b9d0 settings: Add settings for multiple players and controllers
Uses the PlayerInput struct to represent all of the data that constitutes a player.
6 years ago
Zach Hilman fd5fa48674 settings: Add Native type for keyboard 6 years ago
Zach Hilman 152422bab1 settings: Add Native type for mouse buttons 6 years ago
David Marcec 0c3e7b7086 Added missing start/end touch attributes to touchscreen 6 years ago