Commit graph

2233 commits

Author SHA1 Message Date
Ac_K b72f7de405
aoc: Fixes some inconsistencies (#2434)
* aoc: Fixes some inconsistencies

This PR fixes an wrong returned value (introduced in #2414) which cause some DLC not recognized in some games like Super Robot War T.
Additionnally to that, I've removed the EventHandle check too, because it could cause some issues, but sadly it doesn't do the job so I reverted the changes. It should fix Diablo III: Eternal Collection.

* Fix loop

* Revert TitleLanguage change

* write only available ids
2021-07-06 20:17:06 +02:00
mpnico 091edcebb4
Command line argument -f doesn't toggle 'Start games in fullscreen mode' (#2424)
Closes Ryujinx#2308
2021-07-06 20:04:21 +02:00
Billy Laws ddb8351375
Implement 12.0.0 hwopus functions (#2410)
Based off of my RE of 12.0.2 audio services, the newly added parameter can be safely ignored due to ryu not using fixed-size I/O buffers.
2021-07-06 19:49:51 +02:00
riperiperi 94cc365b63
Honour copy dependencies when switching render target (#2433)
* Honour copy dependencies when switching render target

When switching from one render target to another, when both have a copy dependency to each other, a copy can be deferred on the second target when unbinding the first.

Before, this would not be honoured before binding the new texture, so the copy would stay deferred until the render targets change again, at which point it would copy in old data and essentially clear all the draws done during that time.

This change runs synchronize memory to make sure that copies are honoured. This can cause a redundant copy, but it's better than it breaking for now.

This should fix miiedit on AMD/Intel GPUs on windows. May fix other games, or perhaps rare copy dependency bugs on NVIDIA too.

* Address feedback
2021-07-03 01:55:04 -03:00
Ac_K f4078ae267
aoc: Fix wrong check (#2427)
This PR fixes a wrong check added in #2414 which made Pokémon crash.
2021-06-29 22:52:17 +02:00
Mary 00ce9eea62
Fix disposing of IPC sessions server at emulation stop (#2334) 2021-06-29 19:37:13 +02:00
gdkchan fbb4019ed5
Initial support for separate GPU address spaces (#2394)
* Make GPU memory manager a member of GPU channel

* Move physical memory instance to the memory manager, and the caches to the physical memory

* PR feedback
2021-06-29 19:32:02 +02:00
Ac_K 8cc872fb60
aoc/am: Cleanup aoc service and stub am calls (#2414)
* aoc/am: Cleanup aoc service and stub am calls

This PR implement aoc call `GetAddOnContentListChangedEventWithProcessId` (Closes #2408) and `CreateContentsServiceManager`. Additionnally, a big cleanup (checked by RE on latest firmware) is made on the whole service. I've added `CountAddOnContent`, `ListAddOnContent` and `GetAddonContentBaseId` for games which require version `1.0.0-6.2.0` too.

Am service call `ReportUserIsActive` is stubbed (checked by RE, closes #2413).

Since some logic in the service (aoc) which handle the DLCs has been changed, it could be nice to have some testing to be sure there is no regression.

* Remove wrong check

* Addresses gdkchan feedback

* Fix GetAddOnContentLostErrorCode

* fix null pid in services

* Add missing comment

* remove leftover comment
2021-06-29 18:57:06 +02:00
emmauss 28618c58d7
Add Screenshot Feature (#2354)
* Add internal screenshot  capabilities

* update version notice
2021-06-28 22:09:43 +02:00
Ac_K a79b39b913
no name: Mii Editor applet support (#2419)
* no name: Mii Editor applet support

* addresses gdkchan feedback

* Fix comment

* Bypass MountCounter of MiiDatabaseManager

* Fix GetSettingsPlatformRegion

* Disable Applet Menu for unsupported firmwares
2021-06-28 20:54:45 +02:00
gdkchan fefd4619a5
Add support for custom line widths (#2406) 2021-06-25 20:11:54 -03:00
gdkchan 493648df31
Fix default value for unwritten shader outputs (#2412)
* Fix shader default output values

* Shader cache version bump
2021-06-25 19:56:03 -03:00
gdkchan ed2f5ede0f
Fix texture sampling with depth compare and LOD level or bias (#2404)
* Fix texture sampling with depth compare and LOD level or bias

* Shader cache version bump

* nit: Sorting
2021-06-25 00:54:50 +02:00
Ac_K eac659e37b
caps: Stubs GetAlbumFileList0AafeAruidDeprecated and GetAlbumFileList3AaeAruid (#2403)
This PR stubs caps service call `GetAlbumFileList0AafeAruidDeprecated` and `GetAlbumFileList3AaeAruid` (Closes #2035, Closes #2401), both are checked by RE.
This avoid using "ignore missing services" when you want to play World of Light in Super Smash Bros Ultimate.
2021-06-25 00:37:48 +02:00
ooa113y 3359b0fd97
Improve gameTable search (#2398)
* Improve gameTable search

* Remove useless split

* Remove unneeded brackets

* Simplify searchEqualFunc

Co-authored-by: Ac_K <Acoustik666@gmail.com>

* Remove leftovers (oops)

Co-authored-by: Ac_K <Acoustik666@gmail.com>
2021-06-24 02:21:52 +02:00
emmauss 77aab9aca3
Add Direct Mouse Support (#2374)
* and direct mouse support

* and direct mouse support

* hide cursor if mouse enabled

* add config

* update docs

* sorted usings
2021-06-24 02:09:08 +02:00
gdkchan a10b2c5ff2
Initial support for GPU channels (#2372)
* Ground work for separate GPU channels

* Rename TextureManager to TextureCache

* Decouple texture bindings management from the texture cache

* Rename BufferManager to BufferCache

* Decouple buffer bindings management from the buffer cache

* More comments and proper disposal

* PR feedback

* Force host state update on channel switch

* Typo

* PR feedback

* Missing using
2021-06-24 01:51:41 +02:00
riperiperi 12a7a2ead8
Inherit buffer tracking handles rather than recreating on resize (#2330)
This greatly speeds up games that constantly resize buffers, and removes stuttering on games that resize large buffers occasionally:

- Large improvement on Super Mario 3D All-Stars (#1663 needed for best performance)
- Improvement to Hyrule Warriors: AoC, and UE4 games. These games can still stutter due to texture creation/loading.
- Small improvement to other games, potential 1-frame stutters avoided.

`ForceSynchronizeMemory`, which was added with POWER, is no longer needed. Some tests have been added for the MultiRegionHandle.
2021-06-24 01:31:26 +02:00
Ac_K e053663f27
settings: Implement GetDeviceNickName and SetDeviceNickName (#2383)
* settings: Implement GetDeviceNickName and SetDeviceNickName

This PR implement `set` and `sys:set` calls : `GetDeviceNickName` and `SetDeviceNickName` accordingly to RE.
I've cleaned up both services a bit and `SystemStateMgr` class too.

Closes #2110

* Addresses gdkchan_s feedback
2021-06-24 01:18:36 +02:00
Ac_K 55e0c71489
nfc/nfp: Implement ISystemManager and ISystem (#2381)
* nfc/nfp: Implement ISystemManager and ISystem

This PR add permission levels for `nfc` and `nfp` services:
- `nfc`: `CreateUserInterface` and `CreateSystemInterface` are implemented.
- `INfc`: `Initialize` and `IsNfcEnabled` calls are stubbed.
- `nfp`: `CreateDebugInterface` and `CreateSystemInterface` are implemented.
- `INfp`: `GetRegisterInfo2` for `IDebug` and `ISystem` are implemented.

* Addresses gdkchan feedback
2021-06-24 01:05:40 +02:00
gdkchan aea7a6631c
Reduce number of dlls on distribution with single file publish (#2211)
* Enable single file publish

* Set DebugType to embedded on build scripts
2021-06-24 00:40:19 +02:00
Ac_K d6b2ac33aa
input: Fixes TouchPoint wrong attribute (#2390) 2021-06-23 23:44:09 +02:00
gdkchan c71ae9c85c
Fix shader texture LOD query (#2397) 2021-06-23 23:31:14 +02:00
gdkchan ab9d4b862d
Implement VORN (register) Arm32 instruction (#2396) 2021-06-23 23:21:23 +02:00
gdkchan 49edf14a3e
Pass all inputs when geometry shader passthrough is enabled (#2362)
* Pass all inputs when geometry shader passthrough is enabled

* Shader cache version bump
2021-06-23 23:04:59 +02:00
Ac_K eb23933331
hid: Cleanup and implement some calls (#2380) 2021-06-23 22:52:55 +02:00
ooa113y 9efe124fc5
Unbind input on middle click (#2358)
* Unbind input on middle click

* Clear _middleMousePressed unconditionally

* Remove unneded initialization code

* Swap conditions

* CR fixes
2021-06-23 22:51:29 +02:00
Ac_K 7cf3ce7ed2
prepo: Implement SaveSystemReport and SaveSystemReportWithUser (#2379) 2021-06-23 22:41:44 +02:00
Ac_K 0b00473e5d
pl: Implement GetSharedFontInOrderOfPriorityForSystem (#2382) 2021-06-23 22:32:56 +02:00
Mary e334303559
mii: Fix multiple inconsistencies (#2392)
I found multiple inconsistencies while diffing with latest sdb, this PR fixes those findings.
2021-06-23 22:24:16 +02:00
Mary 0644db02ad
kernel: Implement MapTransferMemory and UnmapTransferMemory (#2386)
Based on my reversing of kernel 12.0.0
2021-06-23 21:52:11 +02:00
Ac_K 50ba233ac6
ipc: Remove size checks for buffer type 0x21/0x22 (#2387)
* ipc: Remove size checks for buffer type 0x21/0x22

Since original IPC implementation doesn't check the buffers size, there is no reason to check them so I've removed it. Checking the buffers addresses could prevent to unexpected behaviors.

That's fix a bsd service issue with some homebrew and some games like Knockout City (https://github.com/Ryujinx/Ryujinx-Games-List/issues/3622) which is now bootable:

* addresses gdkchan's review
2021-06-22 19:32:22 +02:00
Ac_K 992ab77f1f
account: Fix wrong condition in TrySelectUserWithoutInteraction (#2384)
* account: Fix wrong condition in TrySelectUserWithoutInteraction

Since the implementation of User Profiles, we can get more than one profile stored. This PR fixes a wrong condition in `TrySelectUserWithoutInteraction`.

Closes #2320

* Some cleanup
2021-06-21 14:20:28 -03:00
Ac_K aca1c37d4b
am: Add all known AppletMessage (#2378)
This PR add all known AppletMessage values for accuracy, nothing more.
`MessageInfo` is renamed to the right `AppletMessage` name.
2021-06-21 13:41:37 -03:00
gdkchan 65fee49e8a
Fix separate bindless sampler at offset 0 (#2360) 2021-06-20 20:48:12 +02:00
LukeFZ afd3153ca4
hid/irs: Stub IsFirmwareUpdateAvailableForSixAxisSensor and CheckFirmwareVersion (#2371)
* Stub two services

Stubs IHidServer::IsFirmwareUpdateAvailableForSixAxisSensor and IIrSensorServer::CheckFirmwareVersion

* Apply suggestions from code review

Also changed PackedMcuVersion to be two shorts instead of two bytes, because that's its actual type

* Apply new code review suggestions

Degroup field from previous assignation + Add padding after SixAxisSensorHandle
2021-06-19 13:53:18 +02:00
Mary 39b25dc124
Miria: Make default profile loads Pro Controller by default (#2368)
This was a regression introduced by Miria.
2021-06-17 03:48:55 +02:00
riperiperi 7ff1f9aa12
End shader decoding when reaching a block that starts with an infinite loop (after BRX) (#2367)
* End shader decoding when reaching an infinite loop

The NV shader compiler puts these at the end of shaders.

* Update shader cache version
2021-06-15 02:09:59 +02:00
emmauss bfcc6a8ad6
Add TouchScreen Manager (#2333) 2021-06-14 08:42:55 +02:00
EmulationFanatic b898bc84ce
Increase height of Settings Window (#2355) 2021-06-10 13:15:41 +02:00
Mary afd68d4c6c
GAL: Fix sampler leaks on exit (#2353)
Before this, all samplers instance were leaking on exit because the
dispose method was never getting called.

This fix this issue by making TextureBindingsManager disposable and
calling the dispose method in the TextureManager.
2021-06-09 01:00:28 +02:00
Mary 60cf3dfebc
Do not clear gpu subchannel state on BindChannel (#2348)
This fixes a regression caused by #980, that was causing a crash on New
Super Lucky's Tale.

As always, this need feedback on possible regression on any games.

Fix #2343.
2021-06-09 00:50:18 +02:00
gdkchan 02e2e561ac
Support bindless textures with separate constant buffers for texture and sampler (#2339) 2021-06-09 00:42:25 +02:00
EmulationFanatic 8588586062
Add SDL2 information & updated game compatibility stats (#2337) 2021-06-03 01:43:23 +02:00
gdkchan 3b90adcd1d
Fix shaders with mixed PBK and SSY addresses on the stack (#2329)
* Fix shaders with mixed PBK and SSY addresses on the stack

* Address PR feedback and nits
2021-06-03 01:41:53 +02:00
gdkchan b84ba43406
Fix texture blit off-by-one errors (#2335) 2021-06-03 01:30:48 +02:00
Mary 534a45d6e8 Reactivate DInput on SDL2
Seems more people than expected use DInput in 2021, will find another
way to fix the latency issue I suppose.
2021-06-02 19:50:21 +02:00
Mary 98916a4f90
Update SDL2-CS (#2327)
Changelog:
- SDL2 was updated to lastest master
- DInput was disabled from build configuration (Close #2238)
- HIDAPI was forced enabled on Linux and libusb library name was fixed (Close #2226)

NOTE about HIDAPI support on Linux:
Make sure that your gamepad is accesible to your user for it to be detected by HIDAPI. This can be done via a udev rule like:

```
KERNEL=="hidraw*", MODE="0660", TAG+="uaccess"
```

**NOTE: This rule is given as an example, this can present a security
risk. Make sure to filter by vendor and product ids.**
2021-06-02 13:50:48 +02:00
riperiperi fe29aff266
Use Quads on OpenGL host when supported. (#2331)
Improves OpenGL performance on FAST RMX and Xenoblade DE/2. Will probably only work on NVIDIA GPUs, but the emulated quads path will still be valid for other GPUs. Note: SLOW RMX gets a bit faster in handheld mode.

I'd recommend checking on platforms without supported host quads to make sure a GL error is actually thrown when attempting GL.Begin(PrimitiveType.Quads)
2021-06-02 13:27:30 +02:00
Mary 7527c5b906
Avoid clearing alpha channel by handle when presenting (#2323)
* Avoid clearning alpha channel by handle when presenting

Previous code was binding then blitting while the framebuffer was bound
and then clearing the alpha channel by its handle.

This ended up triggering a bug since AMD driver 21.4.1 ending up
clearing the whole framebuffer as a result.

New code fix this weird logic by applying the clear on the bound
framebuffer.

Close #2236.

* Address rip's comments

* Fix AMD being broken once again
2021-06-01 09:29:01 +02:00