yuzu on yuzu https://yuzu-mirror.github.io/ en-US yuzu Team Copyright (c) 2017-2026, yuzu; all rights reserved. Sun, 25 Jan 2026 02:45:32 UTC Progress Report January 2024 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/ Sat, 10 Feb 2024 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/ <p>Welcome to 2024, yuz-ers! What better way to begin the year than to do major code refactors resulting in almost full applet support. We present this, and plenty more, to you today! Remember to right click and unmute the embedded videos.</p> <p>Welcome to 2024, yuz-ers! What better way to begin the year than to do major code refactors resulting in almost full applet support. We present this, and plenty more, to you today! Remember to right click and unmute the embedded videos.</p> <h2 id="multiprocess-services-lle-applets-and-project-leviathan">Multiprocess, services, LLE applets, and Project Leviathan</h2> <p>Converting a single process emulator into a multiprocess one is no simple task.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./keyboard.png" title=" Typing speed challenge with the Nintendo keyboard?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/keyboard_hu8dbe05ddaca28d16d15ab3937cf47828_55224_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Typing speed challenge with the Nintendo keyboard?"></a> <p class="has-text-centered is-italic has-text-grey-light"> Typing speed challenge with the Nintendo keyboard?</p> </div> </div> <p>2024 started out quite busy thanks to the combined efforts of <a href="https://github.com/liamwhite">byte[]</a>, <a href="https://github.com/german77">german77</a>, <a href="https://github.com/FernandoS27">Blinkhawk</a>, and <a href="https://github.com/Kelebek1">Maide</a> in implementing multiprocess support, taking advantage of it in multiple areas (heh, get it?) including GPU, input, services, and applet emulation, and fixing long standing problems along the way.</p> <p>As of writing, multiprocess support <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12756" data-gh-pr="12756">is not yet merged,</a> but fixes in the GPU, input, and other modules (implemented by byte[], Blinkhawk, and german77) have already been staged and released, allowing full support to be added in parts.</p> <p>Implementing the requirements to support multiprocess in yuzu led us to make five significant changes in the past month:</p> <ul> <li>Allow the GPU to run multiple programs. This is where SMMU support comes in, which we will discuss in the next section.</li> <li>Rewrite the old, basic applet manager.</li> <li>Rewrite presentation. Part of the prerequisites to run more than one program simultaneously is to be able to display all of them to the user.</li> <li>Rewrite every other relevant area (for example, input) to support multiple processes.</li> <li>Automate the serialization of service calls.</li> </ul> <h3 id="device-mapping-and-smmu">Device mapping and SMMU</h3> <p>We start off with a big one: Blinkhawk implemented device memory mapping emulation and rewrote the GPU implementation with support for the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12579" data-gh-pr="12579">SMMU,</a> or for desktop enthusiasts/Linux VM users/UEFI lurkers, its other common name, IOMMU.</p> <p>The ARM <strong>S</strong>ystem <strong>M</strong>emory <strong>M</strong>anagement <strong>U</strong>nit handles memory mapping for peripheral devices like the GPU. It’s a hardware component on the Switch in charge of translating device virtual memory addresses into physical memory addresses. The GPU adds an MMU of its own, <code>GMMU</code>, an additional layer that maps over the SMMU.</p> <p>The emulator already had a performant memory translation layer for the GMMU, but it could only handle a single program using the GPU at a time, unable to share it with other processes. And support for <em>multiple processes</em> was needed.</p> <p>The main benefits of this rewrite are:</p> <ul> <li>Increased accuracy.</li> <li>Reduced video memory usage (testing shows around a 300MB reduction).</li> <li>Enables multiprocess use of the GPU.</li> <li>Allows other emulated devices to use the device mapper.</li> <li>Leaves room for potential future optimizations</li> </ul> <p>One downside of this change was how it increased debugging complexity, which led to more development time spent with every bug found on its implementation. For example, games on Android getting stuck at 0 FPS randomly, breaking compatibility with NCE, or running out of memory on some game engines. This led to a couple of fixes implemented first by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12749" data-gh-pr="12749">byte[]</a> and then <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12869" data-gh-pr="12869">Blinkhawk himself,</a> with more on the way.</p> <p>This change opened the floodgates to applet emulation and is the starting point to implement <a href="https://github.com/skyline-emu/skyline/pull/2106">Direct Memory Import</a> sometime in the future — but let’s slow down a bit, there’s more to cover.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./miiedit.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Time to launch another program, GPU!</p> </div> </div> <h3 id="project-leviathan">Project Leviathan</h3> <p>german77 had to adapt his input rewrite, <code>Project Leviathan</code> to the requirements of multiprocess too. The rewrite is still ongoing, with more parts planned. But just in January, the following changes, either specifically for multiprocess or more generally as part of the rewrite, were implemented:</p> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12536" data-gh-pr="12536">Use individual applet resources,</a> so each applet has its own view of the controller input.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12549" data-gh-pr="12549">Implement NpadResource emulation,</a> now using the input process ID to distinguish HID state and controller style configuration between multiple processes.</li> <li>Create the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12605" data-gh-pr="12605">abstracted pad</a> structure, which is in charge of updating the shared memory and assignment of controllers. The old implementation was too simple, causing the controller applet to unnecessarily be shown, or showing up with no supported controllers available.</li> <li>Fully implement <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12660" data-gh-pr="12660">abstract vibration,</a> removing old inaccurate code and matching the behaviour of newer Switch firmware.</li> </ul> <p>While this leads to us being able to load the native controller applet (among others) and have fun with it, it doesn’t have much use for emulation.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./controller1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/controller1_hu4fed415505308e65f853a5cd6d052aac_138936_800x0_resize_q90_bgffffff_box_3.jpg" alt="Just for fun"></a> </div> <div class="column is-bottom-paddingless"> <a href="./controller2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/controller2_hu46a82d8bccff11b094fc733d4eae8371_87199_800x0_resize_q90_bgffffff_box_3.jpg" alt="Just for fun"></a> </div> <div class="column is-bottom-paddingless"> <a href="./controller3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/controller3_hu32eaabeb5c5eff9e30d6deee02430a7d_130967_800x0_resize_q90_bgffffff_box_3.jpg" alt="Just for fun"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Just for fun</p> <h3 id="now-presenting">Now Presenting</h3> <p>Besides the emulated GPU, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12761" data-gh-pr="12761">presentation to screen</a> also needed some work to support running applets — without it, none of the benefits could actually be displayed. If there is no multi-layer composition in place, there is no applet fun.</p> <p>byte[] rewrote almost all of the presentation code to support layer overlays and blending, taking special care to not break the existing filtering and antialiasing options. FSR in particular was converted from a compute shader to a fragment shader, so proper blending could be enabled. The end result is the same, with no image quality changes — but now FSR can be used while games display the native inline keyboard, for example.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./keyboard.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> That transparency behind the keyboard wasn’t free.</p> </div> </div> <h3 id="i-am-the-applet-managerhttpswwwyoutubecomwatchv7zls5kndeli"><a href="https://www.youtube.com/watch?v=7ZLS5KNDelI">I AM the applet manager</a></h3> <p>Another critical service that required a rewrite to have proper multiprocess support is <code>AM</code>, the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12760" data-gh-pr="12760">Applet Manager.</a> AM has now been almost completely refactored to track state for every applet individually, properly allowing it to support running more than one at the same time.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./web1.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Help is only one button press away (Super Smash Bros. Ultimate)</p> </div> </div> <p>While byte[] got the rewrite up and running, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12837" data-gh-pr="12837">fixed an issue</a> causing <code>The Battle Cats Unite</code> to softlock past the starting loading screen.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bc.png" title=" This is one of the games of all time. Nyaa. (The Battle Cats Unite)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/bc_hudb520ee4bbe8b47aff425b2c7f109151_1768372_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" This is one of the games of all time. Nyaa. (The Battle Cats Unite)"></a> <p class="has-text-centered is-italic has-text-grey-light"> This is one of the games of all time. Nyaa. (The Battle Cats Unite)</p> </div> </div> <h3 id="sounds-good">Sounds good</h3> <p>Maide was responsible for making <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12831" data-gh-pr="12831">audio emulation</a> compatible with multiprocess. Games should be able to share audio playback with applets, right? Sharing is caring.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./web2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Special menus included (Super Mario 3D All-Stars).</p> </div> </div> <h3 id="universal-serialization-byte">Universal Serialization Byte[]</h3> <p>The <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12783" data-gh-pr="12783">serialization and deserialization</a> of service calls from programs is one of the most important tasks yuzu must perform when interacting with guest programs. Communication between programs and the Switch system modules uses a special binary format with custom parsers. Interacting with guest processes required tedious and error-prone layout calculations for every single interface method yuzu needed to implement, wasting a lot of development time on error checking and maintenance.</p> <p>With the increased involvement in service implementations and the exponential growth of complexity you’ve seen so far, byte[] aims to automate and simplify serialization by using a template-based approach that automatically generates the code needed for the method.</p> <p>So far, the work on multiprocess has taken over twenty thousands lines of code and continues growing. All you have to do now to enjoy your native applets is to <a href="https://rena21.github.io/yuzu-wiki/setup-guide/dump-firmware/">dump your firmware</a>. The minimum required version to get the applets running is firmware 14.0.0.</p> <h3 id="other-service-rewrites-and-fixes">Other service rewrites and fixes</h3> <p>Here’s a toast to Maide for fixing one of the longest standing bugs in yuzu: the passage of time in games like <code>Pokémon Sword/Shield</code> and <code>Pokémon Quest</code>.</p> <p>In the past, while time tracked during saving, some game events like Dens or Pokéjobs wouldn’t reset, forcing users to manually advance time with the custom RTC option. It was quite bothersome.</p> <p>It took an entire <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12499" data-gh-pr="12499">rewrite of the time services</a> to resolve the issue, “only” about nine thousand lines of code. The new implementation is much more accurate, allowing Pokéjobs and other timed events to finally be enjoyed normally in this low-poly, almost-always-30-FPS masterpiece.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./pj1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/pj1_hu64b18fcb6eeabb12ba2e4d3219e7b79a_437692_800x0_resize_q90_bgffffff_box_3.jpg" alt="Get to work! (Pokémon Sword)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pj2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/pj2_hu927cd44b0d4452d14603e5597c4d9995_362698_800x0_resize_q90_bgffffff_box_3.jpg" alt="Get to work! (Pokémon Sword)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Get to work! (Pokémon Sword)</p> <p>Continuing this work, Maide removed some old workarounds that were no longer needed in the time services, and fixed <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12864" data-gh-pr="12864">network clock to local clock</a> synchronisation on every game boot. This fixed time progression in <code>Pokémon Quest</code>. No longer a <a href="https://en.wikipedia.org/wiki/Hype:_The_Time_Quest">Time Quest</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pq.png" title=" Set camp (Pokémon Quest)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/pq_hubc00b355c7bae3747646192bfcea9578_351158_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Set camp (Pokémon Quest)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Set camp (Pokémon Quest)</p> </div> </div> <p>To close the section, byte[] fixed how the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12867" data-gh-pr="12867">AOC service</a> lists available DLC for multi-program applications, allowing <code>Assassin’s Creed Rogue</code> to boot with its DLC installed. Just like the Navy intended.</p> <h2 id="graphics-changes">Graphics changes</h2> <h3 id="a-dose-of-dozen">A dose of Dozen</h3> <p>Unforeseen issues are one of the signature “comes with the job” moments of emulation — you never know from where a new problem will arise, so we’ll have to start this section with a PSA.</p> <p><strong>PSA:</strong> If yuzu has recently started showing Microsoft as the GPU vendor for you, and you can no longer play any game, uninstall the package named <code>OpenCL™, OpenGL®, and Vulkan® Compatibility Pack</code>, or if you prefer to keep it, go to <code>Emulation &gt; Configure… &gt; Graphics &gt; Device</code> and change the GPU to your correct model, without “Microsoft Direct3D 12” at the start of its name.</p> <p>AMD and Intel users running Windows 11 suddenly started having their hardware completely incapable of launching any games while using Vulkan. The reason is something none of us expected at all, Microsoft… And Mesa! Please lower those pitchforks.</p> <p>Microsoft decided to roll out an install of this package, which allows incapable hardware to run the mentioned APIs if no proper driver was provided from the hardware vendor, or just if the hardware is incapable of running it.</p> <p>The project used to achieve this is Mesa <code>Dozen</code>, which <a href="https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14766">runs Vulkan atop a Direct3D 12 interface</a>. The intended purpose is to offer Vulkan support to devices that only ship a Direct3D 12 driver, for example, Qualcomm ARM laptops. We don’t know why Microsoft decided to silently test this feature on x86-64 PCs that already ship hardware capable of proper Vulkan support, but here we are.</p> <p>Those new devices generated by <code>Dozen</code> are added to the Vulkan devices available to the OS, named “Microsoft Direct3D 12 (GPU model name)”, and conflict with how yuzu orders its device list.</p> <p>To ensure the best GPU is selected by default on yuzu, three sorts are performed in order:</p> <ul> <li>Prefer NVIDIA hardware over AMD, AMD hardware over Intel. This favours NVIDIA hardware and also double ensures dedicated GPUs get selected over integrated ones. Plus, in the rare case a user has multiple GPUs from different vendors on a system, we ensure the one with the least issues is picked by default. “Outdated NVIDIA tablet-turned-console likes NVIDIA drivers,” after all.</li> <li>Prefer dedicated hardware over any other, including integrated and CPU rendering. There are people out there trying to run yuzu with CPU rendering.</li> <li>Order in inverse alphabetical order. This helps ensure an RTX 4090 is picked over a GTX 1050, or an RX 7900 XTX over an RX 780m.</li> </ul> <p>Did you notice it? The last point is the problem. <code>Dozen</code> devices share the same identical features as the real Vulkan device but change the name. Since the list is ordered in inverse alphabetical order, a device named “Microsoft” will take priority over an identical one named AMD or Intel.</p> <p>The issue is simple enough to solve: detect when a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12781" data-gh-pr="12781">device is Dozen</a> and demote it to the bottom of the list. Even if <code>Dozen</code> was capable of running yuzu, we would prefer not to run a layered implementation by default.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dozen.png" title=" Nice way of having a Dozen GPUs"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/dozen_huf7c453116c2707b85158c86a9f8bbe05_4379_426x0_resize_q90_bgffffff_box_3.jpg" alt=" Nice way of having a Dozen GPUs"></a> <p class="has-text-centered is-italic has-text-grey-light"> Nice way of having a Dozen GPUs</p> </div> </div> <p>Sadly, <code>Dozen</code> isn&rsquo;t compatible with yuzu for the moment — it lacks multiple mandatory extensions and has some issues your writer enjoyed reporting to its devs while testing this. Fixes for multiple of them arrived in just a couple of days. Mesa devs are built differently.</p> <p>This could be an interesting experiment for Fermi users or other end-of-life hardware once <code>Dozen</code> is suitable for yuzu.</p> <h3 id="your-regularly-scheduled-gpu-changes">Your regularly scheduled GPU changes</h3> <p>The fun testing for multiprocess revealed a graphical issue when opening the web applet help page in <code>Super Smash Bros. Ultimate</code>. One fix for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12875" data-gh-pr="12875">pitch linear reading and writing</a> in the software blitter code later, and Blinkhawk resolved the issue.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/webappletbug_hu779209430c42d559deab939c0825ca1e_1071586_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Da Rules (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/webapplet_hudbd3c25166496320ac0fdd6f6f1e6011_1076144_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Da Rules (Super Smash Bros. Ultimate)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Da Rules (Super Smash Bros. Ultimate)</p> <p>Android users have regularly reminded us that <code>Mortal Kombat 11</code> is unable to boot. After his enthusiastic walk through the code, byte[] found that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12652" data-gh-pr="12652">8-bit and 16-bit storage writes</a> in shaders were completely broken on hardware which did not support them.</p> <p>The problem, at least one of them, was lack of hardware support for <code>shaderInt8</code> and <code>shaderInt16</code>, something the big three, NVIDIA (the Switch included, of course), AMD (and by extension, Xclipse), and Intel, have full support for with up-to-date drivers, but <a href="https://vulkan.gpuinfo.org/listdevicescoverage.php?core=1.2&amp;feature=shaderInt8&amp;platform=all&amp;option=not">Android devices</a> with Adreno and Mali GPUs don’t.</p> <p>Mali moment #1, along with Adreno.</p> <p>The solution byte[] implemented to solve this specific issue is the usual for the lack of hardware support. If you can’t run it, emulate it! Those are very enthusiastic walks. These platforms support storage atomics, so by performing a compare-and-swap loop to atomically (in the thread safety sense, not radioactive) write a value to a memory location, 8-bit and 16-bit values can be written to larger 32-bit memory words without tearing the value seen by other threads.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mk11.png" title=" Dear gods, you don’t need to make the menu low resolution too (Mortal Kombat 11)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/mk11_hu8aa606982b5e6d0b4cc3a71a3383bdb0_1860904_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Dear gods, you don’t need to make the menu low resolution too (Mortal Kombat 11)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Dear gods, you don’t need to make the menu low resolution too (Mortal Kombat 11)</p> </div> </div> <p>This emulation incurs a small performance loss, but beggars can’t be choosers. Mobile GPUs are very stingy with their feature sets, which frequently holds our development back and necessitates adding workarounds.</p> <p>We doubt only <code>Mortal Kombat 11</code> is affected — this change improved many unknown games that were crashing on Android devices or for people running outdated GPU drivers on desktop/laptop PCs. Sadly, this change alone isn’t enough to make the game playable on Android devices. This issue exposed other shader problems related to lack of support for <code>StorageImageExtendedFormats</code>, but that’s homework for later, most likely for future byte[].</p> <p>Switching to the other Linux kernel equipped OS (erm, Linux), Tuxusers reported garbled rendering issues when resizing the yuzu window while on Wayland.</p> <p>The solution was thankfully simple, reverting an unnecessary change in one of the previous DMA fixes. By forcing a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12688" data-gh-pr="12688">recreation of the swapchain</a> each time the window frame size changes, the issue is gone.</p> <p>Proper tear-free gameplay with safe window management shall return to Wayland. HDR support when, Linux?</p> <p>Newcomer <a href="https://github.com/shinra-electric">shinra-electric</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12713" data-gh-pr="12713">updated the MoltenVK dependency</a> to its latest version. Thank you!</p> <p>While the update brings tons of improvements and many Vulkan extensions are now supported, there are no new changes to report in rendering or compatibility on Apple devices. But hey, no reported regressions is good news!</p> <h2 id="android-augmentations">Android augmentations</h2> <p><a href="https://github.com/t895">t895</a> kicked off the new year with a flurry of changes to improve yuzu Android. While one of these changes enhances the overall app performance, the majority are quality-of-life (QoL) fixes that some of our users have been anticipating.</p> <p>As many of you might already be aware, yuzu Android supports exporting user data and saves in ZIP format to transfer between different versions of the app. ZIP compression, in most cases, can result in a reduction of file size compared to the original size of files on disk. However, applying compression overtop of encrypted data is almost always a waste of time.</p> <p>t895 observed that when compression was turned on, these ZIP exports were excessively slow, while still resulting in negligible size reduction gains, as the largest files in the user data are NCAs, and those are encrypted. Therefore, he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12558" data-gh-pr="12558">disabled compression for these ZIP exports,</a> exhibiting up to a 3x decrease in export times.</p> <p>Moving on to the QoL fixes, t895 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12571" data-gh-pr="12571">extended support for custom screen orientations.</a> With this change, yuzu now supports a total of seven orientation styles, listed below.</p> <ul> <li>Auto. Selects any of the four orientations based on the phone’s sensor.</li> <li>Sensor Landscape. Limits the sensor detection to only landscape orientations.</li> <li>Landscape. Fixed regular landscape.</li> <li>Reverse Landscape. Fixed inverted landscape.</li> <li>Sensor Portrait. Limits the sensor detection to only portrait orientations, if the device allows it.</li> <li>Portrait. Fixed regular portrait.</li> <li>Reverse Portrait. Fixed inverted portrait</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./orientations.png" title=" Reverse portrait, the way it’s meant to be played"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/orientations_hu55370b4aa9d8bd15c6c764654f909902_300748_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Reverse portrait, the way it’s meant to be played"></a> <p class="has-text-centered is-italic has-text-grey-light"> Reverse portrait, the way it’s meant to be played</p> </div> </div> <p>Next up is the improved global save manager. There are two possible save directories for games, and the original global save manager was only checking one of them. So, t895 removed this broken feature a while back and has now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12576" data-gh-pr="12576">reintroduced an improved version</a> of the same.</p> <p>With this improved version, you can now also use exports made with the global save manager in the per-game save manager and vice versa.</p> <p>Following that are the new uninstall add-on buttons. t895 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12715" data-gh-pr="12715">added an uninstall button</a> for every kind of add-on in the Android app. yuzers can now easily uninstall any updates, DLCs, mods, and cheats that they might have installed. Note: Currently, yuzu on PC doesn&rsquo;t have UI support for uninstalling mods or cheats.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./uninstall.png" title=" Your internal storage starts breathing again"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/uninstall_huc7aa8ddc28cba42e981bbdde598de794_68231_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Your internal storage starts breathing again"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your internal storage starts breathing again</p> </div> </div> <p>Ever spend a long time copying over your dumps or installing content to NAND, only to have them fail to work? Look no further: t895 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12736" data-gh-pr="12736">brings the PC version&rsquo;s integrity check features to Android.</a> You can now easily verify the file integrity of your game dumps and your NAND contents. To verify a game dump, simply go to your game&rsquo;s properties and under <code>Info</code>, select <code>Verify Integrity</code>. There is also a separate, self-explanatory button within <code>Settings</code> labelled <code>Verify Installed Content</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./verify1.gif" title=""><img src="./verify1.gif" alt="Great for peace of mind after experiencing a game crash"></a> </div> <div class="column is-bottom-paddingless"> <a href="./verify2.gif" title=""><img src="./verify2.gif" alt="Great for peace of mind after experiencing a game crash"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Great for peace of mind after experiencing a game crash</p> <p>How many times have you accidentally opened the in-game menu when using the left thumbstick area? Well, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12738" data-gh-pr="12738">you can now lock the in-game menu</a> so as to avoid accidentally triggering it. When locked, you can still bring up the in-game menu by using the &ldquo;back&rdquo; button or gesture on your device.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lock.png" title=" Anti-frustration changes"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/lock_hu6e5e37dfcf6a35c21db2958ee1ca11e3_152049_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Anti-frustration changes"></a> <p class="has-text-centered is-italic has-text-grey-light"> Anti-frustration changes</p> </div> </div> <p>Now, let&rsquo;s delve into game shortcuts on your home screen. With Android&rsquo;s dynamic shortcuts feature, apps can now provide users with quick access to specific actions or content within an app directly from the home screen. Although this feature was introduced back in 2016, it seems that some Android launchers do not yet support it.</p> <p>While this feature is already supported on yuzu and works perfectly, it becomes pretty tedious when you have to launch each and every game to get a shortcut for it, especially after a reinstall. As a one-size-fits-all solution to this problem, t895 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12747" data-gh-pr="12747">implemented a button</a> in the game properties activity that allows you to easily add a shortcut to any game to your home screen without needing to launch the game first.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./icon.gif" title=" Gotta pin ’em all"><img src="./icon.gif" alt=" Gotta pin ’em all"></a> <p class="has-text-centered is-italic has-text-grey-light"> Gotta pin ’em all</p> </div> </div> <p>t895 followed that up with some <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12796" data-gh-pr="12796">controller focus optimizations.</a> Android controller focus is the highlight you see over buttons indicating that you can select it. These changes fix a few issues observed when using a controller to navigate the yuzu app UI and solved an issue where the emulation surface would appear gray.</p> <p>In his quest to bring feature parity between yuzu on PC and yuzu on Android, t895 implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12777" data-gh-pr="12777">the &rsquo;encryption keys missing&rsquo; warning on Android.</a> You will now get this warning on app startup if you don&rsquo;t have the keys required to decrypt games/firmware.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./keys.png" title=" Time to grab that jig"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/keys_hud36a2cc4c1e4db747ce7ee1b20205846_41731_374x0_resize_q90_bgffffff_box_3.jpg" alt=" Time to grab that jig"></a> <p class="has-text-centered is-italic has-text-grey-light"> Time to grab that jig</p> </div> </div> <p>t895 also implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12824" data-gh-pr="12824">support for multi-program app switching.</a> This feature allows for game compilations like <code>Super Mario 3D All-Stars</code> and <code>Klonoa: Phantasy Reverie Series</code> to switch between games within the bundle.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./multiprogram.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Multi-game drifting! (Klonoa: Phantasy Reverie Series)</p> </div> </div> <p>He also made some minor UI improvements like:</p> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12786" data-gh-pr="12786">Show driver vendor in the FPS overlay.</a> This informs users which driver is loaded.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12826" data-gh-pr="12826">Show System GPU driver information</a> in the driver manager for improved visibility.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./driver.png" title=" Now you can know how outdated it is"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/driver_hue2a37caf87a32d9f2df6b7e913cff8b4_19170_519x0_resize_q90_bgffffff_box_3.jpg" alt=" Now you can know how outdated it is"></a> <p class="has-text-centered is-italic has-text-grey-light"> Now you can know how outdated it is</p> </div> </div> <p>And that&rsquo;s not all. Newcomer <a href="https://github.com/GayPotatoEmma">Emma</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12560" data-gh-pr="12560">implemented basic support for the game dashboard</a> feature found on Pixel devices. Thank you!</p> <p>Resident AMD tester <a href="https://github.com/Moonlacer">Moonlacer</a> noticed that Samsung mobile devices with the new RDNA-based Xclipse GPUs had the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/6900" data-gh-pr="6900">same wireframe issues in various Pokémon games,</a> that plague the PC AMD Vulkan drivers. With some help from <a href="https://github.com/liamwhite">byte[]</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12885" data-gh-pr="12885">a fix for these Xclipse GPU drivers was implemented</a> by considering these devices as AMD, gaining access to the same old workarounds Radeon cards benefit from. Thanks to user <code>no.kola</code> on discord for testing these!</p> <p>Xclipse moment #1. We have some bad news for Xclipse users we’ll discuss in the hardware section.</p> <h2 id="miscellaneous-changes">Miscellaneous changes</h2> <p>One notable standing issue with yuzu is profile corruption, when after a badly-timed crash, the emulator creates a new profile and leaves all user data in the old one, forcing the user to manually move their saves back to the newly created active profile. Thankfully, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12665" data-gh-pr="12665">fixes user profile corruption</a> issues by only saving profile data when contents change.</p> <p>While NCE has been with us for some time now, that doesn’t mean it’s entirely stable yet. As an Android user pointed out, some hardcore mods like <code>Luminescent Platinum</code> for <code>Pokémon Brilliant Diamond/Shining Pearl</code> would get stuck in a black screen while using NCE.</p> <p>After the detective work was finished by byte[], the reason was found to be in how some mods make assumptions about the module layout, and yuzu would try to give each module a dedicated patch section. To alleviate this bottleneck, <a href="https://github.com/GPUCode">GPUCode</a> modified the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12677" data-gh-pr="12677">NCE loader</a> to try to use the same patch section for as many sequential modules as possible.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./platinum.jpg" title=" The community never fails to provide impressive mods (Pokémon Brilliant Diamond)"><img src="./platinum.jpg" alt=" The community never fails to provide impressive mods (Pokémon Brilliant Diamond)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The community never fails to provide impressive mods (Pokémon Brilliant Diamond)</p> </div> </div> <p>This should allow mods for other games that make assumptions about module layout to work under NCE as well.</p> <p>Jumping to a bit of input changes, german77 was notified that a user tried to dump their Amiibos, but yuzu failed to generate any dump because the Amiibos were mounted as read-only and no backup was available. The solution? <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12683" data-gh-pr="12683">Dump Amiibos</a> if no backup exists, no questions asked.</p> <p>Resident helper <a href="https://github.com/anpilley">anpilley</a> decided it was time to improve the available command-line arguments for the yuzu binaries, adding the use of <code>-u</code> to specify a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12695" data-gh-pr="12695">user to load</a> and suppress the user selector from showing. Thank you!</p> <p>Back for more, <a href="https://github.com/FearlessTobi">FearlessTobi</a> decides to tackle a few problems with the virtual file system emulation, or <code>VFS</code>. Since Project Gaia is in indefinite hiatus, priorities have shifted into patching as much of the current implementation as possible.</p> <p>The <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12707" data-gh-pr="12707">list of changes</a> is long: it includes moving files, unifying error code naming for ease of debugging, making file system definitions more consistent with current reverse engineering information available, and leaving the overall structure prepared for future code additions. Never hurts to improve an area that was designed back when there was little information available.</p> <p>The boss of Dynarmic herself, <a href="https://github.com/merryhime">merryhime</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12830" data-gh-pr="12830">updated the bundled build</a> in yuzu to the latest version, bringing some new changes and fixes with it. There are some instruction emulation optimizations, more 32-bit ARM instructions were added, and the startup times of games on Android was improved — it’s not as fast as NCE, but it’s considerably faster for those games that must run on JIT.</p> <p>To close this section and move to an interesting hardware discussion, t895 has one last gift for us this month, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12868" data-gh-pr="12868">per-game audio settings.</a> One of the missing settings that could be set on a per-game basis, and it includes the full set, output engine, output device, input device, etc.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./audio.gif" title=" Sounds good to me!"><img src="./audio.gif" alt=" Sounds good to me!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Sounds good to me!</p> </div> </div> <p>The more you’re able to choose, the better, right?</p> <h2 id="hardware-and-software-section">Hardware and software section</h2> <p>As promised last month, we’ll talk about frame generation, and the new tools available to take advantage of it in yuzu. But first, one last HDR example for NVIDIA users.</p> <h3 id="nvidia-truehdr">NVIDIA TrueHDR</h3> <p>With the 551.XX series of drivers, NVIDIA introduced the option to auto-generate an HDR output for any video displayed on a Chromium-based browser (Google Chrome, Microsoft Edge, Brave, etc). It didn’t take long for the community to come up with plug-ins to take advantage of this change in <a href="https://github.com/emoose/VideoRenderer/releases">local video players</a>, but that’s not the only application outside NVIDIA’s official intended use.</p> <p>Enter <a href="https://www.nexusmods.com/site/mods/781">NvTrueHDR</a>, an alternative to Windows AutoHDR and Special K HDR. Always fun to have more options to pick from!</p> <h3 id="lossless-scaling-to-the-rescue">Lossless Scaling to the rescue</h3> <p><a href="https://store.steampowered.com/app/993090/Lossless_Scaling/">Lossless Scaling</a>, a program intended for resolution scaling, recently introduced a generic frame generation option, making it the first vendor agnostic implementation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ls1.png" title=" Clean UI"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/ls1_hu173910933dc6c69b7d8d98a91f2ac394_15624_880x0_resize_q90_bgffffff_box_3.jpg" alt=" Clean UI"></a> <p class="has-text-centered is-italic has-text-grey-light"> Clean UI</p> </div> </div> <p>Simply set Frame Generation on the right to <code>LSFG</code>. If you’re an Intel iGPU user, set Legacy capture API to enabled, open yuzu, enable Scale, and switch back to playing your game, or press the default hotkey <code>Ctrl + Alt + S</code> while in-game. Exclusive fullscreen is recommended.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ls2.png" title=" Scroll down to find it"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/ls2_hu4213b5e21f98ce808922b2749982e00c_16643_880x0_resize_q90_bgffffff_box_3.jpg" alt=" Scroll down to find it"></a> <p class="has-text-centered is-italic has-text-grey-light"> Scroll down to find it</p> </div> </div> <p>The results are good on smaller displays, but on larger monitors (such as 27 inch displays), the artifacts of the generated frames are too noticeable, making this tool more suitable for laptops and handhelds than for desktop or TV gameplay. Still, it’s a cheap way of improving perceived framerates and bypassing CPU bottlenecks on any GPU vendor without driver or hardware restrictions.</p> <p>Below you can see comparison videos between native 30 FPS and Lossless Scaling generating frames to 60 FPS in <code>The Legend of Zelda: Breath of the Wild</code>. Due to YouTube only supporting 60FPS video, you won&rsquo;t see the true 120 FPS framegen examples.</p> <p> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/v-U7GJYrY64" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/XNBTxr6HBlA" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> </p> <p>The above videos demonstrate native 30 FPS vs Lossless Scaling generating frames from a 30 FPS base. You can see with so little information, artifacts are common. Lossless Scaling doesn’t handle scene transitions.</p> <p> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/CG_e5yOnd9E" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/UpvdLJUtEis" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> </p> <p>The above videos demonstrate native 60 FPS vs Lossless Scaling generating frames from a 60 FPS base. With more information to play with, Lossless Scaling does a better job. Scene transitions are still an issue.</p> <p>While the quality is not perfect, it’s a simple and harmless way of improving the experience on any hardware — especially on <del>ugly</del> 30 FPS games like the Pokémon series, or cinematic experiences like the Xenoblade saga. No double standards here. Still, for those with recent AMD GPUs (RDNA2 and RDNA3 so far), there’s a better option available now:</p> <h3 id="amd-fluid-motion-frames">AMD Fluid Motion Frames</h3> <p>Driver release 24.1.1 introduced the first public release of <a href="https://community.amd.com/t5/gaming/amd-fluid-motion-frames-is-out-now-on-amd-radeon-rx-7000-series/ba-p/634372">AFMF</a>, AMD’s game-independent frame generation algorithm.</p> <p>“But writer, AFMF is only for Direct3D 11 and 12 games!” you say. That’s where you’re wrong. You see, the <a href="https://forums.guru3d.com/threads/amd-software-adrenalin-edition-23-40-01-10-preview-driver-for-amd-fluid-motion-frames.449598/page-35#post-6197794">Guru3D forums</a> has some fantastic information, AFMF can be run on Vulkan, OpenGL, and Direct3D 9/10 too, it only needs a registry edit:</p> <pre tabindex="0"><code>[HKEY_LOCAL_MACHINE\SOFTWARE\AMD\DVR] &#34;GFGEnableAPI&#34;=dword:00000007 </code></pre><p>Manually make this change with regedit, reboot Windows if needed, add yuzu to the Radeon Software, set <code>Wait for Vertical Refresh</code> to <code>Disabled</code>, enable AMD Fluid Motion Frames:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./radeon.png" title=" Good looking UI, AMD"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/radeon_hu93f516816e4b610cd2fc89df77d019eb_94725_944x0_resize_q90_bgffffff_box_3.jpg" alt=" Good looking UI, AMD"></a> <p class="has-text-centered is-italic has-text-grey-light"> Good looking UI, AMD</p> </div> </div> <p>In the performance tab, you can set the overlay to show the generated frames&rsquo; performance (it won’t show up on regular apps or yuzu, as it isn’t informed by the game engine), along with latency and stuttering.</p> <p>Open yuzu, set Fullscreen Mode to Exclusive Fullscreen:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fullscreen.png" title=" It’s as shrimple as that"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/fullscreen_hu125dd8c8d3121a04dba11e7b07d86bfd_24810_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It’s as shrimple as that"></a> <p class="has-text-centered is-italic has-text-grey-light"> It’s as shrimple as that</p> </div> </div> <p>And that’s it, start a game, go into fullscreen by pressing F11 or the hotkey assigned to your controller, and enjoy 2x to 3x the perceived framerate.</p> <p>Note that, while the image quality is much better than the result from Lossless Scaling, AMD disables AFMF if there is too much variance between one frame and the next in order to avoid smoothing out scene transitions like camera changes or opening the menu. This leads to a noticeable frametime inconsistency when a lot of action is happening on screen. We hope AMD adds an option in the future to toggle the sensitivity of this behaviour.</p> <p> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/v-U7GJYrY64" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/8Cbov_uR2Dc" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> </p> <p>The above videos demonstrate native 30 FPS vs AFMF generating frames from a 30 FPS base. While a better result than Lossless Scaling at 30 FPS, artifacts are still noticeable in faster movements, especially on vegetation. Scene transitions are clear and there is less shimmering around the player.</p> <p> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/CG_e5yOnd9E" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/GfRjc9v0jls" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> The above videos demonstrate native 60 FPS vs AFMF generating frames from a 60 FPS base. And at 60 FPS, the results are great! Allowing for smoother gameplay on 120-180Hz displays.</p> <p>No performance graphs are included because your writer doesn’t consider perceived framerate as real performance, but to provide an example, <code>The Legend of Zelda: Tears of the Kingdom</code>, which produces solid 60 FPS in open world with a 5600X and an RTX 3060 Ti, can produce 170-180 “FPS” with AFMF enabled, and with little to no distortion visible.</p> <p>The games can be rendered with an NVIDIA or Intel GPU while still generating frames with AFMF, although the experience is slightly worse than just using the AMD card directly due to the added latency of transmitting the finished frames over PCIe. The only requisite for AFMF to work is to have the display connected to the compatible AMD GPU, any other GPU can do the actual rendering after that. Time to invest in an RX 6400? Smash must look amazing at 240 FPS.</p> <h3 id="intel-delivering-on-its-promises">Intel delivering on its promises</h3> <p>As promised, Intel fixed <a href="https://github.com/IGCIT/Intel-GPU-Community-Issue-Tracker-IGCIT/issues/551">their crashes</a> while building geometry shaders, starting with driver version <a href="https://www.intel.com/content/www/us/en/download/785597/intel-arc-iris-xe-graphics-windows.html">31.0.101.5186/5234</a>.</p> <p>While this allows for games like <code>Xenoblade Chronicles 3</code> to finally get in-game on integrated GPUs and ARC dedicated cards, it seems like there are other areas where the driver needs to mature to produce proper rendering:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xc3.png" title=" Intel moment (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2024/xc3_hu36b458dce752bacecf85a626d9168b50_1458940_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Intel moment (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Intel moment (Xenoblade Chronicles 3)</p> </div> </div> <p>On the flip side, <code>The Legend of Zelda: Tears of the Kingdom</code> improved stability with this driver fix, so Intel Windows specific rendering issues aside, the game should be quite playable now.</p> <h3 id="qualcomm">Qualcomm</h3> <p><a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v24.1.0_R16">K11MCH1</a>’s driver releases continue to flow out, improving performance and compatibility for Adreno users. We strongly recommend staying up-to-date.</p> <p>While there have been new releases of the proprietary driver, nothing of value has been added or fixed yet.</p> <p>Total Adreno moments count this month: 1.</p> <h3 id="exynos-and-mali">Exynos and Mali</h3> <p>Why together? Because we found some <em>interesting</em> limitations in the Exynos hardware that reminds us of the existential crisis Mali suffers. Besides the AMD specific issue we previously mentioned, Exynos’ Xclipse GPU series shares a quality with Mali: total lack of support for BC4 to BC7 texture decoding.</p> <p>While this is <em>fine</em> for native Android games (developers just have to scratch their head at the decision to skip basic texture support, and use an alternative like ASTC), Switch games do use BCn textures, extensively in some cases, and adding the extra CPU work of having to decode those textures into something the GPU can handle (RGBA8) will limit performance and increase memory usage. This is one of the main reasons these GPUs are not on par with Adreno in terms of feature support.</p> <p>So:</p> <p>Total Xclipse moments count this month: 2.</p> <p>Total Mali moments count this month: 2.</p> <h2 id="linux">Linux</h2> <p>Certain distributions like SteamOS, Fedora since <a href="https://bugzilla.redhat.com/show_bug.cgi?id=2216765">version 39</a>, and any distro with a <a href="https://github.com/zen-kernel/zen-kernel/commit/d22e337dca65bd7056e27b93c212df25a9b4c376">linux-zen</a> package available (Arch Linux for example), have significantly increased their default <code>vm.max_map_count</code> values, leading to much more stable out-of-box experiences when running Unreal engine games on yuzu.</p> <p>Progress feels so good! You could learn a little, Windows.</p> <h2 id="future-projects">Future projects</h2> <p>Work on multiprocess support is far from over. We’re aiming to support <code>QLaunch</code>, meaning being able to boot the native game launcher, launch games from there, close them, suspend them, launch a different game, the whole deal.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./ql1.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> QLaunching in 3, 2, 1!</p> </div> </div> <p>Resuming a game works too.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./ql2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Back and forth.</p> </div> </div> <p>The work on applets and multiprocess is exposing a lot of hidden bugs in multiple areas — the accuracy improvements are a very welcome addition; we&rsquo;re having so much fun testing and running the applets.</p> <p>That’s all folks! Thank you for reaching the end of this progress report. We hope to see you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report December 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/ Wed, 10 Jan 2024 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/ <p>Happy New Year, yuz-ers! We say goodbye to 2023 with several great changes, ranging from driver fixes to big memory savings, and quite a bit in between! Let’s go.</p> <p>Happy New Year, yuz-ers! We say goodbye to 2023 with several great changes, ranging from driver fixes to big memory savings, and quite a bit in between! Let’s go.</p> <h2 id="graphics-changes-and-driver-fixes">Graphics changes and driver fixes</h2> <h3 id="vulkan">Vulkan</h3> <p>Drivers are fantastical creatures. They love to exhibit major behavioural changes while still following the Vulkan specification — or more correctly for this issue, the SPIR-V specification.</p> <p>Such was the case with NVIDIA drivers. Since the release of the 540 branch back in September, users have reported sudden crashes when building specific shaders in games, the most common example being some cutscenes and scenarios in <code>Bayonetta 3</code>. However, the problem extended to many other games in unexpected places.</p> <p>After investigating the issue, your writer and <a href="https://github.com/liamwhite">byte[]</a> came to the conclusion that the problem was not the drivers, but a miscompilation in yuzu&rsquo;s shader compiler for <a href="https://registry.khronos.org/OpenGL-Refpages/gl4/html/textureGrad.xhtml">texture gradient</a> operations.</p> <p>Pesky shaders, why don’t we just make them disappear? Well, if you like your games displaying anything besides a <a href="https://www.youtube.com/watch?v=6Peinf-xQWg">black out</a>, you want them, all of them.</p> <p>In some cases, yuzu would incorrectly (and unintentionally) fetch the gradient derivatives as integers (U32), when they were intended to be reinterpreted bitwise as floats (F32). While older drivers would implicitly reinterpret when using the wrong type, the 540 driver series will throw a proper shader validation error, which is the correct behaviour for a bug like this.</p> <p>This meant that if a user with any NVIDIA GPU loaded a pipeline cache with the affected shader after updating to a 540 series driver, or reached a moment where a new affected shader would be built, the game would crash. At the same time, if the user reverted the driver to the older 536/537 series drivers, the same cache would work fine.</p> <p>Culprit found (it was us the whole time), sentence dictated: texture gradient operations will now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12435" data-gh-pr="12435">enforce F32 types on derivatives</a> to comply with the SPIR-V specification. Now games don’t have to crash, users can keep their drivers up to date, and your writer sleeps peacefully at night knowing this is resolved. Anyone using an NVIDIA GPU, regardless of operating system, feel free to update to the latest release for your platform.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bayo3.png" title="Magical Infernal Ladies Fighting (Bayonetta 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/bayo3_hu7f08a002574d4cc420210c811ab0bb37_2408821_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Magical Infernal Ladies Fighting (Bayonetta 3)"></a> <p class="has-text-centered is-italic has-text-grey-light">Magical Infernal Ladies Fighting (Bayonetta 3)</p> </div> </div> <p>Android users have a knack for finding bugs, partially thanks to the different set of default settings we use for the small screen. Handheld mode, for example, is selected by default to improve performance (Mali users appreciate this substantially) and save a tiny bit of RAM, but hey, we’re not in the Android section yet!</p> <p><code>Fight'N Rage</code>, a fantastic beat’em up, had its screen cut in half in handheld mode, something most desktop users missed since it runs fine in docked mode. The issue was — and this is a classic for sprite games by now — in how swizzle and window origin adjustments were being handled. Viewport transform and window origin mode are handled separately in the GPU, so <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12235" data-gh-pr="12235">splitting the two jobs</a> is what doctor byte[] ordered. Feel free to smash that attack button now.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/fnrbug_hue166187039afb4a55b0661a230b817b4_587050_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Quite a big difference (Fight&#39;N Rage)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/fnrfix_hu46039ddb1eb04a5daef868ac49a80384_1094177_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Quite a big difference (Fight&#39;N Rage)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Quite a big difference (Fight&#39;N Rage)</p> <p>Guess who’s back. A game that is special in many aspects, an emulator itself, one of the few native Vulkan titles on the Switch, a game that is even out of print in an era of digital releases, and the reason byte[] started contributing to yuzu.</p> <p>That’s right, <code>Super Mario 3D All-Stars</code> is back in a report, this time addressing one of its remaining interesting quirks: the incredibly slow performance of its intro video on non-NVIDIA and non-Mesa drivers.</p> <p>The quirkiness was the result of the game causing yuzu to continuously recreate its swapchain on every single frame. A swapchain is a set of framebuffer images used by the graphics API and the GPU to draw to the screen.</p> <p>The game used one of its framebuffer images as sRGB during startup, which caused yuzu to detect it as sRGB. The other framebuffer image was only used as linear. Since yuzu tries to respect the colorspace of the output image, this problem was causing yuzu to incorrectly think it needed to recreate the swapchain on every single frame. This constant, per-frame swapchain recreation is not that expensive on NVIDIA and Mesa drivers, but anything else (Intel, AMD, Android drivers) can spend as much as 30ms processing this switching. That’s around 30 FPS lost in a game supposed to render at 60!</p> <p>How do we avoid this? Well, Vulkan always interprets any framebuffer currently being presented to screen as sRGB, so replacing the frame with a non-sRGB one is just adding unnecessary additional work and pissing off several drivers. Changing the logic to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12274" data-gh-pr="12274">ignore sRGB in framebuffer images</a> provides smooth frametimes for users of these drivers.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sm3d.png" title="What does Mario do with that many stars? Not sing Peaches I hope (Super Mario 3D All-Stars)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/sm3d_hu7b88b844e0878fa91963ef69d35749e9_2734983_1024x0_resize_q90_bgffffff_box_3.jpg" alt="What does Mario do with that many stars? Not sing Peaches I hope (Super Mario 3D All-Stars)"></a> <p class="has-text-centered is-italic has-text-grey-light">What does Mario do with that many stars? Not sing Peaches I hope (Super Mario 3D All-Stars)</p> </div> </div> <p>On a related note, let’s talk about presentation limits and how they affect asynchronous presentation, which moves presenting to the screen to a different CPU thread.</p> <p>Due to several factors, yuzu’s Vulkan renderer could only process up to 6 frames at a time. While this isn’t normally an issue on desktop, especially for users that don’t enable Asynchronous Presentation (available in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced</code>), Android, a platform that demands always using asynchronous presentation, showed us that low enough performance with the setting toggled on, regardless of OS or platform, can cause the queue of swapchain images to grow beyond the limit of 6 frames. Thus, leading to a driver crash and your progress being lost. Ouch.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./async.png" title="Feel free to test enabling it now"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/async_huc12be54c88d46f6f74c8e98d6d397705_7673_424x0_resize_q90_bgffffff_box_3.jpg" alt="Feel free to test enabling it now"></a> <p class="has-text-centered is-italic has-text-grey-light">Feel free to test enabling it now</p> </div> </div> <p>Android users found a workaround to this very early on: lowering the game speed limit under 100%, which slowed down the presentation rate, thereby usually keeping yuzu under the 6 frame limit.</p> <p>While that technically worked, the idea is to run games at least at 100% speed whenever possible, right?</p> <p>The easy solution byte[] found for this problem after identifying it was to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12345" data-gh-pr="12345">force the presentation process to wait</a> before reaching the limit, improving stability substantially on low-end hardware, including Android devices, while also improving input lag! Now asynchronous presentation is safe to use, improves frametimes, reduces input latency, and does your laundry! That’s a solid win for everyone.</p> <p>Enough about presentation, let’s talk about clip distance instead now. I can hear you asking in the back, &ldquo;what the living Koopa Castle is a clip distance?&rdquo;</p> <p>Most GPUs allow shaders to set up custom clipping planes for vertex data, which allows the GPU to cut geometry invisible to the viewport with no extra triangles generated or rendering cost. The members of <code>gl_ClipDistance</code>, a global variable and float array declared in the shader, represent the distance to the clipping plane on each vertex.</p> <p>Many games use these values, including <code>Red Dead Redemption</code>, <code>Fire Emblem Warriors: Three Hopes</code>, <code>DEAD OR ALIVE Xtreme 3 Scarlet</code>, <code>Hyrule Warriors: Definitive Edition</code>, and <code>Portal</code>. Weird group, isn’t it? A cowboy, a skimpy Japanese fighter, two medieval warriors, and a Companion Cube walk into a bar…</p> <p>On most desktop drivers, the default values for all global variables will be zero implicitly. However, SPIR-V says that these values are actually undefined. This assumption broke rendering in <code>Portal</code> on the radv Mesa driver ― for clip distances specifically.</p> <p>byte[]&rsquo;s <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12403" data-gh-pr="12403">first fix</a> attempted to only declare an array of clip distances as large as actually needed, which would prevent any undefined values from persisting in the array. While some shaders (like those used in <code>Portal</code>) write directly to the clip distance array values, others (like in <code>Red Dead Redemption</code>) use a loop variable to access the array. Thus, the first fix attempt resulted in declaring an array of zero clip distances in those games, which is illegal in SPIR-V.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./doabug.png" title="Emulation, when The Void does indeed stare back (DEAD OR ALIVE Xtreme 3 Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/doabug_huf4f491b55d66986d6acfafb0b9e34fdc_805484_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Emulation, when The Void does indeed stare back (DEAD OR ALIVE Xtreme 3 Scarlet)"></a> <p class="has-text-centered is-italic has-text-grey-light">Emulation, when The Void does indeed stare back (DEAD OR ALIVE Xtreme 3 Scarlet)</p> </div> </div> <p>After revisiting the issue, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12487" data-gh-pr="12487">implemented a more robust solution:</a> when clip distances are used, always declare an array of as many clip distances as the host driver supports, and use a default value to ensure the array members are all set to zero, avoiding any undefined behaviour. All drivers except Mali support eight clip distances; Mali supports <em>zero</em>, so a special case had to be made for this driver. Mali moment #1.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./doafix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/doafix_hu444eceb506e37b5a14c5cb11ef0e4608_1430057_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was a triumph"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rdr.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/rdr_hu418dc45079d99d772611693eca758cf0_3366091_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was a triumph"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hwde.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/hwde_hu4e33f9708fbfea42816519c475111e82_3697309_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was a triumph"></a> </div> <div class="column is-bottom-paddingless"> <a href="./few.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/few_hu53eeb5ed42da25f43596b8149948e62b_2741867_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was a triumph"></a> </div> <div class="column is-bottom-paddingless"> <a href="./portal.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/portal_hu03ace33a31dbc8a03c1dab0ef8e667aa_2735568_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was a triumph"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This was a triumph</p> <p>GPUs often work with texture data in a variety of formats. Among the parameters used by compressed textures like ASTC and BCn is <code>pitch</code>, which is the size of one row of compressed blocks. This eventually gets divided by the block size of the texture by the emulator, giving the number of blocks per row. This worked flawlessly for linear 1x1 block-sized uncompressed textures, but broke compressed ones that have larger block sizes. Vulkan expects the pitch to be the number of texels (the minimum unit of a texture map, think of pixels but for textures) per row, plus some padding, but yuzu was calculating the value incorrectly.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/kofbug_huf2519062142dfbcae8f049dc02aa0655_1853012_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A new tournament begins (THE KING OF FIGHTERS XIII GLOBAL MATCH)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/koffix_hu95ff19c35510296420aab29dc9f13c2f_1607439_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A new tournament begins (THE KING OF FIGHTERS XIII GLOBAL MATCH)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">A new tournament begins (THE KING OF FIGHTERS XIII GLOBAL MATCH)</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12479" data-gh-pr="12479">Fixing the buffer row length,</a> and, while at it, tuning the software BCn decoder Mali needs (Mali moment #2), is how <a href="https://github.com/GPUCode">GPUCode</a> fixed the rendering of <code>THE KING OF FIGHTERS XIII GLOBAL MATCH</code> and the Eatsa Pizza minigame from <code>Mario Party Superstars</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pizza.png" title="Your writer is old enough to remember playing this on the Nintendo 64 (Mario Party Superstars)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/pizza_huc8c1d5f4751b9657b2d55390c95f1e6a_1469891_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Your writer is old enough to remember playing this on the Nintendo 64 (Mario Party Superstars)"></a> <p class="has-text-centered is-italic has-text-grey-light">Your writer is old enough to remember playing this on the Nintendo 64 (Mario Party Superstars)</p> </div> </div> <p>That ends the Vulkan section, so what’s left is to follow up with the:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./opengl.png" title="And you can’t prove Khronos wrong"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/opengl_hua35ad2ab6f1552afc009fb01632742fc_628296_480x0_resize_q90_bgffffff_box_3.jpg" alt="And you can’t prove Khronos wrong"></a> <p class="has-text-centered is-italic has-text-grey-light">And you can’t prove Khronos wrong</p> </div> </div> <h3 id="opengl">OpenGL</h3> <p>Because <a href="https://github.com/ameerj">epicboy</a> won’t let the old API rest.</p> <p>One remaining issue (of many) for the OG open API was a bug with the shadows of <code>Metroid Prime Remastered</code>. By bringing the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12412" data-gh-pr="12412">counter query accuracy,</a> which was first seen in Vulkan, to OpenGL, this issue is now solved.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./metroid.png" title="SPAAAAACE (Metroid Prime Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/metroid_hud91a79546c5d40ef3f4a3f770be4a74a_1234209_1024x0_resize_q90_bgffffff_box_3.jpg" alt="SPAAAAACE (Metroid Prime Remastered)"></a> <p class="has-text-centered is-italic has-text-grey-light">SPAAAAACE (Metroid Prime Remastered)</p> </div> </div> <p>OpenGL users saw another win with the implementation of two fixes for <code>Xenoblade Chronicles 3</code>. This is particularly important for AMD users, Windows or Linux, since most AMD GPUs can’t avoid vertex explosions while running the game with Vulkan in the Pentelas region of the main story, and the DLC, Future Redeemed.</p> <p>First, by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12415" data-gh-pr="12415">implementing</a> the <code>DrawTransformFeedback</code> macro, which is the OpenGL equivalent of Vulkan’s <code>DrawIndirectByteCount</code>, particles were fixed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xc3.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light">Remember the Game Awards flute guy? (Xenoblade Chronicles 3)</p> </div> </div> <p>And second, a lesson of how a simple typo can cause havoc, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12377" data-gh-pr="12377">fixing the transform feedback binding</a> from <code>strides</code> to <code>sizes</code> stopped the grass in the game from becoming some space demon abomination.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/xc3bug_hu007809d21f6c55f7623ad21acd617f60_4633014_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That experiment really went wrong, Dr. (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/xc3fix_hu0cd2426314e9d7cee549ebfd05975bb7_4648971_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That experiment really went wrong, Dr. (Xenoblade Chronicles 3)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That experiment really went wrong, Dr. (Xenoblade Chronicles 3)</p> <p>With these changes, AMD users suffering from the Pentelas/DLC vertex explosion bug can safely play the game in OpenGL.</p> <p>But you know what would help even more? If epicboy also added more optimizations for the AMD proprietary OpenGL driver. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12437" data-gh-pr="12437">Which is exactly what he did.</a> </p> <p>With the release of the new OpenGL driver back in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/#amd-opengl-25-years-in-the-making">July of 2022</a>, several unsavoury workarounds that yuzu code had for the red vendor could be removed (and now have been), improving performance.</p> <h2 id="android-adventures-and-kernels-with-benefits">Android adventures, and kernels with benefits</h2> <p>Instead of a bulleted list like in previous articles, let’s start with the big change first.</p> <h3 id="saving-ram-makes-games-boot-fast">Saving RAM makes games boot fast</h3> <p>One of the properties of the Linux kernel, which GNU/Linux distributions and Android benefit from, is its flexibility and constant progress made by the community and contributors. One such case is the Linux kernel extension <a href="https://man7.org/linux/man-pages/man2/madvise.2.html">MADV_REMOVE</a>, which allows for freeing up a given range of memory pages, &ldquo;punching a hole&rdquo; in the specified range of memory.</p> <p>Thanks to byte[]’s work, the emulator can <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12358" data-gh-pr="12358">take advantage</a> of this extension to remove the requirement of needing 3GB of free RAM immediately after booting a game, and to also significantly decrease boot times while at it. Memory isn’t a problem for most users with 16GB of system RAM (unless you have too many background processes), but for users with 8GB or lower running an OS with a Linux kernel (desktop Linux or Android), this greatly reduces immediate memory requirements, even allowing <code>Celeste</code> to work on 4GB devices…</p> <p>…For a time. While the system doesn’t need to provide the full 3GB at game boot now, the game will still slowly demand that amount as it runs. But this might be enough to let 8GB devices, or even 6GB ones (which we don’t officially support, but users use them anyway) reach the next save point.</p> <p>Feel free to play the most complex games now on your 8GB Linux laptop or phone and enjoy the improved boot times! We believe only <code>The Legend of Zelda: Tears of the Kingdom</code> still requires 12GB on ASTC compatible devices (Android devices or Intel iGPUs) to be safely playable now.</p> <p>For the Windows gang, sorry: only bad news. The Windows kernel doesn’t have an equivalent to MADV_REMOVE, so if you have a low-end device with a small amount of RAM, Linux is the way to go.</p> <p>No surprise there though.</p> <h3 id="4k">4K</h3> <p>The resolution? No, worse, crazier than pixel density. Remember <code>Paper Mario: The Origami King</code>? Good game, pretty graphics, and fun humour. This game has a unique situation on its hands, its ARM CPU code is illegal. Not &ldquo;FBI OPEN UP&rdquo; illegal, but &ldquo;not able to run natively on contemporary systems due to a difference in stack pointer alignment handling&rdquo; type of illegal. The Switch clears a hardware bit that checks the stack pointer alignment and generates an exception, but practically every other operating system sets it, and there is no way to turn it off without a kernel modification.</p> <p>This meant modern devices couldn’t run this game with NCE enabled. Until now.</p> <p>By using the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12237" data-gh-pr="12237">ARM parser</a> of <a href="https://github.com/merryhime/dynarmic">Dynarmic</a>, byte[] parses the instructions responsible for causing the crash due to the alignment error this game produces, and interprets them in software. The result? Three thousand eight hundred and fifty eight lines of code added to get a game that doesn’t render correctly on Android booting, and it still needs a save file to get past the intro…</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tokbug.png" title="Luigi sure is brave to drive in the Dark Woods (Paper Mario: The Origami King)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/tokbug_hu6b13f71b324dc9859c3698a6a9eee195_394764_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi sure is brave to drive in the Dark Woods (Paper Mario: The Origami King)"></a> <p class="has-text-centered is-italic has-text-grey-light">Luigi sure is brave to drive in the Dark Woods (Paper Mario: The Origami King)</p> </div> </div> <p>So, wasted effort? With byte[]? Never. The game wouldn’t render correctly because the emulator was binding float images with a mismatched sampler type. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12432" data-gh-pr="12432">forcing the use of floats</a> for all pixel formats in the shader cache which aren’t explicitly declared as integer, mobile drivers are now able to properly render the Mario brothers in all their flat glory, along with at least <strong>71</strong> <a href="https://www.reddit.com/r/EmulationOnAndroid/comments/18od8vw/single_pr_fixes_a_lot_of_games_in_yuzu/">other games!</a></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tokfix.png" title="Now that’s more like it, it only costs us a shader invalidation (Paper Mario: The Origami King)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/tokfix_hu0e8c55697c7f6c5f7b8f9a87bbb0175c_2295027_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now that’s more like it, it only costs us a shader invalidation (Paper Mario: The Origami King)"></a> <p class="has-text-centered is-italic has-text-grey-light">Now that’s more like it, it only costs us a shader invalidation (Paper Mario: The Origami King)</p> </div> </div> <p>Slight deja-vu with the fix for NVIDIA 540 driver series previously mentioned, right? This work was an additional one hundred and eighty four lines of code, giving a total of four thousand and thirty eight lines of code, 4K, spent on Origami paper, just for Android.</p> <h3 id="other-android-specific-gpu-changes">Other Android specific GPU changes</h3> <p>Another peculiar problem the Android builds faced were the slow video decoding performance in games like <code>SUPER MARIO ODYSSEY</code>, famous for its video pop-up tutorials. The culprit was unnecessarily downloading some texture memory which was about to be overwritten anyway. Some <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12543" data-gh-pr="12543">tweaks to the DMA code</a> by <a href="https://github.com/FernandoS27">Blinkhawk</a>, and the performance is now fixed!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo.png" title="No more hints here, scra-CAW! ♪ No more hints (SUPER MARIO ODYSSEY)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/smo_hu2d19a78ad8c73289363ee02cd1081e14_998035_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more hints here, scra-CAW! ♪ No more hints (SUPER MARIO ODYSSEY)"></a> <p class="has-text-centered is-italic has-text-grey-light">No more hints here, scra-CAW! ♪ No more hints (SUPER MARIO ODYSSEY)</p> </div> </div> <p>One early regression yuzu had when the Android builds were first introduced affected the FXAA antialiasing filter. As it turns out, the fix for the colour banding FXAA experienced on desktop hardware (which byte[] implemented back in June) missed updating the renderpass to the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12256" data-gh-pr="12256">proper format.</a> By properly using the <code>VK_FORMAT_R16G16B16A16_SFLOAT</code> format for the renderpass, GPUCode resolved the issue.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/fxaabug_hubcdb67ad45822e2dcd2822deece3642c_5205580_1024x0_resize_q90_bgffffff_box_3.jpg" alt="From Cursed Triforce to proper Triangle of Death"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/fxaafix_hu4d117414ddf26622bab3119dbe539e5e_955666_1024x0_resize_q90_bgffffff_box_3.jpg" alt="From Cursed Triforce to proper Triangle of Death"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From Cursed Triforce to proper Triangle of Death</p> <p>The Switch offers a JIT service (not to be confused with yuzu’s JIT, Dynarmic) that allows games to write to code memory during runtime — which wouldn&rsquo;t normally be possible due to the restrictions of the platform. This is currently only used for the official Nintendo 64 emulators in <code>Super Mario 3D All-Stars</code> and the <code>Nintendo Switch Online</code> collection.</p> <p>Properly using <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12513" data-gh-pr="12513">code memory handles</a> allows the JIT service to work with yuzu’s NCE backend, letting the user run games from the <code>Nintendo 64 - Nintendo Switch Online</code> library. Thank you byte[] for yet again making an emulator work inside an emulator.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./n64.png" title="Look, savestates! (SUPER MARIO 64)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/n64_hu2fa165caf4b03a67441972d1bc380816_747215_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Look, savestates! (SUPER MARIO 64)"></a> <p class="has-text-centered is-italic has-text-grey-light">Look, savestates! (SUPER MARIO 64)</p> </div> </div> <p>As a continuation to November’s progress on improving Mali stability due to their lack of support for <code>nullDescriptor</code>, byte[] now added the workaround to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12410" data-gh-pr="12410">not pass null views.</a> </p> <p>Mali moment #3.</p> <p>nullDescriptor was added with the Vulkan extension <a href="https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VK_EXT_robustness2.html">VK_EXT_robustness2</a>, back in 2020, for version 1.1 of the API. Vulkan is currently at version 1.3. Given that the feature has native hardware support on all Direct3D-compatible GPUs, and is trivial to emulate in the driver, we are not sure why this has not been implemented yet&hellip;</p> <p>Turnip drivers are a work in progress from the Mesa developers — while they typically perform and render very well, they are still in development. One case that demonstrated this was how a change to improve driver compatibility in Mali caused Turnip to regress in response. Mali moment # 4? No. This was last month.</p> <p>This only specifically affects the Adreno 610 series GPUs when running Turnip drivers. byte[]’s solution to the issue is to purposely <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12390" data-gh-pr="12390">use the Vulkan API incorrectly</a> for Turnip while we wait for Mesa to address the issue. Now Adreno 610 users can run Turnip drivers again.</p> <h3 id="android-specific-ui-and-miscellaneous-changes">Android-specific UI and miscellaneous changes</h3> <p>Let’s round up the Android changes — we have more to cover, affecting both desktop and Android users too.</p> <p>First and most important to mention, <a href="https://github.com/t895">t895</a> outdid himself and finished implementing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12335" data-gh-pr="12335">Game Properties</a> .</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./config1.gif" title="Kept you waiting, huh"><img src="./config1.gif" alt="Kept you waiting, huh"></a> <p class="has-text-centered is-italic has-text-grey-light">Kept you waiting, huh</p> </div> </div> <p>This new feature can be accessed by long-pressing a game in the list, and allows access to the following menus:</p> <ul> <li>A game information page to check program ID, game developer, game version running, and game ROM path.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./config2.png" title=" Great for diagnosing update installation shenanigans"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/config2_hub806f1270a62913ae69ccf684fdce0ea_41745_397x0_resize_q90_bgffffff_box_3.jpg" alt=" Great for diagnosing update installation shenanigans"></a> <p class="has-text-centered is-italic has-text-grey-light"> Great for diagnosing update installation shenanigans</p> </div> </div> <ul> <li>Per-game settings page, with the option to revert a setting to the global default.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./config3.png" title="As a game tester, and an 8GB sufferer, your writer considers this a huge blessing"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/config3_huabc8ad9cfa988eb7932e32e8fdaa9ade_68294_397x0_resize_q90_bgffffff_box_3.jpg" alt="As a game tester, and an 8GB sufferer, your writer considers this a huge blessing"></a> <p class="has-text-centered is-italic has-text-grey-light">As a game tester, and an 8GB sufferer, your writer considers this a huge blessing</p> </div> </div> <ul> <li>Similarly, a per-game driver selector, for the cases where Qualcomm did something correctly, or an older Turnip release is better.</li> <li>An add-ons manager to install, enable, and disable updates, DLCs, and mods. While there are plans to support compressed mods, right now they must be uncompressed and manually selected here.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./config4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/config4_hue8fa6249305fb0fb75b5bebc3b3b7ad8_31905_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bet you enjoy this one the most"></a> </div> <div class="column is-bottom-paddingless"> <a href="./config5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/config5_hu2a7670e8aff378e75befe8837673af8b_55526_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bet you enjoy this one the most"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Bet you enjoy this one the most</p> <ul> <li>A save data manager, allowing users to export or import per-game saves, alongside the global option.</li> <li>An option to delete all save data of that particular game.</li> <li>An option to clear the pipeline cache of that particular game.</li> <li>And a Start button, which allows you to select a global or custom configuration. Launching from the game list will always load the custom configuration.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./config6.png" title="To round it up"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/config6_hu28a780c26590e8daadc3fc600ab9a1f7_157672_395x0_resize_q90_bgffffff_box_3.jpg" alt="To round it up"></a> <p class="has-text-centered is-italic has-text-grey-light">To round it up</p> </div> </div> <p>This covers one of the biggest missing components the Android build has left. The only remaining settings are a content manager to delete installed content, and a controller mapping UI. Rest assured, we’re working on them.</p> <p>t895 has continued to work on bringing Android to feature parity with the desktop build, while considering the specific needs of the mobile platform. Some of the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12520" data-gh-pr="12520">recent changes</a> included are:</p> <ul> <li>Hiding the Fastmem toggle if CPU debugging is disabled, avoiding confusion on how it operates.</li> <li>Exposing the anisotropic filtering setting in graphics, an option that greatly helps visuals in several games with minimal performance cost.</li> <li>Centering the switch setting title when no description is present.</li> </ul> <p>One of the unique Android features is their <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12387" data-gh-pr="12387">Oboe</a> audio backend, which is, as expected of something unique to the platform, quite robust. byte[] implemented it into yuzu to stop audio from cutting off when changing audio outputs (switching to wireless headphones for example) or starting a screen video capture.</p> <p>The option can be found at <code>Settings &gt; Advanced settings &gt; Audio &gt; Output engine</code>. While Auto is the recommended value (it will always use Oboe on Android), users can take advantage of per-game settings to test Oboe vs Cubeb in any game they want.</p> <p>And finally, a minor change for end users which we think someone out there will enjoy. With the work on the game properties section, t895 also had to equalise the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12518" data-gh-pr="12518">configuration file</a> <code>config.ini</code> to make it work on both desktop and Android builds.</p> <h2 id="memory-heap-allocation-or-how-the-linux-kernel-can-be-wrong-sometimes">Memory heap allocation, or how the Linux kernel can be wrong sometimes</h2> <p>Yes, Linux did an oopsie, how will they ever recover?</p> <p>The Linux kernel has a large set of runtime parameters. One in particular is a limit on how many times a program can use the <code>mmap</code> system call. The default maximum value is 65530, which &ldquo;ought to be enough for anyone&rdquo;, or so the meme goes, but in practice that isn’t always the case.</p> <p>Typically, Switch games will query the amount of memory heap they have available, reserve all of it, and then suballocate from their OS-level reservation as they use up memory. This is already well-supported when using host-mapped addressing (most commonly known as fastmem) on Linux-based operating systems, as it only requires a few calls to map the physical memory blocks which comprise the heap.</p> <p>Games based on Unreal Engine 4 do not do this. Instead of reserving all of the available memory heap immediately, they reserve small blocks from the kernel on demand. If only the software page table is being used, there’s no problem, as the blocks aren’t resulting in calls to <code>mmap</code>.</p> <p>When yuzu uses host-mapped addressing, the emulator propagates all of these mappings into the host address space. That in itself wouldn’t normally be a problem, if it wasn’t for the fact that Unreal Engine 4 can allocate hundreds of thousands of small heap blocks, going over the kernel limit with ease, and crashing the entire program.</p> <p>yuzu is not the only <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/vm-max-map-count.html">project</a> affected by this completely arbitrary limitation — it has been a complaint for quite a long time.</p> <p>To work around this limitation, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12466" data-gh-pr="12466">inserts a layer</a> between the software page table and the host mapping system, constantly tracking the heap allocations made by programs and automatically recycling some less recently used mappings, which causes some stuttering ― but that&rsquo;s better than a game crash. Collection will reduce the number of mappings to around half of the 65530 limit most systems ship with.</p> <p>Yep, 64k is not enough for everyone.</p> <p>This way, Unreal Engine games can be safely played on Linux-based systems, like desktop distributions and Android devices, without needing to disable fastmem and NCE, two big performance settings that no one wants to keep off.</p> <h2 id="project-leviathan-applets-and-input-fun">Project Leviathan, applets, and input fun</h2> <p>As usual, <a href="https://github.com/german77">german77</a> has been having his good share of fun working on input and the native applets.</p> <p>First in the list is a solution for Amiibos with read-only permissions. If a program mounted them as read-only, yuzu doesn’t access any of their encrypted data, and could mark them as corrupt, which wasn’t really the case. Since read-only data is set from the factory, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12255" data-gh-pr="12255">skipping the corruption check</a> allows the use of read-only mounts in games like <code>The Legend of Zelda: Tears of the Kingdom</code>.</p> <p>Next up, an announcement. german77 started working on a rewrite for the HID (human interface devices) code, called <code>Project Leviathan</code> with the intention of further improving the accuracy of yuzu’s input emulation. So far only preliminary work has been done, but some results have already been put into service.</p> <p>The first part finished is the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12289" data-gh-pr="12289">emulation</a> of <code>AppletResource</code>, which allows the developers to start working on multiprocess support in the near future, as well as other necessary resources like <code>AppletResourceUserId</code>, or simply <code>aruid</code>.</p> <p>Following up, german77 implemented the necessary code to allow the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12359" data-gh-pr="12359">creation of multiple instances</a> of HID shared memory, removing an old workaround and relieving the kernel from being responsible for handling shared memory, which in turn allows having a single shared memory instance per aruid.</p> <p>Another spot that is starting to shape up thanks to this HID rewrite is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12425" data-gh-pr="12425">object creation,</a> more specifically, <code>InitializeVibrationDevice</code>, which would cause games like <code>Rocket League</code> to crash.</p> <p>But not only german77 worked on input this month, newcomer <a href="https://github.com/HurricanePootis">HurricanePootis</a> brought us an interesting fix for Linux users. Linux handles hardware permissions on a per-user level. For example, if for some reason the administrator desires it, a user can be completely blocked from having access to the <code>video</code> group, or <code>audio</code>, etc.</p> <p>Connected devices are often only able to be accessed by the <code>root</code> user or group. While this usually isn’t a problem for just using the device, it can block access to the custom Joy-Con and Pro Controller drivers german77 implemented, regardless of whether the user runs an appimage or Flatpak yuzu build. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12292" data-gh-pr="12292">adding a udev rule</a> to grant access to <code>hidraw</code> devices, HurricanePootis circumvented this limitation. Thank you!</p> <h2 id="miscellaneous-changes">Miscellaneous changes</h2> <h3 id="multiprocess-preliminary-work">Multiprocess preliminary work</h3> <p>We spoke about preliminary work for multiprocess support. There’s more to cover on the matter.</p> <p>byte[] refactored how yuzu emulates <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12236" data-gh-pr="12236">CPU core activation.</a> He assures us writing three thousand lines of code simplifies the design of the ARM interface the emulator uses. This has the added benefit of allowing code from multiple guest processes to run simultaneously, which is another of the prerequisites for starting the multiprocess effort.</p> <p>ARM guest emulation also received support for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12394" data-gh-pr="12394">multiple memory instances,</a> which can now coexist and interact with multiple server sessions. One step closer with every pull request.</p> <h3 id="core-kernel-and-file-system-changes">Core, kernel, and file system changes</h3> <p>german77 found some… unexpected… behaviour in how the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12328" data-gh-pr="12328">user profile manager</a> behaved. It generated around 13 instances of itself, which lead to multiple, hard to explain bugs related to user data, including the sudden loss of profile after emulator crashes. Slapping the profile manager and telling it to run a single instance should mitigate most random profile loss issues.</p> <p>Sometimes, games have unexpected file organisation strategies. A recent episode of this phenomenon affects the <code>Batman: Arkham</code> trilogy: the base games ship with a null RomFS. That shouldn&rsquo;t have been a problem; having a RomFS is never a requirement to run a program. <code>Batman: Arkham Asylum</code> did have a RomFS, and was launching fine, but <code>Batman: Arkham City</code> and <code>Batman: Arkham Knight</code> require their updates installed to be playable (their base game size is only 8MB). The update contains the RomFS, but since the base game didn&rsquo;t contain it, yuzu couldn&rsquo;t find the RomFS to load, even with the update installed.</p> <p>Handling this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12263" data-gh-pr="12263">peculiar case</a> fell into byte[]’s hands, and the World’s Greatest Detective can now go fetch <code>?</code> signs all over the place at ease.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./batman.png" title="I am vengeance! I am the night! (Batman: Arkham Knight)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/batman_hu640e444d80cac5fa05387aa2b9d190e0_3603869_1024x0_resize_q90_bgffffff_box_3.jpg" alt="I am vengeance! I am the night! (Batman: Arkham Knight)"></a> <p class="has-text-centered is-italic has-text-grey-light">I am vengeance! I am the night! (Batman: Arkham Knight)</p> </div> </div> <p>Another <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12392" data-gh-pr="12392">file system implementation</a> byte[] gave us was support for the <code>OpenDirectoryMode</code> flag, which allows <code>Portal 2</code> to save and load properly. One has to wonder why this wasn’t fixed earlier.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./portal21.png" title="Are we going to space? (Portal 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/portal21_hu5589a49e0f54136375884b38aed54db4_2018272_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Are we going to space? (Portal 2)"></a> <p class="has-text-centered is-italic has-text-grey-light">Are we going to space? (Portal 2)</p> </div> </div> <p>Some additional work was needed to get this masterpiece fully playable. An entire service needed some patching-up, specifically, <code>ro</code>, or <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12321" data-gh-pr="12321">relocatable object</a> (allowing programs to load libraries on the fly), needed to be rewritten a bit — just over a thousand lines of code.</p> <p>And finally, <code>vi</code>, one of the services responsible for drawing on the screen, needed to distinguish between <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12331" data-gh-pr="12331">closing and destroying layers</a> in order to get <code>Portal 2</code> in-game.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./portal22.png" title="Ever get that feeling of Deja Vu? (Portal 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2023/portal22_hud4a6f1849de063c04ff909b3cb0b3d1c_3226268_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Ever get that feeling of Deja Vu? (Portal 2)"></a> <p class="has-text-centered is-italic has-text-grey-light">Ever get that feeling of Deja Vu? (Portal 2)</p> </div> </div> <p>A silly issue byte[] made in the <a href="https://www.openssl.org/">SSL</a> buffer size configuration broke the Open Course World section of <code>SUPER MARIO MAKER 2</code>. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12372" data-gh-pr="12372">Fixing this configuration mishap</a> allows the game to run its &ldquo;main mode&rdquo;.</p> <p>Yet another set of findings by byte[], yet another battle won against shutdown crashes. This time we have timing related crashes in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12454" data-gh-pr="12454">core timing</a> being addressed, and a rather rare <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12455" data-gh-pr="12455">shutdown crash</a> in the kernel being squashed.</p> <p>Let’s close this longer-than-expected report and move to the hardware section. Our last section in the list is:</p> <h3 id="ui-changes">UI changes</h3> <p>german77 spotted an oopsie in the UI configuration files, leading to the language selection never getting saved. If anyone noticed yuzu always selected the default language, you now know what the reason was. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12402" data-gh-pr="12402">Making this value persistent</a> solved the problem.</p> <p>And lastly one last minor buff to Linux desktop users, from the hands of newcomer <a href="https://github.com/ReillyBrogan">ReillyBrogan</a>.</p> <p>When using a Wayland compositor, program windows are matched to their <code>.desktop</code> shortcut file. The <code>appId</code> window property is intended to match the name of the <code>.desktop</code> file, for example, <code>org.yuzu_emu.yuzu.desktop</code>. Plasma desktop, by default, sets this property to the name of the binary file, which in this case is just <code>yuzu</code>, and doesn’t match the expected value of <code>org.yuzu_emu.yuzu</code>. This led to Plasma desktop users (Steam Deck included) displaying yuzu without our glorious icon. One <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12521" data-gh-pr="12521">manual override</a> later, and the icon is properly there. Thank you!</p> <h2 id="hardware-section">Hardware section</h2> <h2 id="nvidia-safe-to-update">NVIDIA, safe to update</h2> <h3 id="proprietary-nvidia-driver">Proprietary NVIDIA driver</h3> <p>As previously mentioned, it’s safe to update to the latest driver versions thanks to the fixes implemented by byte[]. This will become more critical once the SUPER refresh of Ada cards is out, so perfect timing there. Hopefully they finally provide good value.</p> <h3 id="nvk">NVK</h3> <p>What’s this? A free and open source Mesa Vulkan driver for Turing and later NVIDIA hardware?</p> <p><a href="https://www.phoronix.com/news/Mesa-23.3-Released">It’s still very early days</a>, Mesa just started shipping preliminary support for this new driver, but we can’t wait to try it out once it’s mature enough. There’s nothing better than having the option to choose.</p> <h2 id="amd">AMD</h2> <p>We identified <code>Pokémon Scarlet &amp; Violet</code> crashes on RDNA1 hardware exclusively (RX 5000 series). The usual standard procedure was followed, a custom test case was provided in a bug report.</p> <h2 id="intel">Intel…</h2> <p>In contrast, Intel failed us again. No word on the fix for the geometry shader crash we <a href="https://github.com/IGCIT/Intel-GPU-Community-Issue-Tracker-IGCIT/issues/551">reported</a> back in October yet.</p> <p>We hope it’s just a delay from the holidays. 2024 is the year of <del>the Linux desktop</del> working Intel Windows drivers.</p> <h2 id="qualcomm">Qualcomm</h2> <h3 id="proprietary-qualcomm-driver">Proprietary Qualcomm driver</h3> <p>We recently got our hands on a Snapdragon 8 Gen 3 device (a Red Magic 9), and while the official Qualcomm driver is still mediocre at best, we’re very impressed with the performance of the new Adreno 750 GPU. In spite of its driver, it managed to bruteforce amazing framerate numbers. It still produced the same graphical glitches any other Adreno card has with their respective official drivers.</p> <p>Some games reached the 120 FPS limit imposed by the device’s screen refresh rate. In short, Balanced mode in the Red Magic 9 is faster than Diablo mode in the previous Red Magic 8.</p> <p>Even Turnip, with its <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v24.0.0_R15">early support</a> already shows outstanding results. Here is an Adreno 740 vs an Adreno 750:</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="./sd8g2.jpg" alt="i9-14900K who? (The Legend of Zelda: Breath of the Wild)"> <img src="./sd8g3.jpg" alt="i9-14900K who? (The Legend of Zelda: Breath of the Wild)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">i9-14900K who? (The Legend of Zelda: Breath of the Wild)</p> <p>Speaking of which.</p> <h3 id="turnip">Turnip</h3> <p>Leaving Adreno 750 aside for a moment, the Turnip network of support continues to improve. Current <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases">releases</a> have added support for rare GPU variants, like Adreno 642L and Adreno 644. Performance and stability have improved as well.</p> <p>Keep up to date with Turnip releases; they usually only bring improvements.</p> <h2 id="mali-moment">Mali moment</h2> <p>Total Mali moments count this month: 3.</p> <p>But it’s not all bad news dear Mali sufferers!</p> <p><a href="https://www.phoronix.com/news/Panthor-DRM-Newer-Mali">Newer generations</a> of Mali hardware, codenamed &ldquo;Panthor&rdquo; will have an officially backed Mesa driver, the already existing but almost abandoned <a href="https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26358">Panfrost/PanVK</a> driver. This means that Mali moments may cease existing sometime in the future, in a similar way to how Turnip provides a much better experience to Adreno users.</p> <h2 id="future-projects">Future projects</h2> <p>Multiprocess <a href="https://github.com/yuzu-emu/yuzu/pull/12579">GPU SMMU</a> support is almost done now, thanks to Blinkhawk. We’ll cover it in more detail next month, but you can check the pull request draft meanwhile to see the expected benefits it brings.</p> <p>And maybe the rest of the team has something more going on, yeah. But let’s save that surprise for later, it’s more fun that way (this in no way means any attempt to leak a picture of the current progress was rejected by all devs, no no).</p> <p>That’s all folks! Thank you for reading until the end, we hope to see you all again in the first progress report of 2024!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report November 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/ Mon, 18 Dec 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/ <p>Hello there, yuz-ers! November brought us many GPU fixes, followed shortly by driver fixes, significant Android/ARM changes, more applet work, new input projects, and much more!</p> <p>Hello there, yuz-ers! November brought us many GPU fixes, followed shortly by driver fixes, significant Android/ARM changes, more applet work, new input projects, and much more!</p> <h2 id="mario-role-playing-as-mario">Mario Role-playing as Mario!</h2> <p>As if <code>Super Mario Bros. Wonder</code> wasn’t enough, a cult classic is back, with improved graphics to boot! <code>Super Mario RPG</code> brings some distilled nostalgia to the old SNES-era guard (we still stand strong), so the question was at the tip of their tongues on release day: &ldquo;Does it run in yuzu?&rdquo;</p> <p>It did ― with some buts, as usual. Two things needed to be fixed to get this colourful cast into good shape: an audio fix affecting everyone and a separate fix for NVIDIA users.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rpg1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpg1_hud7965dc9ad7cfc6cee9e1b5fea028332_1504686_800x0_resize_q90_bgffffff_box_3.jpg" alt="Is she in that castle? (Super Mario RPG)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rpg2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpg2_hu5a301f1d301968c674468df4f5a95755_2858769_800x0_resize_q90_bgffffff_box_3.jpg" alt="Is she in that castle? (Super Mario RPG)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rpg3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpg3_hu29308ec89053c272b4efcdf54a677882_2369830_800x0_resize_q90_bgffffff_box_3.jpg" alt="Is she in that castle? (Super Mario RPG)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Is she in that castle? (Super Mario RPG)</p> <p>Users immediately noticed how the game’s background audio was completely muted, detracting a lot from the experience. After performing a cross-examination, <a href="https://youtu.be/5I443rHIYVk">with music and all</a>, <a href="https://github.com/liamwhite">byte[]</a> found out the cause was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12058" data-gh-pr="12058">a leftover</a> from the Opus rewrite <a href="https://github.com/Kelebek1">Maide</a> did <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/#audio-changes">back in September</a>. With this specific case fixed, the game started playing audio as it should.</p> <p>Meanwhile, <a href="https://github.com/ameerj">epicboy</a> performed a separate investigation in the shader recompiler for NVIDIA’s broken rendering.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rpg4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpg4_hu350909d6279ee84ef8d2d0041e99bacc_12913207_800x0_resize_q90_bgffffff_box_3.jpg" alt="Imagine if the Switch was capable of HDR (Super Mario RPG)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rpg5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpg5_hud0f5c6828467bf06e0753cb394b1f15e_12504931_800x0_resize_q90_bgffffff_box_3.jpg" alt="Imagine if the Switch was capable of HDR (Super Mario RPG)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Imagine if the Switch was capable of HDR (Super Mario RPG)</p> <p>For those not familiar with the shader pipeline of yuzu and other emulators:</p> <p>Games have compiled shaders built for the architecture of the console they are intended to run on – in this case, the Switch. Those shaders are useless for any other device, so the emulator has to intercept those shaders during run-time, convert them into a shader format the selected graphics API can understand (in yuzu’s case the options are SPIR-V, GLSL, and GLASM), and only then those converted shaders can be sent to the GPU driver for rendering. After multiple steps of conversion, a Switch shader finally gets turned into a, for example, Ampere shader, or Adreno, or RDNA3. (And now you know why shader stuttering is a thing.)</p> <p>NVIDIA drivers have a lot of optimizations for various code patterns in shaders. When you hit a bug in these optimizations, odd stuff can happen, regardless of settings, API, or shader backend in use. There’s no escape. In this case, it led to swapped character colours in menus because NVIDIA drivers disliked <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12066" data-gh-pr="12066">the specific pattern</a> the game’s shader used in menus ― and unlike most other driver bugs, it was broken in every single backend!</p> <p>Here’s a generic example provided by epicboy:</p> <div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-cpp" data-lang="cpp"><span style="display:flex;"><span>uint low <span style="color:#f92672">=</span> uint(bitfieldExtract(some_number, <span style="color:#ae81ff">0</span>, <span style="color:#ae81ff">16</span>)); </span></span><span style="display:flex;"><span>low <span style="color:#f92672">&lt;&lt;=</span> <span style="color:#ae81ff">16U</span>; </span></span><span style="display:flex;"><span>uint high <span style="color:#f92672">=</span> uint(bitfieldExtract(some_number, <span style="color:#ae81ff">16</span>, <span style="color:#ae81ff">16</span>)); </span></span><span style="display:flex;"><span>uint swapped <span style="color:#f92672">=</span> low <span style="color:#f92672">+</span> high; </span></span></code></pre></div><p>epicboy’s solution was to detect this specific pattern in yuzu before passing it to the driver, and replace the last line with a <a href="https://en.wikipedia.org/wiki/Bitwise_operation">bitwise OR</a>:</p> <div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-cpp" data-lang="cpp"><span style="display:flex;"><span>uint swapped <span style="color:#f92672">=</span> low <span style="color:#f92672">|</span> high; </span></span></code></pre></div><p>This makes the NVIDIA compiler happy and provides colour accurate character sprites in the game–everyone wins.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpgbug_hu4c7afb8664f3c026339efa276a7049d3_555583_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wario? (Super Mario RPG)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/rpgfix_hu2d0899a48e22d4ce5c899265d88233e4_865774_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wario? (Super Mario RPG)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Wario? (Super Mario RPG)</p> <p>With both issues out of the way, there’s only one thing left to say: Happy stomping!</p> <h2 id="project-nice">Project NiCE</h2> <p>Here it is! Time to graduate from a PC emulator compatible with Android to a &ldquo;native&rdquo; Android emulator.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12074" data-gh-pr="12074">NCE support,</a> or <code>Native Code Execution</code>, a huge effort made by <a href="https://github.com/GPUCode">GPUCode</a> and byte[], adapted <a href="https://github.com/skyline-emu/skyline">Skyline</a>’s ability to run game code natively on ARM devices, with no recompiler to slow things down.</p> <p>This sounds great on paper, but what does it mean for users? The advantage of using a JIT recompiler is ensuring compatibility regardless of the device in use ― that’s how an AMD64 computer can run 64-bit ARM games. While this method is good enough for AMD64 desktop and laptops (and one of the few possible ways to do it), it’s very slow on Android phones and tablets, not to mention very taxing, as the recompiled code is less efficient, uses a lot of resources, and requires more power to execute as a byproduct, resulting in increased heat.</p> <p>Thanks to dropping the translation overhead of a JIT, NCE increases performance proportional to how much power and thermal headroom is available on the user’s device. NCE also saves up to 128MB of memory per guest CPU core (of which the Switch has four), meaning up to 512MB of RAM is saved by dropping the JIT.</p> <p>Having a device with active cooling will still produce the best results, but with NCE, performance is higher, battery life is higher, heat output is lower, and games load faster. The FPS boost is usually around 20-100%, depending on the game and device.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./nce1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/nce1_hu635e8a871c6f669e628fe6c585a60a01_87093_800x0_resize_q90_bgffffff_box_3.jpg" alt="Results aren’t comparable between the two devices, Mali was run at 0.5x to reduce its bottleneck"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nce2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/nce2_hu58dda78180f0982e1aa24bfe25f69fcd_86166_800x0_resize_q90_bgffffff_box_3.jpg" alt="Results aren’t comparable between the two devices, Mali was run at 0.5x to reduce its bottleneck"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Results aren’t comparable between the two devices, Mali was run at 0.5x to reduce its bottleneck</p> <p>Sadly, as always, it’s not all perfect ― &ldquo;restrictions may apply.&rdquo; Not all games can take advantage of NCE. Due to limitations in the Linux kernel and the requirements to run on a very restricted memory address space, some early Switch games need to have their updates installed to be able to run with NCE. Games like <code>The Legend of Zelda: Breath of the Wild</code> and <code>ARMS</code> use a deprecated 36-bit address space in their original v1.0.0 release, and NCE requires 39-bit to work. Here the emulator automatically reverts to JIT to allow booting the game. These games get full 39-bit support only with their respective updates installed. You can confirm this when enabling the framerate counter, which will show if NCE or JIT is in use:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./jit.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/jit_hu1cc470e80dabe8be413039c7ae229e60_311706_800x0_resize_q90_bgffffff_box_3.jpg" alt="As simple as that (The Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nce.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/nce_hu51ea7ac0dfc0f8e2c9f35a0245c93713_231815_800x0_resize_q90_bgffffff_box_3.jpg" alt="As simple as that (The Legend of Zelda: Breath of the Wild)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">As simple as that (The Legend of Zelda: Breath of the Wild)</p> <p>Another limitation is 32-bit games. <code>Mario Kart 8 Deluxe</code> and <code>Captain Toad: Treasure Tracker</code>, among others, just won’t work with NCE, and the emulator will, just like with 36-bit games, automatically revert to using the <a href="https://github.com/merryhime/dynarmic">Dynarmic</a> JIT.</p> <p>While there are ways to be able to use NCE with 32-bit games, our investigation found that it would require a secondary 32-bit build target, which we have never supported, and it is no longer viable on Android API versions for Android 11 or later, which happens to be our minimum requirement.</p> <p>There are also rare cases of games refusing to work with NCE, due to Linux being less permissive than the Switch operating system. One example is <code>Paper Mario: The Origami King</code>, which needs to have NCE manually disabled to run correctly for the moment.</p> <p>These limitations apply to both Android devices and other ARM devices like Linux ARM boards or laptops.</p> <p>We enable NCE by default on the latest GitHub and Play Store builds. The option can be found in <code>Settings &gt; Advanced settings &gt; Debug &gt; CPU backend</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cpu.png" title=" Doesn’t hurt to double check"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/cpu_hua960b469b81c548e7bb09400c3257fa7_72967_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Doesn’t hurt to double check"></a> <p class="has-text-centered is-italic has-text-grey-light"> Doesn’t hurt to double check</p> </div> </div> <p>For the setting &ldquo;optimizers&rdquo; out there, disabling Fastmem disables NCE with it, so we don’t recommend disabling it unless you cannot run the game you want otherwise. If you see old pictures of games running with Fastmem disabled but still showing NCE under the framerate counter, that’s because the counter didn’t consider this scenario originally; it has since then been patched to correct this.</p> <h2 id="yet-more-changes-for-android">Yet more changes for Android</h2> <p>But why stop there? There’s more work baked into the Android builds ― here’s this month’s list:</p> <ul> <li>byte[] authored and <a href="https://github.com/t895">t895</a> uploaded the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11972" data-gh-pr="11972">FPS counter.</a> The text was changed to white, its reading is now continuously updated, and it now mentions what CPU backend is in use, JIT or NCE. The FPS counter can be enabled by dragging from the left while running a game and selecting <code>Overlay options &gt; FPS counter</code>.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12018" data-gh-pr="12018">Many improvements were made to the settings tab, thanks to t895.</a> Icons and descriptions have been added, and the order of the elements and the location of some settings was changed. <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./icons.png" title=" Pretty"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/icons_hu8f910d5585f70069cfa2c2c4a157d774_123732_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Pretty"></a> <p class="has-text-centered is-italic has-text-grey-light"> Pretty</p> </div> </div> </li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12014" data-gh-pr="12014">The Settings tab and About page</a> have been tweaked to add a landscape layout. This work by t895 improves usability for tablets, foldables, and other large form-factor devices. <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./layout1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/layout1_hu1b2d40468b27ae709a2103a3f117bb39_121174_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Alphonsokurukuchu for the tablet pics"></a> </div> <div class="column is-bottom-paddingless"> <a href="./layout2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/layout2_hu654d177c9949d1f323ce3f126b8e28d7_70802_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Alphonsokurukuchu for the tablet pics"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Thank you Alphonsokurukuchu for the tablet pics</p> </li> <li>t895 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12034" data-gh-pr="12034">added a drop shadow</a> to the FPS counter to improve readability, and allowed the device’s font style to control the text size of the FPS readout.</li> <li>When enabled, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12035" data-gh-pr="12035">t895 now blocks Picture-in-Picture</a> during startup or shutdown, improving stability.</li> <li><a href="https://github.com/FernandoS27">Blinkhawk</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12036" data-gh-pr="12036">disabled write syncing</a> on Android devices running Turnip drivers, fixing crashes in games like <code>Red Dead Redemption</code> and <code>Luigi’s Mansion 3</code>.</li> <li>By democratic decision from the users, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12043" data-gh-pr="12043">t895 has disabled Picture-in-Picture</a> by default.</li> <li>Blinkhawk re-enabled using <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12081" data-gh-pr="12081">multithreaded pipeline compilation</a> for Android, reducing stuttering when loading caches at boot and building new shaders while in-game. This was made possible thanks to the lower resource consumption under NCE.</li> <li>byte[] found another cause for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12083" data-gh-pr="12083">crashes on Mali GPUs:</a> they don’t support multi-viewport rendering. Disabling this feature greatly improves stability on Mali equipped devices. (And so the list of features Mali doesn’t support keeps growing.)</li> <li>The upper <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12091" data-gh-pr="12091">speed limit was increased to 400%,</a> as t895 found out using a high limit is more stable than disabling it at all. Happy benchmarking!</li> <li>When accessing the Search tab, t895 set the first results before filtering to be your <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12092" data-gh-pr="12092">most recently played games.</a> </li> <li>Thanks to t895, you can now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12093" data-gh-pr="12093">store save exports locally</a> by using a file picker.</li> <li>Another Mali limitation, another workaround by byte[]. This time <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12110" data-gh-pr="12110">nullDescriptor got a special slower codepath</a> so Mali devices can run <code>Super Smash Bros. Ultimate</code>. Everyone is here!</li> <li>byte[] also fixed an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12140" data-gh-pr="12140">edge case in the query cache</a> that caused crashes on Turnip drivers.</li> <li>Users reported the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12166" data-gh-pr="12166">face ABXY buttons on Redmagic controllers</a> were flipped, so <a href="https://github.com/german77">german77</a> addressed the issue.</li> <li>t895 added support in the UI for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12204" data-gh-pr="12204">multiple game folders</a> and the ability to scan subdirectories. Feel free to be as disorganised as you want now; we won’t judge. <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./folders.png" title=" We chads use a single folder"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/folders_huc443d040da8bbbd7a86a595d224849d4_37629_540x0_resize_q90_bgffffff_box_3.jpg" alt=" We chads use a single folder"></a> <p class="has-text-centered is-italic has-text-grey-light"> We chads use a single folder</p> </div> </div> </li> <li>And to close up, after fixing issues affecting Mali and Turnip, byte[] decided it was Qualcomm’s turn to get the axe. The vertex input dynamic state <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12229" data-gh-pr="12229">Vulkan extension</a> is marked as supported by most official Qualcomm drivers and devices, yet on older 600 series GPUs it’s completely broken, leading to games only displaying a black screen. Excluding this extension solves the issue, and exposes how Qualcomm only tests its drivers on very basic conformance tests and nothing else. Do the bare minimum work, let the community do the rest for you…</li> </ul> <h2 id="graphics-changes">Graphics changes</h2> <p>The <code>Force maximum clocks</code> setting seems to cause a lot of confusion among users, which sadly leads to it being enabled in cases where it isn’t intended to be used, particularly power/thermally restricted devices.</p> <p>The setting was originally intended to solve an AMD problem: their RDNA based cards suffer from severe downclocking, or what your writer calls &ldquo;chronic downclocking syndrome&rdquo;, when emulating many games. The GPU load the emulator produces is often so low, its workload fails to be detected as a game, causing the card to keep its clock speeds set to extremely low values. As you might expect, this leads to very low performance.</p> <p>Enter <code>Force maximum clocks</code>, which on desktop yuzu simply generates a dummy compute load to run on the GPU, triggering the card to clock up by force. While this solves the issue and puts the performance of AMD cards on par with NVIDIA (and even helps NVIDIA cards under some scenarios), running a compute load like this is <em>not</em> a viable option for integrated GPUs. Mobile devices have limited cooling and a power budget: there’s a limited amount of power the CPU and the GPU can share, and enabling the setting will shift that budget’s priority to the GPU, while the user wants to run an emulated game, which is almost always severely CPU bottlenecked. The extra power demanded by the compute load leads to increased heat, which will cause lower performance when cooling is not up to par.</p> <p>So, what we mean by all this is, don’t use <code>Force maximum clocks</code> on handhelds <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12153" data-gh-pr="12153">like the Steam Deck,</a> integrated-GPU-only portable computers with limited cooling capabilities, or integrated GPU desktop PCs. The setting will result in degraded performance and extra bothersome fan noise, and it is only intended for dedicated GPUs with proper cooling. Not every guide online knows what they are talking about.</p> <p>To help combat this, byte[] expanded the blocklist of this setting to include the recently released Steam Deck OLED. Since there&rsquo;s no hardware variance in the Steam Deck, it’s a safe case to block.</p> <p>After Linux NVIDIA users running the Wayland display server reported crashes when using the latest drivers, newcomer <a href="https://github.com/lucasreis1">lucasreis1</a> found the cause: The new driver seems to need <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11981" data-gh-pr="11981">allocating window resources</a> before asking or system info. Adding the correct line in the correct place <a href="https://youtu.be/tXGyEq3OJSo?t=41">makes all the difference in the world</a>. Wayland NVIDIA users can now load games crash-free. Thanks!</p> <p>byte[] and Maide have been working on performance improvements for video decoding, aiming to not rely exclusively on FFmpeg for this task. The <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12045" data-gh-pr="12045">initial changes</a> are up, but more work is needed until the results reach the end user.</p> <p>Blinkhawk managed to catch and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12072" data-gh-pr="12072">fix several regressions</a> affecting <code>Pokémon Scarlet/Violet</code> introduced by the new Query Cache.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./scarlet.png" title=" Playable again (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/scarlet_hu882c7789eed555353e985877bbea9498_3040827_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Playable again (Pokémon Scarlet)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Playable again (Pokémon Scarlet)</p> </div> </div> <p>In a bit of sad news, byte[] had to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12173" data-gh-pr="12173">disable</a> the support for the depth bias Vulkan extension which was intended to solve the D24 issues affecting AMD cards on Linux (the Windows driver doesn’t support it yet, and uses a different workaround). RADV users (the Linux Mesa Vulkan driver for AMD GPUs) noticed issues with certain stages in <code>Super Smash Bros. Ultimate</code>. Investigating the cause reveals that, even with the use of the extension, you can only fix some games and break others in the process. While we investigate alternatives for this situation, the old workaround is back in place, allowing players to fight in the Nintendo 64 Zelda stage without going blind from the glare.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/smashbug_hufabf6567733fcc97f18a22eb8589262d_2055974_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Back to the drawing board (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/smashfix_hu156ee7e3c60f68e91081c5b826445d65_3267927_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Back to the drawing board (Super Smash Bros. Ultimate)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Back to the drawing board (Super Smash Bros. Ultimate)</p> <p>Never forgetting about good old OpenGL, epicboy has a list of changes for it this month too.</p> <p>First of all, he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12056" data-gh-pr="12056">implemented asynchronous downloads,</a> a feature that was previously only available on Vulkan, leading to an 11% performance boost when using the old API.</p> <p>Next, epicboy fixed the rendering issues affecting <code>Xenoblade Chronicles: Definitive Edition</code> and <code>Xenoblade Chronicles 3</code> when using the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12068" data-gh-pr="12068">GLASM shader backend</a> ― these two games heavily rely on transform feedback to render. That Monado can look good even if you’re still rocking a Kepler GPU.</p> <p>Continuing the work on improving the performance of OpenGL, epicboy implemented the use of the <code>glBindVertexBuffers</code> and <code>glBindBuffersRange</code> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12094" data-gh-pr="12094">commands,</a> making the use of the previous <code>GL_NV_vertex_buffer_unified_memory</code> extension obsolete. This reduces the API call overhead that is so notorious in OpenGL, reducing CPU use as a result.</p> <p>And finally, to close the section, epicboy helped to mitigate a bothersome disadvantage OpenGL has, shader build times ― but only when the user is running NVIDIA hardware. By lowering the size of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12196" data-gh-pr="12196">the constant buffer</a> in the declaration to the size actually used by the shader, shader compilation performance is improved! It’s not as good as Vulkan, but it’s certainly a VERY welcome addition for those cases where OpenGL is the only option.</p> <h2 id="applets-input-and-other-services">Applets, input, and other services</h2> <p>Back this month for more is <a href="https://github.com/Macj0rdan">Macj0rdan</a> along with german77, partners in crime working in implementing the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12011" data-gh-pr="12011">controller menu applet.</a> Functionality is limited at the moment, but you can now see your connected controllers just as intended. As usual, a firmware dump is required to launch any applets.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./applet1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/applet1_hue41739991dcbf60e1992f1c824dbf939_113863_800x0_resize_q90_bgffffff_box_3.jpg" alt="While this is native fun, don’t expect it to be very usable for the time being"></a> </div> <div class="column is-bottom-paddingless"> <a href="./applet2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/applet2_hu4fed415505308e65f853a5cd6d052aac_138936_800x0_resize_q90_bgffffff_box_3.jpg" alt="While this is native fun, don’t expect it to be very usable for the time being"></a> </div> <div class="column is-bottom-paddingless"> <a href="./applet3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/applet3_hu32eaabeb5c5eff9e30d6deee02430a7d_130967_800x0_resize_q90_bgffffff_box_3.jpg" alt="While this is native fun, don’t expect it to be very usable for the time being"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">While this is native fun, don’t expect it to be very usable for the time being</p> <p>Working on his own, german77 managed to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11969" data-gh-pr="11969">fix the profile pictures</a> for all currently available system applets, like for example, during profile selection. The Switch wants exactly 256x256 images, so included as part of the package is a resizer to just give the applet what it wants.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./profiles.png" title=" They’re multiplying!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/profiles_hu45702b83289ebd506a4767ecd7282163_217657_995x0_resize_q90_bgffffff_box_3.jpg" alt=" They’re multiplying!"></a> <p class="has-text-centered is-italic has-text-grey-light"> They’re multiplying!</p> </div> </div> <p>Continuing his <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/#input-improvements">previous work</a> on infrared shenanigans (which thankfully don’t involve explosives or self-guidance), german77 finished <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11980" data-gh-pr="11980">implementing the</a> <code>moment image processor</code>. This means games like <code>Trombone Champ</code>and <code>WarioWare: Put a lid on it</code> are now playable with Joy-Cons. Feel free to crack that volume dial and torture your neighbours to your heart’s content. Here’s an example by german77 himself, enjoy:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./trombone.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light">Guitar Hero got nothing on this (Trombone Champ)</p> </div> </div> <p>Switching a bit to input, german77 fixed an omission in the input code regarding the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12007" data-gh-pr="12007">single Joy-Con SL and SR</a> buttons, allowing one of the minigames of <code>WarioWare: Plug your leaks</code> to be playable. Oops.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./leak.png" title="Got teflon tape? (WarioWare: Plug your leaks)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/leak_hu5ba23002742174bb7740c7cc9b01f1a3_396220_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Got teflon tape? (WarioWare: Plug your leaks)"></a> <p class="has-text-centered is-italic has-text-grey-light">Got teflon tape? (WarioWare: Plug your leaks)</p> </div> </div> <p>This breaks backwards compatibility with saved input profiles of single right Joy-Cons ― an unlikely configuration for most games. If you are using this configuration, you might have to rebind your controller, but other profiles are unaffected.</p> <p>Thanks to the work of newcomer <a href="https://github.com/dima-xd">dima-xd</a>, the native <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11929" data-gh-pr="11929">software keyboard applet</a> can be run. Sadly, it’s not possible to use it in games at this moment, as it can&rsquo;t be launched on demand yet ― multiprocess support is needed for this. As an apology, here’s how it looks:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./osk.png" title=" Tactile switches? Touch Switch!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/osk_hu0ab42e1f634c47082d143ec27e92df9e_80470_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Tactile switches? Touch Switch!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Tactile switches? Touch Switch!</p> </div> </div> <p>Since yuzu can now work with Mii data inside Amiibos, the code will also automatically <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12183" data-gh-pr="12183">validate their integrity.</a> Thanks to german77’s work, the emulator can now detect corrupted Amiibos and automatically load a backup. This avoids crashes in games sensitive to Amiibo integrity, like <code>Super Smash Bros. Ultimate</code>.</p> <p>Macj0rdan, working solo this time, has a separate fix for us. The controller applet started crashing after the release of firmware 17.0.0. New firmware, new functions to implement ― in this case, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12201" data-gh-pr="12201">implementing</a> <code>SetTouchscreenDimensions</code> solved the problem.</p> <p>One of the calls <code>SUPER BOMBERMAN R 2</code> makes checks for blocked users. Since the emulator doesn’t yet store that information, nor has any use for it anyway, it’s <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12107" data-gh-pr="12107">safe to stub,</a> which is exactly what newcomer <a href="https://github.com/daisymlleung">daisymlleung</a> did. Thank you!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bomber.png" title="The game only boots for now, it doesn’t reach in-game yet (SUPER BOMBERMAN R 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/bomber_huba37e82de10698538d03fdb416d00767_3379_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The game only boots for now, it doesn’t reach in-game yet (SUPER BOMBERMAN R 2)"></a> <p class="has-text-centered is-italic has-text-grey-light">The game only boots for now, it doesn’t reach in-game yet (SUPER BOMBERMAN R 2)</p> </div> </div> <p>To close out this section, <a href="https://github.com/lat9nq">toastUnlimited</a> had to deal with Qt shenanigans. Qt’s text parsing didn’t like how yuzu&rsquo;s frontend strings were stored, causing it to miss many UI translations. A bit of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11984" data-gh-pr="11984">restructuring</a> by the Unlimited Toast, and we’re back in business.</p> <h2 id="miscellaneous-changes">Miscellaneous changes</h2> <p>To help users check the status of their firmware installation, and since the firmware version makes a difference for the system applets, german77 added a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12156" data-gh-pr="12156">firmware version indicator</a> to the status bar of the user interface. Gone is the confusion about &ldquo;when was the last time I updated this?&rdquo;</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fw.png" title="One day there will be an easier way to install firmware"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2023/fw_hub80a2de9a6a3c8794164c3ac8effa7a3_4540_852x0_resize_q90_bgffffff_box_3.jpg" alt="One day there will be an easier way to install firmware"></a> <p class="has-text-centered is-italic has-text-grey-light">One day there will be an easier way to install firmware</p> </div> </div> <p>Mouse emulation, along with keyboard emulation, are options for users within yuzu for the few games that support it. These are available in <code>Emulation &gt; Configure… &gt; Settings &gt; Controls &gt; Advanced</code>, and report to games that a USB keyboard and/or mouse is plugged to the console.</p> <p>To help mouse players ― and we don’t mean &ldquo;use mouse as a stick for aiming&rdquo;, we mean emulating an attached USB mouse ― german77 made sure the actual native cursor of your OS <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12160" data-gh-pr="12160">doesn’t leave the yuzu window.</a> If you hate clicking your own game out of focus, you will like this change.</p> <p>While continuing his work on improving yuzu’s file system emulation, byte[] solved a bug that caused <code>MONSTER HUNTER GENERATIONS ULTIMATE</code> to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11936" data-gh-pr="11936">fail to boot</a> when RomFS mods for the game were installed.</p> <p>But that was only an appetiser; here’s the main dish. byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12208" data-gh-pr="12208">improved the performance</a> of parsing and building RomFS mods, lowering the patch time of <code>The Legend of Zelda: Tears of the Kingdom</code> with mods applied from 2.8 seconds to 0.3 seconds on a high performance CPU (a Ryzen 9 5950X in this case). This was very noticeable in testing.</p> <p>Modders out there, fill up that list ― you won’t waste time now waiting for games to load.</p> <p>Exactly the same fix needed for <code>Super Mario RPG</code>, but in a different spot, allows <code>Star Ocean: The Second Story R</code> to boot and play. What did the trick? Allowing a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11952" data-gh-pr="11952">stereo count</a> of zero or higher and fixing a typo. Coding shenanigans.</p> <p>And to close out this section, what better way to end than enumerating some of the battles byte[] won for improving shutdown stability!</p> <p>Audio gets the first one. When enough <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12019" data-gh-pr="12019">stream data</a> is still waiting in the output queue, the audio renderer will wait until it has space to add more data. But during shutdown, more space might never be made available, which would block the audio renderer forever and hang. Fixing this blockade fixes shutdown operations on Android.</p> <p>Next one is quite a bit more involved, as it involves the procedure needed to <del>kill</del> terminate a process, James Bond style. This procedure consists of two steps for each thread in the terminated process:</p> <ul> <li>The thread is marked for termination and an interrupt is sent to all cores with that thread&rsquo;s affinity if it is runnable.</li> <li>The kernel then waits for the thread to actually terminate.</li> </ul> <p>Runnable threads marked for termination are not removed from the scheduling priority queue. This means they can get scheduled during termination, even if the core already cleared the interrupt when a previous thread was terminated. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12025" data-gh-pr="12025">Checking for termination</a> just before running the thread again, as the Switch does, fixed a very common shutdown deadlock on Android.</p> <p>And lastly, the timing event queue was causing issues. On shutdown, the system calls to clear pending events, even while the timing thread may still be removing items from the event queue. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/12028" data-gh-pr="12028">Locking access</a> to the event queue solves the final shutdown crash of this month.</p> <h2 id="hardware-section">Hardware section</h2> <h3 id="amd-mixing-drivers">AMD, mixing drivers</h3> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/#amd-giving-a-last-hurrah-to-polaris-and-vega">Last month</a>, we reported that AMD is discontinuing driver support for Polaris and Vega products, and speculated how it would affect yuzu.</p> <p>What we didn’t consider is what happens to mixed configurations, for example running a Vega iGPU and an RDNA2 dGPU. This kind of configuration is quite common, as AMD is still selling new devices with integrated Vega GPUs, and laptop vendors can sell configurations with dedicated RDNA2 or RDNA3 products.</p> <p>Unlike Intel, who just decided to say &ldquo;good luck and goodbye&rdquo; to their Gen 9/9.5/11 graphics userbase with no warning, AMD implemented a system where you can still run drivers for mixed configurations. Since on an all-AMD laptop you can’t use different vendor drivers for the two GPUs, this was basically mandatory.</p> <p>What AMD did is provide two different drivers, one for RDNA based hardware, and another for Vega and Polaris. If you have a mixed device, you can install the driver for RDNA based hardware first, and then on top install the driver for Vega and Polaris. This allows you to access all software features of the driver, and allows you to have both GPUs operating with no issue.</p> <p>But there’s a price to pay: the Vulkan driver in the Vega and Polaris driver is <em>older</em> than the one in the RDNA-based hardware driver, and all AMD GPUs running this mixed configuration will run a single Vulkan driver. This results in a setback in features and fixes for the RDNA-based GPU just to keep compatibility.</p> <p>If you experience issues in yuzu when running this configuration, you now know the reason. Sadly, the only solution is to run Linux, which has a single unified and up-to-date Vulkan driver: RADV.</p> <h3 id="intel-fixing-drivers-wip">Intel, fixing drivers (WIP)</h3> <p>Intel confirmed that the geometry shader crash affecting multiple games has been fixed internally, and it’s just a matter of time until a driver comes out with the fix implemented. The currently latest release at the time of writing, 101.5122 (first release driver for gen 2 Iris Xe products), doesn’t include the fix yet.</p> <p>We hope when we mention this in the next progress report, the issue will be fixed.</p> <h2 id="future-projects">Future projects</h2> <p>We’re past the middle of December and we already know the next report will be juicy, just from changes already merged alone. Some things to look forward to include memory savings, improved load times, and higher performance. Blinkhawk is up to something and your writer should really stop spoiling it. Maybe some Christmas gift? Only Emperor Nero knows.</p> <p>That’s all folks! This <a href="https://www.youtube.com/watch?v=CjUVTEExfBg">Folk Blues</a> is over, see you next month, space cowboy.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report October 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/ Thu, 16 Nov 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/ <p>Hello yuz-ers! This past month, we got a plethora of GPU fixes, support for new applets, a lot of work poured into the Android builds, some interesting news of the future, and more. Let’s get to it!</p> <p>Hello yuz-ers! This past month, we got a plethora of GPU fixes, support for new applets, a lot of work poured into the Android builds, some interesting news of the future, and more. Let’s get to it!</p> <h2 id="wowie-zowie">Wowie Zowie!</h2> <p>A new Mario game! And it’s an excellent one at that. <code>Super Mario Bros. Wonder</code> joins the fray of side-scrolling Mario games and refines the genre&rsquo;s gameplay with its new and <em>wonderful</em> levels.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wonder1.png" title=" Such a pretty game (Super Mario Bros. Wonder)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/wonder1_hu980adc554ff5c9e1c33b52c71d63f429_1591694_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Such a pretty game (Super Mario Bros. Wonder)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Such a pretty game (Super Mario Bros. Wonder)</p> </div> </div> <p>The game didn’t boot at release due to incorrect used memory reporting in the kernel. Thankfully, <a href="https://github.com/liamwhite">byte[]</a> quickly found the culprit. It was a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11825" data-gh-pr="11825">single-line change!</a> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wonder2.png" title=" Hope your platforming skills are up to par (Super Mario Bros. Wonder)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/wonder2_hub50d25e9577d2e2a29b17031e3cf1beb_950859_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Hope your platforming skills are up to par (Super Mario Bros. Wonder)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hope your platforming skills are up to par (Super Mario Bros. Wonder)</p> </div> </div> <p>However, this wasn’t enough to get the game in a playable state. Depending on where you are in the game, <code>Super Mario Bros. Wonder</code> internally switches between double and triple buffered VSync presentation modes. This causes the number of images it has available for presentation to frequently change.</p> <p>yuzu wasn’t ready for this due to a misunderstanding of how nvnflinger works. On Android, SurfaceFlinger (the OG Flinger) can free buffers that are beyond the maximum count a program has allocated, but nvnflinger (the Switch&rsquo;s fork) is never supposed to free any buffers unless the program requests it. Maide made a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11827" data-gh-pr="11827">few presentation code changes</a> to support this behaviour, and players are now set to grab those fun Wonder Flowers!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./wonder3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/wonder3_hu2eba16d64da29fc5f0d14810c5a59a24_1557306_800x0_resize_q90_bgffffff_box_3.jpg" alt="Classic Mario (Super Mario Bros. Wonder)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./wonder4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/wonder4_hu0ac37ce5d244ba1e9fd592f23aa8247b_787222_800x0_resize_q90_bgffffff_box_3.jpg" alt="Classic Mario (Super Mario Bros. Wonder)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Classic Mario (Super Mario Bros. Wonder)</p> <p>I bet you didn’t expect to see the sole input change of the month here ― yet here we are. <code>Super Mario Bros. Wonder</code> <em>loves</em> vibration, to a point of saturating the old implementation when using HD Rumble on Nintendo controllers (Joy-Cons, Pro Controllers). This is because waiting for the controller to reply takes time, more than the game would have the patience for, leading to noticeable and bothersome vibration stuttering. That’s right, ASTC, you’re not the only one in town causing stutters. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11852" data-gh-pr="11852">making vibration calls asynchronous,</a> vibration is, while not entirely solved, now <em>much</em> more pleasant.</p> <h2 id="the-gpu-changes">The GPU changes</h2> <p>Undefined behaviour: the formal way to say “here be dragons”. It’s a good practice to avoid dragons ― I mean, undefined behaviour ― in your code, especially when dealing with a complex graphics API like Vulkan.</p> <p>Remember our explanation of <code>depth stencils</code> <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/#more-gpu-changes">back in August</a>? You may wish to reread that, as it provides useful context to what we will talk about next.</p> <p>When a game is using a depth buffer, it is usually drawing into a busy 3D scene while taking advantage of a hardware-accelerated process called depth testing.</p> <p>During depth testing, the GPU hardware determines if a pixel is visible or hidden (occluded) by another pixel. This is decided by their depth values. The depth buffer tracks how far away each stored pixel is from the camera. If a rendered pixel is further away than what has already been drawn on the scene, then the pixel is discarded; if it is closer, then it is kept and the colour buffers are updated. Typically, the depth buffer is also updated and written to, in this case, to store the depth of the new, closer object.</p> <p>It is possible for a game to use depth testing alone, and turn the actual writes to the depth buffer off for specific elements, and many games do this when rendering partially transparent objects. However, the opposite is not allowed by graphics APIs like Vulkan ― hardware designs require depth testing to be enabled in order update the depth buffer. yuzu’s masked clear path for depth/stencil buffers has a shader which updates the depth buffer, and so enables depth writes, but forgot to also enable depth tests. Most of the time, this worked by coincidence, as the game was enabling depth tests and yuzu was not clearing this state. However, not all games enabled them, and without depth tests, games like <code>Super Mario 64</code>, part of <code>Super Mario 3D All-Stars</code>, can’t properly render the face of a certain character (I <em>think</em> his name is in the title of the game.)</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/depthbug_hu0c0a859a0230a314797b2ceb67fcf7b7_967018_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wonder who he is (Super Mario 64)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/depthfix_hu76ef8519ffe23cc9baed7ea24ee5ba18_723120_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wonder who he is (Super Mario 64)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Wonder who he is (Super Mario 64)</p> <p>Thanks to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11630" data-gh-pr="11630">the work done</a> by <a href="https://github.com/Kelebek1">Maide</a>, Mr. Mario Mario renders correctly now.</p> <p>Not stopping there, Maide’s dragon-hunting continued for another pull request. One advantage of using the standard Vulkan Memory Allocator (VMA for short) is how it can help sanitise code.</p> <p>VMA will raise asserts if things are wrong somewhere. In this case, we were accidentally marking a device-local buffer we intend to use exclusively in VRAM as CPU mapped. VMA is very clear here: device local buffers should not be allocated as mapped because they are outright <em>not</em> intended for CPU access. Making it happy <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11734" data-gh-pr="11734">has soothed another dragon.</a> </p> <p>Thanks to users&rsquo; reports, <a href="https://github.com/FernandoS27">Blinkhawk</a> managed to figure out why the new query cache was leaking memory in many games, including <code>The Legend of Zelda: Tears of the Kingdom</code>. After <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11646" data-gh-pr="11646">some slight tweaking,</a> RAM consumption is put in its place.</p> <p>Starting a campaign to combat holes in yuzu&rsquo;s format support, <a href="https://github.com/Squall-Leonhart">Squall-Leonhart</a> has been working on implementing some of the more obscure format conversions, like <code>D32_SFLOAT</code>. For this particular depth format on Vulkan, it can <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11677" data-gh-pr="11677">now be converted</a> to <code>ABGR8_UNORM</code> when the game needs this behaviour. Combined with <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11716" data-gh-pr="11716">adding support for</a> the <code>Z32</code>, <code>FLOAT</code>, <code>UINT</code>, <code>UINT</code>, <code>UINT</code>, <code>LINEAR</code> variants in the internal format table, this work solves rendering issues in games like <code>Disney Speedstorm</code> and <code>Titan Glory</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/disneybug_hu3bb363884c1ac53d0c859b122b054f8e_1080239_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Look, the most powerful mouse in the world (Disney Speedstorm)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/disneyfix_hu12311cfd5a6b94d636b041fe33ab2659_1803754_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Look, the most powerful mouse in the world (Disney Speedstorm)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Look, the most powerful mouse in the world (Disney Speedstorm)</p> <p>Some games also make aliases of images in the D32 depth format. Since a similar limitation with format conversion was present here too, <code>ARGB8_SRGB</code> and <code>BGRA8_UNORM</code>/<code>BGRA8_SRGB</code> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11795" data-gh-pr="11795">can now be converted to</a> <code>D32_SFLOAT</code> to provide proper compatibility.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gothic.png" title=" Aged graphics have this feel of nostalgia (Gothic)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/gothic_hu951a8e7f673e10ce1064cd42733ab1c5_1321520_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Aged graphics have this feel of nostalgia (Gothic)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Aged graphics have this feel of nostalgia (Gothic)</p> </div> </div> <p>Continuing with this streak, Maide <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11688" data-gh-pr="11688">implemented</a> the <code>X8_D24</code> depth format, allowing <code>A Sound Plan</code> to start rendering. However, more work is needed to make this game properly playable.</p> <p>Robustness is a feature Vulkan provides that lets developers handle invalid memory accesses in a cleanly defined way. This can help prevent the application from crashing or <del>summoning dragons</del> invoking undefined behaviour when some part of the code tries to access memory out of bounds.</p> <p>For some reason, either Maxwell and Pascal NVIDIA GPUs have broken robustness support on uniform buffers, or yuzu’s codebase makes a wrong assumption somewhere (most likely the latter). As a result, those two NVIDIA GPU generations (GTX 750/GTX 900/GTX 1000 series) suffer from oversized graphics on <code>Crash Team Racing Nitro-Fueled</code>, due to the game accessing memory out of bounds in the shader. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11789" data-gh-pr="11789">Manually clamping out-of-bounds buffer reads to 0</a> on the affected GPU architectures solves the issues. We are also now investigating what causes this problem in the first place. Maide gets to play detective yet again, dear Watson.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/ctrbug_hu50eb2b509adb494070afc449c1d9e315_1177891_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This GTX 1050 needed a diet (Crash Team Racing Nitro-Fueled)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/ctrfix_hu909be9e5c1cd1e6b34bc4798d6d9e9b4_945308_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This GTX 1050 needed a diet (Crash Team Racing Nitro-Fueled)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This GTX 1050 needed a diet (Crash Team Racing Nitro-Fueled)</p> <p>Maide also fixed a hidden issue with the resolution scaler. Images were being <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11744" data-gh-pr="11744">marked as rescaled,</a> even if the resolution scaler was not in use (running at 1x). This led to a slight additional overhead, and rarely, some assertion failures. While no game bug was known to be caused by this, it’s good to have preemptive fixes for once instead of just reactionary ones.</p> <p>In the meantime, Maide has also been removing image alias bits for all image attachments in an effort to allow the drivers to use more memory optimizations. This pull request also includes <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11747" data-gh-pr="11747">some other minor fixes</a> with it.</p> <p>By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11775" data-gh-pr="11775">implementing</a> the first and subsequent draw commands for vertex arrays, <code>Super Meat Boy</code> finally renders correctly! No more black screens!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smb.png" title=" Well done (Super Meat Boy)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/smb_hu91e9935c0e86ad43b13518d548ad461d_1142993_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Well done (Super Meat Boy)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Well done (Super Meat Boy)</p> </div> </div> <p>And now, one for the Linux gang. <a href="https://github.com/v1993">v1993</a> tested and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11786" data-gh-pr="11786">re-enabled CUDA video decoding</a> on Linux, allowing better video decoding performance for NVIDIA users (running the proprietary driver, of course). We previously disabled CUDA by default because it can fail on systems running both a dedicated NVIDIA GPU and a dedicated AMD GPU (iGPUs are fine), a decently rare configuration that only a few people, like your writer, actually ever use.</p> <p>For those few users running mixed hardware vendors on your systems, please manually select “CPU Video Decoding” if you’re affected by video decoding issues now. This was the previous default behaviour.</p> <p>We received user reports of crashes occurring when grabbing a Grand Star in <code>Super Mario Galaxy</code>, as part of <code>Super Mario 3D All-Stars</code>. byte[] found that the problem is in how the Vulkan scheduler incorrectly flushes data. The solution? <a href="https://www.youtube.com/watch?v=SNgNBsCI4EA">Use a lock</a>. And if that doesn’t work, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11806" data-gh-pr="11806">use more locks.</a> Happy star hunting!</p> <p>To improve OpenGL support even further, <a href="https://github.com/ameerj">Epicboy</a> returns. First, he found that the <code>shfl_in_bounds</code> variable, which is used to track data used in compute shaders, could result in undefined behaviour when threads were inactive and return invalid results. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11847" data-gh-pr="11847">The solution</a> was to move the <code>shfl_in_bounds</code> check after the <code>readInvocationARB</code> function, which requires all threads to be active, to avoid <del>dragons</del> undefined behaviour. This fixed some graphical corruption issues in unit tests, which should lead to fixes in real games too.</p> <p>Next, a simple gift from epicboy: <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11904" data-gh-pr="11904">force enabling</a> <code>Threaded optimization</code>, an NVIDIA-specific OpenGL optimization that enables the use of a new separate CPU thread for graphics rendering. This is a solid performance boost for those running OpenGL with NVIDIA hardware. And for those asking, yes, Vulkan allows the use of a separate thread for rendering too ― but we do it on an API level, instead of a driver setting, so all GPUs can benefit.</p> <p>Maide found a problem occurring with compute shaders when they were triggering invalidations in the buffer cache. yuzu has a lot of code to track the sizes of buffers used by the games. Consider a game using two buffers: the first, with an address range from 1 to 2, and another with a range of 3 to 5. They don&rsquo;t overlap, so there is no issue. Then, after the game runs for a while, a buffer requiring a range of 1 to 5 is used. The previous two buffers would be considered to overlap it and will be deleted. Then, the old buffer data from the two overlaps gets moved to the new third buffer. While this was already working for graphics-related buffers, it didn’t correctly consider compute buffers.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11859" data-gh-pr="11859">Adding the missing loop</a> to fix this behaviour, problems ranging from minimal graphical issues to completely broken game logic are potentially solved. You know what they say: with compute, the sky&rsquo;s the limit. Just ask AI developers.</p> <p>Another optimization Maide implemented affects how buffers are handled after they are successfully deleted. The previous method would unnecessarily create several copies, wasting resources. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11683" data-gh-pr="11683">removing one synchronisation step,</a> only the exact amount of needed copies are used.</p> <p>Now let&rsquo;s discuss a long-standing issue: some 2D games were flipped on AMD, Intel, and Android GPUs. Games can use different APIs to run on the Switch. Nintendo allows the use of Vulkan, OpenGL, and their proprietary API, NVN. This poses a problem for emulation on Vulkan, since <a href="https://vulkan.gpuinfo.org/listdevicescoverage.php?extension=VK_NV_viewport_swizzle&amp;platform=all">only NVIDIA GPUs</a> support the viewport swizzle extension (which allows for transforming viewports).</p> <p>To allow other GPU vendors to render properly in most cases, a fallback implementation was made to handle the case of vertical flips, for use by OpenGL games. A tiny error in its implementation made it unable to correctly track invalidations of the viewport flip state, resulting in garbled graphics in several games. byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11893" data-gh-pr="11893">solved</a> that issue with a one-line change, making games like <code>Stardew Valley</code>, and <code>Streets of Rage 4</code>, finally render properly on non-NVIDIA hardware. No more mirrors needed!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sv.png" title=" THE cozy farming game (Stardew Valley)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/sv_hu7523f5a5e46db621596c28ada1a8ba6f_783219_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" THE cozy farming game (Stardew Valley)"></a> <p class="has-text-centered is-italic has-text-grey-light"> THE cozy farming game (Stardew Valley)</p> </div> </div> <p>While investigating this, a similar but different issue came to light. Many OpenGL games (that is, games using OpenGL to render, not yuzu rendering on OpenGL) ask for a 1920x1080 framebuffer, regardless of whether the game is running in handheld or docked mode. The game then simply moves and resizes the region it’s rendering to inside that 1920x1080 buffer, like moving a small box inside a bigger box, if you will. In the final step, the image is flipped and sent to the bottom of that 1080p render target. yuzu was incorrectly rendering only the top of the render target due to how it used to calculate that flip in the final pass.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11894" data-gh-pr="11894">Adjusting</a> this behaviour made <code>Tiny Thor</code> render correctly in handheld mode.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tt.png" title=" To Valhalla (Tiny Thor)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/tt_hu2b53a1cd6dd4ef8b15e95d5923319967_750150_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" To Valhalla (Tiny Thor)"></a> <p class="has-text-centered is-italic has-text-grey-light"> To Valhalla (Tiny Thor)</p> </div> </div> <p>And to close the graphics section, by following this chain of events, the previous pull request helped spot a bug in our Vulkan presentation that led to <code>Arcaea</code> being incorrectly cropped in handheld mode. 95 lines of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11896" data-gh-pr="11896">cropping-behaviour code changes</a> later, and byte[] solved the issue.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./arcaea.png" title=" Good art style (Arcaea)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/arcaea_hu7b691fcef71ea8b7d5c5641425008037_1145047_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Good art style (Arcaea)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Good art style (Arcaea)</p> </div> </div> <h2 id="android-changes">Android changes</h2> <p>This month the Android build got not only significant UI changes to improve quality of life, but device compatibility was greatly improved for Adreno users. Here’s the full list!</p> <ul> <li>A new <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11649" data-gh-pr="11649">GPU driver manager</a> was developed by <a href="https://github.com/t895">t895</a>, allowing the listing of multiple drivers, useful for quickly switching between proprietary Qualcomm or Mesa Turnip releases, or several versions of each. Due to the beta status of Turnip drivers and the immature code of Qualcomm drivers, the latest release is not always the best.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gpu.png" title=" For all your driver-switching needs!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/gpu_hua4dd432e794ccf666de8c0d679c30ff6_40908_356x0_resize_q90_bgffffff_box_3.jpg" alt=" For all your driver-switching needs!"></a> <p class="has-text-centered is-italic has-text-grey-light"> For all your driver-switching needs!</p> </div> </div> <ul> <li>byte[] solved a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11656" data-gh-pr="11656">crash related to surface recreation,</a> which could be triggered by simply rotating the device.</li> <li>byte[] solved an issue affecting some Android devices that ship an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11876" data-gh-pr="11876">outdated Vulkan 1.1 loader</a> instead of the current latest 1.3, causing the device to report older features than the driver in use actually supports. This resulted in specific Adreno 600 and 700 devices crashing at boot when using any Mesa Turnip driver version. Forcing the correct Vulkan 1.3 features the driver supports solves the issue. We’ll expand on this at the end of the article.</li> <li>t895 implemented a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11909" data-gh-pr="11909">home settings menu grid</a> for devices with bigger screens and/or higher DPIs. This should please our tablet and foldable users. Enjoy!</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wide.png" title=" Landscape lovers rejoice"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/wide_hu26880f346c915470ab53881d53d5c956_71512_772x0_resize_q90_bgffffff_box_3.jpg" alt=" Landscape lovers rejoice"></a> <p class="has-text-centered is-italic has-text-grey-light"> Landscape lovers rejoice</p> </div> </div> <ul> <li>byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11910" data-gh-pr="11910">fixed another case</a> where yuzu would fail to recreate the surface on screen rotations.</li> <li>t895 moved the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11915" data-gh-pr="11915">game list loading process to a separate thread</a> to reduce stuttering when opening yuzu. The process still takes a similar amount of time, but the perceived smoothness is very welcome.</li> <li>t895 solved an issue that caused the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11916" data-gh-pr="11916">touch buttons overlay to get stuck</a> while drawing the in-game menu from the left side.</li> <li>While waiting for a controller settings menu, t895 fixed a bug that caused <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11925" data-gh-pr="11925">all controller input to move to player 2</a> on some devices, blocking users from playing most games. Devices with integrated controllers should have a much better experience now.</li> <li>And finally, following the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/#of-miis-and-applets">recent changes</a> in the desktop version, t895 added a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11931" data-gh-pr="11931">menu to access the currently supported applets,</a> Album and Mii editor, along with the Cabinet applet to manage amiibo data. Wii think you will have fun!</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./cabinet1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/cabinet1_hu6c205d51bb64aafdf9db14b82f9c8d77_34508_800x0_resize_q90_bgffffff_box_3.jpg" alt="We hope to expand this selection in the future"></a> </div> <div class="column is-bottom-paddingless"> <a href="./cabinet2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/cabinet2_huf7351c4bd5851a32809f1a30df097184_37863_800x0_resize_q90_bgffffff_box_3.jpg" alt="We hope to expand this selection in the future"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">We hope to expand this selection in the future</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mii.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/mii_hu7941743f3578c06234d07f441155d2a4_301240_800x0_resize_q90_bgffffff_box_3.jpg" alt="Wii want to play"></a> </div> <div class="column is-bottom-paddingless"> <a href="./album.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/album_hu274f6a753c1bfcc81149a9d3f2d0ef7a_332512_800x0_resize_q90_bgffffff_box_3.jpg" alt="Wii want to play"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Wii want to play</p> <p>The settings menu was also reorganised:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./settings.png" title=" Hope it’s more convenient now"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/settings_hu330d36628c0bf45df70c0c778fc8a487_73745_356x0_resize_q90_bgffffff_box_3.jpg" alt=" Hope it’s more convenient now"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hope it’s more convenient now</p> </div> </div> <h2 id="ui-and-applet-changes">UI and Applet changes</h2> <p>After a rocky start, thanks to the early work of <a href="https://github.com/roenyroeny">roenyroeny</a>, <a href="https://github.com/boludoz">boludoz</a>, and <a href="https://github.com/FearlessTobi">FearlessTobi</a>, we now have proper <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11705" data-gh-pr="11705">shortcut creation</a> support for Windows too!</p> <p>To access this feature, simply right click a game in yuzu’s game list, select Create Shortcut, and pick if you want it on your desktop or the applications section of the start menu. This allows you to start games with a quick start menu search or even from a pin in the menu/taskbar if you so choose.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./shortcut.png" title=" Populate that taskbar"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/shortcut_hu600f5dbf370befc70c2c96ed9a17a6e5_45448_611x0_resize_q90_bgffffff_box_3.jpg" alt=" Populate that taskbar"></a> <p class="has-text-centered is-italic has-text-grey-light"> Populate that taskbar</p> </div> </div> <p>Helping improve this, <a href="https://github.com/german77">german77</a> made the required changes to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11740" data-gh-pr="11740">save multiple resolutions per icon,</a> making smaller sized desktop icons much more readable than before.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./icons.png" title=" Scaling images down doesn’t always look the best"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/icons_hudf885ea0623cf4f8a6fb80ec9378e900_151664_287x0_resize_q90_bgffffff_box_3.jpg" alt=" Scaling images down doesn’t always look the best"></a> <p class="has-text-centered is-italic has-text-grey-light"> Scaling images down doesn’t always look the best</p> </div> </div> <p><a href="https://github.com/DanielSvoboda">DanielSvoboda</a> made several changes in file system handling to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11749" data-gh-pr="11749">improve directory path detection</a> for the shortcuts, making them far more usable and stable. Thank you!</p> <p>Work on improving user experience (UX) is always welcome, it is your writer’s belief that UX is as important as proper functionality, and should never be ignored. To improve the quality of life of people playing with multiple controllers, <a href="https://github.com/flodavid">flodavid</a> changed the behaviour of how users interact with the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11779" data-gh-pr="11779">number of connected controllers</a> in the Controls settings. Users can now more intuitively click the green lights at the bottom to select how many players/controllers they would like to be active. Thank you!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./controls.png" title=" Epic Smash sleepover!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/controls_hue9f91c81c3bebfddc97ed829142816bb_1063_236x0_resize_q90_bgffffff_box_3.jpg" alt=" Epic Smash sleepover!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Epic Smash sleepover!</p> </div> </div> <p>Another welcome UX addition is by <a href="https://github.com/Macj0rdan">Macj0rdan</a>, who implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11903" data-gh-pr="11903">a quick control for game volume</a> with the mouse wheel when the pointer is placed over the volume button in the UI, removing the need to click it and drag a small slider. Thank you!</p> <p>Continuing his work on applet support, german77 implemented the <code>SaveScreenShotEx0</code> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11812" data-gh-pr="11812">service method and its variants,</a> allowing users to take captures from within games themselves instead of globally with the screenshot hotkey. This works for games like <code>Super Smash Bros. Ultimate</code> ― however, note that screenshot editing is not available yet. Homework for later!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smash.png" title=" Save your best moments (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/smash_hu8f12f9c99347fa5c2150b7216b1c4eb3_1334357_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Save your best moments (Super Smash Bros. Ultimate)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Save your best moments (Super Smash Bros. Ultimate)</p> </div> </div> <p>german77 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11892" data-gh-pr="11892">implemented the</a> <code>SaveCurrentScreenshot</code> method, allowing users to take in-game screenshots in <code>Pokémon Scarlet/Violet</code> with its latest update installed. Happy selfie shooting!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./poke.png" title=" Feeling cute, might capture a shiny later (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/poke_hu114389c1174a7f1d7ac91db21ec9d2b9_337813_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Feeling cute, might capture a shiny later (Pokémon Scarlet)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Feeling cute, might capture a shiny later (Pokémon Scarlet)</p> </div> </div> <p>One of the changes german77 introduced broke the <code>Find Mii</code> stage in <code>Super Smash Bros. Ultimate</code>. Since it’s not a popular stage, even among the Smash community, we didn’t notice this issue, and no one reported in our <a href="https://discord.gg/u77vRWY">Discord server</a>, <a href="https://community.citra-emu.org/c/yuzu-support/14">forums</a>, or <a href="https://github.com/yuzu-emu/yuzu/issues/new/choose">GitHub bug report page</a> ― we only found out thanks to complaints on Reddit. This is a reminder to you, the users, please try to report issues in the proper channels! Doing so ensures we see the problems you are having and can work to fix them.</p> <p>yuzu is a large project with many “black box” areas. There will be bugs, many thousands of bugs, that our team may never encounter. Your voice is so important, we hate to see any bug reports slip through the cracks outside of our channels.</p> <p>With that out of the way, by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11822" data-gh-pr="11822">creating random Miis</a> with names, german77 solved the issue.</p> <p>german77 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11846" data-gh-pr="11846">expanded the character limit of cheats</a> to more than 64 characters. Now you can cheat to your heart&rsquo;s content.</p> <p>You know our developers spend a lot of time opening and closing yuzu when byte[] can accurately measure that 10% of shutdown crashes are caused by the game list. He found that the issue was in how Qt deals with messages from objects that were destroyed or disconnected (like stopping the emulator while the game list is loading). By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11846" data-gh-pr="11846">changing the behaviour</a> of how the game list is reported to those events, another source of shutdown crashes has been defeated.</p> <h2 id="kernel-cpu-and-file-system-changes">Kernel, CPU, and file system changes</h2> <p>byte[] has been having a lot of “fun” lately fixing and implementing kernel changes. First off, he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11686" data-gh-pr="11686">fully implemented transfer memory,</a> fixed <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11766" data-gh-pr="11766">incorrect page group tracking,</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11914" data-gh-pr="11914">updated the implementation</a> of KPageTableBase, and has now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11843" data-gh-pr="11843">nearly completed</a> the entire KProcess implementation!</p> <p>As preliminary work for NCE support coming in the near future, byte[] implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11718" data-gh-pr="11718">native clock support</a> for arm64 devices running on Linux or Android. There is no support for ARM Windows devices for now, as none have bothered to include a Vulkan driver yet.</p> <p>The kernel was updated to reflect changes made in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11748" data-gh-pr="11748">firmware version 17.0.0,</a> ensuring support for future games.</p> <p>v1993 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11772" data-gh-pr="11772">solved some warnings</a> that were spamming our build logs ― namely, using <code>std::forward</code> where appropriate, and qualifying <code>std::move</code> calls. This should solve build issues for those experimenting with Darwin build targets.</p> <p>By user request, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11774" data-gh-pr="11774">further improved the build performance of RomFS mods</a> by getting rid of some unnecessary object copies. This also fixed a file handle leak, which now allows modders to edit mod files after stopping emulation, helping them work faster on those <em>juicy and delicious</em> game mods.</p> <h2 id="audio-changes">Audio changes</h2> <p>Thanks to user reports, our audio connoisseur, Maide, found that <code>Ancient Rush 2</code> would crash at the end of the first developers screen. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11735" data-gh-pr="11735">Clearing the DSP buffer</a> after each execution fixes the issue.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ar2.png" title=" Diggy Diggy Hole! (Ancient Rush 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2023/ar2_hu326136e5c95b9e8f32f19b6b750a98aa_2734943_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Diggy Diggy Hole! (Ancient Rush 2)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Diggy Diggy Hole! (Ancient Rush 2)</p> </div> </div> <p>Speaking of audio, byte[] delivered another resounding victory in the shutdown department by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11778" data-gh-pr="11778">fixing a deadlock</a> in the audio renderer.</p> <h2 id="hardware-section">Hardware section</h2> <p>We have some sad news for the old Red Team guard, a warning for the Green Team, and very good news for Adreno droids.</p> <h3 id="nvidia-our-fault-this-time">NVIDIA, our fault this time</h3> <p>The 545 and 546 series of drivers have solved the high VRAM usage crashes we reported this last month, but users are reporting new crashes in games with these drivers. Reverting to the 53X series of drivers solves the problem, but this time, it&rsquo;s not NVIDIA’s fault! Mesa also has many new crashes with the 24.0.0 release, and having the top two drivers crashing under the same conditions is not a coincidence.</p> <p>We found that the problem is in how we are recompiling shaders ― the types of some variables are mismatched. The fix will take some time to implement, so for NVIDIA and Mesa users experiencing crashes in games like <code>Bayonetta 3</code>, we suggest not updating your drivers for the time being.</p> <h3 id="amd-giving-a-last-hurrah-to-polaris-and-vega">AMD, giving a last hurrah to Polaris and Vega</h3> <p>The time has come. The last 2 remnants of the GCN architecture are on their way to be discontinued. AMD started releasing <a href="https://www.anandtech.com/show/21126/amd-reduces-ongoing-driver-support-for-polaris-and-vega-gpus">split drivers</a> for those products, which run outdated Vulkan driver branches compared to RDNA and newer hardware. <a href="https://www.phoronix.com/news/Mesa-24.0-Faster-RADV-Vega">The news</a> of AMDVLK, the official Linux AMD driver, killing support for these products means no new Vulkan drivers will be available.</p> <p>This doesn’t mean the show is over for their owners. For the time being, no new change breaks compatibility with the cards, and Linux Mesa drivers like RADV will continue to provide support, most likely extending it past what the Windows drivers report as supported (as is usually the case with Mesa).</p> <p>But for those stuck on Windows, this is the last ride.</p> <p>GCN4.0, GCN5.0, you weren’t the most efficient cards, but you gave us good value in the worst moments, <em>years</em> of amazing gameplay, and great FineWine moments. We salute you and thank you for your impeccable service, few GPU architectures leave the stage with such a round of applause.</p> <p>o7</p> <h3 id="turnip-a-very-quickly-improving-work-in-progress">Turnip, a very quickly improving work-in-progress</h3> <p>yuzu uses a single codebase for all its releases, upstream/master/main, however you prefer to call it, Mainline, Early Access, and Android all start from there. When improvements to the codebase are added, they eventually reach all releases, Android included.</p> <p>We recently added improved support for <code>occlusion queries</code> (part of project Y.F.C.) to Android to increase performance and accuracy on all devices. But occlusion query support on Turnip drivers with Adreno 725 and 730 GPUs was not working correctly, and this took us a very long time to find. Users experienced crashes that forced them to remain on outdated <a href="https://github.com/yuzu-emu/yuzu-android/releases/">GitHub</a> versions, and we needed to stall a new Play Store release until the problem was investigated and properly solved.</p> <p>The issue was found, reported, and resolved by Mesa in record time in their current Adreno 700 branches, which then driver packagers like <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases">K11MCH1</a> use to build packages Qualcomm users can load on emulators.</p> <p>For this reason we <em>strongly</em> recommend Adreno 730 and Adreno 725 users to update to the latest <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/24.0.0-R-X">Release X</a> driver, which not only fixes the crashes caused by occlusion queries, but also the lack of support for the Adreno 725 and some variants (yes, there are several) of the Adreno 730. It isn&rsquo;t only desktop GPU vendors who love to rename things.</p> <p>By using this driver, we were able to launch newer Android builds with the latest upstream changes, and all Qualcomm users can safely use the latest GitHub builds if they prefer.</p> <p>By the way, the GitHub builds are now properly signed. Rejoice, as you can now update from one to the next without needing to uninstall first. If you want to test experimental and potentially unsafe (but maybe faster) changes before Play Store updates, it’s now much easier.</p> <h2 id="future-projects">Future projects</h2> <p>Let’s begin with what most people want to hear about: Project Nice for Android devices. NCE (Native Code Execution) is progressing very well, but there are still some bugs to iron out. Games are becoming not only playable, but also <em>faster</em> on devices with thermal restrictions. Additionally, the time spent loading and closing games has been significantly reduced now! NCE has helped us understand issues in our CPU emulation in x86_64 too, so expect gains on both fronts.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smo.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Recorded with a Red Magic 7S Pro (SUPER MARIO ODYSSEY)</p> </div> </div> <p>No promises on a release date per usual, but as politicians love to say: “We’re working on it.”</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./bayo2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Destroying those touch screen controls! (Bayonetta 2)</p> </div> </div> <p>Blinkhawk is <em>suggesting</em> that your writer informs you he is working on a new project seeking to make the GPU process-agnostic, allowing multiprocess emulation within the GPU. No fancy names this time, we’ve simply been calling this “Multiprocess” internally. Multiprocess is a mandatory step towards UMA support, which will provide huge gains for iGPUs and SoC users, as well as reducing RAM consumption.</p> <p>That’s all folks! Apologies for the delay, university homework and finals are killing your writer. Thank you for reading until the end. See you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report September 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/ Fri, 20 Oct 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/ <p>Hi yuz-ers! Last month has been interesting, and we&rsquo;re excited to report what we&rsquo;ve been up to. Miis come out to play, GPU changes, Android improvements, and more! Let’s get into it.</p> <p>Hi yuz-ers! Last month has been interesting, and we&rsquo;re excited to report what we&rsquo;ve been up to. Miis come out to play, GPU changes, Android improvements, and more! Let’s get into it.</p> <h2 id="of-miis-and-applets">Of Miis and applets</h2> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./miiedit4.png" title=" Wii want to play"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/miiedit4_hu41d6dc016301cdcc0300f604e2c87625_1189872_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Wii want to play"></a> <p class="has-text-centered is-italic has-text-grey-light"> Wii want to play</p> </div> </div> <p>For quite some time, it has been possible to load the default Miis in supported games on yuzu. However, yuzu&rsquo;s implementation of the Mii service was lacking the necessary support for the Mii database.</p> <p>The Mii database is a file saved on the Switch which holds up to 100 Miis. Without the proper support for this database within the Mii service, it was impossible to load your custom Miis.</p> <p>Our in-house input emulation expert, <a href="https://github.com/german77">german77</a>, embarked on an adventurous journey to test the MiiEdit applet as part of his ongoing quest to make system applets function smoothly on yuzu. Initially, things were progressing well, but his efforts hit a roadblock when softlocks while booting the applet became a recurring issue.</p> <p>Suspecting that erroneous data from the Mii service might be the root cause of these softlocks, german77 decided to undertake the task of completely reverse engineering the Mii service. His dedicated efforts led to an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11526" data-gh-pr="11526">almost fully-implemented Mii service,</a> with the only missing piece being the ability to send and receive Miis from nearby users. This <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11480" data-gh-pr="11480">comprehensive implementation</a> involved rectifying some of the older code, reorganising data structures, and, at long last, providing support for the eagerly anticipated Mii database. Adventurous users have the ability to load their own Mii characters in any game by placing their console’s database file at <code>%appdata%/yuzu/nand/system/save/8000000000000030/MiiDatabase.dat</code>.</p> <p>With the Mii service completed and behind him, Narr swiftly returned to the task of making the MiiEdit applet function seamlessly on yuzu. Thanks to some troubleshooting assistance from <a href="https://github.com/liamwhite">byte[]</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11569" data-gh-pr="11569">he ultimately managed to make it work.</a> The last piece of the puzzle was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11561" data-gh-pr="11561">completing Mii database support for the applet,</a> and with this crucial addition, yuzu&rsquo;s Mii functionality is now more robust than ever. Users can now seamlessly create, edit, and store their Miis using the new MiiEdit applet via <code>Tools</code> &gt; <code>Open Mii Editor</code>, and games can automatically generate a random Mii for players without crashing.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./miiedit1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/miiedit1_huf6955a72d528907ca29f2659463cb3aa_162871_800x0_resize_q90_bgffffff_box_3.jpg" alt="Edit to your heart’s content"></a> </div> <div class="column is-bottom-paddingless"> <a href="./miiedit2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/miiedit2_hu92662f8fcd4017050ca1e8f76403e138_39605_800x0_resize_q90_bgffffff_box_3.jpg" alt="Edit to your heart’s content"></a> </div> <div class="column is-bottom-paddingless"> <a href="./miiedit3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/miiedit3_hu5afb51020863b2c4cf67db449aed1b1a_104300_800x0_resize_q90_bgffffff_box_3.jpg" alt="Edit to your heart’s content"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Edit to your heart’s content</p> <p>Building on the success of the MiiEdit applet, Narr continued his productive streak by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11632" data-gh-pr="11632">fully implementing support for the Cabinet applet.</a> The Cabinet applet, if you weren&rsquo;t already familiar, is the amiibo manager applet. With these recent changes, users can register, rename, delete, and restore their amiibo data via <code>Tools</code> &gt; <code>Amiibo</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./cabinet1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/cabinet1_huaa2eeeb143d2fffb6ff6b37df56e405e_48286_800x0_resize_q90_bgffffff_box_3.jpg" alt="And register as many as you want"></a> </div> <div class="column is-bottom-paddingless"> <a href="./cabinet2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/cabinet2_huf8d72ddbd3f4f47f1a26a71876551aa7_60227_800x0_resize_q90_bgffffff_box_3.jpg" alt="And register as many as you want"></a> </div> <div class="column is-bottom-paddingless"> <a href="./cabinet3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/cabinet3_hud88f0a0e7868c12803329639e277ef18_152089_800x0_resize_q90_bgffffff_box_3.jpg" alt="And register as many as you want"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">And register as many as you want</p> <h2 id="graphics-changes">Graphics changes</h2> <p>Switching to the graphics department, let’s begin with some interesting decisions from the Khronos group that affected the Linux Mesa drivers.</p> <p>After getting reports of crashes when running <code>Pikmin 4</code> on Linux, byte[] discovered that Khronos removed the ability to declare an <code>OpTypeSampledImage</code> for buffer textures from the latest release of the SPIR-V specification, the shader backend used by yuzu for Vulkan support.</p> <p>This is extremely unusual — usually a deprecation is preferred (to not affect old code). Mesa, being the textbook example of following the specification, followed through with this change, forcing us to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11435" data-gh-pr="11435">skip samplers for buffer textures.</a> With these weird Vulkan decisions properly handled, <code>Pikmin 4</code> is once again playable for those running Mesa drivers.</p> <p>Speaking of <code>Pikmin 4</code>, and of <code>Master Detective Archives: RAIN CODE</code>, byte[] also found the cause of the lighting issues and wrong faces rendering affecting the former and the latter game, respectively.</p> <p>byte[] noticed an additional validation error Mesa was providing when debugging the issue with sampled buffers. yuzu&rsquo;s SPIR-V emitter was generating atomic operations on a typeless image, which the SPIR-V specification has never allowed. After a false start by trying to avoid typeless images, he found the real culprit: the code for generating SPIR-V atomics incorrectly used the array index of the image, instead of its designated descriptor.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11567" data-gh-pr="11567">Correcting this shader behaviour</a> fixed the headlamp lighting required in specific dark sections of <code>Pikmin 4</code> and the facial expressions of characters in <code>Master Detective Archives: RAIN CODE</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./p4.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> A little bit of exploration never hurt anyone (Pikmin 4)</p> </div> </div> <p><a href="https://github.com/GPUCode">GPUCode</a> also joined the fray this month with several code additions.</p> <p>First of all, something <em>light</em>, let’s introduce <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11535" data-gh-pr="11535">separate command buffer uploads!</a> This gives the benefit of a slight performance uplift, caused by reduced renderpass breaks, which greatly helps mobile GPUs. The larger the renderpass, the longer mobile GPUs can keep data in tile memory, so breaking it is a costly operation. Dedicated GPUs benefit from this change, but much less.</p> <p>We measured an 8% performance increase in some games with a 5800X3D. Lower end systems could see bigger gains.</p> <p>GPUCode also fought against the rendering issues affecting <code>Mortal Kombat 1</code> and <code>Sonic Forces</code> when using Vulkan. For those deep into the yuzu lore, this is a compute shader implementation of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11556" data-gh-pr="11556">MSAA image copies,</a> similar to what epicboy <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/#other-gpu-and-video-changes">did back in February</a>. As said back then, compared to OpenGL, Vulkan requires a lot more work.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/mk1bug_hu0484047029cd7620ae413019522a7d63_2205823_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Round 1, Fight! Emutality! (Mortal Kombat 1)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/mk1fix_hu07f4d662774f6dd090d9d98796543ff4_2247559_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Round 1, Fight! Emutality! (Mortal Kombat 1)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Round 1, Fight! Emutality! (Mortal Kombat 1)</p> <p>This change also improves the original shader, allowing games like <code>Pinball FX3</code> to render and work correctly now, regardless of the graphics API in use, while also improving the rendering of games like <code>Fate/EXTELLA: The Umbral Star</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./msaa1.png" title=" I ask of you. Are you my Master? (Fate/EXTELLA: The Umbral Star)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/msaa1_hud22aa0a610107e5b63ae500bbb6b6de0_2093286_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" I ask of you. Are you my Master? (Fate/EXTELLA: The Umbral Star)"></a> <p class="has-text-centered is-italic has-text-grey-light"> I ask of you. Are you my Master? (Fate/EXTELLA: The Umbral Star)</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./msaa2.png" title=" Don’t break it, please (Pinball FX3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/msaa2_hu0aafa841ced3b072d538cb446c0fce3f_2594612_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Don’t break it, please (Pinball FX3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don’t break it, please (Pinball FX3)</p> </div> </div> <p>Players of <code>The Legend of Nayuta: Boundless Trails</code>, and other Falcom games like <code>The Legend of Heroes</code> series, reported that text was rendered incorrectly, displaying weird colour highlights. GPUCode investigated this and found that we were using the wrong colour component order (BGR vs RGB for example) for the <code>A4B4G4R4_UNORM</code> texture format. Instead, <code>A4B4G4R4_UNORM_PACK16_EXT</code> has <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11557" data-gh-pr="11557">the order</a> the game expects, providing correct rendering.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/nayubug_hu64ead8b017ae1b1ddc7ec832d85304f0_1957838_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Ask Jobs what he thinks about good font rendering (The Legend of Nayuta: Boundless Trails)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/nayufix_hud2d56a5a64b8358f000e1681d859ef3d_1981706_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Ask Jobs what he thinks about good font rendering (The Legend of Nayuta: Boundless Trails)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Ask Jobs what he thinks about good font rendering (The Legend of Nayuta: Boundless Trails)</p> <p>Continuing this trend of texture fixes, GPUCode also identified a bug in how sRGB textures were being handled.</p> <p>The problem was that sRGB textures could not be used as storage images in shaders. The solution was to create the texture as linear, which is another colour space that does not have gamma correction, and then use an sRGB view to access it. This way, the texture can be used as a storage image and still have the correct colours.</p> <p>However, this solution had an unintended side effect. When the texture was used directly without the view — for example, when it was resolved by copying it to another image — the colours were wrong because the colour space had changed.</p> <p>To fix this, the pull request <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11562" data-gh-pr="11562">ensures sRGB creation is only disallowed when transcoding,</a> which means that it always applies except when converting compressed formats to uncompressed formats on the GPU. This way, the texture is created as sRGB and has the correct colours in both cases.</p> <p>Thanks to this, <code>Momotaro Dentetsu</code> and <code>Star Ocean First Departure R</code> can now render with the colours and gamma intended by their developers. The way it’s meant to be played, as a certain luxury-focused graphics card vendor says.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/momobug_hub38371d9641e949afb557390d414e109_1891423_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Don’t mess with my gamma! (Momotaro Dentetsu)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/momofix_hu35743bbee982b4aa136b88f4e74112be_1950468_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Don’t mess with my gamma! (Momotaro Dentetsu)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Don’t mess with my gamma! (Momotaro Dentetsu)</p> <p>Now’s the turn for our classic <a href="https://en.wikipedia.org/wiki/List_of_Key_video_games">Key</a> visual novel fans, your writer included. Users reported the games had some terrible flickering. The cause, as <a href="https://github.com/Kelebek1">Maide</a> found out, is due to how particular the rendering for these classic games is. Most games create a single render target on a single address, either 1080p or 720p. Key’s visual novels instead use the same address to create both 720p and 1080p render targets, with the 1080p one being created first, but never being used. yuzu, by default, always picked the first render target.</p> <p>This wasn’t an issue for other games, but for this engine, the texture cache constantly detected the wrong image, causing it to alternate between both render targets on each frame. This resulted in a black frame being rendered between two valid frames, causing dangerous flickering for those with photosensitive epilepsy.</p> <p>By changing yuzu’s behaviour to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11479" data-gh-pr="11479">look for the most recently modified image</a> to present, the issue is completely fixed, and users can now cry entire nights reading these games.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./planetarian.png" title=" All the stars in the sky are waiting for you (planetarian)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/planetarian_hu827ccd17d177875ca5cba2816bce46c4_1885076_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" All the stars in the sky are waiting for you (planetarian)"></a> <p class="has-text-centered is-italic has-text-grey-light"> All the stars in the sky are waiting for you (planetarian)</p> </div> </div> <p>And to close this section, <a href="https://github.com/FernandoS27">Blinkhawk</a> fixed some <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11646" data-gh-pr="11646">memory leaks</a> caused by the recent query cache rewrite.</p> <h2 id="android-additions">Android additions</h2> <p>Our resident Terminator and Nier: Automata enjoyer <a href="https://github.com/t895">t895</a>, and other members of the team, continue to work hard on improving the experience of the Android build:</p> <ul> <li>A hardware limitation exposed by the Buffer Cache Rewrite from Project Y.F.C. was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11471" data-gh-pr="11471">worked around.</a> This change was done by GPUcode.</li> <li>A bug where certain temporary <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11505" data-gh-pr="11505">settings would be reset</a> on emulation start (for example, “Limit emulation speed”) has been fixed.</li> <li>An issue where <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11506" data-gh-pr="11506">game shortcuts would appear cropped</a> on certain devices was fixed.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11523" data-gh-pr="11523">The amount of thread workers for shader compilation</a> was reduced to one. This is intended to reduce memory consumption.</li> <li>More <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11542" data-gh-pr="11542">screen orientation and aspect ratio</a> misbehaviours were fixed.</li> <li>An issue where the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11564" data-gh-pr="11564">input overlay</a> would <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11583" data-gh-pr="11583">draw offscreen</a> on some devices was fixed.</li> <li>An issue where the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11594" data-gh-pr="11594">settings activity</a> would appear dim when in landscape mode while using 3 button navigation was fixed.</li> <li>The in-game menu could be unintentionally opened during the loading animation. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11597" data-gh-pr="11597">This is now fixed.</a> </li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11613" data-gh-pr="11613">Several crashes</a> related to the initial setup, emulation activity, and emulation fragment are now fixed.</li> <li>The emulator will now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11616" data-gh-pr="11616">correctly reload the settings file</a> after resetting all settings.</li> <li>Lastly, a new settings menu <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11603" data-gh-pr="11603">unifies all content installation</a> into a single place. Users can now access the <code>Manage yuzu data</code> menu to import/export firmware, saves, user data, and install game content, console, and Amiibo keys. The <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11543" data-gh-pr="11543">new User data option</a> allows users to backup and restore all app data. Useful for example when migrating to other builds, like from a GitHub release to a Play Store release.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./data1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/data1_huec5aebe646ab7d58b1e36e55080229a7_98514_800x0_resize_q90_bgffffff_box_3.jpg" alt="For the convenience of the lady and the gentleman"></a> </div> <div class="column is-bottom-paddingless"> <a href="./data2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/data2_hu395fd84380074c82edf7f0ee4c229e94_104176_800x0_resize_q90_bgffffff_box_3.jpg" alt="For the convenience of the lady and the gentleman"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">For the convenience of the lady and the gentleman</p> <h2 id="audio-changes">Audio changes</h2> <p>Maide shines here by giving us a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11460" data-gh-pr="11460">rewrite</a> of the hardware Opus service, responsible for handling decompression of Opus-formatted audio in games. The old implementation lacked several functions documented by the reverse engineering community, which is what this rewrite focused on the most.</p> <p>Now the hardware Opus implementation matches the current information available. Maide also took the opportunity to move the processing of Opus to the emulated ADSP (the emulated implementation of the audio coprocessor of the Switch).</p> <p>The end result of this effort is allowing games that previously faced crashes when trying to decode Opus audio, like <code>MLB The Show 22 &amp; 23</code>, the <code>Touhou</code> series games, <code>Pokemon Quest</code>, <code>Pokemon Let's Go Eevee!/Pikachu!</code>, and <code>Sea of Stars</code> to play the audio correctly without crashing.</p> <p>Maide also fixed audio command processing, avoiding some command lists from returning early before being properly finished. After an interruption, the previous implementation would restart processing the list from the beginning instead of continuing from where it left off. This stalled audio rendering until it finished properly. Correcting <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11465" data-gh-pr="11465">this behaviour</a> solved cases where the audio engine would run too slowly, improving performance.</p> <p>Another issue that required quite the investigation caused background sound in <code>Xenoblade Chronicles 2</code> to cut off randomly. The cause was found to be in the data source commands during loops. Changing the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11467" data-gh-pr="11467">behaviour between its different versions</a> restored proper ambient noises to this great game and a few others.</p> <p>To close this section, Maide also discovered what caused the dropping of music and voices in <code>New Super Mario Bros. U Deluxe</code>’s final level. The audio command buffer sometimes took longer to process than estimated, which caused voices in the renderer to be dropped. The game depends on this behaviour to some extent, but yuzu&rsquo;s calculation of the estimation was subtly incorrect, causing almost everything to be dropped.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11520" data-gh-pr="11520">Improving the time estimation algorithm</a> solved the issue. Let’s hear those voices!</p> <h2 id="miscellaneous-changes">Miscellaneous changes</h2> <p>Sometimes, we overlook testing on devices that don&rsquo;t meet our standard hardware recommendations. With the addition of the new Vulkan VSync options, we made an incorrect assumption. As it turns out, users do not always have Vulkan drivers installed! Shocking, right?</p> <p>While most of the time users do have support for Vulkan, that certainly is not the case for NVIDIA Fermi users (people that were promised a Vulkan driver but never got it), or users of Linux distros which don&rsquo;t package GPU firmware files, like <a href="https://trisquel.info/">Trisquel</a>. This caused the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11450" data-gh-pr="11450">VSync combobox</a> to refuse to offer any options when no Vulkan driver and device was detected, which blocked OpenGL-only users from toggling VSync.</p> <p>While it’s easy to just ask the users to upgrade to newer hardware, and/or use a more functional distro, that doesn’t change the fact that the behaviour is incorrect.</p> <p>Enter <a href="https://github.com/lat9nq">toastUnlimited</a>, who fixed the UI and took the opportunity to improve the broken Vulkan detection, ensuring OpenGL is selected as the default API if needed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ogl.png" title=" Fermi still rocking it"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/ogl_hu8c53b7d0f31ae7480a5119cf7d671fe5_25253_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Fermi still rocking it"></a> <p class="has-text-centered is-italic has-text-grey-light"> Fermi still rocking it</p> </div> </div> <p>byte[] fixed <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11473" data-gh-pr="11473">language selection</a> being ignored in multi-program applications, which was affecting games like <code>Super Mario 3D All-Stars</code>, <code>Grandia HD Collection</code>, and others. Proper localisation is very important to us! Not everyone can corrupt their minds by learning English, after all.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sm3das.png" title=" ¡Mamá Mía! (Super Mario 3D All-Stars)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/sm3das_hu0acb139774504fd6ab66b7b82848c357_1228134_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" ¡Mamá Mía! (Super Mario 3D All-Stars)"></a> <p class="has-text-centered is-italic has-text-grey-light"> ¡Mamá Mía! (Super Mario 3D All-Stars)</p> </div> </div> <p>Newcomer <a href="https://github.com/rkfg">rkfg</a> found one of those bugs that makes you question how this even worked before. yuzu&rsquo;s parsing for the PFS file format would try to read filenames from the header as a C string. C strings definitionally end at a null byte, but this failed to account for the fact that the next null byte could sometimes be well past the end of the header, and parsing a file with this specific construction would cause yuzu to fail to find files inside the archive and/or crash. By unconditionally <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11553" data-gh-pr="11553">inserting a null byte</a> after the header data, rkfg solved this one. Now games like <code>Luigi’s Mansion 3</code> don’t encounter strange crashes seemingly out of nowhere.</p> <p>While working on more file system improvements, byte[] implemented a simple NCA (Nintendo Content Archive) verification system, which checks that the names of NCA files match their contents to guard against filesystem corruption. Now users can <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11456" data-gh-pr="11456">check the integrity</a> of their game dumps by right clicking a game in the game list and selecting <code>Verify Integrity</code>. Implementing proper signature and hash-based verification is planned, but expected to be very slow in comparison.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./verify.png" title=" Always helpful"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/verify_hu9e3b037ee10e605fce2bad8f4c6b122c_49743_531x0_resize_q90_bgffffff_box_3.jpg" alt=" Always helpful"></a> <p class="has-text-centered is-italic has-text-grey-light"> Always helpful</p> </div> </div> <p>By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11483" data-gh-pr="11483">stubbing</a> the <code>GetSaveDataSizeMax</code> filesystem service method, <a href="https://github.com/FearlessTobi">FearlessTobi</a> made <code>Minecraft Legends Deluxe Edition</code> able to display its boot screen. Sadly the game crashes after that, guess there’s more work to do!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./minecraft.png" title="This is as far as it goes for now (Minecraft Legends)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/minecraft_hu57fe6eb90a981e783f2c47aa0abdb600_163137_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This is as far as it goes for now (Minecraft Legends)"></a> <p class="has-text-centered is-italic has-text-grey-light">This is as far as it goes for now (Minecraft Legends)</p> </div> </div> <p>Continuing with the stubbing procedures, fixing up <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11540" data-gh-pr="11540">purchase info calls</a> allows <code>The Settlers: New Allies</code> to start properly.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./nvidia.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/nvidia_hu4d4c1e80aba904a8f2f93dcfc4e034fe_1423164_800x0_resize_q90_bgffffff_box_3.jpg" alt="NVIDIA on the left, AMD on the right (The Settlers: New Allies)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./amd.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/amd_hu4b0ca270ad15b41e87bebe078b60ebe9_3873769_800x0_resize_q90_bgffffff_box_3.jpg" alt="NVIDIA on the left, AMD on the right (The Settlers: New Allies)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">NVIDIA on the left, AMD on the right (The Settlers: New Allies)</p> <p>As you can see, more work is needed to get this game to render properly. Extra points for being a game that renders better on AMD over NVIDIA.</p> <p>But what about <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11496" data-gh-pr="11496">a new service?</a> byte[] added a stub for the <code>ngc</code> service, allowing the <code>Baten Kaitos HD</code> collection to work.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bk1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/bk1_hufc710ef3a4bbfdd05ee787d5a98024f4_1768147_800x0_resize_q90_bgffffff_box_3.jpg" alt="Old-school (Baten Kaitos HD collection)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bk2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/bk2_hu447f8aea59c14bf9cdbea99cdf7ad20f_2054850_800x0_resize_q90_bgffffff_box_3.jpg" alt="Old-school (Baten Kaitos HD collection)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Old-school (Baten Kaitos HD collection)</p> <p>Likewise, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11590" data-gh-pr="11590">adding</a> the <code>GetFileSystemAttribute</code> service method makes <code>Tiny Thor</code> playable; it no longer gets stuck during the initial loading screens. C’mon, without googling, spell the name of Thor’s hammer correctly.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./tt1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/tt1_huc14e54889e39cc08eb46a6df83639e11_917527_800x0_resize_q90_bgffffff_box_3.jpg" alt="So adorable! (Tiny Thor)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./tt2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/tt2_hu2a2113eb932503eeae3b0cbacaed9995_1039092_800x0_resize_q90_bgffffff_box_3.jpg" alt="So adorable! (Tiny Thor)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./tt3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/tt3_hu7ed080b1b4f273d44ce90dfcb4c9c00d_458637_800x0_resize_q90_bgffffff_box_3.jpg" alt="So adorable! (Tiny Thor)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">So adorable! (Tiny Thor)</p> <p>Back again with good fixes is <a href="https://github.com/Squall-Leonhart">Squall-Leonhart</a>, who now focused on Windows file system error handling. For example, yuzu would simply crash if you disconnected a removable storage containing games loaded into yuzu’s list, a network SMB share, or a Bitlocker protected location was unavailable.</p> <p>But not anymore! By adding the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11499" data-gh-pr="11499">proper error handling</a> to these file system exception cases, the emulator now avoids a crash here; complaining, but working.</p> <p>Managing another critical blow to the fight for proper shutdown behaviour, byte[] managed to spot an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11652" data-gh-pr="11652">optimization</a> that should save around a second of time on high-end CPUs. Does this mean the fighting is over? No, some edge cases remain, but now under normal circumstances, closing a game should be almost instantaneous. We have a medal ready for byte[].</p> <h2 id="hardware-section">Hardware section</h2> <h3 id="nvidia-vram-fixes-and-focusing-on-the-latest-hardware">NVIDIA: VRAM fixes, and focusing on the latest hardware</h3> <p>The latest driver releases have proven to be stable for Turing and newer products, but we got reports of small regressions affecting Pascal and Maxwell users. If you’re still running older 750, 900, and 1000 series products and you face new issues in games, try reverting to older driver versions like the 52X series.</p> <p>Still, it&rsquo;s worth to mention that driver release <code>545.84</code> seems to have solved the instabilities caused by excessive VRAM use, like for example while running <code>The Legend of Zelda: Tears of the Kingdom</code> in the Depths with 2GB/4GB GPUs of any architecture. This is great news for low-end users struggling to run this particularly ASTC-heavy game.</p> <h3 id="amd-general-fixes-autohdr-vsync-problems-and-frame-interpolation">AMD: general fixes, AutoHDR, VSync problems, and frame interpolation</h3> <p>First, good news, the latest Windows driver version at the time of writing, <code>23.10.2</code> has solved the D24 issue affecting AMD cards on Vulkan. Those bothered by clipping lines and textures should upgrade to get the proper graphics experience. Keep in mind that this doesn&rsquo;t solve the vertex explosions affecting the Pentelas region and the DLC of <code>Xenoblade Chronicles 3</code>, we manage to confirm this is a different issue affecting AMD cards on a much lower level, as it is architecture, OS, and driver agnostic.</p> <p>Another good bit is that recent drivers also seem to have introduced DXGI swapchain support, allowing AMD cards to work with AutoHDR out of the box. There doesn&rsquo;t seem to be a driver toggle for this though. Users interested in enabling AutoHDR for yuzu can use <a href="https://github.com/ledoge/autohdr_force">this piece of software</a> to do the registry work for them.</p> <p>Now for a bit of bad news. Windows driver version <code>23.9.3</code> and newer cause the VSync options to be ignored, resulting in tearing during gameplay. If you’re affected by this, revert back to driver <code>23.9.2</code> for now. The standard procedure was followed: we&rsquo;ve opened a ticket with AMD regarding this issue and provided a generic test case.</p> <p>ED: Driver <code>23.10.2</code> seems to have solved this issue entirely, we recommend updating to it.</p> <p>Switching to something more interesting, we heard you! Despite our previous rants about frame generation, we think vendor-agnostic frame generation like FSR3 would be cool to make Pokémon games playable, but the same requisites which prevent us from using FSR2, or even DLSS/XeSS for that matter, apply here. Games don’t report their motion vector data to the console, since they were never developed to support DLSS.</p> <p>There are ways to implement this, such as adding one frame of delay and extrapolating data. The downside here is that 33ms of delay for 30 FPS games would be an awful experience. We could guess motion from previous frames, but this could have a very high performance cost and can potentially produce erratic results, old frames can&rsquo;t read the future. Or we could dip our toes into AI, which has given us unsatisfactory results in the past. While coding a generic way to extract motion vector data might be possible, it’s a huge endeavour, so expect it to be a very low priority at the moment. We have bigger fires to put out first, after all.</p> <p>What could work is <a href="https://community.amd.com/t5/gaming/amd-fluid-motion-frames-is-out-now-on-amd-radeon-rx-7000-series/ba-p/634372">AFMF</a>, if AMD adds Vulkan support for it in the future.</p> <p>“But writer, AFMF is not vendor-agnostic! It’s an AMD Windows driver exclusive feature!” you say. Ah, but that&rsquo;s where you’re wrong. It is vendor-agnostic on desktop PCs! Kinda.</p> <p>The only thing you have to do is get an RX 6400 (or higher) as a secondary GPU in your desktop PC, connect your displays to it, and enjoy enforcing frame interpolation even when using a primary Intel or NVIDIA GPU for rendering! Sadly, this doesn’t apply to yuzu yet, because the current beta driver for AFMF at the time of writing only supports the Direct3D 11 and 12 APIs.</p> <p>Let’s hope we get Vulkan support and we may be able to finally see <code>Tears of the Kingdom</code> hitting over 100 FPS, or <code>Pokémon Scarlet</code> model animations reaching <del>smooth</del> cinematic 30 FPS. Meanwhile, try to enjoy converting 20 FPS to 40 when using Path Tracing. At least you don’t have to pay 500+ bucks for this.</p> <h3 id="intel">Intel&hellip;</h3> <p>Sadly, we have another driver-level issue to report from Team Blue. This time, the problem is in geometry shaders. The SPIR-V shader compiler crashes the Vulkan Arc driver due to a <a href="https://www.youtube.com/watch?v=bLHL75H_VEM">null pointer dereference</a>. This affects many games, even popular ones like <code>Xenoblade Chronicles 3</code> and <code>The Legend of Zelda: Tears of the Kingdom</code>.</p> <p>The bug report has been filed. Fingers crossed for a resolution faster than seven months this time, and a more satisfatory result than 14th gen products.</p> <h3 id="turnip-steadily-progressing">Turnip, steadily progressing</h3> <p>The latest release of the Turnip driver for Adreno 700 series at the time of writing, <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v23.3.0_R7">R7</a>, seems to reduce overhead considerably, resulting in less overheating for Qualcomm Android users. Since the driver is also compatible with Adreno 600 series GPUs, we recommend users to give it a try.</p> <p>A word of warning though! Turnip drivers don’t have support for Adreno 725 and Adreno 730 GPUs at the moment. Older releases like <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v23.3.0_R5">R5</a> can be used on these devices instead.</p> <p>The official Qualcomm driver got some updates, but it continues to be absolutely terrible, so we don’t recommend using it, if at all possible.</p> <h2 id="future-projects">Future projects</h2> <p>Project Nice, the implementation of native code execution (NCE) for ARM devices is booting its first games!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./nce1.jpg" title=""><img src="./nce1.jpg" alt="And so it begins…"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nce2.jpg" title=""><img src="./nce2.jpg" alt="And so it begins…"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">And so it begins…</p> <p>A lot more work is needed before we can even move to the internal testing phase. There are many crashes and softlocks to sort out first, so please have some patience, Android gang.</p> <p>With the progress on the Album applet going so well, german77 is progressing further into other interesting applets too. Stay tuned.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./album.png" title="There’s an easter egg somewhere here!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2023/album_hu47cc800b9760a5b4485a01698cbc99ee_1379543_1024x0_resize_q90_bgffffff_box_3.jpg" alt="There’s an easter egg somewhere here!"></a> <p class="has-text-centered is-italic has-text-grey-light">There’s an easter egg somewhere here!</p> </div> </div> <p>That’s all folks! Hope you enjoyed this month&rsquo;s report. See you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report August 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/ Wed, 13 Sep 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/ <p><a href="https://www.youtube.com/watch?v=HkGNeN0LGOE">Tuturu~</a> yuz-ers. Did you feel that the last report was too short? Well, August was at full throttle! This month offers important graphical fixes, developers working around GPU limitations, several long overdue file system fixes, Skyline framework support, some Android and Apple love, and more!</p> <p><a href="https://www.youtube.com/watch?v=HkGNeN0LGOE">Tuturu~</a> yuz-ers. Did you feel that the last report was too short? Well, August was at full throttle! This month offers important graphical fixes, developers working around GPU limitations, several long overdue file system fixes, Skyline framework support, some Android and Apple love, and more!</p> <h2 id="yuzu-fried-chicken-forever">yuzu Fried Chicken Forever</h2> <p>And Robin.</p> <p>This is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11225" data-gh-pr="11225">the final piece</a> of <code>Project Y.F.C.</code>, the <code>Query Cache Rewrite</code>, and the implementation of <code>Host Conditional Rendering</code>. But before we start, we must explain a few things.</p> <h3 id="why-do-we-need-a-query-cache">Why do we need a query cache?</h3> <p>Many GPUs expose <em>counters</em>, which are used to gather data from the various commands that GPU executes — things like how many pixels were drawn or how many triangles were generated. Games use <em>queries</em> to fetch and load these counters into memory whenever they need to use them.</p> <p>yuzu&rsquo;s query cache is responsible for tracking the values of GPU counters for Switch games and services query requests from the game.</p> <h3 id="what-is-it-used-for">What is it used for?</h3> <p>Some games can make use of this fetched data to further optimise their rendering. For example, <code>SUPER MARIO ODYSSEY</code> optimises the amount of triangles it renders using a commonly used technique called <em>occlusion culling</em>.</p> <p>Occlusion culling is a feature that disables rendering of objects when they are not currently seen by the camera because they are offscreen or obscured (occluded) by other objects.</p> <p>In <code>SUPER MARIO ODYSSEY</code>, the game first renders simple boundary boxes that cover all objects that will be rendered on the screen. It then queries the number of pixels rendered to each box, and only renders the real objects whose corresponding boxes had any pixels rendered.</p> <p>Similarly, <code>Splatoon</code> games use pixel counts to check whose ink a given character is touching. The game tests for both ally ink and enemy ink and if both tests fail, then the character is not standing in any ink.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ink.png" title=" Medium-well (Splatoon 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/ink_hu8ae1c1692ffa18f59946c0faf8e81642_2442981_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Medium-well (Splatoon 2)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Medium-well (Splatoon 2)</p> </div> </div> <h3 id="development--challenges">Development &amp; Challenges</h3> <p>yuzu already had a query cache which was developed many years ago. However, this implementation was not perfect and had many issues. To name just a few:</p> <ul> <li>It could not hold any queries except pixel counts</li> <li>It failed to write to memory in the correct order</li> <li>It didn&rsquo;t invalidate queries that were later overwritten by other query types</li> </ul> <p>Our resident GPU dev, <a href="https://github.com/FernandoS27">Blinkhawk</a>, set out to rework the query cache to fix these issues and modernise the code. But, as he would later come to figure out, it wasn&rsquo;t going to be easy.</p> <p>Recall that the query cache works by running queries on the host GPU. As it turns out, figuring out how to make it work on the host GPU was actually the hardest part of the entire rewrite, due to significant differences between what the Switch GPU does and what host graphics APIs like Vulkan expose.</p> <p>During development, Blinkhawk ran into two big challenges with Host GPU queries. First, for performance reasons, we can&rsquo;t submit commands to the host GPU immediately upon processing them. We need to batch them in order to get any reasonable level of speed. This leads to the question: when do we need to perform the queries and sync the memory?</p> <p>As soon as you start a game, the game begins making queries to get GPU counters. Normally, the results are obtained by the Switch&rsquo;s GPU immediately after counting is done — when the rendering is done. But games like <code>SUPER MARIO ODYSSEY</code>, which use occlusion culling, make a <em>lot</em> of queries.</p> <p>So, if we tried to run all those queries and write the results on the host (user&rsquo;s) GPU in the same way, it would stall the GPU heavily after drawing each scene element to write back the counters.</p> <p>To prevent this from happening, Blinkhawk synchronises memory whenever the game requests the GPU to wait for commands to finish rendering. This allows for efficient batching, and for GPU commands which occur after the wait to utilize the counter values.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./occ.png" title=" Turn the camera around and the whole city magically disappears (SUPER MARIO ODYSSEY)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/occ_hu9d09660c2439ac4def1590ef21ab8dc7_3362691_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Turn the camera around and the whole city magically disappears (SUPER MARIO ODYSSEY)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Turn the camera around and the whole city magically disappears (SUPER MARIO ODYSSEY)</p> </div> </div> <p>Second, in the guest (Switch&rsquo;s) GPU, counters can be reset at any time or not at all. But this behaviour is not exposed in graphics APIs such as OpenGL and Vulkan. Instead, these APIs have queries that only count a smaller section such as a single draw or multiple draws. This meant that we would need to take all the query results and sum them up, especially if the game never resets the counter.</p> <p>In the old query cache, we used to sum all of the query results on a single GPU thread, which couldn&rsquo;t keep up with heavy workloads. As the number of query results increased, so did the time it took to sum them. This was fine for around 50 or 80 queries, but some games can easily make thousands of queries within a single frame.</p> <p>Blinkhawk experimented with a few different algorithms before finally settling on an implementation based on the <a href="https://en.wikipedia.org/wiki/Prefix_sum">Hillis Steele Scan Algorithm</a>.</p> <p>The result? Well, let the following list speak for itself:</p> <ul> <li>The lantern in <code>Luigi’s Mansion 3</code> is fixed.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./qcr1.png" title=" No flashbangs (Luigi’s Mansion 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/qcr1_hu97fca5501d2306597d89ec0d9b1cc34b_1925416_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" No flashbangs (Luigi’s Mansion 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> No flashbangs (Luigi’s Mansion 3)</p> </div> </div> <ul> <li>The level of detail in <code>Pokémon Scarlet &amp; Violet</code> is fixed when using High GPU accuracy. No more tree flickering.</li> <li>Rendering in some Koei Tecmo games like <code>Marvel Ultimate Alliance 3: The Black Order</code> is fixed when using High GPU accuracy.</li> <li>Glow particles in <code>Xenoblade Chronicles 2 &amp; 3</code> are fixed when using High GPU accuracy and disabling Asynchronous shader building.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xc3.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Properly filling the Flame Clock (Xenoblade Chronicles 3)</p> </div> </div> <ul> <li>Shadows in <code>Metroid Prime Remastered</code> are fixed.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./qcr2.png" title=" Not that Dark Samus (Metroid Prime Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/qcr2_hu87582b7a4ad220e4d6bb431ae4dfbce5_1416238_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Not that Dark Samus (Metroid Prime Remastered)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Not that Dark Samus (Metroid Prime Remastered)</p> </div> </div> <ul> <li>Performance increased for low-end and/or power-limited hardware in games that make use of Host Conditional Rendering, like <code>Pokémon Scarlet &amp; Violet</code>, <code>Luigi’s Mansion 3</code>, <code>SUPER MARIO ODYSSEY</code>, most Koei Tecmo titles, and many others.</li> <li>And more!</li> </ul> <h2 id="more-gpu-changes">More GPU changes</h2> <p>GPU changes don’t end there; there’s still quite a bit to cover.</p> <p>Let’s begin with a surprise port: <code>Red Dead Redemption</code> arrived on Switch and other consoles this month, and with it came a new take on the proprietary RAGE engine, giving our devs some quirks to iron out. You know, the usual with new releases.</p> <p>The Dynamic GPU Duo (Blinkhawk and <a href="https://github.com/Kelebek1">Maide</a>) analysed the game and concluded that the reason for the initial broken rendering was caused by the lack of support on Vulkan for masked <a href="https://en.wikipedia.org/wiki/Stencil_buffer">depth stencil</a> clears.</p> <p>A depth stencil, or combined depth and stencil buffer, is a type of image that combines a depth buffer and stencil buffer into a single image in memory, speeding up the GPU&rsquo;s tests to determine if any given pixel will be drawn.</p> <p>To elaborate a bit further:</p> <ul> <li>The depth buffer stores the distance between the camera and pixel currently closest to it, allowing the GPU to determine which pixels will be covered up by other objects and therefore shouldn&rsquo;t be drawn.</li> <li>The stencil buffer is more specialised: it stores a single byte for each pixel, which developers generally use to tag certain types of objects. As an example, the ground may be assigned a value of 1, trees and foliage 2, the player 17, and so on. It’s useful to know which pixels belong to which objects for applying various effects. <a href="https://youtu.be/By7qcgaqGI4?t=1390">Here</a> is a great video showing an example of how stencil buffers are used in <code>The Legend of Zelda: Breath of the Wild</code>. The material mask buffer mentioned in this video is a stencil buffer, and is used to prevent effects from applying to undesired materials.</li> </ul> <p>The main use for these buffers is to correctly render scenes with shadows, reflections, and transparency. As the video example shows, many types of graphical effects are made much easier by tagging each pixel, since this allows the GPU to conditionally apply an effect based on the pixel&rsquo;s material type.</p> <p>So why were clear operations a problem on Vulkan? In graphics programming, clears are used to reset all of a buffer&rsquo;s data to a specified value. Graphics APIs such as the Switch’s NVN and OpenGL support applying a <a href="https://registry.khronos.org/OpenGL-Refpages/es2.0/xhtml/glStencilMask.xml">mask</a> to clear operations. The mask changes which bits of the image will be affected when the clear is applied: bit positions set to 1 are affected by the clear, and bit positions set to 0 are left alone. For example, if the game needs the upper 4 bits of the 8-bit stencil for a subsequent draw, then it may set the mask to binary <code>00001111</code>, and clear the stencil with a value of 0. This will cause only the lower 4 bits to be cleared, and the upper 4 bits are left alone, as desired.</p> <p>OpenGL supports masks on all clear operations, including colour, depth, and stencil buffers. However, Vulkan was designed to support mobile GPUs, and on mobile GPUs, the most efficient implementation may be to entirely discard the old buffer when clearing it. This avoids reading the buffer back from memory, which can be expensive. So Vulkan does not have a direct equivalent of masked clears, and requires clearing the entire &ldquo;aspect&rdquo; of an image (colour, depth, or stencil) at once.</p> <p><code>Red Dead Redemption</code> was using a masked clear on its stencil buffer. This is why the bug was only affecting grass and bushes: the game was trying to keep those values intact with the mask. But since we translated clears directly from the game to Vulkan clears, we were just wiping out the entire stencil buffer, breaking the bush and grass rendering in the process.</p> <p>The solution we came up with for Vulkan is similar to a trick <a href="https://github.com/yuzu-emu/yuzu/pull/9631">we previously used for Persona 5 Royal</a>: use a regular draw, rather than a clear. With a regular draw, we are able to use the built-in hardware support for applying a stencil mask, and produce the same result as OpenGL.</p> <p>The new system in place works by drawing a fullscreen triangle, which allows the regular stencil hardware to handle masking and buffer writing. Thanks to this, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11320" data-gh-pr="11320">rendering issues in grass and bushes in Red Dead Redemption are now solved.</a> Howdy! You get correct rendering directly to your face, like it or not.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rdr.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/rdr_hufe67af7a0daad68ba899011c682eacca_2669692_800x0_resize_q90_bgffffff_box_3.jpg" alt="You have some tequilas, then Juan decides he is an adventurer (Red Dead Redemption)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./juan.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/juan_hudfb9df49ec994b89e45e054055e4decb_2074359_800x0_resize_q90_bgffffff_box_3.jpg" alt="You have some tequilas, then Juan decides he is an adventurer (Red Dead Redemption)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">You have some tequilas, then Juan decides he is an adventurer (Red Dead Redemption)</p> <p>Blinkhawk and Maide also spotted an old regression in how indirect compute dispatch is emulated. For the uninitiated, indirect dispatch is a technique used to allow the GPU to get the amount of work it needs to perform from a result generated by another compute shader or GPU operation, instead of being passed by the CPU at the moment of recording. Avoiding the slower CPU path by letting the GPU work indepedently like this improves performance. Such an independent and strong Tegra X1 GPU. Look at it grow.</p> <p>Thanks to this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11383" data-gh-pr="11383">late intervention,</a> <code>Mario + Rabbids Kingdom Battle</code>, <code>Mario + Rabbids Sparks of Hope</code>, and <code>Sea of Solitude</code> now render much better: shadows in the Rabbids series have the proper level of shade, and environments in Sea of Solitude are now visible.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mr.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/mr_hu1299100a3f87e4754e32b88175e2260b_3168834_800x0_resize_q90_bgffffff_box_3.jpg" alt="This one took a while, eh (Mario &#43; Rabbids Kingdom Battle &amp; Sea of Solitude)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sos.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/sos_huaae1de8f13bb39511d1963201693f7ea_1916300_800x0_resize_q90_bgffffff_box_3.jpg" alt="This one took a while, eh (Mario &#43; Rabbids Kingdom Battle &amp; Sea of Solitude)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This one took a while, eh (Mario &#43; Rabbids Kingdom Battle &amp; Sea of Solitude)</p> <p>The water in Sea of Solitude requires emulating other very tricky aspects of the Tegra X1, so that’s homework for later.</p> <p>As Maide also has learnt by now, <code>Accelerated DMA</code> fast path is an eccentric lady. She’s responsible for uploading and downloading image data directly from the GPU, converting image data on the CPU and system memory. But, it can only work when just the right conditions are met. If you don’t tread carefully enough near her, you will get the wrong data, in the wrong place, at the wrong moment. Such was the fortune of <code>Sid Meier's Civilization VI</code>, a game that crashed on Vulkan, and rendered completely broken on OpenGL.</p> <p>The culprit? Not marking a destination buffer and/or image as modified, causing any future read to not trigger the corresponding download. This resulted in the game reading the wrong data. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11278" data-gh-pr="11278">This quirk of the fast path has now been solved,</a> and a CPU fallback path for cases when an address isn’t valid for a given image format has been added. Strategy fans can now nuke each other to their heart&rsquo;s content. Gandhi says peace was never an option.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./civ.png" title=" Just one more turn (Sid Meier&#39;s Civilization VI)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/civ_hu91f5b936413d896f70191b3fe53c8f6a_2917222_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Just one more turn (Sid Meier&#39;s Civilization VI)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Just one more turn (Sid Meier&#39;s Civilization VI)</p> </div> </div> <p>For our <em>cultured</em> players out there, Blinkhawk and <a href="https://github.com/liamwhite">byte[]</a> bring us much-awaited fixes for <code>Bayonetta 3</code>. They involve emulating how the Switch’s GPU drivers emulate a feature the hardware doesn’t support. Yep.</p> <p>This story revolves around <code>textureGrad</code>, an OpenGL function that does texture lookups over multiple mipmap levels based on the supplied angle, and returns a single texel.</p> <p>Well, the Maxwell-based GPU on the Tegra X1 of the Switch can’t do this natively for 3D textures, so it uses the SAM and RAM instructions to enter into and leave a special mode, which we don&rsquo;t know much about — but we do know it is used for calculating the derivatives for the texture fetch.</p> <p>By looking for this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11316" data-gh-pr="11316">instruction pattern,</a> Blinkhawk implemented preliminary support for the fog and clouds in <code>Bayonetta 3</code>. byte[] later <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11430" data-gh-pr="11430">fixed the implementation</a> to make it behave the way Blink initially intended, and to avoid crashes on Mesa and RDNA3-based GPUs (AMD Radeon RX 7000 series).</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bayobug_hu9b64b2669cd2b09aac8db07473b744d6_3586653_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Mystic Mist (Bayonetta 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bayofix_huec0e9606966f439cac60f1a4b515bcd7_3552949_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Mystic Mist (Bayonetta 3)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mystic Mist (Bayonetta 3)</p> <p>Not intending to stop there, Blinkhawk also improved the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11389" data-gh-pr="11389">logic for discarding unnecessary writes</a> in the buffer cache, and improved how the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11393" data-gh-pr="11393">size of the index buffer</a> (where indices of vertices to form meshes is stored) is estimated. The result? A 69% or higher performance boost in <code>Bayonetta 3</code>, depending on the system specs. Nice.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bayo1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bayo1_hue6d9694de686db3eb78659e54002d7ad_2896407_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ara, ara (Bayonetta 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bayo2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bayo2_hu3d9bf3652d58a29dc848c2dac08e5cd4_2335367_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ara, ara (Bayonetta 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bayo3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bayo3_hu47203933dbbf0b985643a24234573e31_3445270_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ara, ara (Bayonetta 3)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Ara, ara (Bayonetta 3)</p> <p>byte[] discovered that yuzu’s implementation of nvnflinger, the service responsible for presenting to screen, was missing a scale mode option, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11281" data-gh-pr="11281">preserve aspect ratio.</a> Implementing it solves the rendering of <code>Gunvolt Chronicles Luminous Avenger iX</code> in its base version.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gunvolt.png" title=" Hell yeah, sprites! (Gunvolt Chronicles Luminous Avenger iX)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/gunvolt_hu261ee6cda1575c020bcbdd7727ba4f48_272658_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Hell yeah, sprites! (Gunvolt Chronicles Luminous Avenger iX)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hell yeah, sprites! (Gunvolt Chronicles Luminous Avenger iX)</p> </div> </div> <p>A user reported an unknown change from a long time ago was causing <code>AI: THE SOMNIUM FILES</code> to constantly crash. byte[] found the culprit was hiding in how mappings were being aligned during allocation but not deallocation, a bug originally discovered by ex-Skyline emulator developer <a href="https://github.com/skyline-emu/skyline/commits?author=bylaws">bylaws</a>. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11375" data-gh-pr="11375">Regression solved, game stable, case closed.</a> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ai.png" title=" Elementary, my dear user (AI: THE SOMNIUM FILES)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/ai_hudc09661f2b5ea0b96db2652c3e02a44d_1249250_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Elementary, my dear user (AI: THE SOMNIUM FILES)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Elementary, my dear user (AI: THE SOMNIUM FILES)</p> </div> </div> <p>And finally, to close this section with what is more of a build process change than a graphics code change, <a href="https://github.com/vonchenplus">vonchenplus</a> added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11302" data-gh-pr="11302">MoltenVK as an external dependency</a> to yuzu’s CMake settings, allowing Apple users to automatically get the latest version of this translation library when building yuzu on their Vulkan-starved machines. (AGXV, anyone?)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./m1.png" title=" Let’s begin with simple stuff (DRAGON QUEST III The Seeds of Salvation)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/m1_hu4ec7173b46c449cb6fc22a50ace7f7be_929323_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Let’s begin with simple stuff (DRAGON QUEST III The Seeds of Salvation)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Let’s begin with simple stuff (DRAGON QUEST III The Seeds of Salvation)</p> </div> </div> <p>Properly keeping up with MoltenVK updates allows macOS builds to run some basic games, but there’s still much to do to get the forbidden fruit company&rsquo;s devices up to speed.</p> <h2 id="opengl-specific-improvements-which-also-improve-vulkan">OpenGL-specific improvements, which also improve Vulkan</h2> <p>That’s right, Mesa and NVIDIA Fermi/Kepler users, it’s your turn to get some love. <a href="https://github.com/ameerj">Epicboy</a> is back with some great changes for the <del>old</del> classic API that started it all, OpenGL.</p> <p>First on the list is a major overhaul for GPU ASTC decoding, for both OpenGL and Vulkan APIs. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11149" data-gh-pr="11149">Code optimizations</a> in several areas of the compute shader-based decoder improved Vulkan ASTC decoding performance by up to 60%, but it made OpenGL on NVIDIA <em>15 times</em> faster, making it now slightly faster than Vulkan at decoding ASTC textures.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./astc.png" title=" Subtle jump"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/astc_hu4a44927b91dafd2e58d9b0cb91ea9a01_17208_721x0_resize_q90_bgffffff_box_3.jpg" alt=" Subtle jump"></a> <p class="has-text-centered is-italic has-text-grey-light"> Subtle jump</p> </div> </div> <p>GPUs which were left behind on Vulkan support can now enjoy much smoother performance in titles like <code>The Legend of Zelda: Tears of the Kingdom</code>, <code>Bayonetta 3</code>, <code>Luigi’s Mansion 3</code>, etc.</p> <p>To get the most out of this change, the <code>ASTC recompression</code> method must be set to <code>Uncompressed</code>, and <code>Enable asynchronous presentation</code> should be enabled if you’re using Vulkan. Both options can be found in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced</code>.</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> later <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11216" data-gh-pr="11216">blocked Mesa’s native ASTC decoder,</a> as it is now considerably slower than our implementation.</p> <p>And lastly, Epicboy solved what was a very common issue for <code>Pokémon Legends: Arceus</code> players before we made Vulkan the default API. Sit down, kids, it’s story time.</p> <p>In the not-so-far-away good old days, yuzu was only experimenting with an incomplete and immature Vulkan backend, there was no LDN/LAN support, and an Android release was considered to be a fever dream. Back then we used the OpenGL API by default, and out of its three options for shader backends, GLASM was the shader backend of choice, since it didn’t affect incompatible drivers — it’s an NVIDIA-only &ldquo;feature&rdquo; and any other driver would automatically revert to the vendor-agnostic GLSL. This provided NVIDIA users the best experience at the time, with the lowest shader build times available, until Vulkan improved enough to be the full replacement it is today.</p> <p>A very common report during these migration days was that character shading in <code>Pokémon Legends: Arceus</code> was wrong — it either introduced weird motes to characters, or they looked completely devoid of any form of lighting. This problem was quickly found to be rooted in GLASM.</p> <p>Since GLASM was, and continues to be, almost impossible to work on due to its complete lack of tools to debug and assist development, no developer wanted to touch it after Rodrigo introduced it. As he later left for greener pastures, this has resulted in our GLASM shader backend becoming entirely unmaintained.</p> <p>Well, enter 2023, and Epicboy rolled up his sleeves and got to work. He discovered that the issue was in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11282" data-gh-pr="11282">how GLASM handled transform feedback.</a> By implementing support for multiple transform feedback buffers, he has not only solved the issue in the only good main Pokémon release in the Switch (writer’s opinion, you can’t prove me wrong), but most likely many other modern Switch games that rely on transform feedback to render.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/plabug_hucb112d1bbc3bb40637f8e225dd3831ac_2785176_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Still good graphics for the Gamecube (Pokémon Legends: Arceus)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/plafix_hu1b1d752f43f1876e4d721e27c1bd1556_2778345_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Still good graphics for the Gamecube (Pokémon Legends: Arceus)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Still good graphics for the Gamecube (Pokémon Legends: Arceus)</p> <p>We hope our warriors still rocking the never-dying GTX 400 to 700 series GPUs benefit from these changes.</p> <h2 id="skyline-framework-part-3">Skyline framework: Part 3</h2> <p>After a long, <em>looong</em> wait, support for the <a href="https://github.com/skyline-dev/skyline">Skyline</a> framework, and with it, support for the <a href="https://github.com/Raytwo/ARCropolis">ARCropolis</a> modding framework for <code>Super Smash Bros. Ultimate</code> has finally landed! But we’re getting ahead of ourselves. Let’s see how byte[] made this possible.</p> <p>As part of implementing a security technique called ASLR (Address Space Layout Randomization), there is a large range of addresses that a program&rsquo;s code can be loaded at on the Switch. In fact, even though the Switch only has 4 GB of physical memory, the size of the region where program code can be virtually mapped can be as large as 512GB. Programs shouldn&rsquo;t make assumptions about where they are loaded inside the address space, because they can be shifted around anywhere inside this range on the console. As it turns out, the Skyline framework requires that the program not be loaded at the very start of the region, but yuzu always loaded it there, causing it to reliably crash. byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11326" data-gh-pr="11326">worked around this limitation of Skyline</a> by shifting the code load address further into the ASLR region, allowing room for it to operate.</p> <p>yuzu’s code responsible for handling service calls from guest code is not exactly in <em>ideal shape</em>. One particularly annoying issue from the early days of the emulator is a lock which prevents a service object from receiving concurrent requests from different sessions. Since the implementation is incorrect (the lock should not be present at all), but a lot of existing yuzu code depends on it, byte[] instead <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11327" data-gh-pr="11327">avoids locking only around calls to socket interfaces,</a> avoiding a deadlock when Skyline&rsquo;s TCP logger is active. More work remains to be done to remove this service lock once and for all.</p> <p>With these changes, the Skyline framework is operational, but a bit more work was needed to get ARCropolis up and running, and the Smash modding community happy. Thankfully, byte[] didn’t stop there, and continued implementing the required changes.</p> <p>ARCropolis used to incorrectly initiate the handshake when connecting to an SSL/TLS socket without first setting a hostname. This has been <a href="https://github.com/skyline-rs/rust-native-tls/commit/94134cd3bcf5b495d1be336b4b0e8c47399ae1a4">fixed</a> in ARCropolis’s dependencies, but most users have not updated yet to the corrected releases, so <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11328" data-gh-pr="11328">yuzu has to support this behaviour.</a> </p> <p>And lastly, yuzu was missing support for HTML manual mods, so byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11342" data-gh-pr="11342">implemented support for that</a> too.</p> <p>The end result after these few fixes is that most mods for Super Smash Bros. Ultimate are now working!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./arc1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/arc1_hubf25de628d2d8498e8a5a56fd584806b_141507_800x0_resize_q90_bgffffff_box_3.jpg" alt="Let the modding begin! (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arc2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/arc2_hu8a5d2954866c47f1708d48938c04606c_349195_800x0_resize_q90_bgffffff_box_3.jpg" alt="Let the modding begin! (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Let the modding begin! (Super Smash Bros. Ultimate)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./arc3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/arc3_hu56ebc3a9d514c5b88dc7d21b84a4ee4a_2576193_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bocchi-chan vs Melia, the fight of the century (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arc4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/arc4_hua82f5cc7f8780c9dc40bb4e025625352_2277753_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bocchi-chan vs Melia, the fight of the century (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arc5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/arc5_hude8a81e85cc5664b89ba1c4499bbc78d_2743524_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bocchi-chan vs Melia, the fight of the century (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Bocchi-chan vs Melia, the fight of the century (Super Smash Bros. Ultimate)</p> <p>Happy modding! <a href="https://gamebanana.com/tuts/14688">Here’s a tutorial</a> for those interested.</p> <h2 id="project-terra">Project Terra?</h2> <p>Yep, byte[] asked for a rename. From now on, Project Terra will be the name of the effort to fix the current virtual file system emulation implementation while Project Gaia is in the works.</p> <p>Why the rename? Because we have a lot of fixes to tell you about. To begin with, yuzu now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11284" data-gh-pr="11284">supports sparse and compressed NCA games!</a> This means a long list of titles whose eShop releases couldn’t previously boot are now either running or perfectly playable, and their RomFS can be fully dumped.</p> <p>Here’s a nowhere-close-to-complete list of now-working eShop titles:</p> <ul> <li><code>Splatoon 3</code></li> <li><code>Bayonetta 3</code></li> <li><code>Atelier Ryza 3: Alchemist of the End &amp; the Secret Key</code></li> <li><code>Double Dragon Gaiden: Rise of the Dragons</code></li> <li><code>OneShot: World Machine Edition</code></li> <li><code>Skullgirls: 2nd Encore</code></li> <li><code>Everdream Valley</code></li> <li><code>Magical Drop VI</code></li> <li><code>Hatsune Miku - The Planet Of Wonder And Fragments Of Wishes</code></li> <li><code>MLB The Show 23</code></li> <li><code>Sports Story</code></li> <li><code>Front Mission 1st: Remake</code></li> <li><code>Cursed to Golf</code></li> <li><code>Ruined King: A League of Legends Story</code></li> <li><code>Mega Man Battle Network Legacy Collection</code></li> <li>And many more!</li> </ul> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11309" data-gh-pr="11309">Support for gamecard dumps with a prepended key area</a> has been added too, thanks to byte[]. This allows using dumps with the option to dump the key area enabled.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bike1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bike1_hue813fdb7947f0eb981f6ddc3b9453e73_2164043_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nice bike (Fuuraiki 4)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bike2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bike2_hu58d530e8c840cb7efa106d244aa59f59_2052930_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nice bike (Fuuraiki 4)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bike3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/bike3_hu239e2b30935e579b06d1b3ff0c3cc3b3_3273350_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nice bike (Fuuraiki 4)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Nice bike (Fuuraiki 4)</p> <p>Installing updates and DLC for multi-program applications (such as a game launcher with several games inside) didn&rsquo;t work properly on yuzu. This meant games like <code>Super Mario 3D All-Stars</code> would only launch the base game version no matter what the user did. The current virtual file system implementation can’t properly support this, which is one of the many areas Project Gaia is geared to fix. To bypass this limitation, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11319" data-gh-pr="11319">creates synthetic update metadata</a> inside yuzu, allowing the update/DLC to pass through and load correctly.</p> <p><a href="https://github.com/FearlessTobi">FearlessTobi</a> fixed <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11367" data-gh-pr="11367">an <em>old</em> regression</a> affecting how the game’s size is displayed on the game list when using games dumped with an outdated method. How old is the regression? Well, it’s 5 years old by now.</p> <p>FearlessTobi also fixed a bug in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11370" data-gh-pr="11370">how an error is handled</a> when a game tries to rename a file to a name that already exists. This was causing <code>GRID Autosport</code> to crash on boot.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./grid.png" title="Running in the 90s (GRID Autosport)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/grid_hubc7d2610c4cf4a5c735965c9cc751a05_1764514_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Running in the 90s (GRID Autosport)"></a> <p class="has-text-centered is-italic has-text-grey-light">Running in the 90s (GRID Autosport)</p> </div> </div> <p>Not stopping there, FearlessTobi also fixed yuzu&rsquo;s command line arguments to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11371" data-gh-pr="11371">properly load updates and DLC</a> when booting a game — for example, when using a script.</p> <p>Users reported that some RomFS dumps from games don’t always include all game assets, with one example being <code>KLONOA Phantasy Reverie Series</code>. byte[]’s investigation showed that several areas of the RomFS dump code were… of low quality. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11381" data-gh-pr="11381">After a moderate rewrite,</a> RomFS dumps of multi-title games should now include all assets.</p> <h2 id="audio-input-and-core-changes">Audio, input, and core changes</h2> <p>Let’s start with the sole input change of this progress report. <a href="https://github.com/german77">german77</a> almost broke his streak!</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11406" data-gh-pr="11406">Updating SDL to version 2.28.2</a> fixed issues affecting Xbox controller trigger motion events and their rumble while the program runs in the background. 8BitDo gamepad mapping while in XInput mode was fixed for Linux. And a controller lockup that happened when initialising some unofficial PS4 controllers is now fixed.</p> <p>Some users&rsquo; machines have improperly configured audio devices, which can lead to games locking up on boot. This lovely behaviour forced Maide to work on a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11359" data-gh-pr="11359">test to run early in the boot process</a> to see which audio backend can properly start the audio device. If the device fails to initialise with both cubeb and SDL, the null backend is selected and the game continues to work, just without any audio output.</p> <p>If you find that a game has no audio but is otherwise working, you should check your drivers, check any intermediate programs like equalisers, and check your OS settings for issues.</p> <p>Opus is a lossy open-source and royalty-free (as it always should be) audio format used by several games. Like with the VP9 video format, its implementation in yuzu is not as simple as just playing the file. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11390" data-gh-pr="11390">By implementing</a> the <code>OpenHardwareOpusDecoderForMultiStreamEx</code> and <code>DecodeInterleavedForMultiStream</code> service methods (Opus multistream support), FearlessTobi ensured games like <code>MLB The Show 22</code> are now playable.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11419" data-gh-pr="11419">Implementing</a> the <code>GetWorkBufferSizeExEx</code> service method, on the other hand, allowed <code>Sea of Stars</code> to boot.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./sos1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/sos1_hu9c48c8afb78fa6d83a858c88386b4408_451499_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nothing beats the look of a classic RPG (Sea of Stars)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sos2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/sos2_huea34c75a5328341b54610ad12323804a_2286131_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nothing beats the look of a classic RPG (Sea of Stars)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sos3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/sos3_huf3c87ec5a6cfa44184da37aa7291627f_1801445_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nothing beats the look of a classic RPG (Sea of Stars)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sos4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/sos4_hub66b7a38bc8fabc48b8fecb4d0974842_2058456_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nothing beats the look of a classic RPG (Sea of Stars)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Nothing beats the look of a classic RPG (Sea of Stars)</p> <p>If anyone experienced audio related crashes (specifically related to audio effects) in games like <code>The Legend of Zelda: Tears of the Kingdom</code>, <code>SUPER MARIO ODYSSEY</code>, and some others, well, with the help from <a href="https://github.com/ChiefGokhlayeh">ChiefGokhlayeh</a>, Maide <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11408" data-gh-pr="11408">found the broken node Id index</a> that caused the problem.</p> <p>Still fighting the war of shutting down yuzu in a sensible manner, byte[] changed the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11384" data-gh-pr="11384">shutdown timeout</a> to more closely match the behaviour of the Switch. Most games now exit within one second.</p> <p>Another area where shutting down has improved, this time related to the Skyline framework, is cancelling pending socket operations caused by the TCP logger. One of the operations can remain waiting for a host to be accepted. This will never complete once a shutdown event is triggered, so <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11385" data-gh-pr="11385">a swift termination is issued</a> now.</p> <h2 id="android-augmentation">Android augmentation</h2> <p>Besides all previously reported changes, Android got its share of specific bugfixes and UI changes too, courtesy of <a href="https://github.com/t895">t895</a>:</p> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11271" data-gh-pr="11271">Miscellaneous settings tweaks,</a> including displaying settings values in list view, reducing the opacity of non-editable settings, removing some unnecessary default buttons in slider dialogs, and a few other minor changes.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./grey.png" title="These settings can&#39;t be changed while running a game"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/grey_hu5e489adbb11a44387c25ab72d8a562c9_41274_389x0_resize_q90_bgffffff_box_3.jpg" alt="These settings can&#39;t be changed while running a game"></a> <p class="has-text-centered is-italic has-text-grey-light">These settings can&#39;t be changed while running a game</p> </div> </div> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11272" data-gh-pr="11272">Show associated values for home settings.</a> </li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11273" data-gh-pr="11273">Changes to the initial setup,</a> showing if a step was completed, and automatically moving to the next page on completion.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./setup.gif" title="Easier setup!"><img src="./setup.gif" alt="Easier setup!"></a> <p class="has-text-centered is-italic has-text-grey-light">Easier setup!</p> </div> </div> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11337" data-gh-pr="11337">Automatically rotate the screen</a> between landscape and reverse-landscape.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11352" data-gh-pr="11352">Search for programs up to 3 subfolders deep.</a> </li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11378" data-gh-pr="11378">Use appCategory to report yuzu as a game.</a> This should improve game launcher detection, but surprisingly, it’s not enough to make Samsung’s Game Launcher detect yuzu.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11380" data-gh-pr="11380">A settings rework,</a> including better material animations, hiding paired options, adding a settings search function, and improving restore states for dialogs properly.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./setting1.gif" title=""><img src="./setting1.gif" alt="Cleaner and more functional"></a> </div> <div class="column is-bottom-paddingless"> <a href="./setting2.gif" title=""><img src="./setting2.gif" alt="Cleaner and more functional"></a> </div> <div class="column is-bottom-paddingless"> <a href="./setting3.gif" title=""><img src="./setting3.gif" alt="Cleaner and more functional"></a> </div> <div class="column is-bottom-paddingless"> <a href="./setting4.gif" title=""><img src="./setting4.gif" alt="Cleaner and more functional"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Cleaner and more functional</p> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11392" data-gh-pr="11392">Fixing some activity issues,</a> like the surface appearing stretched when changing orientation, or starting a game in landscape mode and then switching to portrait.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11405" data-gh-pr="11405">Adding new loading and closing animations.</a> </li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./load.gif" title=""><img src="./load.gif" alt="Showing the progress"></a> </div> <div class="column is-bottom-paddingless"> <a href="./close.gif" title=""><img src="./close.gif" alt="Showing the progress"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Showing the progress</p> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11413" data-gh-pr="11413">Support intents to emulation activity,</a> so users can launch games from other apps like Daijishō.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dai.gif" title="For those who prefer it"><img src="./dai.gif" alt="For those who prefer it"></a> <p class="has-text-centered is-italic has-text-grey-light">For those who prefer it</p> </div> </div> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11416" data-gh-pr="11416">Adding the ability to create dynamic app shortcuts,</a> so users can make per game icons.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./icon.gif" title="A faster way to get in-game!"><img src="./icon.gif" alt="A faster way to get in-game!"></a> <p class="has-text-centered is-italic has-text-grey-light">A faster way to get in-game!</p> </div> </div> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11420" data-gh-pr="11420">Fixing a bug in the game content installer</a> that would lead to a crash when trying to install an update or DLC.</li> <li>And more!</li> </ul> <p>Also joining forces in the Android effort, byte[] fixed a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11357" data-gh-pr="11357">virtual file system bug</a> that made any game with updates installed fail to boot after merging his earlier changes to support compressed and sparse NCAs.</p> <h2 id="desktop-ui-improvements">Desktop UI improvements</h2> <p>The desktop side of things also got its share of developer love.</p> <p>Newcomer <a href="https://github.com/mdmrk">mdmrk</a> brings us a very requested feature: <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10519" data-gh-pr="10519">per-game play time tracking!</a> It’s shown in the game list as a new column. Thank you!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./time.png" title="Power level reading"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/time_hudb5491ebc34c900011bbb66abb4ede94_4525_272x0_resize_q90_bgffffff_box_3.jpg" alt="Power level reading"></a> <p class="has-text-centered is-italic has-text-grey-light">Power level reading</p> </div> </div> <p>Since the introduction of the screenshot feature, yuzu has only saved captures in a 16:9 aspect ratio, regardless of the selected aspect ratio in graphics settings. Also, the resolution of the captures was always based on the chosen resolution multiplier value; if 2x was in use, any capture while playing in docked mode would be 3840x2160 in size.</p> <p>With motivation from some recent mods that bypass our scaler and render games in 1x resolution directly at 4K, toastUnlimited added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11303" data-gh-pr="11303">configuration options for screenshot resolution,</a> along with considering the aspect ratio selected by the user. Now users can set the screenshot resolution in <code>Emulation &gt; Configure… &gt; General &gt; UI &gt; Resolution</code>. Auto will use the previous logic of using the resolution multiplier value, but many other resolution options can be picked. Additionally, what the user selects in <code>Emulation &gt; Configure… &gt; Graphics &gt; Aspect Ratio</code> will determine the aspect ratio and resulting resolution of the screenshots. Feel free to experiment, and save your best gameplay moments!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./res.png" title="A picture is worth a thousand words"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/res_hu4ad0ac5a022a571e979d4a2090e77096_26456_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A picture is worth a thousand words"></a> <p class="has-text-centered is-italic has-text-grey-light">A picture is worth a thousand words</p> </div> </div> <p>Per-game settings are a great way to customise the settings and mods of each game. One option in a weird spot was <code>Console mode</code> — whether a game was played in docked or handheld mode. The old implementation relied on controller profiles: the user would set some controller mapping, the type of controller, the console mode, save all of this as a profile, and then set each game to use the preferred controller profile. The problem with this approach is that it forces users to save different controller profiles, when in most cases a single one is used, for example, a Pro Controller profile using a Sony Dual Sense. To simplify this particular situation, toastUnlimited <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11356" data-gh-pr="11356">added a Console Mode to the per-game system properties.</a> Much easier, right?</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./console.png" title="For even more customisation"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/console_hu5c1ab4c4d573ece6e9cd2b3a8d8dd3d4_151350_902x0_resize_q90_bgffffff_box_3.jpg" alt="For even more customisation"></a> <p class="has-text-centered is-italic has-text-grey-light">For even more customisation</p> </div> </div> <h2 id="hardware-section">Hardware section</h2> <p>This section has been pretty calm lately. For the most part, drivers have been behaving and not introducing critical regressions recently, and the Mesa Turnip driver for the Adreno Android players has been progressing healthily. It’s not fully stable yet, but rendering and performance are in a good spot. There’s only one vendor to discuss this time, and it is…</p> <h3 id="amd-and-the-d24-situation">AMD, and the D24 situation</h3> <p>We continue our investigations into how to deal with the lack of hardware support for the D24 depth format on Red Team hardware.</p> <p>Some fun and totally-not-evil experiments (faking lack of support with an RTX 3060 Ti) proved that while the D24 glitches are easy to reproduce on compatible hardware by just commenting out some lines, we also confirmed that the vertex explosions affecting <code>Xenoblade Chronicles 3</code> in its DLC, <code>Future Redeemed</code>, and in the <code>Pentelas region</code> of the main game are <em>not</em> caused by the lack of D24 on AMD cards. Any other GPU vendor with D24 support disabled renders those sections perfectly fine, leaving us again with no clue on what Radeon GPUs hate about this particular game.</p> <p>On Windows, OpenGL continues to be the only alternative for Red Team users for the time being. Mesa, on the other hand, seems to have solved the issue (at least on Polaris hardware) with their latest version, so &ldquo;just use Linux&rdquo; seems to be a way to fix an AMD-specific problem once again.</p> <p>But it’s not all bad news! A new Vulkan extension, <code>VK_EXT_depth_bias_control</code>, which is for now only available on the Linux Mesa RADV driver, allows yuzu to properly fake D24 support, fixing the rendering issues on games like <code>Pokémon Sword &amp; Shield</code>, <code>Super Smash Bros. Ultimate</code>, and <code>Mario Tennis Aces</code>, among others.</p> <p>Blinkhawk <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11402" data-gh-pr="11402">added a preliminary implementation</a> supporting <code>VK_EXT_depth_bias_control</code> to yuzu for testing. We hope AMD adds support for it in their Windows drivers, as it is known they use the feature internally for OpenGL.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/d24bug_hue53718eabe28dba94c039d4b60802912_62957_306x0_resize_q90_bgffffff_box_3.jpg" alt="Hardware support for the right formats matters (Pokémon Sword)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2023/d24fix_hu570de75242439608c32cd571bf6d3255_61239_285x0_resize_q90_bgffffff_box_3.jpg" alt="Hardware support for the right formats matters (Pokémon Sword)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hardware support for the right formats matters (Pokémon Sword)</p> <p>As a small anecdote about <code>Super Smash Bros. Ultimate</code>, we had to hardcode a value to allow AMD cards to render this game not long after the introduction of our Vulkan API. The story with D24 has been with us since the very beginning.</p> <h3 id="samsung-xclipse-920">Samsung Xclipse 920</h3> <p>Technically it is the same vendor, right?</p> <p>Recent changes in which Vulkan extensions are mandatory and which are optional made this AMD RDNA2-based GPU work with the Android releases, adding another compatible vendor to the group of decent-enough SoC GPUs, along with Adreno and Mali. Exynos 2200 users can now enjoy their Switch games on their Android devices!</p> <h2 id="future-projects">Future projects</h2> <p>Blinkhawk is back to proposing ideas which are so crazy, we could never properly explain them here. And both byte[] and Morph are cooking interesting projects for after they finish their current challenges.</p> <p>That’s all folks! Thank you for taking the time to read until the end. We hope to see you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report July 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/ Sun, 13 Aug 2023 06:45:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/ <p>Hey there, yuz-ers! Welcome back to our monthly report on all the improved features, performance gains, and bug fixes we&rsquo;ve made. Let&rsquo;s jump right in!</p> <p>Hey there, yuz-ers! Welcome back to our monthly report on all the improved features, performance gains, and bug fixes we&rsquo;ve made. Let&rsquo;s jump right in!</p> <h2 id="aliens-and-ghosts-are-real-and-they-run-on-unreal-engine">Aliens and ghosts are real&hellip; and they run on Unreal Engine!</h2> <p>The wait was long, but worth it. Another game in the charming Pikmin franchise has finally arrived on Earth, just in time to join the wave of UFO reports!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pk1.png" title=" Imagine a crossover with Toy Story, it would explain The Claw! (Pikmin 4)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/pk1_hufc562064b79b78961620c4bb28ec9db0_6240508_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Imagine a crossover with Toy Story, it would explain The Claw! (Pikmin 4)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Imagine a crossover with Toy Story, it would explain The Claw! (Pikmin 4)</p> </div> </div> <p>This time, <code>Pikmin 4</code> decided to use Unreal Engine 4, which guarantees good performance and quality on the Switch. However, this engine also guarantees headaches for emulating its use of sparse textures, as well as guaranteeing instability for NVIDIA GPU users running Vulkan, as previous games have demonstrated.</p> <p><a href="https://github.com/liamwhite">byte[]</a> identified and fixed a regression caused by a recent change to the texture cache which severely <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11093" data-gh-pr="11093">impacted stability</a> on NVIDIA GPUs, causing constant device losses (the driver cutting off the GPU from rendering, resulting in an emulator crash).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pk2.png" title=" Moss seems tired (Pikmin 4)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/pk2_hu280adb40647340e464734650ebe2cc67_7167249_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Moss seems tired (Pikmin 4)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Moss seems tired (Pikmin 4)</p> </div> </div> <p><a href="https://github.com/GPUCode">emufan</a> found that hardcoding the total number of texture buffers to <code>16</code> was causing crashes in some Unreal Engine 4 games and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11098" data-gh-pr="11098">bumped up the count</a> to <code>32</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rain1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/rain1_hu7c7bddc6faf00a12340de6bdc19272d8_2372816_800x0_resize_q90_bgffffff_box_3.jpg" alt="Good thing this game didn&#39;t cross paths with Pikmin (Master Detective Archives: RAIN CODE)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rain2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/rain2_hua9e34870ada7726c14ab686b4709328c_1820347_800x0_resize_q90_bgffffff_box_3.jpg" alt="Good thing this game didn&#39;t cross paths with Pikmin (Master Detective Archives: RAIN CODE)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Good thing this game didn&#39;t cross paths with Pikmin (Master Detective Archives: RAIN CODE)</p> <p>This change has not only helped <code>Pikmin 4</code> but also <code>Master Detective Archives: RAIN CODE</code>, another recent release using this same engine.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./rain3.png" title=" Yeah, good name for a train, I&#39;ll board it in Dracula Station (Master Detective Archives: RAIN CODE)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/rain3_hu01aca6352955257bb8bbc9e60c72e0f8_1184169_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Yeah, good name for a train, I&#39;ll board it in Dracula Station (Master Detective Archives: RAIN CODE)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Yeah, good name for a train, I&#39;ll board it in Dracula Station (Master Detective Archives: RAIN CODE)</p> </div> </div> <p>Many things have improved, but there&rsquo;s still a lot of work remaining to improve the compatibility of games using this popular game engine!</p> <h1 id="per-game-configurations---reimagined">Per-game configurations - Reimagined!</h1> <p>If you&rsquo;re experienced with yuzu, it is very likely that you&rsquo;ve seen and used per-game configurations. But if you didn&rsquo;t know, yuzu supports per-game configurations as an easy way to set game-specific settings, without having to change your global settings for every game you start. For the games which require GPU accuracy to be high instead of normal, or for games which work best with OpenGL over Vulkan, per-game configurations allow you to easily override settings like these.</p> <p>So, what&rsquo;s new, you ask? The brains behind this feature&rsquo;s implementation and our trusty slice of toast, <a href="https://github.com/lat9nq/">toastUnlimited</a>, has started working towards a future where yuzu could select a game-specific configuration file curated by the community, and then apply those settings by default! The ultimate goal is for users to be able to apply the optimal settings for any game by default, without having to tinker with the many, many configuration options we have today.</p> <p>Sounds exciting, right? Heck yeah! While toast was finalizing his designs, he quickly ran into a road-block of his own design: our current per-game configuration system. The existing system&rsquo;s design made it difficult to programmatically define and override each setting in multiple places across yuzu&rsquo;s backend and frontend systems.</p> <p>toast decided to take the challenge head-on and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10839" data-gh-pr="10839">rewrote the entire settings backend</a> to improve it, all while making it programmatically easier to define and implement any setting. Thanks to these changes, developers now only need to write out the UI text for a setting and the system will do the rest (reading, writing, representing in the UI, resetting global state).</p> <p>This also had the benefit of providing the perfect opportunity to rework several parts of the global settings UI! For example, System settings now includes <code>Multicore CPU Emulation</code> support, all three possible values for <code>Memory Layout</code>, and <code>Limit Speed Percent</code>.</p> <p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/systembug_hu71b90e17443a51d03e00fbbd90381f8e_17384_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Important changes to System settings"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/systemfix_hu9b8a2568b26f439d5261d0b0f1ec52e9_19518_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Important changes to System settings"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Important changes to System settings</p>  </p> <p>The Graphics section also got its fair share of changes. Besides reorganizing the different options, the new <code>ASTC Decoding Method</code> option now lists our 3 different alternatives for handling that pesky ASTC format: CPU, GPU, and asynchronous CPU decoding.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/gpubug_hu51361a3697cb9689613b7cb94853883e_23864_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Graphics settings also got some love"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/gpufix_hu9002f93ffee13ea56d2fcf7bdb221741_24489_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Graphics settings also got some love"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Graphics settings also got some love</p> <p>There are plenty of changes here, but enough about the global settings! toast also changed how per-game configurations are updated. They will now show an X button on the right of each setting if they were modified from the global value, allowing you to quickly revert them if needed.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/custombug_hua89e2502b02d47ea4a59be952645bd64_171712_902x0_resize_q90_bgffffff_box_3.jpg" alt="Graphics settings also got some love"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/customfix_huda7dd7295aae9ba7167ffb1aa2086f85_169059_902x0_resize_q90_bgffffff_box_3.jpg" alt="Graphics settings also got some love"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Graphics settings also got some love</p> <p>Stay tuned for follow-up changes to our settings, building on top of this new foundation!</p> <h1 id="graphics-changes">Graphics changes</h1> <p><a href="https://github.com/Kelebek1">Maide</a> continued his efforts to improve performance through optimization and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10996" data-gh-pr="10996">his latest changes further optimize</a> one of his <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10457" data-gh-pr="10457">earlier optimizations.</a> We heard you like optimizations, so we put optimizations in your optimizations so you can optimize while you optimize. While the original changes aimed to reduce memory allocations while copying data from the guest to the host (user&rsquo;s PC), the latest changes remove data copying entirely, resulting in nearly 10% performance boost in parts of <code>Super Mario Odyssey</code>, such as the Metro Kingdom area. <code>Xenoblade Chronicles: Definitive Edition</code> also sees similar gains.</p> <p>byte[]&rsquo;s <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11136" data-gh-pr="11136">latest fix</a> significantly improves the slowest shader compilation times in <code>Splatoon 3</code>, reducing it from <code>30 seconds</code> to about <code>4 seconds</code>. A <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10583" data-gh-pr="10583">recent change to our texture cache&rsquo;s <code>AccelerateDMA</code> logic</a> was identified to have been causing device losses and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10993" data-gh-pr="10993">has been since been reverted.</a> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sp3.png" title=" She calls it Sasha (Splatoon 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/sp3_hu7ff3925acc9ddbbf9d8d2db2bdcb3faf_1367902_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" She calls it Sasha (Splatoon 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> She calls it Sasha (Splatoon 3)</p> </div> </div> <h1 id="input-changes">Input Changes</h1> <p><a href="https://github.com/german77">german77</a> continued his reverse engineering of the Switch NFC service and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11096" data-gh-pr="11096">improved yuzu&rsquo;s code accuracy.</a> He also fixed a bug, which would cause mice to stop working after some time, by avoiding an accidental division by zero.</p> <p>Newcomer <a href="https://github.com/SuperSamus">SuperSamus&rsquo;s</a> first contribution to yuzu was to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11050" data-gh-pr="11050">remove a workaround on button mapping within yuzu</a> which used to invert the face buttons mapping. With these changes, SDL properly uses the native A/B and X/Y mapping of Nintendo devices. Thank you!</p> <p>Note: This change <strong>BREAKS</strong> controller configurations for those using Nintendo controllers without the direct driver.</p> <h1 id="android-changes">Android changes</h1> <p><a href="https://github.com/bunnei/">bunnei</a> implemented changes to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11017" data-gh-pr="11017">fix an issue where Turnip drivers would fail</a> on certain Snapdragon devices and added checks for broken Qualcomm 7xx drivers. This means that any Snapdragon user should be able to run Turnip drivers now. Links are provided in the Hardware section later in this article.</p> <p><a href="https://github.com/t895">t895</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11067" data-gh-pr="11067">disabled the prompt to save user data when uninstalling yuzu.</a> This feature often caused issues when users attempted to use different APK versions.</p> <p>t895 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11070" data-gh-pr="11070">added some helpful error prompts</a> to inform users why certain buttons were disabled on some devices. The most common case is Mali or Xclipse users trying to install custom drivers, a feature that is only available for Adreno users, at least for now.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mali.png" title=" Your Mesa driver is in another castle"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2023/mali_hu7b35479ec860e50e23062372701462c2_105413_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Your Mesa driver is in another castle"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your Mesa driver is in another castle</p> </div> </div> <h1 id="miscellaneous-changes">Miscellaneous changes</h1> <p>Apart from the ones highlighted above, there have also been several smaller changes that don&rsquo;t necessarily fit nicely into a single category. So let&rsquo;s quickly discuss them below:</p> <p><a href="https://github.com/FearlessTobi">FearlessTobi</a> added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11047" data-gh-pr="11047">detection for compressed and sparse NCAs within yuzu&rsquo;s filesystem.</a> Instead of failing silently, yuzu will now log this info and abort the parsing.</p> <p>toast added a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11042" data-gh-pr="11042">new Linux build script which added the libraries required to enable <code>Wayland</code> support</a> in our official AppImage releases.</p> <p>Not stopping there, toast <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11186" data-gh-pr="11186">fixed a memory leak with the new timezone data generator.</a> This would happen when games tried to ask for timezone information too many times. This was resolved by keeping track of the generated timezone binary instead of recreating it repeatedly.</p> <p>toast also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11030" data-gh-pr="11030">bypassed an MSVC build crash</a> on <code>Windows version 10 1809 LTSC</code> from the new timezone binary changes by temporarily disabling it for MSVC until there is a solution from Microsoft. The reason, for those interested, is <a href="https://github.com/microsoft/STL/issues/3853#issuecomment-1627630752">documented here</a>.</p> <p>byte[] implemented missing service functions, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11113" data-gh-pr="11113">fixing a bug that caused <code>Quake</code> to fail to launch,</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11135" data-gh-pr="11135">fixed a bug that resulted in <code>Splatoon 3</code> having an endless loading screen when LAN was enabled.</a> </p> <p>byte[] also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11016" data-gh-pr="11016">fixed an issue within yuzu&rsquo;s filesystem</a> which resulted in either corrupt save data or failing to save data.</p> <p>A previous merge caused games with non-ASCII titles to crash on Linux due to <code>DBus</code> expecting a <code>UTF8</code> string. This has now been <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11007" data-gh-pr="11007">fixed.</a> Thanks <a href="https://github.com/zeltermann">zeltermann</a>!</p> <p><a href="https://github.com/Morph1984">Morph</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10999" data-gh-pr="10999">fixed a bug that broke the game installation progress bar</a> after the recent buffer size increase by refactoring the progress bar calculation code.</p> <p>Morph also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11173" data-gh-pr="11173">fixed a bug where yuzu would crash on systems with weak CPUs running at very low clock speeds</a> due to yuzu&rsquo;s strict requirements on CPU clock precision.</p> <p>german77 eliminated almost 2GB of memory usage in some circumstances by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11128" data-gh-pr="11128">fixing a memory leak within Discord presence code,</a> presumed to be caused by <code>cpp-httplib</code>.</p> <p>german77 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11142" data-gh-pr="11142">fixed a crash in yuzu&rsquo;s gamelist</a> that happened when you launched yuzu without keys.</p> <p>yuzu newcomer and Citra expert, <a href="https://github.com/Steveice10">Steveice10</a>, implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10974" data-gh-pr="10974">a few improvements to Vulkan surface creation on macOS.</a> <a href="https://github.com/comex">comex</a> submitted <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10990" data-gh-pr="10990">a few fixes and workarounds for macOS to resolve a few undefined behaviour errors.</a> Thank you both! This doesn&rsquo;t mean full MoltenVK support yet, but the gap is now smaller.</p> <h2 id="hardware-section">Hardware section</h2> <h3 id="nvidia">NVIDIA</h3> <p>The latest driver released at the time of writing, 536.99, is stable and also seems to have improved Vulkan performance a small but measurable amount, between 3% and 7%. Free performance is free performance.</p> <h3 id="amd">AMD</h3> <p>It&rsquo;s July and we have another new AMD GPU driver with yet another extension causing issues. If you recall from our <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/#amd">June progress report</a>, we reported that the latest AMD drivers had broken a Vulkan feature - <code>extendedDynamicState3ColorBlendEquation</code>, and we had to temporarily disable usage of it on AMD driver version <code>23.5.2</code> and above.</p> <p>Fast-forward to July, and it&rsquo;s still broken for some. Giving credit where due, AMD <em><strong>did</strong></em> fix this issue with driver version <code>23.7.2</code>, but only for <code>RDNA2</code> GPUs (RX 6000 series). <code>GCN4</code>, also known as <code>Polaris</code> (RX 400 and 500 series), are confirmed to still be broken. In light of this, and the fact that the fixed driver still reports the same Vulkan version, we <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11182" data-gh-pr="11182">reverted</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11163" data-gh-pr="11163">our revert</a> of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10946" data-gh-pr="10946">our original change from June</a> and have <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11204" data-gh-pr="11204">currently disabled usage of this extension on all AMD official drivers</a> until this is fixed and has a new version number.</p> <h3 id="turnip">Turnip</h3> <p>Mesa never slows down its progress, and <a href="https://github.com/K11MCH1">K11MCH1&rsquo;s</a> AdrenoTools releases are a true blessing from the fairies.</p> <p>For Adreno 600 users (Snapdragon ### series), <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/vk.1.3.261-A6XX">progress is steady</a>. But the <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v23.3.0-dev">best news</a> is for A700 users (Snapdragon # Gen # series), which now see much improved rendering and performance on the Mesa Turnip drivers.</p> <p>Some games still require the proprietary Adreno driver to be more stable or faster, but at this rate of progress, we’ll most likely see this change soon!</p> <h2 id="future-projects">Future projects</h2> <p>Behind the counter, there has been great progress in some key projects. The last missing piece of <code>Project Y.F.C.</code>, the <code>Query Cache Rewrite</code>, was released but we&rsquo;ll talk about it next time. We&rsquo;re sure Xenoblade and Luigi&rsquo;s Mansion fans will love it! byte[] continues to improve the current file system emulation — maybe some particular games will start working soon? And Maide has some interesting ideas to implement in the shader cache code.</p> <p>That&rsquo;s all folks! Thank you for reading until the end. See ya next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report June 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/ Mon, 10 Jul 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/ <p>Hello again, yuz-ers! Our devs, old and new, show no signs of slowing down. This month we have general performance and stability improvements, many graphics bug fixes, Android gets its first wave of improvements, and much more! Helmets on, let’s ride.</p> <p>Hello again, yuz-ers! Our devs, old and new, show no signs of slowing down. This month we have general performance and stability improvements, many graphics bug fixes, Android gets its first wave of improvements, and much more! Helmets on, let’s ride.</p> <p>Before we dive into the report, we have some important news to share. We&rsquo;ve received reports that some users have been experiencing crashes when trying to use Vulkan or change settings. The culprit is <code>Overwolf</code>, a mod manager/overlay that comes with a faulty and outdated Vulkan layer, messing up the GPU’s Vulkan driver. We strongly advise users to uninstall Overwolf until they have fixed their Vulkan layer.</p> <p>Now that we’ve cleared that up, let’s get started.</p> <h2 id="illusion-of-time">Illusion of Time</h2> <p>While we implement many features of the Switch operating system, and can boot most games without a firmware dump, some games still require one. This is necessary for things like Mii models or to properly render foreign scripts and button fonts. The firmware files also include the resources needed for proper time zone support.</p> <p>Thanks to the amazing work of <a href="https://github.com/lat9nq">toastUnlimited</a>, yuzu <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10603" data-gh-pr="10603">now ships with</a> virtually all <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10797" data-gh-pr="10797">time zone data</a> that the Switch has by default!</p> <p>In the past, yuzu would pretend that the system was in GMT, and then adjust the universal time by the local offset on the guest. While this usually worked, it’s not accurate to how the Switch reports times.</p> <p>The default “Auto” time zone setting will now send a location-accurate time zone to the guest (instead of following the old GMT rule) using the synthesised time zone archive. The new system also sends a correct representation of the universal time, regardless of whether there is a firmware dump or not.</p> <p>Now, while Linux had few issues with the new system (aside from a frustrating issue with Flatpak), Windows has some specific requirements. There are two important things to keep in mind:</p> <ul> <li>When the changes were released, users needed to run at minimum a 2019 version of Windows 10, with 1809 no longer compatible. For LTSC users, this meant only the newest 2021 release would work. We later <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11030" data-gh-pr="11030">implemented a solution</a> for this. If you&rsquo;re running Windows LTSC 1809, or for some reason blocked Windows Update on a regular Windows version, remember to update to the latest yuzu version.</li> <li>You need the latest Visual C++ 2022 redistributable. Download it from this link: <a href="https://aka.ms/vs/17/release/vc_redist.x64.exe">https://aka.ms/vs/17/release/vc_redist.x64.exe</a></li> </ul> <p>Don’t forget to set your clock correctly!</p> <h2 id="graphics-changes">Graphics changes</h2> <p>This month has been full of GPU changes, so let’s start with a <em>simple</em> one.</p> <p>There’s never rest for the wicked, so <a href="https://github.com/FernandoS27">Blinkhawk</a> makes good use of that extra time doing what he does best: pulling big changes out of thin air. In this case, he investigated what happens if a memory page is being used by the GPU and written by the CPU at the same time. Lovely little bugs that have been haunting us for half a decade, that’s what happens!</p> <p>What Blinkhawk adds here is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10942" data-gh-pr="10942">a mechanism to register small CPU writes</a> that sneak through while the page is being accessed by the GPU, properly invalidating the page if needed. The following bugs have now been fixed as a result:</p> <ul> <li>Fixes the vertex explosions affecting <code>Pokemon Scarlet &amp; Violet</code>. Use High GPU accuracy.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./scarletbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./scarletfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No explosions near the Academy, Megumin! (Pokémon Scarlet)</p> <ul> <li>Fixes the slow rain and snow particles in <code>The Legend of Zelda: Breath of the Wild</code> &amp; <code>The Legend of Zelda: Tears of the Kingdom</code>.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./rainbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./rainfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It’s raining Chuchus out there (The Legend of Zelda: Tears of the Kingdom)</p> <ul> <li>Fixes some particle corruption exclusive to <code>Tears of the Kingdom</code> seen, for example, while teleporting.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./telebug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./telefix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It’s not perfect yet, but it’s almost there (The Legend of Zelda: Tears of the Kingdom)</p> <ul> <li>Fixes the erratic movement of some particles in <code>SUPER MARIO ODYSSEY</code>.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smobug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smofix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Even the particles dance in this game (SUPER MARIO ODYSSEY)</p> <ul> <li>Fixes the hilariously wrong eyebrows affecting some characters in <code>Xenoblade Chronicles 3</code>, like Noah and Sena. Writer’s note: I will miss this one, it was fabulous.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xc3bug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xc3fix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hey, Noah’s eyes are up here (Xenoblade Chronicles 3)</p> <ul> <li>Fixes the corrupted save thumbnails in <code>Xenoblade Chronicles: Definitive Edition</code>.</li> </ul> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/picbug_hu19d8bf186ca84dab29b63c56628a4cb9_2153077_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That’s Dunban over there! (Xenoblade Chronicles: Definitive Edition)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/picfix_hua1e36c572adbfce31cc9245747260022_2347332_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That’s Dunban over there! (Xenoblade Chronicles: Definitive Edition)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That’s Dunban over there! (Xenoblade Chronicles: Definitive Edition)</p> <ul> <li>And more!</li> </ul> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10783" data-gh-pr="10783">Here’s some good news for the low-RAM folks!</a> <p>Since native Switch game shaders can’t be run directly on the user’s GPU, yuzu has to recompile them into an intermediate representation (IR) which is a middle format that can be optimized and then converted to a shader that users&rsquo; GPU drivers can actually handle (SPIR-V/GLSL/GLASM). For performance reasons, a significant amount of memory is preallocated to store these blocks of IR, and the old implementation would use 34MB per thread, twice.</p> <p>68MB per thread may not seem like a lot, right? But this allocation is made as many times as the total thread count of the CPU, SMT included. With some quick maffs, you can see that a Ryzen 3600 would gobble up 816 MB of system RAM, a Ryzen 7950X or an i9 13900 would need 2.2GB, and many phones with 8-threads SoCs would lose 544MB to these allocations. This is, of course, not much of a problem for users with 32GB of system memory, but for 16GB or lower, particularly 8GB RAM users, this is a very steep price to pay. It is not uncommon to see a laptop with only 8GB of RAM and a 12 thread-equipped Ryzen 5500U for example, or 8GB phones and tablets.</p> <p><a href="https://github.com/liamwhite">byte[]</a> wasn’t happy with this behaviour, so he replaced it with a much more memory-friendly one. The current use per-thread is about 134KB now. That’s a whopping 99.6% reduction!</p> <p>One of the ways to make games look better is by forcing higher values of anisotropic filtering, which makes textures at steep angles look much sharper. The old implementation had to skip nearest-neighbour samplers on mipmapped images to avoid rendering issues in games like <code>Fire Emblem: Three Houses</code> and <code>ASTRAL CHAIN</code>. This decision meant that many games like <code>Metroid Prime Remastered</code> would see no benefit from using higher values of anisotropic filtering, to the point that <a href="https://github.com/Wollnashorn">Wollnashorn</a> would create mods to force the textures of <code>Breath of the Wild</code> and <code>Tears of the Kingdom</code> to trilinear filtering, allowing yuzu&rsquo;s anisotropic filtering setting to do its job.</p> <p>While that was a nice workaround, Wollnashorn wasn’t satisfied with this solution, so they improved the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10744" data-gh-pr="10744">heuristics</a> used to allow anisotropic filtering on any texture format without rendering issues, improving image quality, and as a bonus, even fixing an old rendering bug affecting <code>Mario Kart 8 Deluxe</code> too!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/afbug_huca256697ecd432c02bfaff97cdc0b3f2_5933615_1024x0_resize_q90_bgffffff_box_3.jpg" alt="More accurate and better looking! (Mario Kart 8 Deluxe)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/affix_hue8b47451de7a67660f1e4fbd81f30642_6275693_1024x0_resize_q90_bgffffff_box_3.jpg" alt="More accurate and better looking! (Mario Kart 8 Deluxe)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">More accurate and better looking! (Mario Kart 8 Deluxe)</p> <p>Now you can safely select 16x filtering and enjoy the results, which you can find in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Anisotropic Filtering</code>:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./af.png" title=" Anisotropic Filtering at 16x may affect performance on integrated GPUs, something to keep in mind"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/af_hu5ec9bdc6473c39622e29885d92d458a9_21428_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Anisotropic Filtering at 16x may affect performance on integrated GPUs, something to keep in mind"></a> <p class="has-text-centered is-italic has-text-grey-light"> Anisotropic Filtering at 16x may affect performance on integrated GPUs, something to keep in mind</p> </div> </div> <p>In another batch of old issues fixed by Blinkhawk, he managed to pinpoint the cause for Unreal Engine 4 games having broken textures and crashing when running with Vulkan, a problem that mostly affected NVIDIA cards.</p> <p>Unreal Engine 4 is a big fan of <a href="https://docs.unity3d.com/Manual/SparseTextures.html">sparse textures</a> to the point of really pushing the limits of the texture cache code. A bug affecting how NVN virtual images were being remapped after sparse memory gets converted to regular mapped memory caused games like <code>SHIN MEGAMI TENSEI V</code>, <code>Bravely Default</code>, the <code>Pikmin 4 Demo</code>, and many others to display corrupted textures at random.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/yvcbug1_hu5962334573b5891cdcf4ea0c3c443f7d_1450812_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Optical camouflage gone wrong, clearly Protag-kun here is not as good as major Motoko (SHIN MEGAMI TENSEI V)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/yfcfix1_hua7973954396b765d8f791efc76e1278b_1362626_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Optical camouflage gone wrong, clearly Protag-kun here is not as good as major Motoko (SHIN MEGAMI TENSEI V)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Optical camouflage gone wrong, clearly Protag-kun here is not as good as major Motoko (SHIN MEGAMI TENSEI V)</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/yfcbug1_hu0ee85abfa5dd43dc30df594e586680b6_1832302_1024x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s not a phase, mom! (BRAVELY DEFAULT II)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/yfcfix2_huf54f6530e936dccfefddb248eb5bae7e_1912409_1024x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s not a phase, mom! (BRAVELY DEFAULT II)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It&#39;s not a phase, mom! (BRAVELY DEFAULT II)</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10953" data-gh-pr="10953">Fixing this regression</a> allows games to render properly once again.</p> <p>Speaking of the <code>Pikmin 4 Demo</code>, the game taught us that while you can do it, 3D textures really <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10956" data-gh-pr="10956">don’t need to be accelerated</a> by DMA operations. In order to avoid crashes in Unreal Engine 4 games like this, the LLE slow code path will be used instead.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pm4.png" title=" More proof that games don’t need high requirements to be fun (Pikmin 4 Demo)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/pm4_hu0a1a70fe69aadbe12c3f6fd959ee0496_7305869_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" More proof that games don’t need high requirements to be fun (Pikmin 4 Demo)"></a> <p class="has-text-centered is-italic has-text-grey-light"> More proof that games don’t need high requirements to be fun (Pikmin 4 Demo)</p> </div> </div> <p>This pull request introduced a regression that affected rendering in <code>Metroid Prime Remastered</code>. Thankfully, <a href="https://github.com/gidoly">gidoly</a> quickly solved it by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/11012" data-gh-pr="11012">merging both approaches,</a> old and new.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mprbug_hu9bad97dafa29f206b37a66bdb7e47fd2_7309374_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Chozo Suite error 404: Texture not found (Metroid Prime Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mprfix_hu6b86bbca0b9fb300be24ad2632e29d2c_6480646_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Chozo Suite error 404: Texture not found (Metroid Prime Remastered)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Chozo Suite error 404: Texture not found (Metroid Prime Remastered)</p> <p>While working on these crashes, byte[] changed the behaviour of the Vulkan memory manager to prefer (instead of require) <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10994" data-gh-pr="10994">using device local memory</a> (VRAM) for image memory, which ends up allowing up to 50% of shared memory (system RAM) to be used by the GPU. This simple trick makes most Unreal Engine 4 games stable, but it is very likely it has the cost of making VRAM intensive games stutter more often once VRAM gets close to full, for example, when running <code>The Legend of Zelda: Tears of the Kingdom</code> on a GPU with 4GB of VRAM or less.</p> <p>It’s a high price to pay considering <code>Tears of the Kingdom</code> is by far the most played game on yuzu, but we think the huge number of games that benefit from stable gameplay outweighs the latest Zelda stuttering a bit more on low-end GPUs with dedicated VRAM.</p> <p>What better way to prove that statement than by continuing to write about <code>The Legend of Zelda: Tears of the Kingdom</code>! Ever since its release, the modding community has been working tirelessly to improve the rendering quality of the game. During their testing they discovered that any rendering resolution mod higher than 1008p would break ambient occlusion effects when scaled above 1x resolution.</p> <p>byte[], with some help from Wollnashorn&rsquo;s initial investigation, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10675" data-gh-pr="10675">adjusted the rescale size thresholds,</a> and now the game can be safely upscaled with mods to reach that glorious real 1080p rendering—and can then be scaled with yuzu’s internal resolution scaler to any desired resolution.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/aobug_huc40d67876053e7cc62d4c169f6837f69_7152950_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The ambient occlusion of this game may not be perfectly implemented, but it really helps with the ambiance of the scene (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/aofix_hu03fd81b21d201532edb6d309f4390cbf_7520155_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The ambient occlusion of this game may not be perfectly implemented, but it really helps with the ambiance of the scene (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The ambient occlusion of this game may not be perfectly implemented, but it really helps with the ambiance of the scene (The Legend of Zelda: Tears of the Kingdom)</p> <p>Now you can enjoy the game in all its splendour, without sacrificing any details.</p> <p>While profiling the GPU code, Maide found a way to squeeze more performance out of the game. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10668" data-gh-pr="10668">combining vertex and transform feedback buffer bindings</a> instead of binding them individually, thousands of API calls per frame can be avoided. This leads to a small 1-3% improvement in framerates in general, but it manages to boost <code>Tears of the Kingdom</code> by a whopping 17%. The tests were performed with a Ryzen 5 5600X, so it’s very likely that newer CPUs will see even bigger gains.</p> <p>By adding some <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10818" data-gh-pr="10818">additional samples checks</a> when finding the correct render target, <a href="https://github.com/vonchenplus">vonchenplus</a> fixed the device loss crashes that affected <code>Fire Emblem Engage</code> while playing in handheld mode, as well as the squished character portraits that affected some systems. This change also fixes incorrect colour and shadows in <code>SpongeBob SquarePants: The Cosmic Shake</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/feebug_hube1119c08af3a37bd3c55678b2834537_1267218_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That portrait wasn’t very engaging, your excellency (Fire Emblem Engage)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/feefix_hu35029dfdbe3fc0e1c70695bbadbd07ad_1814016_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That portrait wasn’t very engaging, your excellency (Fire Emblem Engage)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That portrait wasn’t very engaging, your excellency (Fire Emblem Engage)</p> <p>vonchenplus also fixed <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10798" data-gh-pr="10798">resolution scaling issues</a> affecting <code>Titan Quest</code> and <code>Crysis Remastered</code>; glitchy picture-in-picture bug begone!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/crybug_hu05a9b9739a3feb413e905745de8d85f1_9960692_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Yes, we can run Crysis, now at 4k (Crysis Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/cryfix_huf957cce001763fdd981862aabb362c10_13113172_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Yes, we can run Crysis, now at 4k (Crysis Remastered)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Yes, we can run Crysis, now at 4k (Crysis Remastered)</p> <p>OpenGL also got some love once again thanks to efforts made by <a href="https://github.com/ameerj">Epicboy</a>.</p> <p>In a surprising discovery (or as stated in the pull request description, “here’s a fun one”), Epicboy found out that NVIDIA’s OpenGL drivers get a significant performance boost in shaders using local memory if the previous shader that was executed uses a lot of local memory. This seems to be an OpenGL-specific quirk in the NVIDIA driver, as Vulkan is not affected.</p> <p>This <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10916" data-gh-pr="10916">beautiful driver trick</a> gives a 2-10% performance increase depending on the size of the GPU.</p> <p>But the OpenGL gains didn’t stop there. <code>Persistent Buffer Maps</code> were already in use by the texture cache, but <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10476" data-gh-pr="10476">extending their use</a> to the buffer cache more than doubles the performance of OpenGL on NVIDIA hardware!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ogl.png" title=" Fermi and Kepler users rejoice (tested with an RTX 3070)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/ogl_hu6fa0f798d536b7b08d8dc5487d58c495_83963_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Fermi and Kepler users rejoice (tested with an RTX 3070)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Fermi and Kepler users rejoice (tested with an RTX 3070)</p> </div> </div> <p>We expect a similar improvement when using Mesa drivers on Linux.</p> <p>While most NVIDIA users are advised to stick to Vulkan now, as it is still faster and with WAY less shader stuttering, these changes should greatly help Fermi and Kepler (GTX 400 to GTX 700 series) users that, due to driver support reasons, must still use OpenGL. Or those who just like to live dangerously.</p> <p>With the introduction of the resolution scaler, we added FXAA as a possible anti-aliasing filter, a preferred option over SMAA for games that already look too crisp, or simply for users that can’t afford the performance loss of SMAA. Its Vulkan implementation has had issues with colour banding since release. Not satisfied with that, byte[] solved the problem by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10670" data-gh-pr="10670">using a higher colour bit depth.</a> Sometimes, solutions don’t need to be complicated.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/fxaabug_hu3a4034d760d3123c3651d7b24df2422a_2444273_1024x0_resize_q90_bgffffff_box_3.jpg" alt="For those old enough to remember what it felt getting a GPU that could do 24-bit colour (SUPER MARIO ODYSSEY)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/fxaafix_hu9feaa4978f0e4669aa73e8fe1b8c1d10_2634439_1024x0_resize_q90_bgffffff_box_3.jpg" alt="For those old enough to remember what it felt getting a GPU that could do 24-bit colour (SUPER MARIO ODYSSEY)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">For those old enough to remember what it felt getting a GPU that could do 24-bit colour (SUPER MARIO ODYSSEY)</p> <p>Many Switch games support dynamic framerates, or get mods that support dynamic framerates, meaning unlocking the framerate (by default by pressing Ctrl + U) is a great way to get a much better and smoother experience while emulating those games. By the way, here’s a <a href="https://github.com/Law022/Dynamic-Frame-Rate/wiki/Game--List">list</a> of such games for those curious.</p> <p>One unwanted side effect with this is that video playback won’t be able to keep up with the increased framerate, often desynchronizing audio while still having to wait for the video to end. To mitigate this, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10666" data-gh-pr="10666">added a toggle</a> in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced</code> called “Sync to framerate of video playback” that, when enabled, will dynamically re-enable the framerate limit while a video cutscene is playing.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./af.png" title=" Totally not the same pic from earlier"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/af_hu5ec9bdc6473c39622e29885d92d458a9_21428_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Totally not the same pic from earlier"></a> <p class="has-text-centered is-italic has-text-grey-light"> Totally not the same pic from earlier</p> </div> </div> <p>While digging into the AccelerateDMA code, Epicboy found an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10583" data-gh-pr="10583">incorrect check</a> that affected buffer-to-texture copies. Fixing it increased performance by a whopping 1%, but as any avid gamer knows, average framerates are only half of the story. This change also improved frametime consistency, especially in sudden spikes, which are arguably the most noticeable during gameplay.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./frame1.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/frame1_hue4fee63952289a32178d3bf9a383dfa2_57387_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./frame2.png" title=" I have become frametime, the destroyer of gameplay"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/frame2_hua3a2ffcdbd0e3dd23ecddd154c356fb1_116685_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" I have become frametime, the destroyer of gameplay"></a> <p class="has-text-centered is-italic has-text-grey-light"> I have become frametime, the destroyer of gameplay</p> </div> </div> <p>Users enjoy testing yuzu on a wide variety of devices; one particularly interesting example is the Tegra X1 product line from NVIDIA, the same architecture that powers the actual Nintendo Switch. Since there are drivers available for those devices, yuzu can be run in a Linux environment, but for some reason, those drivers don’t include the <code>VK_EXT_robustness2</code> extension, which was mandatory up until now. Newcomer <a href="https://github.com/mrcmunir">mrcmunir</a> decided to change this and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10635" data-gh-pr="10635">mark the extension as optional,</a> making the most optimal ARM boards for Switch emulation able to enjoy gameplay with yuzu.</p> <p>To close the graphics section, we saved the best for last: toastUnlimited removed the use of a Windows only external memory Vulkan extension. Why? To make yuzu <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10829" data-gh-pr="10829">compatible with Wine</a> while using Vulkan! Why would someone run yuzu on Wine when a native and faster Linux version is available? We don’t know! But you can definitely do it now, given you build Wine from source yourself with support for Vulkan child windows. We only intend to use this for debugging MinGW releases—for end users, we won&rsquo;t provide any support for running releases in Wine.</p> <p>This is a fun case where all developers asked your writer to skip mentioning this change because it was considered redundant for this report. To them I say: YOLO.</p> <h2 id="android-additions">Android additions</h2> <p>The new supported platform in town has a lot of improvements to boast of, but the most important one gets the honour of starting the section.</p> <p>Thanks to the joint work of byte[] and <a href="https://github.com/GPUCode">GPUCode</a>, and the help from <a href="https://github.com/bylaws">bylaws</a> who allowed us to use Skyline’s BCn texture decoder, yuzu can now properly advertise <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10837" data-gh-pr="10837">support for Mali GPUs!</a> </p> <p><a href="https://www.youtube.com/watch?v=6EBuKP-uc94">Kept you waiting, huh.</a></p> <p>This means users of Mediatek, old Samsung Exynos, and Google Tensor CPUs <a href="https://en.wikipedia.org/wiki/Mali_(processor)#Implementations">(among others)</a> can run their games in yuzu as long as they have a <a href="https://en.wikipedia.org/wiki/Mali_(processor)#Variants">G-series Mali GPU</a>, for example the Mali-G710 on the Pixel 7 series.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mali1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mali1_hu1d23c2cf256796dbbf677fedcc1b4e61_2266565_800x0_resize_q90_bgffffff_box_3.jpg" alt="SUPER MARIO ODYSSEY and Pokémon Mystery Dungeon Rescue Team DX (Running on a Pixel 7 Pro)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mali2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mali2_hu61742f4208e5a58c2308e3b9e79d9515_3742552_800x0_resize_q90_bgffffff_box_3.jpg" alt="SUPER MARIO ODYSSEY and Pokémon Mystery Dungeon Rescue Team DX (Running on a Pixel 7 Pro)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">SUPER MARIO ODYSSEY and Pokémon Mystery Dungeon Rescue Team DX (Running on a Pixel 7 Pro)</p> <p>This theoretically doubles the compatibility of yuzu’s Android builds, as Mali is the most common GPU family in the Android ecosystem.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mali3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mali3_hu6dcad96f3faecadb9a6b80c4455a6207_1598923_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Skyward Sword HD, Advance Wars 1&#43;2: Re-Boot Camp, and OCTOPATH TRAVELER (Running on a Pixel 7 Pro)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mali4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mali4_hu3aa4e41249464e2a08b8846fe8e4da70_3810690_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Skyward Sword HD, Advance Wars 1&#43;2: Re-Boot Camp, and OCTOPATH TRAVELER (Running on a Pixel 7 Pro)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mali5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/mali5_hu129eb784aba1170e358d116334038434_3023488_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Skyward Sword HD, Advance Wars 1&#43;2: Re-Boot Camp, and OCTOPATH TRAVELER (Running on a Pixel 7 Pro)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Skyward Sword HD, Advance Wars 1&#43;2: Re-Boot Camp, and OCTOPATH TRAVELER (Running on a Pixel 7 Pro)</p> <p>Further testing with Mali revealed that while the driver implemented support for the <code>VK_EXT_extended_dynamic_state2</code> extension in older Mali drivers, the implementation for <code>VK_EXT_extended_dynamic_state</code> was not fully functional, and yuzu was not behaving correctly in this case. This is most likely the reason both extensions were removed by Google from Pixel drivers. To avoid users of affected drivers experiencing no rendering output at all, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10790" data-gh-pr="10790">disabled the use of the extension</a> on Mali hardware.</p> <p>It should be noted that while the Mali drivers are much better at following the Vulkan specification than others, the physical hardware specifications are lacking. Only high-end devices will reach playable framerates at the moment. Lower-end Mali products will be too weak for Switch emulation, even if they meet the driver requirements to run the emulator. But hey, you’re welcome to try it out and see how it goes!</p> <p>There’s also been a LOT of work put into the Android user interface.</p> <p>To begin with, <a href="https://github.com/PabloG02">PabloG02</a> has given us a hand again, this time by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10551" data-gh-pr="10551">storing the position of overlay controls</a> as a percentage, so if there is a change in the dimensions of the window, for example by using a foldable device, or rotating the screen on a tablet, the overlay controls stay in approximately the same location.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./move.png" title=" Place your input anywhere you want!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/move_hud6f67d754d9a481c8b73a97d9a59dd1c_218120_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Place your input anywhere you want!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Place your input anywhere you want!</p> </div> </div> <p>To help users with transferring the required files to yuzu and with debugging, PabloG02 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10578" data-gh-pr="10578">added UI options</a> to import firmware files, a requirement to run and properly display some games, and an option to quickly share the last log file, which can help our support members when trying to diagnose the reason for a crash. Thanks!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./firmware.png" title=" Select your firmware dump location"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/firmware_hu26d3c8b7a4cd3e0e17a6c184d36bec01_118823_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Select your firmware dump location"></a> <p class="has-text-centered is-italic has-text-grey-light"> Select your firmware dump location</p> </div> </div> <p>Users can be very particular about the configuration of overlay controls. Some may be fine with just using the Switch’s touch screen instead (depending on the game), and some have different preferences of opacity levels for buttons. For cases like these, <a href="https://github.com/t895">t895</a> added a dialog to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10557" data-gh-pr="10557">adjust the scale and opacity</a> of the overlay controls.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./overlay.png" title=" Size and transparency"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/overlay_hu1d82ac199b388a8bb05068c472f68df0_1639746_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Size and transparency"></a> <p class="has-text-centered is-italic has-text-grey-light"> Size and transparency</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ov1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/ov1_hu9e87f4a073d33d225abe094cb0a98e43_495201_800x0_resize_q90_bgffffff_box_3.jpg" alt="It’s also a great way to enjoy touch-only games (Witch on the Holy Night)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ov2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/ov2_hu9e87f4a073d33d225abe094cb0a98e43_487212_800x0_resize_q90_bgffffff_box_3.jpg" alt="It’s also a great way to enjoy touch-only games (Witch on the Holy Night)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It’s also a great way to enjoy touch-only games (Witch on the Holy Night)</p> <p>yuzu includes a notification to ensure the app isn’t closed by Android when switching apps. We need to do this to ensure users don’t lose their progress, but it can also be used to include some cool features.</p> <p>One possibility is support for Picture-in-Picture when minimising the app. t895 did the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10633" data-gh-pr="10633">preliminary work</a> to allow changing the aspect ratio, and newcomer <a href="https://github.com/AbandonedCart">AbandonedCart</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10639" data-gh-pr="10639">did the actual magic.</a> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./pip1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/pip1_hu15c81f35fdc6bddfb41b5dc2b760f677_759708_800x0_resize_q90_bgffffff_box_3.jpg" alt="That’s a spicy music player (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pip2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/pip2_hu14800d98a82dfcb0a5774d15fe6a5f12_172206_800x0_resize_q90_bgffffff_box_3.jpg" alt="That’s a spicy music player (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That’s a spicy music player (Super Smash Bros. Ultimate)</p> <p>Later, a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10811" data-gh-pr="10811">button to mute/unmute</a> was added to the Picture-in-Picture overlay.</p> <p>Android doesn’t only run on phones and tablets. You can find people crazy enough to play yuzu on TVs too! For those madlads, newcomer <a href="https://github.com/qurious-pixel">qurious-pixel</a> added support for an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10650" data-gh-pr="10650">Android TV</a> banner. Thank you!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tv.png" title=" NVIDIA SHIELD anyone?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/tv_hu750a44f29930417d51b84de905dbf2b7_7764_320x0_resize_q90_bgffffff_box_3.jpg" alt=" NVIDIA SHIELD anyone?"></a> <p class="has-text-centered is-italic has-text-grey-light"> NVIDIA SHIELD anyone?</p> </div> </div> <p>Since release, users have reported games looking strangely blurry, and issues with the aspect ratio of the rendering window and the orientation of the overlay controls when flipping the device.</p> <p>This is a bit of an embarrassing one: all those issues were caused by decoupling the rotation of the Vulkan surface with the frontend layer. This explains why aspect ratios were distorted and the overlay was inverted when the device was rotated, but the explanation for the blurriness issue deserves special mention. Games present to the screen in docked mode using a landscape form factor and resolution of 1920x1080, but phones typically have a portrait mode form factor. What happens if the window starts rendering at 1920x1080, then gets modified to 1080x1920 by the device and is stretched to fit the screen? Well, this:</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/tv_hu750a44f29930417d51b84de905dbf2b7_7764_320x0_resize_q90_bgffffff_box_3.jpg" alt="Did we mention we’re new at this?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/bunnei_hueb4e081b50f5bdda9b221ba3b5add097_17625_320x0_resize_q90_bgffffff_box_3.jpg" alt="Did we mention we’re new at this?"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Did we mention we’re new at this?</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10703" data-gh-pr="10703">By keeping rotation in sync,</a> both intentionally by the user and unintentionally by the device, all mentioned issues are solved. Oops!</p> <p>Continuing the effort of reaching feature parity with the desktop builds, <a href="https://github.com/german77">german77</a> added support for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10705" data-gh-pr="10705">installing updates and DLCs</a> to NAND, just like on PC.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dlc.png" title=" Remember to hold to select multiple files!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/dlc_hu2b6ad261939940c4b9b59ceff9cdd39a_102257_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Remember to hold to select multiple files!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Remember to hold to select multiple files!</p> </div> </div> <p>AbandonedCart once again comes to the rescue by adding support to allow this option to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10794" data-gh-pr="10794">install multiple files</a> at once. It’s not fun having to constantly repeat the process to install every single thicc <code>Atelier Ryza: Ever Darkness &amp; the Secret Hideout</code> DLC, but it’s so worth it.</p> <p>Big Boss <a href="https://github.com/bunnei">bunnei</a> made some changes to the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10746" data-gh-pr="10746">default graphics settings</a> to improve the out-of-the-box experience, as well as add options required to solve rendering issues and/or improve performance.</p> <p>Joining yuzu on Android from the desktop release is <code>Reactive Flushing</code>, an option that can significantly reduce performance in the name of rendering accuracy. To provide the best performance, the option is disabled by default, but if you want accurate shadows in Bayonetta games, or proper save thumbnails, remember to enable it.</p> <p><code>Force maximum clocks</code> is now disabled by default, since it’s not very relevant while the main bottleneck is on the CPU side of the emulation process. We’ll revisit this toggle once native code execution is implemented.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gpu.png" title=" Feature parity with the PC releases, little by little"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu_hu5be91e778c64891734bdec50d2004c3f_131402_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Feature parity with the PC releases, little by little"></a> <p class="has-text-centered is-italic has-text-grey-light"> Feature parity with the PC releases, little by little</p> </div> </div> <p>An often forgotten feature of the Nintendo Switch is touch support. While in handheld mode, some games allow you to play without controls, just with the screen. Support was present since release for the Android build, but it wasn’t accurate — the touch event would happen offset to the side of where the user would touch their finger. german77 fixed this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10751" data-gh-pr="10751">touchy behaviour,</a> making playing visual novels with no overlay buttons a joy.</p> <p>One of the nice additions of Android 13 is the option to set <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10760" data-gh-pr="10760">per-app languages,</a> so properly declaring the available language translations allows users to take advantage of this feature. Thanks <a href="https://github.com/FearlessTobi">flTobi</a>!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lang.png" title=" Your phone knows more languages than you"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/lang_hu2f31d4c199e4586574e78433fa2de919_51281_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Your phone knows more languages than you"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your phone knows more languages than you</p> </div> </div> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10808" data-gh-pr="10808">Expanding the Debug section</a> a bit, t895 added the option to disable <code>CPU Fastmem</code>. This will reduce performance, but is useful for debugging purposes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./debug.png" title=" Extremely recommended to leave at default values"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/debug_hu6a96a6d1da4310947b47aa94ea538d99_53175_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Extremely recommended to leave at default values"></a> <p class="has-text-centered is-italic has-text-grey-light"> Extremely recommended to leave at default values</p> </div> </div> <p>Additionally, an option to select the audio backend was added too.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./audio.png" title=" Volume controls"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/audio_hu1ce52eed879249605b3af8b6f454dafc_19796_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Volume controls"></a> <p class="has-text-centered is-italic has-text-grey-light"> Volume controls</p> </div> </div> <p>Because it is only supported on Qualcomm devices, t895 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10864" data-gh-pr="10864">now hides</a> the <code>Install GPU driver</code> option if the user is running a non-Qualcomm device. Since we don’t offer the option to run different drivers on these devices, there’s no reason to show it. Of course, if Mesa can deliver a good driver for Mali hardware in the future, we will support custom drivers for it then.</p> <p>As a way to warn users with devices that may not be capable of stable emulation, AbandonedCart <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10869" data-gh-pr="10869">added a warning</a> if it doesn’t have at least 8GB of RAM. Android versions prior to the upcoming 14 don’t let apps know the exact RAM amount of the device, so available free RAM is used instead.</p> <p>Speaking of which, t895 added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10945" data-gh-pr="10945">support for Android 14.</a> Better to be ready beforehand! You never know when Google might surprise us.</p> <p>Before we end this section, let us clarify something. The Android builds are not limited to the changes mentioned here, but also include any other core improvements mentioned in this article. For instance, the previously discussed GPU changes, and to be discussed memory and ARM optimizations are also included in the Android builds. These changes have boosted performance by 30-70% in the latest versions, for example, and none were Android specific.</p> <p>We have also completed our release backups on GitHub! You can find them <a href="https://github.com/yuzu-emu/yuzu-android/releases/">here.</a> If you want to download a previous version, test experimental features, or avoid using the Google Play Store, feel free to grab the APK from there.</p> <h2 id="making-cpus-go-the-opposite-of-brrr-amd-edition">Making CPUs go the opposite of BRRR, AMD edition</h2> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/#making-cpus-go-the-opposite-of-brrrr">Back in March</a>, we explained why Windows is not accurate enough when very high precision timers are required, so in order to improve performance, power consumption, and temperatures on x86_64 CPUs, specific CPU instructions are needed to reduce the time the CPU spends improperly idling. We have a big mistake to correct here. We said only Intel offered such instructions starting with Alder Lake, and that AMD didn’t offer any.</p> <p>Fortunately, we were wrong! AMD does indeed have its own implementation, the <code>monitorx</code> and <code>mwaitx</code> instructions pair, which have been out since <em>2015</em>, predating Ryzen!</p> <p>By performing his usual black magic, <a href="https://github.com/Morph1984">Morph</a> implemented support for these instructions, providing the same benefit only Intel users previously enjoyed, namely performance and battery life improvements for power-limited products (laptops, handhelds) or CPUs with fewer core counts.</p> <p>Since AMD CPUs running Windows can now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10935" data-gh-pr="10935">properly idle for longer</a> while waiting, power consumption and/or performance numbers are improved, depending on which limit is hit first: the power budget of the CPU or a framerate cap. Sadly, your writer (who got tasked with testing this change) doesn’t have access to an Asus Rog Ally handheld, or even a Ryzen laptop, to do proper benchmarks, so instead please accept the numbers collected with a desktop Ryzen 5 5600X. The results should be better with a proper mobile platform, but alas, we can only show what we tested.</p> <p>Power consumption saw a 10-16% reduction, which translates with this particular CPU model to around a 10W reduction. While simulating a power limited scenario (capping the PPT to 40W), performance improved up to 60%, but on average a 20% gain is more often expected.</p> <p>Now, we can guess what some of you may be thinking, “how much does this help the Steam Deck? That’s a power-limited system with only four cores!” It makes no difference on the Deck. Let us explain.</p> <p>The Steam Deck by default runs a Linux distribution. Linux doesn’t benefit from these changes as its kernel, unlike Windows’, is actually decent and can run high-precision timer events without any problem or undocumented SDK usage. If there’s no need to spin the CPU at all, it gets to idle properly. So unless you installed Windows onto your Steam Deck, you already had the best performance it can offer.</p> <h2 id="arm-changes">ARM changes</h2> <p>The Android release taught us something very important: Using <a href="https://github.com/merryhime/dynarmic">Dynarmic</a> adds a lot of overhead on ARM CPUs. While this doesn&rsquo;t pose any major obstacles on Apple Silicon M1 and M2 Macs, it&rsquo;s a big problem for Android devices, which are constantly power-limited with virtually no room for waste.</p> <p>To reduce the overhead here, we are planning to implement a feature from Skyline, <code>native code execution</code>, or NCE, letting the game’s code run directly on the processor untranslated. This will work for most 64-bit games, but 32-bit Switch games have some special requirements that complicate this.</p> <p>NCE is a project that will take some time, but for now, byte[] already implemented a way to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10747" data-gh-pr="10747">decouple Dynarmic</a> from the ARM interface, allowing for a separate CPU backend in the future. Let’s see what the future brings.</p> <p>We’re still calling it Project Nice, right? Right.</p> <p>Regarding 32-bit games, it’s worth mentioning that behind the scenes, <a href="https://github.com/merryhime">Merry</a> constantly works on optimising and fixing bugs in Dynarmic. Recently, Merry was able to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10933" data-gh-pr="10933">enable an optimization</a> for ARM64 host hardware. Block linking allows blocks of guest code that directly jump to each other to directly jump to each other when recompiled as well. After enabling it, this resulted in a 60-70% performance boost for 32-bit games like <code>Mario Kart 8 Deluxe</code> on Android SoCs. This serves as yet another reminder that emulation is very CPU-focused.</p> <h2 id="linux-specific-fix">Linux specific fix</h2> <p>Long gameplay sessions can sometimes feel like a gamble regarding stability. That’s a very common problem for emulators due to how they have to handle memory in unique ways to match two completely different systems. This was especially true for Linux users, who had to rely on increasing the size of the <code>vm.max_map_count</code> kernel parameter for certain games to avoid out-of-memory crashes. Since the emulator needs to create placeholder memory mappings to keep up with the virtual memory requirements of the game, it wasn’t hard to saturate the default value, resulting in a crash once the placeholder mappings outnumbered the max mapping count.</p> <p>Enter newcomer <a href="https://github.com/kkoniuszy">kkoniuszy</a>, who had a simple yet very effective idea. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10550" data-gh-pr="10550">keeping track of the creation</a> of such placeholder mappings and using that information to create fewer larger ones instead of several smaller ones, the stress on <code>vm.max_map_count</code> is reduced and generally no longer needs to be modified. This results in stable game sessions when playing for hours. Thank you!</p> <h2 id="input-improvements">Input improvements</h2> <p>The work to make Amiibos and their Near-Field Communication (NFC) behave the same as on real Switch hardware continues. With the proper implementation finished <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/#input-and-amiibo-improvements">last month</a>, german77 has focused on the last items on the checklist.</p> <p>First of all, backup support. On the Switch, Amiibo data is stored in the console every time data is loaded or saved. This is intended to help games restore corrupted Amiibo tags in case of errors. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10623" data-gh-pr="10623">With this implementation,</a> yuzu now can do the same with Joy-Cons and Pro Controllers. The backups will be stored in <code>%appdata%\yuzu\amiibo\backup</code>.</p> <p>Our input dev added support for Foomiibos, blank but configurable Amiibo dumps with a signature included at the end, by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10795" data-gh-pr="10795">adding their size as a valid input.</a> </p> <p>Activision releases NFC equipped toys (aka not-Amiibos) for the <code>Skylanders</code> games saga, and they are compatible with the Nintendo Switch, so of course, they must work on yuzu too! <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10842" data-gh-pr="10842">The implementation</a> should be transparent; just connect and map a controller, and it’s ready to scan the toys.</p> <p>And to finish up the NFC section, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10903" data-gh-pr="10903">bugfixes and support for third-party controllers</a> in a single pull request to rule them all.</p> <p>Controllers sometimes fail to properly restore to a previous state when pairing. This could make yuzu lose input when the controller fails to use the NFC sensor. If the game stopped polling for Amiibos while one was in range, the Amiibo would be lost but not signaled. This pull request addressed this particular scenario.</p> <p>Many third-party controllers don’t accept all commands. Reducing the number of attempts to obtain valid data and disabling most commands if errors occur will minimise the stuttering caused by the configuration process when setting up the NFC interface.</p> <p>Lastly, if the controller properly reports support for NFC, but the user loads an amiibo from a binary dump, we would mistakenly show an error. This is now fixed.</p> <p>Now, what about regular input changes? Well, we have a bit to talk about there too.</p> <p>SDL, the external library used here to handle input (it can do much more than that), does get updates, and it doesn’t hurt to keep up with those from time to time, after validating they are stable, of course. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10873" data-gh-pr="10873">Updating to version 2.28.0</a> improved the calibration profile used on official Switch controllers, added support for the new DualSense Edge controller from Sony, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10891" data-gh-pr="10891">fixed some issues with Pro Controllers,</a> and added other minor changes and fixes that benefit the emulator.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10950" data-gh-pr="10950">Mouse controls</a> got more tuning love. This time there are some minor tweaks to its calibration. Returning to center will consider the assigned deadzones, and motion input has better sensitivity.</p> <p>For those not in the know, if you set input to Keyboard/Mouse, or manually map a stick to the mouse, you can use the mouse for controlling movement. <code>Ctrl + F9</code> is the default hotkey to take and release control of the mouse while playing.</p> <p>Lastly, for the fitness enthusiasts, there are some improvements for the Ring-Con.</p> <p>german77 improved Ring detection by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10937" data-gh-pr="10937">adding timeouts</a> to let the scanning process try again after a fixed time.</p> <p>And newcomer <a href="https://github.com/kiri11">kiri11</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10908" data-gh-pr="10908">improved the wording</a> of the help text to properly enable the Ring-Con, making it much less confusing. Thanks!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ringcon.png" title=" Fitness at 4K"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/ringcon_hu2d302a1b32dac3fca4dcc1940d6fb798_12860_342x0_resize_q90_bgffffff_box_3.jpg" alt=" Fitness at 4K"></a> <p class="has-text-centered is-italic has-text-grey-light"> Fitness at 4K</p> </div> </div> <h2 id="yet-more-gaia-lite">Yet more Gaia-lite</h2> <p>Yes, there’s more progress by byte[] in fixing the current file system implementation while we wait for <code>Project Gaia</code>.</p> <p>The <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/#project-gaia-lite">previously reported</a> “algorithmic complexity issue” when loading mods was working like a charm on Linux, but Windows always has to be difficult. A <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10588" data-gh-pr="10588">memory cache</a> was added to fully realise the load time benefits on Microsoft’s OS too.</p> <p>In another single-line-of-code revelation, byte[] discovered that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10718" data-gh-pr="10718">increasing the size of the buffer</a> when copying files can more than triple the installation speed of updates and DLCs. Hurray for simple fixes like this!</p> <p>A common problem modders and users had to deal with is a hard limit on the number of files that can be loaded per session. Games like <code>Fire Emblem Engage</code> have so many files that it previously was not even possible to replace all of them with a mod. Of course, byte[] wasn’t happy with this, so by adding a file <a href="https://en.wikipedia.org/wiki/Cache_replacement_policies#Least_recently_used_(LRU)">LRU</a> cache to control the number of open files, he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10729" data-gh-pr="10729">removed the file limit.</a> Users can now run as many mods as they want on their games, and they can have as many files as they need too!</p> <p>But the fun doesn’t stop there for byte[]. Yet again, Windows demands special attention… <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10806" data-gh-pr="10806">A couple of optimizations</a> and Windows users can now properly benefit too.</p> <p>An oversight in the code responsible for caching RomFS mods prevented any caching from taking effect at all, making yuzu take typically twice as long as it needed to when loading a game with them enabled. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10594" data-gh-pr="10594">fixing</a> this oversight, byte[] further reduced game load times with mods.</p> <h2 id="audio-fixes">Audio fixes</h2> <p>Linux users running the SDL audio backend reported having no audio out when using the JACK output. The problem, as newcomer <a href="https://github.com/zeltermann">zeltermann</a> found out after some investigation, is in how SDL identifies the CPU characteristics of the user’s hardware.</p> <p>SDL’s <code>CPUInfo</code> subsystem is called to report the specifications of the user’s CPU. SDL then uses that information to properly configure itself for the environment it will run on, setting optimizations and deciding which internal code paths to use. We thought CPUInfo shouldn’t be necessary just for audio output, so it was disabled in yuzu.</p> <p>Well, under normal circumstances, it would have been fine, but SDL can’t decide if not having CPU information means there is or there isn’t a CPU present. <a href="https://en.wikipedia.org/wiki/Single_instruction,_multiple_data">SIMD</a> support is reported as disabled, but <a href="https://en.wikipedia.org/wiki/SSE2">SSE2</a> is assumed as enabled. This contradiction leads to the fallbacks intended to run in case SIMD support was disabled to fail, making some functions return null, completely destroying audio output.</p> <p>This chain reaction of events is solved by giving SDL what it wants: a proper <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10739" data-gh-pr="10739">report by CPUInfo.</a> Now Linux users can enjoy their games with audio when using the SDL output. Thank you!</p> <p>Out-of-bounds, the silent killer of so many programs… yuzu is of course not immune to them, as Morph found out. An <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10966" data-gh-pr="10966">out-of-bounds write</a> leads to corruption in an audio heap buffer, which leads to beeping noises, speaker rattling, and crashes in multiple games, including but not limited to <code>Xenoblade Chronicles: Definitive Edition</code>, <code>Xenoblade Chronicles 2</code>, <code>Super Smash Bros. Ultimate</code>, and more.</p> <p>A few tweaks here and there in the audio core code, and the issues are gone.</p> <h2 id="ui-changes">UI changes</h2> <p>Switch games provide pretty game icons for the launcher. Needless to say, yuzu makes good use of them while rendering the game list. What wasn’t considered when using these icons for the user interface is that some games offer multiple alternatives for different languages. yuzu would just pick the first one available.</p> <p>Enter newcomer <a href="https://github.com/keve1227">keve1227</a> who coded in the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10591" data-gh-pr="10591">logic required</a> to properly pick the right image depending on the console language the user picks in <code>Emulation &gt; Configure… &gt; System &gt; Language</code>. Thanks!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./langbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/langbug_hu082ebe67db66a300b783c7d37f4bc78a_476656_800x0_resize_q90_bgffffff_box_3.jpg" alt="Gotta find ’em all"></a> </div> <div class="column is-bottom-paddingless"> <a href="./langfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/langfix_hu082ebe67db66a300b783c7d37f4bc78a_476239_800x0_resize_q90_bgffffff_box_3.jpg" alt="Gotta find ’em all"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Gotta find ’em all</p> <p>The OpenGL API has three available shader backends in yuzu, and since the only way to know which one is selected is from checking the option in <code>Emulation &gt; Configure… &gt; Graphics</code>, newcomer <a href="https://github.com/xcfrg">fastcall</a> decided it was due time to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10614" data-gh-pr="10614">add this info</a> to the status bar. Thanks!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./oglui.png" title=" You won’t forget you left GLASM enabled any more!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/oglui_hubf45bd4e37746150ed364399ad45a049_15439_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" You won’t forget you left GLASM enabled any more!"></a> <p class="has-text-centered is-italic has-text-grey-light"> You won’t forget you left GLASM enabled any more!</p> </div> </div> <h2 id="hardware-section">Hardware section</h2> <p>Before starting with the driver rants, we want to share a possible way to save up to 2 GB of VRAM by taking advantage of Windows 11’s per-app graphics selector, assuming you have multiple GPUs available in your system. This has the potential of helping VRAM-intensive games like <code>The Legend of Zelda: Tears of the Kingdom</code>, and may also improve 1% lows on native PC games too.</p> <p>For some reason, Windows uses around 1-2 GB of VRAM only for rendering the desktop. That’s a heavy blow for GPUs equipped with 8 GB or less, without even considering other programs running in the background.</p> <p>The requisites are a desktop PC running an up-to-date Windows 11, either a motherboard with two full length PCI-Express slots or a CPU with an integrated GPU, and all GPUs being new enough to still get driver updates (a GT 710 won’t work with an RTX 4070 as they run different driver versions, and an Intel HD 620 won’t receive new driver updates). In this example we will use an RTX 3060 Ti and an RX 6600, a combination you might be familiar with from previous articles and charts. A lower-end GPU like a GTX 750 or the integrated GPU of an Intel 11th Gen. (and newer) or Ryzen CPU would also work perfectly fine for this purpose.</p> <p>It should be noted that most laptop users already do this with no user intervention, as most laptops don’t include hardware mux switches and just pass the finished frames over the PCIe bus.</p> <p>The main trick here is to connect the display or displays to the secondary card, in order to get Windows, your browser, Discord, etc., to spend VRAM exclusively on the secondary card, letting yuzu and other programs/games get full access to the entire VRAM of the main GPU. To do this, we will take advantage of some relatively recent additions to Windows 11.</p> <p>The first step after setting up the GPUs (desktop PCs may need to enable integrated GPUs on the UEFI configuration/BIOS) is to select the high performance card in display settings:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./gpu1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu1_huf78e191afeffd4892d530923a6b004fe_28288_800x0_resize_q90_bgffffff_box_3.jpg" alt="On desktop PCs, Windows 10 fails here by not letting you select which card is which"></a> </div> <div class="column is-bottom-paddingless"> <a href="./gpu2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu2_huc202a074e58bb9c0a2de706eae2f657e_68536_800x0_resize_q90_bgffffff_box_3.jpg" alt="On desktop PCs, Windows 10 fails here by not letting you select which card is which"></a> </div> <div class="column is-bottom-paddingless"> <a href="./gpu3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu3_hu5125ceb9143dfefff173ff626f91889e_38327_800x0_resize_q90_bgffffff_box_3.jpg" alt="On desktop PCs, Windows 10 fails here by not letting you select which card is which"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">On desktop PCs, Windows 10 fails here by not letting you select which card is which</p> <p>While this is enough for yuzu after a reboot, you will also need to manually set up each game or program that requires using the high performance GPU:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./gpu4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu4_hu62ae307e92ba0c9665f1943daa3b68e9_53935_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tech tip: Forza is faster if you run it with your main GPU"></a> </div> <div class="column is-bottom-paddingless"> <a href="./gpu5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu5_hu8390e6219123c60f938b19fef8c7f8c1_54922_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tech tip: Forza is faster if you run it with your main GPU"></a> </div> <div class="column is-bottom-paddingless"> <a href="./gpu6.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/gpu6_huef3af2c0499a6166852fb401551a98ad_52851_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tech tip: Forza is faster if you run it with your main GPU"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Tech tip: Forza is faster if you run it with your main GPU</p> <p>Like this, you get the benefits of more free VRAM on the high performance GPU, and if the secondary GPU is more efficient, a power consumption reduction overall when using the PC. More available VRAM results in improved minimum framerates (the 1% low for example).</p> <p>The cons for using this method is that frame data is transferred over the PCIe interface, which can be saturated. This can result in slightly lower average framerates and more input lag. But hey, a free way to get a 4GB GPU to run <code>The Legend of Zelda: Tears of the Kingdom</code> with better frame pacing is worth a try, right?</p> <h3 id="nvidia-no-sign-of-progress">NVIDIA, no sign of progress</h3> <p>The new (at the time of writing) 536.40 driver release that adds support for the RTX 4060 hasn’t introduced any regression for yuzu. So it’s safe to update, just not “safe to upgrade” from older hardware yet. Maybe the RTX 5000 series will be a more viable option.</p> <p>And from an interesting report that just came in, it seems using the NVIDIA Control Panel’s “Prefer maximum performance” option while playing <code>Xenoblade Chronicles 3</code> in conjunction with “Use asynchronous shader building” causes vertex explosions, most noticeably in cutscenes. yuzu’s own “Force maximum clocks” toggle, while less efficient, doesn’t reproduce this interesting behaviour. Something to keep in mind if you’re exploring Aionios with an NVIDIA GPU.</p> <h3 id="amd">AMD</h3> <p>Since driver release 23.7.1, a mysterious older “23.10.01.41 for Additional Vulkan Extensions” version, and the beta driver only available to Windows Insider testers, AMD official Vulkan drivers introduced a regression in how the <code>VK_EXT_extended_dynamic_state3</code> extension handles colour blending. <a href="https://github.com/goldenx86">Your writer</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10946" data-gh-pr="10946">blocked the affected bit</a> while we monitor if future AMD driver releases manage to solve this problem.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/amdbug_hu17c3bc6a3d185c94d30a64cca0773439_1694707_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Who gave Link the Batman’s Detective Mode? (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2023/amdfix_hu10b83a5f07a910827940527992eb243c_1928433_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Who gave Link the Batman’s Detective Mode? (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Who gave Link the Batman’s Detective Mode? (The Legend of Zelda: Tears of the Kingdom)</p> <p>The performance loss from this change is very small, so feel free to update to the latest drivers.</p> <p><a href="https://github.com/GPUCode">GPUCode</a> has found a way to emulate D24 support on AMD GPUs by using the <code>VK_EXT_depth_bias_control</code> extension, which is currently only available on the RADV Mesa driver on Linux. In the near future, we’ll check if this method solves the remaining graphical issues specific to AMD hardware. If it works, it would also solve the issue on the AMD official drivers, once/if the extension is supported there too.</p> <p>We know it’s not fun having to switch to OpenGL to be able to play some games, so we’re gearing up to combat even hardware limitations to defeat this foe.</p> <h3 id="intel">Intel</h3> <p>Intel had its fair share of fixes this month too. First of all, as promised last month, byte[] added a translation for FP64 to FP32 when used in shaders. This was required because Generation 12 Intel graphics (UHD 700/Iris Xe/Arc A series) removed support on a hardware level for double precision operations. With this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10693" data-gh-pr="10693">shader translation</a> in place, games will no longer suddenly crash when trying to use these shaders, for example during the opening cutscene of <code>Tears of the Kingdom</code> after starting a new game.</p> <p>The next issue is an interesting mix of unique behaviour by the Switch&rsquo;s own graphics drivers, yuzu’s code at fault, and another case of lack of hardware support. Intel&rsquo;s GPUs allow the use of control barriers as specified by SPIR-V, which requires all threads in a dispatch to execute the same barriers at the same times, and don&rsquo;t allow any threads to exit early if another barrier will occur. But all other GPU vendors besides Intel, including mobile GPUs, do allow threads to exit early, and will free up barriers on the remaining threads as needed. This situation caused Intel GPUs to hit device losses, as guest compute shaders had barriers that ended up hitting this exact type of control flow.</p> <p>By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10699" data-gh-pr="10699">removing barriers</a> after conditional control flow, Intel GPUs are free from their device loss crashes.</p> <p>And lastly, one loose end remained, our toggle to disable the compute pipeline on Intel GPUs. This option was a stopgap solution until a driver update was released. But since Intel has finally published a driver update fixing the issues, it has now become irrelevant. toastUnlimited therefore modified the option to only show up in yuzu’s settings if an old driver known to be affected is still in use. The disable compute pipeline toggle is now a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10835" data-gh-pr="10835">legendary drop option</a> only available for the most unlucky Generation 12 users, as the option will also remain hidden for unaffected Generation 11 and older devices. <a href="https://www.intel.com/content/www/us/en/download/729157/intel-arc-iris-xe-graphics-beta-windows.html">Remember to update your drivers!</a></p> <p>With all driver and yuzu stability-related issues fixed, we can finally recommend Intel hardware again, especially current-generation integrated GPUs like the Iris Xe. While the lower-end 80EU-equipped Iris Xe can bottleneck performance at docked 1X mode in the most intensive games, it makes up for that by having zero texture related stuttering thanks to being the last breed of Intel GPUs with native ASTC texture support. We don’t know if future iGPUs will keep supporting ASTC, but it’s a reality that Arc dedicated GPUs don’t offer it.</p> <p>Still, we can finally focus on working on the few remaining quirks for the Generation 12 architecture. Right now, the Iris Xe can easily beat a Geforce MX450 in ASTC intensive games like <code>The Legend of Zelda: Tears of the Kingdom</code>, using less RAM and having no texture stuttering. Here, the E-cores are a blessing for shader building.</p> <p>Hopefully future Intel products offer better FP16, higher performance, longer driver life support, don’t base their pricing on software gimmicks like their competition, and add a much-needed dedicated compute queue.</p> <h3 id="android">Android</h3> <p>With the release of the Android builds, the whole team is learning about the platform’s ecosystem, its features and limitations, quirks and advantages. There are fun times ahead for sure. This means we also learned about the depressing state of its GPU drivers…</p> <h4 id="adreno-or-just-waiting-for-mesa">Adreno, or just waiting for Mesa</h4> <p>Adreno hardware has great specifications, but their proprietary official drivers are incredibly bad! We’re starting to work on improving rendering on the official Adreno drivers used by default on Qualcomm equipped devices, but there’s only so much we can do. The real solution comes from, you guessed it, the team that manages to make good drivers with no access to confidential information: Mesa.</p> <p>One has to wonder why Android vendors don’t just use Mesa to begin with. Nothing deemed “confidential” or “trade-secret” here is more important than providing good software support!</p> <p>While the Adreno 600 series is well-supported and has great rendering with Mesa Turnip drivers, the 700 series is too new to enjoy the same benefits. There have been a few packaged releases by <a href="https://github.com/K11MCH1">K11MCH1</a> using the currently-in-development a700 branch of Mesa Turnip, but it’s exactly what it says on the tin: currently in development. We can’t work on fixing regressions on a driver that is a work in progress; the only thing to do is to wait for it to mature.</p> <h4 id="mali-good-drivers-slow-hardware-weird-decisions">Mali, good drivers, slow hardware, weird decisions</h4> <p>Mali is the complete opposite of Adreno. While there is no current Mesa support for it, we found their proprietary Vulkan driver to be in great shape once its initial quirks were addressed. The same can’t be said about their OpenGL ES driver as our friends at Citra will gladly tell you, but thankfully that’s not an issue here. The main problem is that the most common hardware the driver gets to run on is pretty subpar, at least for Switch emulation. Clearly, high-end devices won’t have much issue on the GPU front as they are not far behind Adreno in hardware specs, but the rest of the product stack will suffer from low framerates and GPU bottlenecks.</p> <p>Unfortunately, due to an unstable kernel API, and the lack of a maintained Mesa driver for these devices, there isn&rsquo;t currently any practical way to replace the running driver on a Mali device with a better one. If a device ships with an outdated driver too old for yuzu and the vendor doesn’t update it, chances are nothing can be done about it.</p> <p>That’s either planned obsolescence at its finest, or sheer incompetence. We’ll let you be the judge of that.</p> <h2 id="future-projects">Future projects</h2> <p>Fun stuff is cooking, we can’t announce the several yet-unnamed projects at the moment, but know this ship isn’t slowing down any time soon.</p> <p>There’s work by Blinkhawk for faster GPU emulation, native code execution for ARM CPUs, MacOS gets a bit of much needed love, and more. We’ll be reporting progress on these projects in the future, so keep your eyes peeled.</p> <p>toastUnlimited started a big UI rewrite for the <a href="https://github.com/yuzu-emu/yuzu/pull/10839">per-game configurations</a>.</p> <p>Some changes that didn’t make it in time for the cut-off date of this article include fixing crashes affecting Unreal engine games running on NVIDIA GPUs. We’ll cover those next month.</p> <p>That’s all folks! Thank you for reading until the end. We hope to see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report May 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/ Sat, 17 Jun 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/ <p><em>What a month!</em> GOAT releases, yuzu ventures onto new platforms, we get a taste of Project Gaia, full Amiibo support, further Project Y.F.C., and a lot more! Put on your safety belt and start playing some <a href="https://youtu.be/8B4guKLlbVU">eurobeat</a>, this will be a long ride.</p> <p><em>What a month!</em> GOAT releases, yuzu ventures onto new platforms, we get a taste of Project Gaia, full Amiibo support, further Project Y.F.C., and a lot more! Put on your safety belt and start playing some <a href="https://youtu.be/8B4guKLlbVU">eurobeat</a>, this will be a long ride.</p> <h2 id="the-legend-of-zelda-tears-of-the-vram">The Legend of Zelda: Tears of the VRAM</h2> <p>Six years and the wait was worth it. No pay to win mechanics, no soul-draining microtransactions, no apology letter published after release. <a href="https://youtu.be/i1qnIBLNOG0?t=16">Just game, just good game</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./totk1.png" title=" Runs on a 2015 tablet. (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/totk1_hu4c26e6f44ce602714c2f9c45119e276c_6949524_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Runs on a 2015 tablet. (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Runs on a 2015 tablet. (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>Zelda is back, and once again teaches the gaming industry how to make a video game, while also making it fit inside a 15-year-old USB stick and run on an 8-year-old mobile SoC.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./totk2.png" title=" And it’s only 16GB! (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/totk2_hu1691cbeb1cce00455f62c66c8a7c7a9a_6221803_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" And it’s only 16GB! (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> And it’s only 16GB! (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p><code>The Legend of Zelda: Tears of the Kingdom</code> not only made its predecessor (a game which already reinvented how open-world gameplay should be done) look like a tech demo, but it also turned out to be one massive heavyweight, punching way above its class in hardware requirements when emulated. The combination of a heavier physics engine, massive amounts of shaders, and the ludicrous use of enormous ASTC textures has brought emulators to their knees.</p> <p>Let’s begin with the most complex problem the Princess introduced the project to. The old Switch-emulation-on-PC nemesis, now elevated to new heights: ASTC.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./deer.png" title=" Deer. (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/deer_hue909b28ae187dd3247bf93e7ec2d87af_11809427_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Deer. (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Deer. (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>As there isn&rsquo;t a single dedicated desktop or laptop graphics card that supports the native decoding of <a href="https://en.wikipedia.org/wiki/Adaptive_scalable_texture_compression">ASTC textures</a> (with the exception of Intel iGPUs), yuzu is forced to transcode them on the fly into a safe and lossless format that all GPUs support; in this case, the <code>RGBA8</code> format.</p> <p>This was perfectly fine until now (even on 2GB GPUs), since <code>ASTRAL CHAIN</code> was the only game that made &ldquo;extensive&rdquo; use of ASTC textures, shipping with 4K textures on a mobile device intended for 1080p and 720p screen resolutions. Our garbage collector, introduced two years ago with <a href="https://yuzu-mirror.github.io/entry/yuzu-hades/">Project Hades</a>, which our veteran users know as “the memory Reaper”, was tuned for this worst case scenario at the time.</p> <p>But what happens if a game with many more textures and a teletransportation system that allows the player to reach different regions in-game (and, in turn, load a truckload of new, different textures) releases? What if this hypothetical game made use of dozens and dozens of huge ASTC textures?</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./totk3.png" title=" The VRAM is on fire! (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/totk3_hu69161542e16dd42527c449c77bb331f0_9025078_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The VRAM is on fire! (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The VRAM is on fire! (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>Well, suddenly the old and trusted garbage collector we developed is no longer capable of keeping even 8GB GPUs working. That’s right, the VRAM starvation affecting the PC gaming industry hurts yuzu too. Serious changes had to be made, and they had to allow 2GB GPUs to still be compatible somehow.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gpu.jpg" title=" Your writer’s Tower of VRAM Testing. GTX 750 2GB, RX 550 2GB, and RX 6600 8GB. Not pictured, GTX 1650 4GB, GTX 1660 SUPER 6GB, and RTX 3060 Ti 8GB"><img src="./gpu.jpg" alt=" Your writer’s Tower of VRAM Testing. GTX 750 2GB, RX 550 2GB, and RX 6600 8GB. Not pictured, GTX 1650 4GB, GTX 1660 SUPER 6GB, and RTX 3060 Ti 8GB"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your writer’s Tower of VRAM Testing. GTX 750 2GB, RX 550 2GB, and RX 6600 8GB. Not pictured, GTX 1650 4GB, GTX 1660 SUPER 6GB, and RTX 3060 Ti 8GB</p> </div> </div> <p>The solution, which took many attempts, was split into several parts to ensure that no other games were negatively affected by the changes, and required the combined efforts of <a href="https://github.com/Kelebek1">Maide</a>, <a href="https://github.com/liamwhite">byte[]</a> and <a href="https://github.com/FernandoS27">Blinkhawk</a>.</p> <p>While investigating very low VRAM devices, byte[] found that yuzu used <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10286" data-gh-pr="10286">incompatible memory property flags</a> when the Vulkan memory allocator was under pressure, causing low VRAM GPUs to crash when trying to actually use a recycled allocation.</p> <p>Having more VRAM available certainly helps, but that’s not enough to avoid the game from biting off more than the GPU’s memory can chew under stressful conditions — for example, teleporting between different regions.</p> <p>Previously, if VRAM was almost full, the memory manager would try to use shared memory, which is just a portion of system RAM, for new allocations. This caused massive slowdowns during gameplay, as the transfer operation of going over system RAM, CPU, PCIe, GPU, and finally VRAM is a slow process that introduces a high latency.</p> <p>Collecting memory in VRAM is much faster than transferring data over to system RAM. So, instead of relying on the slow shared memory, the memory manager (Reaper) now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10288" data-gh-pr="10288">keeps everything in dedicated memory</a> (VRAM), leaving some free space to accommodate sudden spikes in VRAM usage when new assets are loaded. If you see 2GB or more of always-free VRAM in your system, know that its purpose is to keep gameplay smooth, even on 4GB GPUs. Don’t worry, we’re not wasting your precious VRAM. We’re just keeping it warm and cozy for when you need it. This also has the added benefit of saving on system RAM consumption, allowing 8GB RAM users to have more stable gameplay.</p> <p>All of this is not enough to allow 4GB VRAM users or less to achieve stable gameplay, so it’s time to reveal the ace up yuzu’s sleeve. What if, instead of relying on the pixel-accurate but bigger <code>RGBA8</code> texture format, the emulator recompressed to some other smaller formats?</p> <p>Ladies and gentlemen, we present you <code>ASTC recompression</code>, a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10398" data-gh-pr="10398">new option</a> available in <code>Emulation &gt; Configure &gt; Graphics &gt; Advanced</code> that intends to reduce VRAM consumption by turning those Ganon-cursed unsupported ASTC textures into something more suitable for low-VRAM GPUs.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./astcrecomp.png" title=" We recommend avoiding BC1 if possible."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/astcrecomp_hua6fbb28a9636f9125975b59c1e7c36d0_14281_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We recommend avoiding BC1 if possible."></a> <p class="has-text-centered is-italic has-text-grey-light"> We recommend avoiding BC1 if possible.</p> </div> </div> <p>The principle is pretty simple, we just add one more step to the recompression process, from ASTC &gt; RGBA8, to ASTC &gt; RGBA8 &gt; <a href="https://en.wikipedia.org/wiki/S3_Texture_Compression">BC1 or BC3</a>.</p> <p>The default <code>Uncompressed</code> setting uses the old <code>RGBA8</code> method, which preserves the original image quality, but also consumes the most VRAM. For users that wish to emulate <code>Tears of the Kingdom</code>, we recommend setting this option if their GPU has at least 10-12GB of VRAM. For other, more <strong>reasonable</strong> games, this option is suitable for users with cards with at least 4GB of VRAM.</p> <p>The <code>BC3 (medium quality)</code> setting reduces the VRAM usage of ASTC textures by a factor of four, with a very minimal loss in quality, typically showing as marginally softer textures. This setting is recommended for emulating <code>Tears of the Kingdom</code> on 6GB and 8GB GPUs. For other games, this setting is good for GPUs with 3GB of VRAM.</p> <p>Finally, the <code>BC1 (low quality)</code> setting cuts down the VRAM consumption by a factor of eight, but will also have a significant impact on texture quality, to the point where some assets will look completely different. We don’t recommend using this setting unless you really have to. It allows users with 4GB of VRAM to play <code>Tears of the Kingdom</code> without significant issues, and will make 2GB users have a smoother and more reliable experience in other games.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bc11.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/bc11_hu1f674452370eccfd708de7b768ba77de_11681037_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last, BC1 vs BC3 vs ASTC (Fire Emblem Engage)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bc31.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/bc31_hu94f37d3941248d118c6ab5ac7ce2c451_8337901_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last, BC1 vs BC3 vs ASTC (Fire Emblem Engage)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./astc1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/astc1_huead856a653126882f7408344941cb705_8190681_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last, BC1 vs BC3 vs ASTC (Fire Emblem Engage)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From first to last, BC1 vs BC3 vs ASTC (Fire Emblem Engage)</p> <p>As you can see, BC1 destroys image quality in some games.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bc12.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/bc12_hu7985fb6b7462d7a53a917bbf4a86066b_2623192_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last, BC1 vs BC3 vs ASTC (The Legend of Zelda: Tears of the Kingdom)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bc32.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/bc32_hu0b16de1510bcea3c9bf010ebc2cc5a26_2580495_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last, BC1 vs BC3 vs ASTC (The Legend of Zelda: Tears of the Kingdom)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./astc2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/astc2_hue80861dd99209960b580762d9d2c534d_2558465_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last, BC1 vs BC3 vs ASTC (The Legend of Zelda: Tears of the Kingdom)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From first to last, BC1 vs BC3 vs ASTC (The Legend of Zelda: Tears of the Kingdom)</p> <p>But in others, the difference is less noticeable. If you only have 2GB of VRAM and 8GB of RAM, the sacrifice may be worth it.</p> <p>This is currently done using the CPU, but GPU acceleration is planned for the future. We also hope to add an option to use BC7 in the future to provide a higher quality experience.</p> <p>Keep in mind that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10398" data-gh-pr="10398">ASTC recompression</a> only works on ASTC textures, so the actual VRAM usage reduction will depend on the game. Not every resource held in VRAM is ASTC. If your hardware can handle ASTC natively, this setting won’t do anything for you, as there&rsquo;s no need for any recompression.</p> <p>In addition, byte[] has also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10422" data-gh-pr="10422">tuned the memory manager</a> to be more ruthless. This change should help improve gameplay stability during long sessions on systems with less RAM. yuzu always aims to support a minimum of 8GB of RAM on systems with dedicated GPUs.</p> <p>He also made sure that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10452" data-gh-pr="10452">memory collection doesn’t happen during the configuration step,</a> so that it doesn&rsquo;t cause a device loss (i.e. the GPU driver shutting down).</p> <p>By fixing the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10433" data-gh-pr="10433">block depth adjustment on slices,</a> Blinkhawk solved the rendering issues affecting the gloom textures on the terrain in <code>Tears of the Kingdom</code>, a bug that was especially frustrating on low VRAM hardware.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/gloombug_hu97940f3797ff5cf99ed91267dcd08503_1482598_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Let’s not make the gloom feel depressed… (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/gloomfix_huc6e12810f24c64c096e2f247e20b96a2_1445193_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Let’s not make the gloom feel depressed… (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Let’s not make the gloom feel depressed… (The Legend of Zelda: Tears of the Kingdom)</p> <p>And for integrated GPU users with 16GB of system RAM or less, such as the Steam Deck, newcomer <a href="https://github.com/scorpion81">scorpion81</a> has a treat for you. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10411" data-gh-pr="10411">Setting a hard cap at 4GB</a> allows <code>Tears of the Kingdom</code> to be playable without hitting the page file/swap too hard.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./astcbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./astcfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The difference made on a 2GB equipped GTX 750 (The Legend of Zelda: Tears of the Kingdom)</p> <p>That wraps up the list of changes made to memory management to allow <code>Tears of the Kingdom</code> to be playable in at least the components listed in our <a href="https://yuzu-mirror.github.io/help/quickstart/#hardware-requirements">hardware requirements</a>.</p> <p>These changes would not be necessary if GPUs just supported ASTC textures. Wouldn&rsquo;t you like your games to be no bigger than 100GB instead of having software features that ruin image quality, such as frame generation? Native ASTC decoding support would make this possible.</p> <p>An Intel Iris Xe iGPU can run the game at 30 FPS in handheld mode while using less memory than any other hardware combination, all thanks to being their last GPU capable of decoding ASTC. More on Intel&rsquo;s driver support later.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./totkception.png" title=" We need to go deeper! (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/totkception_hu47371e20be95bdb32a4f67883fedbadf_6286128_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We need to go deeper! (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> We need to go deeper! (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>This was the worst part&hellip; up to this point. More work was needed to get the game to boot and render properly. Let’s dive into that.</p> <p>One thing that both the Switch and Android devices have in common is the way they present to the screen. Google&rsquo;s OS uses <code>SurfaceFlinger</code> (the only good Linux presentation method), and the Switch uses <code>nvnflinger</code>, which is a custom adaptation of <code>SurfaceFlinger</code> designed for the Switch&rsquo;s firmware and operating system. While this gives us a good frame of reference for how <code>nvnflinger</code> should be emulated, sometimes bugs can still sneak in. These bugs are not always easy to spot, especially if no game had rendering problems until now.</p> <p>byte[] realised that yuzu was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10236" data-gh-pr="10236">serialising binder responses incorrectly</a> (in a different way to how Android does it). Fixing this simple bug allowed for <code>Tears of the Kingdom</code> to boot.</p> <p>Meanwhile, Maide implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10234" data-gh-pr="10234">shader fixes,</a> suggested by <a href="https://github.com/Kristijan1001">Kristijan1001</a>, solving issues with cloud flickering and missing geometry in The Depths.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./depths.jpeg" title=" Your GPU is fine, it’s just software. (The Legend of Zelda: Tears of the Kingdom)"><img src="./depths.jpeg" alt=" Your GPU is fine, it’s just software. (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your GPU is fine, it’s just software. (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>Next is a bug that only affected the base game. Following updates were unaffected, as they rendered in a different order.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./red.png" title=" Ganon likes to record Link… (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/red_hud6d4bcc4aeed3191d1fee6deb4efb26a_1662324_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Ganon likes to record Link… (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Ganon likes to record Link… (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>This mysterious red dot on the right was caused by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10243" data-gh-pr="10243">incorrectly tracking</a> render target indexes when clearing. Thanks to some behaviour changes made by Maide, Link is no longer being spied on.</p> <p>After the game was released, several users reported that the date in the game&rsquo;s save files was always set to January 1st, 1970. After checking the behaviour of the Switch, byte[] implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10244" data-gh-pr="10244">a few changes</a> that solved the issue with an updated service implementation that allows for computing the time in nanoseconds, automatically adjusting for clock skew, and using the same clock source as the system’s steady clock.</p> <p>There were also reports of graphical glitches when using the 2X resolution scaling factor: Link and terrain textures would become corrupted after switching weapons.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./2x.png" title=" Scrambled textures. (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/2x_hud4ddb31e2abf39c65898258ea642c893_2656586_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Scrambled textures. (The Legend of Zelda: Tears of the Kingdom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Scrambled textures. (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>Blinkhawk quickly found the cause of this problem: wrong clears were performed in the code responsible for synchronization in the buffer cache. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10249" data-gh-pr="10249">Some tweaks,</a> and the game can be safely played while scaled.</p> <p>For the Linux AMD users, especially those not using the latest Mesa RADV Vulkan driver releases, byte[] found that one of the features of <code>VK_EXT_extended_dynamic_state3</code>, dynamic depth clamp, was implemented incorrectly in the driver, leading to vertex explosions in some expository moments in the game.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/radvbug_hu3e3fbdd95b8c532ec485605a68ef924b_215985_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Oh, there goes the vertex… (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/radvfix_hu21bf0834f03b5ea53d95076456c9f7f6_2208018_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Oh, there goes the vertex… (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Oh, there goes the vertex… (The Legend of Zelda: Tears of the Kingdom)</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10262" data-gh-pr="10262">Disabling the feature</a> for the affected driver version and older solves this issue.</p> <p>Another identified issue affected the light projection made by the Ultrahand ability, intended to help the player position objects. The green glow had a pixelated look, caused by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10402" data-gh-pr="10402">missing barriers on attachment feedback loops.</a> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="./ultrabug.jpg" alt="Green Lantern hand. (The Legend of Zelda: Tears of the Kingdom)"> <img src="./ultrafix.jpg" alt="Green Lantern hand. (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Green Lantern hand. (The Legend of Zelda: Tears of the Kingdom)</p> <p>Several keyboard strokes later, and byte[] went green with envy.</p> <p>Next on the list of weird rendering issues is one that affected camera changes — for example, when talking to an NPC or aiming with the bow/throwing a weapon. Large areas in front of the player would turn black for a frame and then return to normal. Needless to say, it was very distracting.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./bow.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> A bow so cursed, it tries to take you to the Shadow Realm! (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <p>This bug was caused by the way the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10418" data-gh-pr="10418">texture cache</a> processed aliases and overlaps, which were in the wrong order and caused sync problems. After a few tries by Blinkhawk and byte[], the issue was finally fixed.</p> <p>While investigating bugs related to <code>Tears of the Kingdom</code>, a copy-paste error hidden in the code for 3 years was also found. In the shader recompilation code, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> copied over the wrong value from one line to the next. This is another interesting case of the problem not being an issue until now, as no one noticed this bug until Zelda needed rescuing again&hellip; By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10459" data-gh-pr="10459">changing a single character,</a> byte[] solved the terrain gaps that could be spotted from a distance all over the map, but most noticeably in The Depths.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/gapbug_hu499b45ba78b0d6d67f03437b528d7810_2847630_1024x0_resize_q90_bgffffff_box_3.jpg" alt="What’s deeper than The Depths? (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/gapfix_hufe7d491bb8f69350d1ae04f2af87db62_2833307_1024x0_resize_q90_bgffffff_box_3.jpg" alt="What’s deeper than The Depths? (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">What’s deeper than The Depths? (The Legend of Zelda: Tears of the Kingdom)</p> <p>In an interesting case where a UI setting is needed to improve a game’s rendering, byte[] added an option to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10464" data-gh-pr="10464">clean the cache storage for a game,</a> which can be accessed from the <code>Remove</code> menu when right clicking a game in yuzu’s game list.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./remove.png" title=" It’s fun to watch the game reconstruct the images in real time."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/remove_hu11d246035b50058ef89bca88801cf802_29282_790x0_resize_q90_bgffffff_box_3.jpg" alt=" It’s fun to watch the game reconstruct the images in real time."></a> <p class="has-text-centered is-italic has-text-grey-light"> It’s fun to watch the game reconstruct the images in real time.</p> </div> </div> <p>This option is needed because using Asynchronous shader building in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced</code> will mess up fused weapon icons in the weapon selection menu, as well as autobuild history.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/cachebug_hua9a14e9e9ea5142730f8724f2b9950ce_2680105_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Not even close, baby! (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/cachefix_huef5336b2385dcd7ea9d9005c249bbfb3_2885615_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Not even close, baby! (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Not even close, baby! (The Legend of Zelda: Tears of the Kingdom)</p> <p>Disabling Asynchronous shader building and clearing the cache storage lets the game properly rebuild the images of all your weaponized abominations.</p> <p>That’s the progress so far with <code>The Legend of Zelda: Tears of the Kingdom</code>! You may have noticed there are no performance improvements mentioned here. We’re following one of the most important rules of coding, “Make it work. Make it right. Make it fast.”</p> <p>As this is a particularly popular game (and for good reason), here are some recommendations that user reports and fixes have taught us.</p> <ul> <li>This game is very demanding on hardware. What we list in yuzu’s <code>recommended</code> <a href="https://yuzu-mirror.github.io/help/quickstart/#hardware-requirements">hardware requirements</a> is the minimum needed to sustain 30 FPS in most areas. A 6-core desktop Zen 2/11th gen Core, 16GB of RAM, and a GPU with at least 6GB of VRAM are the baseline for now.</li> <li>The latest CPUs (Zen 4/13th gen Core, always speaking of desktop products) provide massive improvements in IPC, RAM bandwidth, and cache sizes. Where a Ryzen 7 5800X3D barely manages 55 FPS, a Ryzen 5 7600 reaches 90 FPS.</li> <li>Normal GPU accuracy can be used to improve performance safely.</li> <li>Unsafe CPU accuracy can improve performance at the cost of small inaccuracies.</li> <li>Enabling asynchronous presentation degrades performance a bit.</li> <li>Don&rsquo;t use <code>Decode ASTC textures asynchronously</code> for this game, it will cause crashes.</li> <li>In some rare cases audio events can cause crashes, so be careful when using multi-arrow bows and bombs.</li> <li>The Depths are particularly hungry for VRAM. Remember to use ASTC recompression if you are VRAM starved. We recommend at least 8GB of VRAM for 2X resolution scaling using BC3 compression.</li> <li>The modding community has been providing amazing mods. Dynamic framerate, improved resolution and details, and much more are only a few clicks away. Here’s a <a href="https://github.com/HolographicWings/TOTK-Mods-collection">collection with recommendations</a>.</li> <li>Old FPS mods compatible with the base version of the game (1.0.0) are unstable and will cause softlocks and crashes during certain actions like the Game Over screen. Update your game and use newer mods.</li> <li>Remember to test the game without mods before reporting issues, as mods are still altering memory regions to work.</li> <li>If you disabled <code>Use Fast GPU Time</code> due to recommendations from modders, do it only for <code>Tears of the Kingdom</code>, as you will be seriously affecting performance in other games. Right clicking a game in yuzu’s game list and selecting properties shows the per-game configuration. We strongly recommend keeping <code>Use Fast GPU Time</code> enabled in all scenarios.</li> </ul> <p><a href="https://www.youtube.com/watch?v=1pN8TvupNn4">Now go. Let the Legend come back to life.</a></p> <h2 id="project-lime">Project Lime</h2> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10508" data-gh-pr="10508">Bet you didn’t expect this.</a> <p>That’s right, with the blessing from Skyline’s <a href="https://github.com/bylaws">bylaws</a>, help from Dolphin’s <a href="https://github.com/t895">t895</a> and Citra’s <a href="https://github.com/GPUCode">GPUCode</a>, work from yuzu’s and Citra’s <a href="https://github.com/FearlessTobi">flTobi</a>, <a href="https://github.com/bunnei">bunnei</a>, <a href="https://github.com/merryhime">Merry</a>, <a href="https://github.com/Schplee">Flamboyant Ham</a>, <a href="https://github.com/german77">german77</a>, and more, yuzu is now <a href="https://yuzu-mirror.github.io/downloads/#android">available for Android devices</a>!</p> <p>We recommend that you read the dedicated yuzu on Android article <a href="https://yuzu-mirror.github.io/entry/yuzu-android/">here</a>. In this section, we will give you an overview of our future plans, some tips on settings and hardware requirements, and a realistic outlook on what you can expect from yuzu on Android right now.</p> <p>The Android version of yuzu was not an easy feat. It took us almost eight months of hard work to make it happen. Right now, the core is essentially the same as the desktop version, with an Android UI and <em>very few</em> platform-specific tweaks. This means you can enjoy features like 32-bit game support, NVDEC video decoding support, motion, controller automapping, resolution scaling, and filters. On the other hand, features like mod and cheat management, LDN, and the controller configuration applet are still under development. Our goal is to gradually have the Android builds reach parity with the PC version.</p> <p>In addition to the Google Play Store, we will soon be posting releases on our GitHub, and F-Droid is also on the horizon.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lime1.png" title=" Don’t judge, it’s a light game and loads quickly, it was great for testing. (Sakura Neko Calculator)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/lime1_hu3025deda088ea43d826cd4ce5d7e4bbf_1119083_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Don’t judge, it’s a light game and loads quickly, it was great for testing. (Sakura Neko Calculator)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don’t judge, it’s a light game and loads quickly, it was great for testing. (Sakura Neko Calculator)</p> </div> </div> <p>One of the biggest lessons we learned from Project Lime is that, even after 8 years since the launch of the NVIDIA Tegra X1 (the SoC that powers the Nintendo Switch), Android SoC vendors still don’t know how to make GPU drivers.</p> <p>They all started working on Vulkan drivers around the same time in 2016. And yet, none of them have managed to deliver a compliant and stable Vulkan Android driver, except for the rare few NVIDIA devices.</p> <p>It is obvious that only 4 vendors have the expertise and the commitment to make Vulkan drivers work: NVIDIA, AMD, and Mesa, with a special mention for Intel, who recently stepped up their game.</p> <p>Although not one of these 4, we decided that limiting support to Qualcomm SoCs was our only option for now if we didn&rsquo;t want to spend several months further modifying our GPU code to accommodate all the quirks and broken extensions of Android phones and tablets. Not because their driver is decent — it’s bad. But it was just good enough to get some games to render, albeit incorrectly most of the time.</p> <p>Qualcomm is the best option (and for now, the only one) because bylaws created <a href="https://github.com/bylaws/libadrenotools">AdrenoTools</a>, which lets users load the <em><strong>vastly</strong></em> superior <a href="https://docs.mesa3d.org/drivers/freedreno.html">Mesa Turnip</a> drivers on their Adreno 600 series GPUs, providing more accurate rendering, comparable to the quality expected of PC products. Any Qualcomm SoC with a name like “Snapdragon ###” from the 460 to the 888+ equipped with an Adreno 600 series GPU can choose to use either the proprietary Qualcomm driver or Mesa Turnip.</p> <p>The performance gain you can expect from a device with a Snapdragon Gen 1 or Gen 2 is quite significant. But the problem is that, while the Adreno 700 series GPU that comes with it is very powerful hardware-wise, the proprietary Qualcomm driver for it is subpar at best, and Mesa has only just begun to work on adding support for Turnip. There&rsquo;s an early driver release to test, but results are not great for now. It will take weeks, if not months, before we see proper support emerge. In the meantime, we intend to work on improving the rendering on the official Adreno drivers.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./driver.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/driver_hu79e5580693449f2927282912ff23d783_115103_800x0_resize_q90_bgffffff_box_3.jpg" alt="Try several, don’t marry the first one that works. Divorcing a shader cache isn’t fun."></a> </div> <div class="column is-bottom-paddingless"> <a href="./driver2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/driver2_hu79e5580693449f2927282912ff23d783_116167_800x0_resize_q90_bgffffff_box_3.jpg" alt="Try several, don’t marry the first one that works. Divorcing a shader cache isn’t fun."></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Try several, don’t marry the first one that works. Divorcing a shader cache isn’t fun.</p> <p>The Adreno 500 series is too outdated for yuzu. Its proprietary Vulkan driver is missing many of the essential features required, and Turnip has no plans to support it either.</p> <p>Mali is an example of good but weak hardware being limited by the quirks of its available drivers. Unlike Adreno, Mali has no viable Mesa alternative to rescue it, and the current proprietary Mali drivers are in bad shape for Switch emulation. Its current status is that it won’t boot any game on yuzu, but:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mali.jpg" title=""><img src="./mali.jpg" alt="Internal dev build, work-in-progress in getting G series Mali running."></a> </div> <div class="column is-bottom-paddingless"> <a href="./mali2.jpg" title=""><img src="./mali2.jpg" alt="Internal dev build, work-in-progress in getting G series Mali running."></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Internal dev build, work-in-progress in getting G series Mali running.</p> <p>We’re working on solving all the quirks needed to get Mali rendering on yuzu as soon as possible. This is the most common GPU vendor on the platform after all. Mali support will happen, we just need some time. Expect news very soon!</p> <p>The last case of hardware that should work, but doesn’t, is the AMD RDNA2-based Xclipse 920 from Samsung, used only in the latest Exynos 2200 SoC, and somehow completely skipped from the S23 series phones. Available information suggests that it may just be an old AMD Windows driver ported to Android, but for some reason the devices refuse to start rendering on yuzu. This is a GPU we want to get working, as there is no clear reason why it doesn&rsquo;t work, while desktop AMD products work almost flawlessly. Unfortunately, we haven&rsquo;t yet been able to get our hands on one, but we&rsquo;ll update with more info once we do.</p> <p>For all other vendors like PowerVR, Vivante, etc: don&rsquo;t bother. These vendors offer such low quality drivers that support is impossible.</p> <p>We’re working hard on improving GPU compatibility, adding the necessary changes needed to boot within the limitations set by the vendors.</p> <p>CPU emulation still relies on the Dynarmic JIT, instead of native code execution. This allows us to run 32-bit games like <code>Mario Kart 8 Deluxe</code>, but is slow for 64-bit games. Expect “good” compatibility, similar to the desktop version thanks to this, but also low performance and high temperatures. Native code execution, or NCE (do I smell <code>Project Nice</code>?) is on our list of goals for the Android builds.</p> <p>The CPU itself, while very crucial for performance and the main bottleneck for now, is less important than the GPU, for the reasons previously mentioned (the drivers). The same rules as on PC apply here: 6 cores or more is preferred, and the highest possible IPC is strongly recommended. A Snapdragon 8 Gen 2 can be twice as fast as a Snapdragon 865.</p> <p>RAM use is both a blessing and a curse. A blessing because Android devices natively support ASTC textures — the format is designed for such devices. This allows the GPU to use very little RAM, just like on the Switch.</p> <p>The curse is that, because Android is such a heavy OS, there is no guarantee that complex games will run on devices with 6GB of RAM. 8GB is the strong recommendation, which puts compatibility on the pricey side of the spectrum. A certain Zelda game we wrote a lot about currently requires at least 12GB of RAM to run.</p> <p>There are ongoing efforts to reduce memory requirements, such as native code execution and <a href="https://en.wikipedia.org/wiki/Unified_Memory_Architecture">UMA</a> optimizations for the GPU code, but the reality is that emulation adds overhead and Android will only get fatter over time. We may be able to get light 2D games running on 4GB devices, but we don&rsquo;t expect complex 3D games to run on less than 8GB any time soon, if ever.</p> <p>We have set the minimum required operating system to Android 11. This decision was made to prevent installation on completely unsuitable hardware (like Adreno 500 series devices or older T series Mali GPUs), and to reduce installation on low-memory devices as much as possible. This is final, as there are no plans to support older Android versions.</p> <p>Of course, it must be a 64-bit Android 11 or newer; just like on desktop, 32-bit devices will never be supported.</p> <p>Users with capable hardware stuck on older Android versions can either build yuzu themselves and remove the code responsible for performing this check, or install custom ROMs such as <a href="https://lineageos.org/">LineageOS</a> to get unofficial Android updates on their device.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lime2.png" title=" Your writer will enjoy playing visual novels and simple platformers. (The Liar Princess and the Blind Prince)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/lime2_hueff6b71be2e0d0f9bb98040525381bef_1762391_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Your writer will enjoy playing visual novels and simple platformers. (The Liar Princess and the Blind Prince)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your writer will enjoy playing visual novels and simple platformers. (The Liar Princess and the Blind Prince)</p> </div> </div> <p>Now that we have covered the harsh reality of Android software and hardware, let’s focus on the current experience.</p> <p>We included a customisable input overlay with haptics, which can be disabled if you prefer to play with a Bluetooth Xbox controller, Sony Dualshock 4 or Dual Sense, or a Nintendo Pro Controller, and a framerate counter. You can access these settings in-game by dragging from the left side of the screen.</p> <p>If you updated from a previous version, the overlay may be invisible. Just select <code>Overlay Options &gt; Reset Overlay</code> to make it visible again.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./settings1.png" title=" Set as you see fit. (Cooking Mama: Cookstar)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/settings1_hue4d1bdf3d0261eecda07c557799ce8e2_1136719_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Set as you see fit. (Cooking Mama: Cookstar)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Set as you see fit. (Cooking Mama: Cookstar)</p> </div> </div> <p>While playing a game you can select Settings from the left menu, or select it from the main menu.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./settings2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/settings2_hu49138a21e1d583ef4777a555be7a1086_114570_800x0_resize_q90_bgffffff_box_3.jpg" alt="Expect this tab to expand in the coming months."></a> </div> <div class="column is-bottom-paddingless"> <a href="./settings3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/settings3_huffda48ad9043c8eec40ecef47ef12a69_151188_800x0_resize_q90_bgffffff_box_3.jpg" alt="Expect this tab to expand in the coming months."></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Expect this tab to expand in the coming months.</p> <p>Here you will find setting and customization options. Most are self-explanatory, but if you want explanations for the options in Advanced settings, check our settings glossary <a href="https://community.citra-emu.org/t/settings-glossary/768483">here</a>.</p> <p>After the initial configuration is done, just tap a game and play. A search option is available for your convenience, along with a few search filters.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./list.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/list_hu2320918461605780dbcca582471489a6_2209877_800x0_resize_q90_bgffffff_box_3.jpg" alt="Choose your destiny."></a> </div> <div class="column is-bottom-paddingless"> <a href="./search.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/search_hud0f3348da429cdff75027bfc9d114daa_1605280_800x0_resize_q90_bgffffff_box_3.jpg" alt="Choose your destiny."></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Choose your destiny.</p> <p>One of the first improvements added by <a href="https://github.com/PabloG02">PabloG02</a> is a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10534" data-gh-pr="10534">save manager</a> that can be accessed from the Settings. This makes importing and exporting saves very simple. Thank you!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./saves.png" title=" It’s dangerous to go alone, take this!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/saves_hu645ef100a855fb762da9c3fedb9aeb66_117171_540x0_resize_q90_bgffffff_box_3.jpg" alt=" It’s dangerous to go alone, take this!"></a> <p class="has-text-centered is-italic has-text-grey-light"> It’s dangerous to go alone, take this!</p> </div> </div> <p>One important thing to remember: Android has the most… unusual file system permissions. We recommend creating a yuzu folder on your storage root to store your keys, as to avoid any permissions issues.</p> <p>You can get different Adreno and Turnip driver versions to test from <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases">here</a>. Keep in mind, this option will only change the driver for yuzu. It won’t (and can’t) replace anything on a system level.</p> <p>At the time of writing, we recommend <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v23.2.0-dev">Turnip 23.2.0</a> (or <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v23.1.0-dev">23.1.0</a> if you have Android 11) for Adreno 600, while Adreno 700 users can run the <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v676.22FIX">Qualcomm 676.22</a> driver to improve performance and compatibility somewhat.</p> <p>There’s an early alpha Turnip release supporting Adreno 730 and 740 products (but not 725) <a href="https://github.com/K11MCH1/AdrenoToolsDrivers/releases/tag/v23.2.0_A7XX">here</a>. It is also compatible with Adreno 600 series hardware, so it’s a simple global driver to test.</p> <p>There have been reports of users not being able to load custom drivers — we are still investigating this, but there&rsquo;s still a lot of work to do.</p> <p>For those interested in playing with the source, we have a work-in-progress build guide <a href="https://yuzu-mirror.github.io/wiki/building-for-android/">here</a>.</p> <p>That’s all fo… What do you mean there’s still a whole article to write? Oh right, we have more to talk about!</p> <h2 id="other-graphical-changes">Other graphical changes</h2> <p>Because this isn’t just a Zelda emulator after all.</p> <p>Who wants more <code>Project Y.F.C.</code> goodies? Blinkhawk serves us <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10155" data-gh-pr="10155">Reactive Flushing,</a> with fries.</p> <p>In the early days of yuzu, if the CPU were to read an area modified by the GPU, full sync flushing between the host and guest GPU (emulated and system’s GPU) would trigger (let’s call it “old reactive flushing”). This was safe and rendered things properly, but was also slow. Blinkhawk replaced this system with predictive flushing some years ago, improving performance significantly but introducing several graphical regressions, such as broken shadows and lighting, wrong thumbnails on saves and photos, and even vertex explosions.</p> <p>With this release of the yuzu fried chicken, Blinkhawk introduces the new Reactive Flushing, which has the following fixes:</p> <ul> <li>Fixes old regressions such as <code>Bayonetta 2</code>&rsquo;s shadows.</li> <li>Fixes lighting in <code>Xenoblade Chronicles</code> games.</li> <li>Improves performance in buffer-heavy games like <code>Monster Hunter Rise</code>.</li> <li>Thumbnails and in-game photos in a bunch of games such as: saves in <code>Xenoblade Chronicles Definitive Edition</code> and <code>Xenoblade Chronicles 3</code>, camera photos in <code>ASTRAL CHAIN</code>, and partially fixes thumbnails in <code>Luigi's Mansion 3</code>.</li> <li>Vertex explosions in <code>Pokemon Violet/Scarlet</code> and <code>Yoshi’s Crafted World</code>.</li> <li>Make High GPU Accuracy fully use asynchronous buffers in Vulkan, improving performance.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rf1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf1_hu8dbdccbc6ed361d5e89f2d55e23c50ba_4823016_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Bayonetta 2, ASTRAL CHAIN, Xenoblade Chronicles Definitive Edition, and Luigi’s Mansion 3"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rf2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf2_hu1f096d0b69a6735dffe23ed72d798c9e_224002_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Bayonetta 2, ASTRAL CHAIN, Xenoblade Chronicles Definitive Edition, and Luigi’s Mansion 3"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rf3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf3_hu99696c8b361a4017b324bb9289331f33_807874_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Bayonetta 2, ASTRAL CHAIN, Xenoblade Chronicles Definitive Edition, and Luigi’s Mansion 3"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rf4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf4_hu34564d58e04b064fb3a255d797339f18_1115335_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Bayonetta 2, ASTRAL CHAIN, Xenoblade Chronicles Definitive Edition, and Luigi’s Mansion 3"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From first to last: Bayonetta 2, ASTRAL CHAIN, Xenoblade Chronicles Definitive Edition, and Luigi’s Mansion 3</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rf6.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf6_hudfeaeac304dba5b51f0356eaea661685_2177740_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Mario &#43; Rabbids Kingdom Battle, Pokémon Scarlet, and Yoshi&#39;s Crafted World"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rf7.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf7_hu797db64f8f829402eac55b0e0c4cfe38_1504355_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Mario &#43; Rabbids Kingdom Battle, Pokémon Scarlet, and Yoshi&#39;s Crafted World"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rf8.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rf8_hu05d53871f60f905ec6c5cfbc8b961c40_3548527_800x0_resize_q90_bgffffff_box_3.jpg" alt="From first to last: Mario &#43; Rabbids Kingdom Battle, Pokémon Scarlet, and Yoshi&#39;s Crafted World"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From first to last: Mario &#43; Rabbids Kingdom Battle, Pokémon Scarlet, and Yoshi&#39;s Crafted World</p> <p>The option still carries a performance cost, sometimes a considerable one. It’s enabled by default, but users can disable it from <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Enable Reactive Flushing</code>. If you need the performance, and can tolerate the graphical regressions introduced by disabling it, the option is there.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./reactive.png" title=" If you have performance to spare, keep it enabled."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/reactive_hubd6eef459c8ea3e6a379f091fac92161_14845_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" If you have performance to spare, keep it enabled."></a> <p class="has-text-centered is-italic has-text-grey-light"> If you have performance to spare, keep it enabled.</p> </div> </div> <p>Users with AMD and Intel GPUs complained that high-framerate mods couldn&rsquo;t push the framerate past the display&rsquo;s refresh rate when using Vulkan. This was because the VSync toggle was assuming the best option for each hardware driver based on compatibility.</p> <p>What used to be just VSync on, off, or triple buffer in the good old OpenGL days is now more complex with Vulkan, even if current games insist on mistakenly calling the setting “VSync on” for legacy reasons. In fact, nowadays there are 4 VSync options commonly supported by GPU drivers:</p> <ul> <li>Immediate: No VSync. Tearing will happen, but no framerate restrictions will apply.</li> <li>FIFO: Double buffering. This is equivalent to yuzu’s old VSync on. Tearing won’t happen, but input will have one frame of latency, and the refresh rate can’t exceed the display’s capabilities.</li> <li>Relaxed FIFO: Identical to regular FIFO, but allows for tearing to happen if a desynchronisation happens. Can be considered similar to adaptive VSync. Useful for games with dynamic framerates.</li> <li>Mailbox: Triple buffering, avoids tearing while allowing for framerates higher than the refresh rate of the display. Similar to what AMD calls Enhanced sync, and what NVIDIA calls Fast sync.</li> </ul> <p>Mailbox is the obvious recommendation for most games, so of course only NVIDIA on Windows, Mesa on Linux, and Android drivers offer support for it.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vsync.png" title=" Android has no tolerance for tearing."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/vsync_hu8208f0c845c8bc89fe93622ab7464e50_4915_486x0_resize_q90_bgffffff_box_3.jpg" alt=" Android has no tolerance for tearing."></a> <p class="has-text-centered is-italic has-text-grey-light"> Android has no tolerance for tearing.</p> </div> </div> <p>Per your writer’s <del>begging</del> request, <a href="https://github.com/lat9nq">toastUnlimited</a> updated the old VSync toggle in the Graphics menu to a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10125" data-gh-pr="10125">proper drop list</a> mentioning all available Vulkan options.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mailbox.png" title=" If it is an option, pick Mailbox."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/mailbox_hu0cfaecfd579b213e5427a84ff9fe5935_31918_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" If it is an option, pick Mailbox."></a> <p class="has-text-centered is-italic has-text-grey-light"> If it is an option, pick Mailbox.</p> </div> </div> <p>If, for example, someone with an AMD or Intel GPU on Windows wants to play <code>Super Smash Bros. Ultimate</code> with a 120 FPS mod on a 60 Hz display, they now have the option to use Immediate mode, which is what the emulator switches to when the player unlocks the framerate with Ctrl + U. The rest can just enjoy Mailbox.</p> <p>We recommend setting the driver’s control panel to Enhanced/Fast sync for the best results.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./amd.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/amd_hu68872be7292166c3d641d27f66b99701_481412_800x0_resize_q90_bgffffff_box_3.jpg" alt="Press F to sync"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nvidia.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/nvidia_hua5e5873b92bd27e4a2cc31b038ec2870_77019_800x0_resize_q90_bgffffff_box_3.jpg" alt="Press F to sync"></a> </div> <div class="column is-bottom-paddingless"> <a href="./intel.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/intel_hu6d3abb7448a4b00d0dcb1390428ba7fe_90849_800x0_resize_q90_bgffffff_box_3.jpg" alt="Press F to sync"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Press F to sync</p> <p>Maide found an issue related to the size of the pipeline cache. yuzu used to return the size of the shader code in bytes, which was later used to resize the unsigned 64 bit integer array in charge of storing the cache, making the array 8 times larger than it was supposed to be. This is fixed by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10145" data-gh-pr="10145">using the length of the array</a> instead of the size in bytes.</p> <p>A common complaint from users with 8GB of RAM is that games become unstable over time. This isn&rsquo;t necessarily a memory leak — it&rsquo;s likely just the system running out of RAM as new shaders are added to the pipeline cache. This change greatly benefits them. <del>But it’s 2023, you should seriously consider getting 16GB by now. Tears of the Kingdom is not Super Mario Odyssey.</del></p> <p>ASTC continues to be in the news here — this time a problem with <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10206" data-gh-pr="10206">3D ASTC</a> textures, because it isn’t enough to deal with flat 2D ones. A bug in their implementation caused the level Frantic Fields in <code>Donkey Kong Country: Tropical Freeze</code> to render incorrectly. Some tweaks by the ‘hawk, and the Kong army is back in action.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dk.png" title=" No more quicksand! (Donkey Kong Country: Tropical Freeze)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/dk_huf12c2bfd48914622096c4076786a9c57_3069171_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" No more quicksand! (Donkey Kong Country: Tropical Freeze)"></a> <p class="has-text-centered is-italic has-text-grey-light"> No more quicksand! (Donkey Kong Country: Tropical Freeze)</p> </div> </div> <p>yuzu&rsquo;s buffer cache is responsible for storing most forms of arbitrary data for the GPU to process. Buffers can be modified by either the GPU or the CPU, so yuzu would track the buffer to one type of modification, then wait for the other type of modification to synchronize the data. But in reality, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10216" data-gh-pr="10216">performing the synchronization</a> before tracking the modification would make much more sense. Maide noticed this discrepancy and set out to correct it, streamlining the code.</p> <p>Since the old code would track buffers globally, some draws would end up ignoring channel swaps, leading to leftover values from the wrong channel getting bound in uniform buffers. If instead we <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10469" data-gh-pr="10469">move buffer bindings</a> to be channel specific, the issue is solved. This fix should affect more games using multiple 3D channels too.</p> <p>Continuing with code optimisations, Maide found some incorrect behaviour in how render targets are selected.</p> <p>The <code>Render Target</code> (The OG RT for rendering devs before RTX came to town) is a texture containing the image to be rendered during a draw or clear operation.</p> <p>The emulator has to look at the format of the available render targets to determine which one to clear. For example, suppose there are 5 images bound as render targets, indexed from <code>0</code> to <code>4</code>, and the game requests to clear the render target with index <code>2</code>. The next step is to look at the format of render <code>target[2]</code> in the array. This is where the old code would work incorrectly and inefficiently, as it would iterate through all the render targets and pick the first one that returned a valid format corresponding to <code>target[2]</code>. This could very well be <code>target[2]</code> as expected, or an earlier render target such as <code>target[0]</code> or <code>target[1]</code>, in which case the code would completely ignore the actual render target we wanted to clear.</p> <p>In short, this process was both slower and potentially unsafe due to the risk of clearing the wrong render target. Not happy with this, Maide worked to sort it out, getting <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10217" data-gh-pr="10217">the correct render target</a> cleared.</p> <p>Time to introduce another term! <code>Descriptor Sets</code> are a feature of the Vulkan API. Their purpose is to allow the CPU to update input bindings, the list of resources used by a shader, in an efficient way.</p> <p>Previously, yuzu would share the same descriptor set update queues between guest operations (operations directly translated from a game) and host operations (operations yuzu performs to emulate specific Switch GPU features which don&rsquo;t exist in Vulkan). This could mistakenly end up with host operations overwriting the descriptor set updates of a guest pipeline during processing. At best, this would break the state of the guest pipeline, and at worst, it would take down the entire GPU driver. If you experienced random crashes in <code>Xenoblade Chronicles</code> games, <code>Luigi’s Mansion 3</code>, <code>Bayonetta 3</code>, among others, you might now know why.</p> <p>So, how can this be solved? “Simple!” Let’s just give the host and guest compute pipelines their own <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10222" data-gh-pr="10222">queues.</a> Having this information in separate queues fixes the data integrity issues, greatly improving stability.</p> <p>Newcomer <a href="https://github.com/danilaml">danilaml</a> identified a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10254" data-gh-pr="10254">missing bitflag</a> in the header responsible for decoding H.264 videos. This fixes video rendering for <code>Layton's Mystery Journey: Katrielle and the Millionaires' Conspiracy</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./layton.png" title=" Games are boring without their cutscenes, right? (Layton&#39;s Mysterious Journey: Katrielle and the Millionaires)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/layton_hu61fe7f70d48a912b3d7702ec39e3685b_903484_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Games are boring without their cutscenes, right? (Layton&#39;s Mysterious Journey: Katrielle and the Millionaires)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Games are boring without their cutscenes, right? (Layton&#39;s Mysterious Journey: Katrielle and the Millionaires)</p> </div> </div> <p>Not stopping there, danilaml also added support for deinterlaced video playback by using the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10283" data-gh-pr="10283">yadif filter</a> included with <a href="https://ffmpeg.org/">FFmpeg</a>, fixing the game&rsquo;s video rendering. Thank you!</p> <p>Intel’s Linux Mesa Vulkan driver, ANV, broke the <code>VK_KHR_push_descriptor</code> extension with version 22.3.0 and later, causing several games to fail to boot. toastUnlimited <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10365" data-gh-pr="10365">disabled the extension</a> to ensure proper game compatibility, and then, after a quick response from the ANV developers fixing the issue, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10414" data-gh-pr="10414">allowed the use</a> of the extension on current Mesa versions. Mesa is an example of how GPU driver development should be done.</p> <p>GPUCode improved overall performance when using Vulkan in a few percentage points by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10474" data-gh-pr="10474">removing a wait semaphore.</a> Every bit helps.</p> <p><a href="https://github.com/ameerj">Epicboy</a> continues his crusade to improve OpenGL. This time, he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10483" data-gh-pr="10483">fixed</a> the use of <code>Accelerate ASTC texture decoding</code> when ASTC recompression was set to Uncompressed.</p> <p>And finally, to close this section, Maide fixed homebrew console apps crashing by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10506" data-gh-pr="10506">skipping a section of the buffer cache</a> that isn’t needed when an app doesn’t use graphics.</p> <h2 id="project-gaia-lite">Project Gaia-lite</h2> <p>byte[] implemented some file system changes on his own, giving us a taste of what’s to come.</p> <p>Here’s a fun one. Why does it take minutes to boot <code>Fire Emblem Engage</code> or <code>Animal Crossing: New Horizons</code> with mods? Because the old implementation became quadratically slower as the number of the files in the game increased!</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10183" data-gh-pr="10183">Fixing</a> the terrible time complexity reduces patch times during boot in <code>Fire Emblem Engage</code> from one and a half minutes to <em>three seconds</em>, and in <code>Animal Crossing: New Horizons</code> from about a minute to <em>one and a half seconds</em>. Wow!</p> <p>That function wasn&rsquo;t the only source of unnecessarily quadratic behavior. Reads also grew quadratically in time with file count, which has now been <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10463" data-gh-pr="10463">optimized,</a> improving in-game load times as well as boot times.</p> <p>Another source of slowdown we&rsquo;ve identified comes from unnecessary copying and freeing of strings, and we plan to address this in Project Gaia in the future.</p> <p>Finally, a savedata reader for <code>cache storage</code> needed to be <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10237" data-gh-pr="10237">stubbed</a> to get <code>Tears of the Kingdom</code> to boot.</p> <h2 id="input-and-amiibo-improvements">Input and Amiibo improvements</h2> <p>HD Rumble is one of the marketed features of the Switch, which is a cool way of saying the official Switch controllers have <code>Linear Resonant Actuators</code> in charge of rumble, instead of the good old rumble motors we were used to in the past.</p> <p>Well, Sony’s DualSense controller also has linear resonant actuators, so in theory, it should be able to emulate HD Rumble. The problem is that SDL, the API we use to support non-Nintendo controllers on yuzu, currently doesn’t expose a way to take advantage of these fancy actuators.</p> <p>Well, newcomer <a href="https://github.com/marius851000">marius851000</a> improved this situation for DualSense owners, so they came up with the idea to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10119" data-gh-pr="10119">change the rumble amplitude</a> based on the frequency requested by the game, with 140-400 Hz operating as the low frequency, and 200-700 Hz as the high frequency. This way, some sense of “rumble audio”, and an overall better shaky-shaky experience, is achieved. Thank you!</p> <p>To help you see if the motion controls are working, german77 has added a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10167" data-gh-pr="10167">cute little cube</a> to the controller preview. Feel free to play with it!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./motion.png" title=" Warning, it’s addictive."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/motion_hu5a14615918c04a3900571ae7311923ba_33611_489x0_resize_q90_bgffffff_box_3.jpg" alt=" Warning, it’s addictive."></a> <p class="has-text-centered is-italic has-text-grey-light"> Warning, it’s addictive.</p> </div> </div> <p>Stick drift is not the only fear for gamers using controllers, there’s also the rarer <em>motion drift!</em> This could happen naturally, or after some <em>serious gaming</em> moments, so an option for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10203" data-gh-pr="10203">recalibration</a> was needed. Thankfully german77 took care of it, adding the option if you right click the Motion # mapping in <code>Emulation &gt; Configure… &gt; Controls</code>. If you use it, remember to leave the controller/device on a flat surface for at least 5 seconds so the process can take place.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gyro.png" title=" Stop shaking!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/gyro_hud5dc13a28e9fbe9cdfd4f257119508a4_28667_499x0_resize_q90_bgffffff_box_3.jpg" alt=" Stop shaking!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Stop shaking!</p> </div> </div> <p>Now something for the <del>dirty cheaters</del> open-minded players out there. Games will block trying to use the same Amiibo more than once, so german77 added a way to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10207" data-gh-pr="10207">randomly generate a new ID</a> each time the Amiibo is used. The option can be enabled from <code>Emulation &gt; Configure.. &gt; Controls &gt; Advanced &gt; Use random Amiibo ID</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./id.png" title=" Bottom right corner, can’t miss it."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/id_hu98332bea17ee04d2b7ea800ee8f5ed2a_37465_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Bottom right corner, can’t miss it."></a> <p class="has-text-centered is-italic has-text-grey-light"> Bottom right corner, can’t miss it.</p> </div> </div> <p>Keep in mind games like <code>Super Smash Bros. Ultimate</code> will complain if the ID changes.</p> <p>Scanning for Amiibos seems to be a very demanding task for the available Bluetooth bandwidth when using Joy-Cons. To mitigate this, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10265" data-gh-pr="10265">reduced the scan rate</a> from once per frame (30 or 60 Hz) to 5 Hz, and reduced the number of attempts to get valid data to 1 down from 7. This should alleviate the right Joy-Con’s oversaturation of the available Bluetooth bandwidth, reducing stutters considerably.</p> <p>But what if you want to enjoy some Amiibo scanning on your Pro Controller? Previously, support was only available for Joy-Cons. But now, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10344" data-gh-pr="10344">Pro Controllers are also supported!</a> As long as the controller is connected over Bluetooth and the custom Pro Controller driver is enabled in <code>Emulation &gt; Configure.. &gt; Controls &gt; Advanced &gt; Enable direct Pro Controller driver [EXPERIMENTAL]</code>. That EXPERIMENTAL label is in its last days now.</p> <p>Not stopping there with the Amiibo changes, german77 also implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10396" data-gh-pr="10396">full support for Amiibo writing</a> when using a Joy-Con or Pro Controller! This enables the last missing piece for full Amiibo emulation, just as you would use them on the Switch itself.</p> <p>Feel free to scan to your heart&rsquo;s content! As long as you managed to grab one of the plastic things while they were in stock.</p> <p>It&rsquo;s worth mentioning that writing Amiibo data will require dumping the relevant keys. However, if all you want to do is load decrypted Amiibo dumps, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10415" data-gh-pr="10415">added support</a> for using them without needing to dump the Amiibo keys.</p> <p>At this point, the only thing left to complete Amiibo support is to add a manager!</p> <h2 id="audio-and-miscellaneous-changes">Audio and miscellaneous changes</h2> <p>The war against properly shutting down yuzu rages on. This time Maide implements a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10128" data-gh-pr="10128">fix in the DSP engine</a> so it closes before a required system instance is terminated. This way a deadlock is avoided during shutdown, improving the situation slightly. Another battle won, but how many remain?</p> <p>This next one left us wondering&hellip; <a href="https://github.com/ronikirla">ronikirla</a> reported that <code>Pokémon Mystery Dungeon Rescue Team DX</code> would consistently crash due to a read access violation after two hours of gameplay.</p> <p>That’s not a simple bug to track down and fix, yet someone in ronikirla&rsquo;s Twitch chat identified the issue as a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10178" data-gh-pr="10178">bad block check</a> in the address space code and passed along a fix.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pmd.png" title=" Love the art style! (Pokémon Mystery Dungeon Rescue Team DX)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/pmd_hu74176344ca696e4eceaffd94e3b889d8_4269472_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Love the art style! (Pokémon Mystery Dungeon Rescue Team DX)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Love the art style! (Pokémon Mystery Dungeon Rescue Team DX)</p> </div> </div> <p>The change seems to also fix <code>Advance Wars 1+2: Re-Boot Camp</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./aw.png" title=" Bond, yuzu Bond. (Advance Wars 1&#43;2: Re-Boot Camp)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/aw_hu1b26414fd4c4e53c79337156101a36d9_4380502_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Bond, yuzu Bond. (Advance Wars 1&#43;2: Re-Boot Camp)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Bond, yuzu Bond. (Advance Wars 1&#43;2: Re-Boot Camp)</p> </div> </div> <p>Recent changes made to audio emulation improved performance and solved crashes, but also had an interesting regression. Some sound effects played at a slower speed.</p> <p>After doing some extensive reverse engineering, Maide reached the conclusion that due to how the DSP works, a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10221" data-gh-pr="10221">5 ms timeout</a> is needed in the processing wait. With the timeout implemented, <code>SUPER MARIO ODYSSEY</code> and <code>Kirby Star Allies</code>, among others can now play back their audio at full speed.</p> <p><a href="https://github.com/danilaml">danilaml</a> continues to deliver the good stuff. This time, simply <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10362" data-gh-pr="10362">updating cubeb</a> (one of our audio backends, and most of the time the default one) fixed a bug that muted the emulator after waking the PC from sleep. Feel free to close your lids and continue later!</p> <p>Users noticed that after recent changes to fix the wire audio in <code>SUPER MARIO ODYSSEY</code>, audio in many games could desync and sound crackled or distorted. bylaws suggested allowing the audio buffer to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10471" data-gh-pr="10471">wait indefinitely</a> if a queue is too big, so Maide implemented this idea and et voilà, the problem is gone! (Pardon my French; Spanish is cooler).</p> <h2 id="ui-improvements">UI improvements</h2> <p>If your yuzu is configured with multiple user profiles, and the <code>Prompt for user on game boot</code> option in <code>Emulation &gt; Configure &gt; General</code> option is enabled, you will have to click the profile you want to boot and then click OK. Well, for the newcomer <a href="https://github.com/Qigo42">Qigo42</a>, this was unsatisfactory, so they allowed the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10189" data-gh-pr="10189">profile selection pop-up</a> to work with just a double click! Nothing beats quality-of-life changes. Thank you!</p> <p><a href="https://github.com/jbeich">jbeich</a> is back, fixing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10205" data-gh-pr="10205">BSD support</a> again! It’s always good to have more OS alternatives working.</p> <p>Continuing the trend in quality-of-life changes, newcomer <a href="https://github.com/grimkor">grimkor</a> has a nice gift for us.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./context.png" title=" And now, for your convenience…"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/context_hu46997d07b4f2c6fc1abd9425f442806f_3804_211x0_resize_q90_bgffffff_box_3.jpg" alt=" And now, for your convenience…"></a> <p class="has-text-centered is-italic has-text-grey-light"> And now, for your convenience…</p> </div> </div> <p>A <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10352" data-gh-pr="10352">context menu</a> for the filter and antialiasing options! You no longer have to go through the entire list of options if you want to try a different one, simply right click and choose. Thank you!</p> <p>If you double clicked a game in the game list, you could end up double clicking it again or pressing enter before the game list got unloaded, which would cause yuzu to try to load the game twice, and usually just crash. german77 fixed this up by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10482" data-gh-pr="10482">immediately disabling the game list</a> after a game has been launched.</p> <h2 id="hardware-section">Hardware section</h2> <p>We no longer only support the PC! In future articles, we will include any news for Android GPU vendors.</p> <h3 id="nvidia">NVIDIA</h3> <p>We have some good news and a little disappointment for the Green Team. But first, we have some progress with the Maxwell and Pascal situation.</p> <p>In the past, we used to recommend users to stick to older driver releases for the GTX 750/900/1000 series, as anything newer than the 470 driver series was unstable. Thanks to the work done with the garbage collector for <code>Tears of the Kingdom</code>, we now know that the problem with these cards is how the driver handles out-of-memory situations. We were even able to observe it on Turing cards with 4GB, so it wasn&rsquo;t unique to older cards, we just didn&rsquo;t have a game that used VRAM as much as Zelda.</p> <p>We reported our findings to NVIDIA with a test case, so it’s in their hands now.</p> <p>As the VRAM fills up, an AMD card will get slower and slower until it stops working and crashes yuzu, while an NVIDIA GPU would corrupt the entire desktop, taking all the displays with it, sometimes even forcibly rebooting the system.</p> <p>Using the ASTC recompression option helps a lot to avoid this problem. But if it does happen, it can still cause a system lock or reboot, so we need a way to mitigate this while NVIDIA investigates the issue.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/nvidiabug_hu013442e1f034522763ac77510f38d058_1763805_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now playable with only 2GB of VRAM! (The Legend of Zelda: Tears of the Kingdom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/nvidiafix_hu9e782bcf9dfa45b179a0b37047b4e46f_896532_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now playable with only 2GB of VRAM! (The Legend of Zelda: Tears of the Kingdom)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Now playable with only 2GB of VRAM! (The Legend of Zelda: Tears of the Kingdom)</p> <p>Fortunately, we stumbled upon a stopgap measure that solves the problem, and we updated our <a href="https://community.citra-emu.org/t/recommended-settings/319349">recommended settings</a> guide to include it. Just change <code>Vulkan/OpenGL presentation method</code> in the NVIDIA Control Panel to <code>Prefer layered on DXGI Swapchain</code>. The same setting used to get AutoHDR working helps contain the out-of-VRAM crashes. Using this in combination with BC1 ASTC recompression will make old 2GB cards run without crashes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./nvcp.png" title=" This interface is so old…"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/nvcp_hue047e2b4af35569fb587c75128172f73_24253_530x0_resize_q90_bgffffff_box_3.jpg" alt=" This interface is so old…"></a> <p class="has-text-centered is-italic has-text-grey-light"> This interface is so old…</p> </div> </div> <p>Switching to the the good side of news, <a href="https://github.com/HolographicWings/">HolographicWings</a> made an amazing tutorial on how to use <code>DLDSR</code> in yuzu <a href="https://github.com/HolographicWings/TOTK-Mods-collection/blob/main/Guide/Guide.pdf">here</a>. DLDSR is a way to use the Tensor cores available in RTX cards to upscale the image. You can consider it a mix of DLSS and FSR 1.0, as it works for any game, but uses deep learning instead of traditional filters. Needless to say, it’s a great way to improve image quality if you have the hardware to test it.</p> <p>And in other good news, <a href="https://special-k.info/">Special K</a> now supports HDR in Vulkan and it works with yuzu! NVIDIA is still the only supported vendor, as this is only possible thanks to the magic <code>Prefer layered on DXGI Swapchain</code> option, but the quality and customization offered by Special K over AutoHDR is outstanding. That expensive OLED never looked so tempting.</p> <p>Note that we have confirmed in testing that <code>Prefer layered on DXGI Swapchain</code> needs to be manually enabled for Special K to work properly. This also includes other NVIDIA-exclusive goodies such as input lag reduction thanks to NVIDIA Reflex. Feel free to experiment with the app, it&rsquo;s amazing.</p> <p>Here are some comparison pics in .jxr format, they can be opened with the default Photo app included with Windows 11, and an SDR control capture in .png format:</p> <ul> <li>First the scene in <a href="https://github.com/yuzu-emu/yuzu-emu.github.io/blob/hugo/site/content/entry/yuzu-progress-report-may-2023/sdr.png">SDR</a>, the default experience.</li> <li>Windows 11’s <a href="https://github.com/yuzu-emu/yuzu-emu.github.io/blob/hugo/site/content/entry/yuzu-progress-report-may-2023/autohdr.jxr">AutoHDR</a> with the Cemu renaming trick.</li> <li>SpecialK’s HDR with <a href="https://github.com/yuzu-emu/yuzu-emu.github.io/blob/hugo/site/content/entry/yuzu-progress-report-may-2023/specialk.jxr">Perceptual Boost disabled</a>.</li> <li>SpecialK’s HDR with <a href="https://github.com/yuzu-emu/yuzu-emu.github.io/blob/hugo/site/content/entry/yuzu-progress-report-may-2023/specialkpb.jxr">Perceptual Boost enabled</a>.</li> </ul> <p>Keep in mind, Special K needs to be tuned to the capabilities of the display, and my humble 350 nit Gigabyte G27Q is a disservice to what this change can do on actually good HDR displays. Expect better results if you have an OLED, or a display with dimming zones and a higher peak brightness.</p> <p>Now, on to the disappointing news: the RTX 4060 Ti.</p> <p>We don’t understand what kind of decisions NVIDIA took when deciding the Ada Lovelace GeForce product stack, but it has been nothing but mistakes. The RTX 4060 Ti 8GB with only a 128-bit wide memory bus and GDDR6 VRAM is a serious downgrade for emulation when compared to its predecessor, the 256-bit wide equipped RTX 3060 Ti. You will be getting slower performance in Switch emulation if you get the newer product. We have no choice but to advise users to stick to Ampere products if possible, or aim higher in the product stack if you have to get a 4000 series card for some reason (DLSS3 or AV1 encoding), which is clearly what NVIDIA is aiming for.</p> <p>The argument in favour of Ada is the increased cache size, which RDNA2 confirmed in the past helps with performance substantially, but it also has a silent warning no review mentions: if you saturate the cache, you’re left with the performance of a 128-bit wide card, and it’s very easy to saturate the cache when using the resolution scaler — just 2X is enough to tank performance.</p> <p>Spending 400 USD on a card that has terrible performance outside of 1X scaling is, in our opinion, a terrible investment, and should be avoided entirely. We hope the 16GB version at least comes equipped with GDDR6X VRAM, which would increase the available bandwidth and provide an actual improvement in performance for this kind of workload.</p> <h3 id="amd">AMD</h3> <p>AMD has shown steady progress with each new driver release and, thanks to this, the experience on yuzu is in very good shape for Radeon owners, besides some documented hardware limitations causing graphical issues we&rsquo;ve mentioned <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/#amd-delivering-on-their-promises">in the past</a>.</p> <p>The main exception is a rendering issue affecting <code>Tears of the Kingdom</code>, which only happens with RDNA3 hardware, the RX 7000 series.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rdna1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rdna1_huba7fb081b6abfe4dc05cb4142b8c0b37_180216_800x0_resize_q90_bgffffff_box_3.jpg" alt="Both the RX 7900 and RX 7600 series are affected. (The Legend of Zelda: Tears of the Kingdom)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rdna2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rdna2_hucbdf059d8a2682edf0f036817329fb07_238824_800x0_resize_q90_bgffffff_box_3.jpg" alt="Both the RX 7900 and RX 7600 series are affected. (The Legend of Zelda: Tears of the Kingdom)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rdna3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/rdna3_hu175162c6e17dd125a4cc3e3c9b305672_240888_800x0_resize_q90_bgffffff_box_3.jpg" alt="Both the RX 7900 and RX 7600 series are affected. (The Legend of Zelda: Tears of the Kingdom)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Both the RX 7900 and RX 7600 series are affected. (The Legend of Zelda: Tears of the Kingdom)</p> <p>As you can see, the textures get mangled in an interesting way. We couldn’t find any issue in the code, and older hardware is not affected, so we submitted a simple test case to AMD to demonstrate the extent of the problem. Affected users will have to wait to see if future driver updates solve this.</p> <h3 id="intel">Intel</h3> <p>After the… peculiar <a href="https://github.com/IGCIT/Intel-GPU-Community-Issue-Tracker-IGCIT/issues/159">discussion</a> we had with Intel regarding their drivers and how they handle bug reports, we are happy to announce the <a href="https://www.intel.com/content/www/us/en/download/729157/intel-arc-iris-xe-graphics-beta-windows.html">latest public beta driver</a> solves the SPIR-V issues we reported seven months ago! We strongly recommend Intel Windows users to update to this driver to improve stability with most games.</p> <p>Sadly, fixing this issue showed us two areas where yuzu is at fault. But luckily both issues have fixes in testing in the latest Early Access release (at the time of writing). If everything goes according to plan, they should hit Mainline in a few days. Stay tuned.</p> <p>The first problem is in yuzu&rsquo;s code. Some compute shaders have barriers in places that result in generating invalid SPIR-V code, and while NVIDIA and AMD have no problem with it, Intel is following the Vulkan specification much more closely and doesn’t like the result, leading to crashes. While we test the solution, for now we recommend Mainline Intel users to keep the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10181" data-gh-pr="10181">freshly added</a> <code>Enable Compute Pipelines (Intel Vulkan only)</code> disabled in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./compute.png" title=" This is just temporary (famous last words…)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2023/compute_hu99131a1e93851dbfb303e19b6f4d772f_19272_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" This is just temporary (famous last words…)"></a> <p class="has-text-centered is-italic has-text-grey-light"> This is just temporary (famous last words…)</p> </div> </div> <p>The other issue is a hardware limitation. Intel decided to remove support for Float64 operations on their Generation 12 graphics products (UHD 700/Xe/Arc) without providing a driver fallback. Well, it turns out that, for unknown reasons, <code>Tears of the Kingdom</code> requires over the top precision in its cutscenes — precision that current Intel hardware physically lacks, causing us to crash when building the shader. We’re testing a Float64 to Float32 shader conversion to solve the problem. For now, Mainline Intel users will want to use a save that&rsquo;s past the intro cutscene, or use OpenGL, as the OpenGL spec dictates that Float64 must be supported one way or another, even if it is via software emulation.</p> <p>Currently, the game is playable at a mostly-consistent 30 FPS with an i5 1240P running an Iris Xe iGPU (if you stick to handheld rendering), and exhibits better performance than AMD&rsquo;s Vega iGPUs.</p> <p>For those interested in the experience with desktop products, here is footage captured with an Arc A770 16GB:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./totk.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Arc is viable! (The Legend of Zelda: Tears of the Kingdom)</p> </div> </div> <h2 id="future-projects">Future projects</h2> <p>We don’t have much to announce for now regarding ongoing projects — we were very busy with <code>Tears of the Kingdom</code> and the Android release!</p> <p>GPUCode is working on a couple of cool things. One of them is implementing a way to have an equivalent to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10545" data-gh-pr="10545">DXGI presentation</a> working on Intel and AMD hardware; that way, AutoHDR can be used with any GPU vendor, not just NVIDIA.</p> <p>That’s all folks! For real this time. If you&rsquo;ve reached this point, thank you for your patience and for reading to the end. We hope you&rsquo;ve enjoyed this mega-report! See you next month! <del>We all need some sleep…</del></p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> New Platform Release - yuzu on Android https://yuzu-mirror.github.io/entry/yuzu-android/ Tue, 30 May 2023 00:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-android/ <p>Hey there, yuz-ers! We are happy to announce that yuzu is available, today, for Android! There&rsquo;s so much to discuss and show you, let&rsquo;s get started!</p> <p>Hey there, yuz-ers! We are happy to announce that yuzu is available, today, for Android! There&rsquo;s so much to discuss and show you, let&rsquo;s get started!</p> <p> </p> <h1 id="where-do-i-get-it">Where do I get it?</h1> <p>If you&rsquo;re too excited, you can jump in immediately by downloading yuzu from the Google Play Store!<br></p> <article class="message" style="border-radius:10px;"> <div class="message-header" style="border-radius:10px 10px 0 0;"> <p>Download yuzu for free, or support us and receive some fantastic benefits with Early Access.</p> </div> <div class="message-body" style="text-align: center;"> <div class="columns is-desktop"> <div class="column"> <a href="https://play.google.com/store/apps/details?id=org.yuzu.yuzu_emu"> <div style="align-items: center"><img alt="yuzu mainline" src="./svg/mainline.svg" width="400"></div> <img alt="Get it on Google Play" src="https://play.google.com/intl/en_us/badges/static/images/badges/en_badge_web_generic.png" width="200"> </a> </div> <div class="column"> <a href="https://play.google.com/store/apps/details?id=org.yuzu.yuzu_emu.ea"> <div style="align-items: center;"><img alt="yuzu early access" src="./svg/early_access.svg" width="400"></div> <img alt="Get it on Google Play" src="https://play.google.com/intl/en_us/badges/static/images/badges/en_badge_web_generic.png" width="200"> </a> </div> </div> </div> </article> <p>The GitHub releases aren&rsquo;t live yet, but we will edit this article with a link to download them once they are. This initial release won&rsquo;t have parity with the feature-rich Desktop builds of yuzu, but we are looking forward to introducing all the features you love as we fine-tune them for Android.</p> <br> <article class="message"><div class="message-header"> <p>⚠️ Update</p> </div> <div class="message-body"><p style="color:white;"> <b>Standalone GitHub releases are now available <a href="https://github.com/yuzu-emu/yuzu-android/releases/" style="color:#03a9f4;"> here.</a> </b> </p></div></article> <p>Features such as multiplayer over LAN/LDN, Input Profiles, TAS, etc. are not yet available. For now, we want to focus on compatibility and performance as performing cutting-edge emulation on typical Android hardware has several challenges.</p> <p>If you&rsquo;re still reading, make sure to stick around for a little development history, expectations, and compatibility reports!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/botw_hu288dabd54c4df12af13e179000f13198_2015343_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Breath of the Wild (Samsung Galaxy S20 FE, Mesa Turnip GPU driver Vs. Samsung Galaxy S23, Qualcomm proprietary GPU driver)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/botw_adreno_hu48b69fb6684628bb69d2b1fac92e03a3_1694738_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Breath of the Wild (Samsung Galaxy S20 FE, Mesa Turnip GPU driver Vs. Samsung Galaxy S23, Qualcomm proprietary GPU driver)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Breath of the Wild (Samsung Galaxy S20 FE, Mesa Turnip GPU driver Vs. Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <h1 id="why">Why?</h1> <p>In the past year, we have made significant strides in improving both the accuracy and performance of yuzu. And with many more such improvements in progress, we understood that the longer we waited, the more challenging it would become for us to support an Android build.</p> <p>With this public release, all future yuzu development activities will account for, and address, both feature and platform compatibility for Android. This is expected to help facilitate and streamline our development process to better achieve our goal of platform independence.</p> <p>We hope to welcome Android developers interested in lending their expertise to a cutting-edge project and produce new yuzu features, optimizations, and other improvements!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="skyrim.png" title=" You&#39;re finally awake! yuzu on Android launched! (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/skyrim_hud781edb267d9b060700f6e88ea611772_2753287_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" You&#39;re finally awake! yuzu on Android launched! (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> <p class="has-text-centered is-italic has-text-grey-light"> You&#39;re finally awake! yuzu on Android launched! (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)</p> </div> </div> <h1 id="state-of-things-where-are-we-what-can-users-expect">State of things: Where are we? What can users expect?</h1> <p>Before we talk more about where we are and what users can expect, we would like to make a few things clear:</p> <ul> <li> <p>We&rsquo;re committed to improving the feature parity, compatibility, and performance of our Android builds; most improvements for desktop platforms, like Windows and Linux, will also help improve our Android users&rsquo; experience.</p> </li> <li> <p>yuzu Android is in rapid development and early builds should be considered akin to a beta.</p> </li> <li> <p>Expect to see a variety of results regarding compatibility and performance on different devices, discussed in more detail later.</p> </li> </ul> <p>With that out of the way, let&rsquo;s dive into the state of things for yuzu Android.</p> <h2 id="some-background">Some background</h2> <p>Like our sister project, Citra, yuzu has always been developed with multi-platform support in mind. We&rsquo;ve supported major desktop operating systems, such as Windows and Linux, since the earliest builds of yuzu. yuzu&rsquo;s core code has, by design, been kept modular and frontend agnostic to ensure any future efforts to expand supported platforms does not run into unwanted dependency issues.</p> <p>Although we originally couldn&rsquo;t support macOS due to Apple deprecating OpenGL support on it, there has been a recent rekindling of efforts to support macOS using MoltenVK — and it so happens that the new Macs are powered by 64-bit ARM-based Apple Silicon (M1/M2, at the time of writing) SoCs (System-on-Chip). But then we faced another hurdle — Dynarmic&rsquo;s lack of host recompilation support for ARM64.</p> <p>In case you weren&rsquo;t aware, yuzu uses <a href="https://github.com/merryhime/dynarmic">Dynarmic</a> for its CPU emulation. Dynarmic works by recompiling (translating) the Nintendo Switch&rsquo;s (guest) ARM CPU instructions to the user&rsquo;s (host) CPU. And because Dynarmic didn&rsquo;t yet support recompiling guest code for ARM64, yuzu&rsquo;s CPU emulation couldn&rsquo;t work on any of these host CPUs.</p> <p>Thanks to the efforts of <a href="https://github.com/liamwhite">byte[]</a> and <a href="https://github.com/merryhime">merryhime</a>, this hurdle didn&rsquo;t stand in our way for too long. With ARM64 host support ready to go, byte[] set his sights on getting yuzu to work on macOS. But that&rsquo;s a story for another day.</p> <p>By the way, did you know that there are other platforms that use ARM64 SoCs extensively?</p> <h2 id="bringing-yuzu-to-android">Bringing yuzu to Android</h2> <p>Knowing that Dynarmic support for ARM64 host recompilation was underway and that Vulkan support on Android would probably be better than macOS, we were optimistic about getting yuzu working on Android.</p> <p><a href="https://github.com/FearlessTobi">flTobi</a> and <a href="https://github.com/bunnei">bunnei</a> quickly started putting things together, with the first goal to simply get yuzu building for Android. These early builds lacked a working renderer to display graphics, but progress was promising. After some fixes, they got a few 32-bit games such as <code>Mario Kart 8 Deluxe</code> and <code>Captain Toad: Treasure Tracker</code> booting with just the audio.</p> <p>Once the Dynarmic ARM64 support was completed, byte[] joined them and the trio got working on getting the Vulkan renderer backend working on Android. While OpenGL ES didn&rsquo;t pan out, bunnei was able to get yuzu to render basic homebrew on Android with Vulkan:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./proto1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/proto1_hu7d98b4fdf5c238ed23a9bd72a736787e_143512_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> <div class="column is-bottom-paddingless"> <a href="./proto2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/proto2_hu69b8e6990c2f06e174d60a343c3330c1_493248_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./proto3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/proto3_hu838d443e1e1ba4b878618efd8b6f96d7_327396_800x0_resize_q90_bgffffff_box_3.jpg" alt="Snake, try to remember the basics of rendering"></a> </div> <div class="column is-bottom-paddingless"> <a href="./proto4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/proto4_hu09610889b48776ed7123ed31fee600b4_192509_800x0_resize_q90_bgffffff_box_3.jpg" alt="Snake, try to remember the basics of rendering"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Snake, try to remember the basics of rendering</p> <p>With our lead moderator <a href="https://github.com/Schplee">Flamboyant Ham</a> working on a new input overlay design and app themes, <a href="https://github.com/german77">german77</a> started working with them on integrating the input backend to the touch-screen overlay. As a sudden surprise for us, developer <a href="https://github.com/t895">t895</a>, who&rsquo;s been improving <a href="https://github.com/dolphin-emu/dolphin">Dolphin&rsquo;s</a> Android app, accepted our request and joined the team to work on overhauling our app UI.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ui1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/ui1_hu6f59b90a9a19086cdc720f134d322330_321432_800x0_resize_q90_bgffffff_box_3.jpg" alt="Peruse our settings and customize as you see fit!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ui2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/ui2_hu4600dbf20a8fb46467e980eca82b2a1e_134627_800x0_resize_q90_bgffffff_box_3.jpg" alt="Peruse our settings and customize as you see fit!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ui3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/ui3_hu842b9b18c85d57cf7828ed87c6130ac0_124189_800x0_resize_q90_bgffffff_box_3.jpg" alt="Peruse our settings and customize as you see fit!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Peruse our settings and customize as you see fit!</p> <p>Together, with Flamboyant Ham creating the designs and t895 working his dev magic, an onboarding process and search menu were added, helping users select their keys, games folder, and search for titles with ease!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./intro1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/intro1_hu62de5ba706f9889db5cef6161a430b03_131518_800x0_resize_q90_bgffffff_box_3.jpg" alt="Simple and straightforward - our favorite!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./intro2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/intro2_hufd006daf3df20b8b2809baf415a949b0_104201_800x0_resize_q90_bgffffff_box_3.jpg" alt="Simple and straightforward - our favorite!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./search.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/search_hue69d5fd14331a06f2918393a60a118f7_2531671_800x0_resize_q90_bgffffff_box_3.jpg" alt="Simple and straightforward - our favorite!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Simple and straightforward - our favorite!</p> <p>Special thanks to the Citra GPU dev, <a href="https://github.com/GPUCode">GPUCode</a>, for taking their time away from Citra Android and Vulkan development to improve this release with their special sauce <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9973" data-gh-pr="9973">Async Presentation</a> .</p> <h1 id="what-to-expect">What to expect?</h1> <p>Android is a platform that boasts a huge userbase, but brings with it its fair share of problems. As there is a lot of hardware variation for Android devices, compatibility and performance will vary. So, to temper expectations, we would like to clarify our minimum requirements for the near future.</p> <h2 id="hardware-requirements">Hardware requirements</h2> <p>At the moment, yuzu requires devices powered by Qualcomm Snapdragon SoCs which have Adreno GPUs. Devices powered by SoCs like Exynos, Mediatek, etc. are expected to not work at all due to their &ldquo;worse-than-Adreno&rdquo; GPU drivers, at least for the near future.</p> <br> <article class="message"><div class="message-header"> <p>⚠️ Update</p> </div> <div class="message-body"><p style="color:white;"> <b>yuzu now supports Xclipse based and Mali G-series based SoC GPUs.</b> </p></div></article> <p>Also, yuzu on Android has high RAM requirements, therefore fairly high-end devices provide the best experience (e.g. SD 865 and 8GB of RAM or better).</p> <p>yuzu on Android ships with the ability to run custom GPU drivers, such as newer official Adreno drivers, or <a href="https://docs.mesa3d.org/drivers/freedreno.html">Turnip</a> using <a href="https://github.com/bylaws/libadrenotools">libadrenotools</a> to improve the performance on older generation Snapdragon SoCs. Apart from this, there are still many more Android-specific optimizations to be done. We have plenty of opportunity to improve performance, but this explains the current high minimum system requirements.</p> <p>This initial release has been intentionally kept fairly minimal so that we can focus on improving performance and stability. As stated earlier, feature parity with our PC builds is something we&rsquo;re committed to, but expect it to happen slowly and not immediately.</p> <h2 id="performance-and-compatibility">Performance and Compatibility</h2> <p>Regarding software requirements, yuzu requires Android 11 or newer and a myriad of mandatory Vulkan extensions that the Play Store will automatically check for. That being said, the Android GPU driver ecosystem is very inconsistent; not all devices will be the same. Being able to download and install yuzu doesn&rsquo;t mean the performance or compatibility will be great. As expected, Qualcomm is (currently) king here.</p> <p>All Qualcomm device users will have the option to test different Mesa Turnip driver versions, thanks to <a href="https://github.com/bylaws/libadrenotools">libadrenotools</a>. We will link them in our <a href="https://discord.gg/u77vRWY">Discord server</a>. You can download any compatible drivers, and select them by going to <code>Settings &gt; Install GPU Driver &gt; Install</code> in yuzu.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gpu_driver_install.png" title=" Just tap on Install!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/gpu_driver_install_hu567ffde8e7b5ab42484669911065be2a_218201_540x0_resize_q90_bgffffff_box_3.jpg" alt=" Just tap on Install!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Just tap on Install!</p> </div> </div> <p>The latest is not always better, and specific games may prefer specific drivers.</p> <p>Currently, the best compatibility is achieved using Adreno 600 series GPUs running the Mesa Turnip drivers. If you want games to start and render correctly, this is the way to go.</p> <p>The best performance comes from Adreno 700 series hardware (Snapdragon 8 Gen 1 and newer), which won&rsquo;t have Turnip support for a while. While performance is typically higher, you will experience rendering issues or some games refusing to start.</p> <br> <article class="message"><div class="message-header"> <p>⚠️ Update</p> </div> <div class="message-body"><p style="color:white;"> <b>Current Turnip drivers provide good support for both Adreno 600 and 700 series hardware, but performance is still better with official Qualcomm drivers in the few games that render correctly with them.</b> </p></div></article> <p>With that said, take a look at some performance numbers from several games:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./performance.png" title=" Not too shabby for a first release!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/performance_hu2b55b5b504193e5f4d963ad39e9c9a77_33691_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Not too shabby for a first release!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Not too shabby for a first release!</p> </div> </div> <p>We think that devices with Exynos 2200 and newer SoCs running AMD RDNA2 GPUs could also work well, but we haven’t been able to test them out due to how hard they are to find.</p> <br> <article class="message"><div class="message-header"> <p>⚠️ Update</p> </div> <div class="message-body"><p style="color:white;"> <b>Samsung's Xclipse 900 series GPUs are perfectly usable now.</b> </p></div></article> <p>Available information suggests they run some older form of the AMD proprietary driver, so support may be somewhat good knowing AMD&rsquo;s track record.</p> <p>Regardless of the device, disabling <code>Docked mode</code> and/or using lower resolution multipliers can help with performance in most games. However, your mileage will vary here. Some games may prefer docked mode, and some drivers don&rsquo;t play well with resolution multipliers under 1x. You&rsquo;ll have to test and see what works for you!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./graphics_settings.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/graphics_settings_hu5d94fd2028d4082bd4134708cf5e34f5_214628_800x0_resize_q90_bgffffff_box_3.jpg" alt="We&#39;re still figuring out what the best settings are for each game, so please experiment!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./system_settings.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/system_settings_hu7234e078ed35c3ba308f05c8faf0f119_159848_800x0_resize_q90_bgffffff_box_3.jpg" alt="We&#39;re still figuring out what the best settings are for each game, so please experiment!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">We&#39;re still figuring out what the best settings are for each game, so please experiment!</p> <p>Cooling is an important factor of performance as well. We tested several devices with the Snapdragon 8 Gen 2 SoC, and while a gaming-oriented Redmagic 8 Pro had no problems keeping its clock speeds high (even locked to maximum) and temperatures low, a regular Samsung Galaxy S23, on the other hand, is a boiling machine, climbing to 90°C in seconds. This temperature won&rsquo;t damage the device, as TjMax is at 100°C, but higher temperatures do lead to lower clock speeds.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pokemon_sword_cpu_usage.png" title=" Hand warmer included (Pokémon Sword)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/pokemon_sword_cpu_usage_hube0069d3642a8e9c1324f76d521b68e8_2052366_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Hand warmer included (Pokémon Sword)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hand warmer included (Pokémon Sword)</p> </div> </div> <p>Overheating leading to thermal throttling can result in a 30-50% performance loss over time, so this is one of the few times when gamer-gimmick marketing isn&rsquo;t lying.</p> <p>Regarding other specs, RAM is crucial. The recommended value is 8GB or more, big emphasis on more, and the absolute minimum is 6GB, but this will lead to many resource intensive games crashing. <code>The Legend of Zelda: Tears of the Kingdom</code> requires 12GB at the moment.</p> <p>Storage is not a critical aspect, but keep in mind that Switch games are typically large — there are visual novels over 20GB, and that&rsquo;s not counting updates and DLC.</p> <p>Controller input support is in its early stages. The ability to configure multiple controllers and their button mappings is currently being worked on, but not yet ready. Xbox, PlayStation, and Switch Pro controllers are automatically mapped when they are paired over Bluetooth. Generic DirectInput controllers are supported, but until more development time is spent dedicated to them, you may see some mapping issues and potentially missing mappings for buttons. Joy-Cons are not supported for now, Android doesn&rsquo;t allow access to them so they will have missing functionality.</p> <p>An on-screen input overlay will always be available, and it can be hidden while playing. Swipe from the left side of the screen and toggle <code>Input Overlay &gt; Show Overlay</code> if you want to disable it. The Button and Stick placements can be adjusted here as well.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./input1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/input1_hu7d05dd863d82bb76b53ea4529660112b_302740_800x0_resize_q90_bgffffff_box_3.jpg" alt="Adjust to your liking"></a> </div> <div class="column is-bottom-paddingless"> <a href="./input2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/input2_hu95fb207c34b12c5a667f5d67cecc973f_199689_800x0_resize_q90_bgffffff_box_3.jpg" alt="Adjust to your liking"></a> </div> <div class="column is-bottom-paddingless"> <a href="./input3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/input3_hu6508c04901adf99a6f817434a1842340_205510_800x0_resize_q90_bgffffff_box_3.jpg" alt="Adjust to your liking"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Adjust to your liking</p> <h1 id="setup-guide">Setup guide</h1> <p>If you need help setting up yuzu, our <a href="https://yuzu-mirror.github.io/help/quickstart/">Quickstart Guide</a> will provide all the steps required to get up and running. All the same requirements apply, including having a PC and the mandatory hacked Nintendo Switch. The yuzu on Android onboarding process will have you select the location of your <code>prod.keys</code> file.</p> <p>The only major difference is that the yuzu folder is located in <code>Android/data/org.yuzu.yuzu_emu/files</code>, which you will need access to in order to install Switch firmware files and any preferred mods. A quick-and-easy management interface for DLC, updates, mods, and saves will be added at a later date, so for those who dare, the process must be done manually for now (or copied from your PC installation of yuzu).</p> <p>In recent Android versions, Google started blocking access to app folders in file managers, so it is recommended to instead use Android&rsquo;s integrated file manager to access the yuzu folder. Here is a link to an app that allows users to have <a href="https://play.google.com/store/apps/details?id=com.marc.files">direct access to it</a>.</p> <p>Alternatively, you can always connect the phone/tablet to your PC via USB cable. No restrictions apply there.</p> <h1 id="conclusion">Conclusion</h1> <p>And there you have it! We&rsquo;re excited for the opportunity that Android provides us, to hear all of your feedback, and we hope you enjoy playing!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./totk.png" title=" The Legend of Zelda: Tears of the Kingdom"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/totk_hue196ed8fc1e98709b473ca2d2af62eb2_976956_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The Legend of Zelda: Tears of the Kingdom"></a> <p class="has-text-centered is-italic has-text-grey-light"> The Legend of Zelda: Tears of the Kingdom</p> </div> </div> <p>We don&rsquo;t have anything else to talk about for now, but please enjoy the below selection of screenshots taken from yuzu on Android!</p> <h1 id="media">Media</h1> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="totk_qcom.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/totk_qcom_hu074e11d2e5e0fb98ddbbcf8fabc0ef1e_1294851_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Tears of the Kingdom (Samsung Galaxy S20 FE, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="totk_qcom2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/totk_qcom2_hue62b4ec23f32b8c0ed8dbbc4f2c507c0_531358_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Tears of the Kingdom (Samsung Galaxy S20 FE, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Tears of the Kingdom (Samsung Galaxy S20 FE, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="ssmb.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/ssmb_hub40203b89b0349a673b6fc83cf42921a_2343591_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="ssmb2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/ssmb2_hub2f8595851c0b56baecdb4e97414bd69_1756930_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Smash Bros. Ultimate (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="mk1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/mk1_hu3243736b2b1291e5231efd53f2963540_2312787_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="mk2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/mk2_hu169cd2a6f596b44f6c653ec989c7042d_2584405_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mario Kart 8 Deluxe (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="smo1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/smo1_hu51137cb4490c76ca429cacf58bf3786b_2645049_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="smo2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/smo2_hud82764d666df9cfef2b38dadd79288db_1199547_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="acnh.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/acnh_hu786a05ac3767d7b9cb95ea54b287b632_2385951_800x0_resize_q90_bgffffff_box_3.jpg" alt="Animal Crossing: New Horizons (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="acnh2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/acnh2_hue6a2ef5067c316512525fa578fa33de5_1603818_800x0_resize_q90_bgffffff_box_3.jpg" alt="Animal Crossing: New Horizons (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Animal Crossing: New Horizons (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="tloz-awakening.png" title=" The Legend of Zelda: Link&#39;s Awakening (Samsum Galaxy S23, Qualcomm proprietary GPU driver)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/tloz-awakening_hu5c26ec0a00cc0732baf203c54e17d41e_2608019_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The Legend of Zelda: Link&#39;s Awakening (Samsum Galaxy S23, Qualcomm proprietary GPU driver)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The Legend of Zelda: Link&#39;s Awakening (Samsum Galaxy S23, Qualcomm proprietary GPU driver)</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="tloz-ss.png" title=" The Legend of Zelda: Skyward Sword HD (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/tloz-ss_hu37a2b43980d0e0f56e05c708a55286a4_1715400_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The Legend of Zelda: Skyward Sword HD (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The Legend of Zelda: Skyward Sword HD (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="dkctf.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/dkctf_hu761ff8e1a346e4ff9195dc630234ac27_2192055_800x0_resize_q90_bgffffff_box_3.jpg" alt="Donkey Kong Country: Tropical Freeze (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="dkctf2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/dkctf2_hu7f9111758047a36445be9bce07f39f8d_2219440_800x0_resize_q90_bgffffff_box_3.jpg" alt="Donkey Kong Country: Tropical Freeze (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Donkey Kong Country: Tropical Freeze (Samsung Galaxy S20 FE, Mesa Turnip GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="fe_engage.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/fe_engage_hu8b9e065c3630838f4fc28def757b9ed0_2258923_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem Engage (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="fe_engage2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/fe_engage2_hu2963457f7a863d8e903d83d163676602_2153602_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem Engage (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fire Emblem Engage (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="dread.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/dread_hue45dc85ae2b35b9141c22e8b50770a37_1604162_800x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="dread2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/dread2_hu15d80e1f8afc768323d708fcc839e2c4_817863_800x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Metroid Dread (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="pokemon-shield.png" title=" Pokémon Sword (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/pokemon-shield_hu7ff78e8669b06488b436d03ad0cb1f47_2294918_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Pokémon Sword (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Pokémon Sword (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="arceus.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/arceus_hu2f09464e5227ffa36c4d0c54fbc0cb38_1764145_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokemon Legends: Arceus (Samsung Galaxy S20 FE, Turnip GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="arceus2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/arceus2_hub9ae1cfdeaa2dd10bc617b1a13f9828f_1564092_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokemon Legends: Arceus (Samsung Galaxy S20 FE, Turnip GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokemon Legends: Arceus (Samsung Galaxy S20 FE, Turnip GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="sm3d_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/sm3d_1_hubaf177c44f672af8cc76ae26eb1ea862_1746952_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario 3D World &#43; Bowser&#39;s Fury (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="sm3d_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/sm3d_2_huab034ee6848261863cd219e07d6fabca_2390210_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario 3D World &#43; Bowser&#39;s Fury (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario 3D World &#43; Bowser&#39;s Fury (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="atelier_ryza_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/atelier_ryza_1_hu3d04eca0ee8cb50c5c9d28a2c3ad9fc6_2987081_800x0_resize_q90_bgffffff_box_3.jpg" alt="Atelier Ryza: Ever Darkness &amp; the Secret Hideout (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="atelier_ryza_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/atelier_ryza_2_hub5f7449fe3201ab95d497df57daef16c_2669439_800x0_resize_q90_bgffffff_box_3.jpg" alt="Atelier Ryza: Ever Darkness &amp; the Secret Hideout (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Atelier Ryza: Ever Darkness &amp; the Secret Hideout (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="d3_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/d3_1_hu710f4eb46ad73d26cbc5923896144488_1656624_800x0_resize_q90_bgffffff_box_3.jpg" alt="Diablo III: Eternal Collection (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> <div class="column is-bottom-paddingless"> <a href="d3_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-android/d3_2_hu888aced21d54d4efda780c12c2e27be2_1970471_800x0_resize_q90_bgffffff_box_3.jpg" alt="Diablo III: Eternal Collection (Samsung Galaxy S23, Qualcomm proprietary GPU driver)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Diablo III: Eternal Collection (Samsung Galaxy S23, Qualcomm proprietary GPU driver)</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> </p> Progress Report April 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/ Wed, 10 May 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/ <p>Hello yuz-ers! There were fewer individual changes this month, but the changes that were made are substantial! You won&rsquo;t want to miss this.</p> <p>Hello yuz-ers! There were fewer individual changes this month, but the changes that were made are substantial! You won&rsquo;t want to miss this.</p> <p>Poor Melia up there.</p> <h2 id="project-yfc-190">Project Y.F.C. 1.90!</h2> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> showed up one weekend and asked, “Want to test a 50% performance boost and almost perfect rendering on Normal GPU accuracy?” And that’s exactly what we did.</p> <p>A more accurate name for this change would be “a rewrite of the Buffer Cache Rewrite”, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10084" data-gh-pr="10084">perhaps rBCR for short?</a> Essentially, Blinkhawk rewrote most of the old buffer cache changes that <a href="https://github.com/ReinUsesLisp">Rodrigo</a> introduced <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/">two years ago</a>, taking into account the new demands of recent games and the issues found with the original BCR.</p> <p>Part of the work <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10088" data-gh-pr="10088">also involves:</a> </p> <ul> <li>Allowing the verification of fencing and writing of asynchronous downloads in a separate thread</li> <li>Restructuring how accuracy is managed by skipping host-guest fence synchronization and not downloading on host conditional rendering for normal GPU accuracy</li> <li>Improving consistency for <code>Query Cache</code> asynchronous downloads</li> </ul> <p>The results are amazing. Most games that used to need High GPU accuracy to render correctly can now run on Normal with no issues. Additionally, all this wizardry reduces bandwidth usage and boosts performance up to 87% for everyone (50% on average), from the low-end APUs to the high-end beasts.</p> <p>Here’s an incomplete list of changes:</p> <ul> <li>As noted previously, many games which required High GPU accuracy to be visually accurate now work with Normal GPU accuracy with minimal sacrifice.</li> <li>Particles and character lighting/shading in <code>Pokémon Sword &amp; Shield</code> have been fixed on Normal GPU accuracy. Performance has improved by up to 40% on Normal GPU accuracy.</li> <li>Models (the BowWow, for example) and particle rendering are fixed on Normal GPU accuracy in <code>The Legend of Zelda: Link's Awakening</code>. Performance on Normal accuracy, with correct rendering, is now up to 70% higher than before.</li> <li>Lighting in <code>Diablo II: Resurrected</code> has been fixed and will no longer flicker.</li> <li>Lighting and shadows in <code>Luigi's Mansion 3</code> will no longer randomly flicker.</li> <li>Pokémon photograph detection and data of <code>New Pokémon Snap</code> has been fixed on Normal GPU accuracy. This results in up to a 50% increase in performance with working photograph detection.</li> <li><code>Kirby and the Forgotten Land</code> vertex explosions, lighting, and particles have been fixed on Normal GPU accuracy. This results in an up to 40% performance increase, with accurate rendering on Normal accuracy.</li> <li>Red lights in some machines in <code>Xenoblade Chronicles 2</code> have been fixed.</li> <li><code>Fire Emblem Warriors</code> has been accurately fixed and no longer requires a workaround.</li> <li><code>MONSTER HUNTER RISE</code> now accurately renders on Normal GPU accuracy, resulting in an up to 50% performance increase (note, however, that updates after 3.0.0 still have issues and require more work).</li> <li>Vertex explosions in <code>Persona 5 Royal</code> no longer occur with Normal GPU accuracy, resulting in an up to 30% increase in performance.</li> <li><code>Atelier Ryza</code> series games now render correctly.</li> <li>The pessimistic flushes option in advanced graphics settings is no longer needed in any of the affected games it benefitted and we have now removed it.</li> <li><code>Mortal Kombat 11</code> no longer has any vertex explosions.</li> <li><code>NieR:Automata The End of YoRHa Edition</code> now renders correctly.</li> <li><code>Bayonetta 3</code> no longer requires High GPU accuracy to render correctly.</li> <li><code>Splatoon 2</code>’s ink physics work correctly on AMD GPUs while using High GPU accuracy.</li> <li>Particles in <code>The Legend of Zelda: Breath of the Wild</code> have been fixed, resulting in 40% higher performance and accurate rendering on Normal GPU accuracy.</li> <li>Tree flickering in <code>The Legend of Zelda: Breath of the Wild</code> has been fixed on all GPU accuracy options.</li> <li>And much, much more!</li> </ul> <p>No option needs to be enabled to take advantage of all of this, just switch GPU accuracy to Normal if you haven’t already. What are you waiting for?</p> <p>Here are some stats of some of the most popular games. We compared High GPU accuracy in Mainline 1407, and Normal GPU accuracy in Mainline 1421. All tests are done at 2X resolution scaling, and using mods to disable dynamic resolution when possible.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./yfc1.png" title=" Hardware makers cry over this kind of free performance boost"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/yfc1_hu1ca0f7be3ca1b352ba00516928888a28_20568_720x0_resize_q90_bgffffff_box_3.jpg" alt=" Hardware makers cry over this kind of free performance boost"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hardware makers cry over this kind of free performance boost</p> </div> </div> <p>And then we have these four, the high FPS squad. They&rsquo;re reason enough to consider asking the modding community to start releasing 240 FPS mods!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./yfc2.png" title=" When you gotta go so fast on a previous generation CPU that a second graph is required"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/yfc2_hua95c5b25a667dce02039959de714a454_15699_720x0_resize_q90_bgffffff_box_3.jpg" alt=" When you gotta go so fast on a previous generation CPU that a second graph is required"></a> <p class="has-text-centered is-italic has-text-grey-light"> When you gotta go so fast on a previous generation CPU that a second graph is required</p> </div> </div> <p>Expect even higher numbers with a Zen 4 3D V-cache chip. For example, in the same testing spot of <code>Breath of the Wild</code>, a non-3D 7900X gets 90 FPS.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bsod.png" title=" Your writer’s PC is feeling like a snail compared to the current monsters on sale…"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/bsod_hub9a87add176dcd185d07255d7c6944a8_1981763_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Your writer’s PC is feeling like a snail compared to the current monsters on sale…"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your writer’s PC is feeling like a snail compared to the current monsters on sale…</p> </div> </div> <h2 id="other-graphical-changes">Other graphical changes</h2> <p><a href="https://github.com/citra-emu/citra">Citra</a>-legend <a href="https://github.com/GPUCode">GPUCode</a> stepped up to give us a hand with presentation. Presentation is the final step of most graphics code — the process of getting the output to the screen.</p> <p>GPUCode&rsquo;s work <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9973" data-gh-pr="9973">moves swapchain operations</a> to a separate thread in order to avoid stalling the main GPU thread. This improves performance in more demanding titles and on low-end hardware, and can make the difference between barely getting 60 and getting a smooth 60 frames per second in many cases.</p> <p>However, it can also make the frametimes less consistent, therefore we&rsquo;ve turned it off by default to allow for further testing. We need to determine which systems and games benefit the most. For those interested in trying it, the toggle is available in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Enable asynchronous presentation (Vulkan only)</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./async.png" title=" Share your experience with us!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/async_hue0996b1ae49311328229b5c8975de57c_26389_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Share your experience with us!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Share your experience with us!</p> </div> </div> <p><a href="https://github.com/vonchenplus">vonchenplus</a> continues to work on making the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10008" data-gh-pr="10008">code match the information NVIDIA has made public</a> in their latest documentation.</p> <p>You may remember <a href="https://github.com/Wollnashorn">Wollnashorn</a> from their role in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/#new-challenger-approaching">overhauling the Vulkan pipeline cache</a>. Now, Wollnashorn presents us with a technique to bypass hardware limitations in order to make <code>The Legend of Zelda: Breath of the Wild</code> render accurately on non-NVIDIA hardware.</p> <p>Object edges, especially grass blades, had distinct black borders on AMD and Intel GPUs. The issue occurred regardless of the driver in use, so it was clearly a hardware limitation, and an incompatibility with what the game expects. <code>The Legend of Zelda: Breath of the Wild</code> uses a technique called deferred rendering–in this particular case, shadows render at half the resolution. Four pixels of the full resolution depth texture are sampled simultaneously with a <a href="https://registry.khronos.org/OpenGL-Refpages/gl4/html/textureGather.xhtml">textureGather</a> call. <code>textureGather</code> has the characteristic of working with normalized floating-point coordinates for the texture, so each fragment is always at the boundary of the four selected pixels.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gather.png" title=" The four special pixels"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/gather_hu7568f8d0b364fb97b0f831708bb03e63_11036_549x0_resize_q90_bgffffff_box_3.jpg" alt=" The four special pixels"></a> <p class="has-text-centered is-italic has-text-grey-light"> The four special pixels</p> </div> </div> <p>Now, <code>textureGather</code> uses floating-point, and each GPU design will have a different rounding precision. Additionally, thanks to a <a href="https://www.reedbeta.com/blog/texture-gathers-and-coordinate-precision/">blogspot by Nathan Reed</a>, we know the integer coordinates of the pixel on the texture are calculated by the GPU after a conversion from a floating-point number to a fixed-point number.</p> <p>With floating point conversions involved, you may be able to tell where this is going. If the user’s GPU is not using the same rounding precision as the Nintendo Switch, different pixels can be sampled. Ergo, only NVIDIA GPUs got the four correct pixels the game intended.</p> <p>How did Wollnashorn solve this? With a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10030" data-gh-pr="10030">clever little trick,</a> of course. Adding a very tiny (1/512) subpixel offset to the sample coordinates is sufficient to fudge the rounding. Achieving that required modifying the code of the SPIR-V and GLSL backends, altering how the operation is handled only for AMD and Intel hardware for now, with the option to force it for any other future hardware that may require it, for example, a certain fruit company.</p> <p>Here’s the final result:</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/botwbug_huc94fba8e453f244c1eb2ffcde3d424d4_3564871_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Funny how we end up sharing the same problems Cemu faced (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/botwfix_hua41d5eebbd2221c48daaa4feb265f9ad_3441229_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Funny how we end up sharing the same problems Cemu faced (The Legend of Zelda: Breath of the Wild)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Funny how we end up sharing the same problems Cemu faced (The Legend of Zelda: Breath of the Wild)</p> <p>Something we have to mention is that this doesn’t fix a very similar-looking black line issue present when using <code>anisotropic filtering</code> values higher than Default with AMD and Intel GPUs. That’s a separate issue and we recommend Red and Blue Team users to at least set a per-game setting for <code>The Legend of Zelda: Breath of the Wild</code> to set it to Default only. The game doesn’t benefit from higher values anyway, since its terrain textures don’t seem to take advantage of it.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/afbug_hu19ba5ebbef1fd13e58d5f18d4e742f4f_1900734_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That’s a clean look all around (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/affix_hu86b423ea4caacd1bcc9ddb65124300a3_1930313_1024x0_resize_q90_bgffffff_box_3.jpg" alt="That’s a clean look all around (The Legend of Zelda: Breath of the Wild)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That’s a clean look all around (The Legend of Zelda: Breath of the Wild)</p> <p>Linux got its well deserved share of love too thanks to <a href="https://github.com/liamwhite">byte[]</a>.</p> <p>First up, he fixed up <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10051" data-gh-pr="10051">initialization of the Vulkan swapchain on Wayland,</a> helping Linux NVIDIA users to be able to launch their games. As some of you may know, NVIDIA was historically very stubborn about their support of Wayland, and it doesn’t help that most Wayland compositors are very stubborn on their own too. The year of the Linux desktop, always around the corner…</p> <p>Second, he fixed a crash that happened to Flatpak users trying to play <code>Bayonetta 3</code>. An <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10069" data-gh-pr="10069">out-of-bounds</a> could occur in an array access intended for size estimations, leading to “nasty stuff”. A small adjustment, and the issue is no more. Nice pull request number there.</p> <p>Speaking of out-of-bounds, <a href="https://github.com/Kelebek1">Maide</a> found an interesting case happening in corner sampling due to a previously added offset. Not accounting for this offset caused another out-of-bounds situation during <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10074" data-gh-pr="10074">2D texture blitting.</a> </p> <p>Fixing this special case solved the depth-of-field rendering issues in <code>Kirby Star Allies</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/kirbybug_hu0bc591a192ed9095fa6df942e8082595_187737_360x0_resize_q90_bgffffff_box_3.jpg" alt="Poyo! (Kirby Star Allies)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/kirbyfix_hue3e0410ac72719ac1bd78f847100984c_181254_360x0_resize_q90_bgffffff_box_3.jpg" alt="Poyo! (Kirby Star Allies)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Poyo! (Kirby Star Allies)</p> <p>Still on fire, and with more work to come, Blinkhawk hasn’t stopped. For something light, he decided to refactor a big part of <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/#project-yfc-175">Accelerate DMA</a> to do <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10082" data-gh-pr="10082">texture downloads</a> through the texture cache instead. The result is a return to the performance <code>Pokémon Sword &amp; Shield</code> and <code>Hyrule Warriors: Age of Calamity</code> had before the old Y.F.C 1.75 changes. Add up the gains from Y.F.C 1.90, and you have a winner for low-end systems!</p> <p>We have many more changes Blinkhawk implemented, but they didn’t make it in time for the deadline for the progress report, so we will be mentioning them next month.</p> <h2 id="general-changes-and-settings-glossary">General changes and settings glossary</h2> <p>The modding community requested us to allow for larger texture mods. The old 6GB limit was not enough, so byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10035" data-gh-pr="10035">expanded it to support a custom 8GB arrangement</a> instead, giving almost all of it to the emulated program.</p> <p>However, this had unforeseen consequences.</p> <p>We discovered that users like to enable settings without knowing what they do. Shocking, right?</p> <p>Having a much higher amount of memory available than the normal development console would has caused problems. For example, after getting several reports of Pokémon failing to respawn in <code>Pokémon Scarlet &amp; Violet</code> after playing the game for a few minutes, we narrowed the changes down to users with this setting enabled.</p> <p>However, this option is <strong>only meant</strong> for very large texture mods, and should not be enabled unless you are using such a mod. Unfortunately, it was on the first page of the yuzu settings when opening it, so it was a very visible setting. Additionally, we found some YouTube tutorials which incorrectly suggested it may improve performance and stability, and users followed that. This would have resulted in 4GB of extra RAM wasted for no benefit, and potentially caused issues in games.</p> <p>To try to prevent this, we recommend reading our new <a href="https://community.citra-emu.org/t/settings-glossary/768483">settings glossary</a>, which together with our <a href="https://community.citra-emu.org/t/recommended-settings/319349">recommended settings</a> page, should help people understand what each setting does, and what’s recommended to change.</p> <p>Moreover, to solve the problem for the users who don’t check our official channels, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10124" data-gh-pr="10124">moved the setting</a> to the bottom of the <code>System</code> tab, and renamed it, ensuring that no previous configuration file will enable it again without user intervention. If you have a real need for extended memory layout, make sure to manually enable it again. Or don’t, we won’t judge you… too much.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/extendedbug_hu346e19ec9a68ff51d29d0d3689fb73dc_20952_1024x0_resize_q90_bgffffff_box_3.jpg" alt="You have been relegated to System settings"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/extendedfix_hua746fa1d9d2072337ecce3a12f2e6431_20409_1024x0_resize_q90_bgffffff_box_3.jpg" alt="You have been relegated to System settings"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">You have been relegated to System settings</p> <p>Users reported that <code>IGS Classic Arcade Collection</code> wasn’t playable. vonchenplus investigated the cause and found the reason in our audio emulation. Apparently the game doesn’t do a very good job implementing its audio code on the Switch, and fails to initialize a new audio output session, which should return an error. Properly <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10056" data-gh-pr="10056">returning this error as a result</a> is enough to get the game working.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./igs.png" title=" Nothing beats the classics (IGS Classic Arcade Collection)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/igs_hu19241526fcb90ac27ddfb7e5037c3af8_1277614_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Nothing beats the classics (IGS Classic Arcade Collection)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Nothing beats the classics (IGS Classic Arcade Collection)</p> </div> </div> <p>One of the options made available to our <a href="https://yuzu-mirror.github.io/entry/ldn-is-here/">LDN</a> users is the ability to <a href="https://yuzu-mirror.github.io/help/feature/multiplayer/">create private rooms</a>, providing hosts with several options to configure their servers as they want.</p> <p><a href="https://github.com/twitchax">twitchax</a> knows that for certain server hosts, such as <code>fly.io</code>, a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10068" data-gh-pr="10068">custom bind address</a> is needed. They implemented the functionality and now users can pass the <code>--bind-address</code> argument to the room’s configuration. Thanks!</p> <p>Continuing his work on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10086" data-gh-pr="10086">improving CPU timing accuracy,</a> <a href="https://github.com/Morph1984">Morph</a> fixed confusion between the raw CPU frequency and <code>Counter-timer Frequency</code>, or CNTFRQ. The difference between the two is that CNTFRQ reports the frequency of the system clock, instead of the CPU frequency. While fixing this, he also reduced the time it takes to measure timing information by about 60%.</p> <p>What does this mean for the user? A sweet 1-7% performance boost.</p> <h2 id="input-changes">Input changes</h2> <p>Also known as <a href="https://github.com/german77">german77</a>’s section.</p> <p>How you interact with a game might just be more important than even graphics or audio. After all, it’s what differentiates it from a CG animated movie. As it is tradition by now, our dear Kraken has been working on further improving yuzu’s input emulation.</p> <p>A big part of the work of writing an emulator involves reverse engineering, so he’s been working on making the NFC service match what the Switch does internally — in this case, implementing all the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10053" data-gh-pr="10053">remaining missing interfaces,</a> putting them on the same level as what the real console does.</p> <p>This next change is a simple revelation that came from the work done on TAS. If you implement a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10060" data-gh-pr="10060">virtual controller,</a> it won’t need range and dead zone settings as it will be <em>virtually</em> perfect (sorry, not sorry).</p> <p>But not all work was done by german77, <a href="https://github.com/v1993">v1993</a> caught a little nasty bug that slipped by. Motion emulation with mouse movement is handled by a 3D vector (x, y, z). Yes, surprise math lesson, deal with it. Anyway, yuzu was doing this:</p> <p>(x, y, z) = (x, y, z) + (1, 2, z)</p> <p>Which results in:</p> <p>(x + 1, y + 2, 2z)</p> <p>The z component was being doubled by mistake!</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10055" data-gh-pr="10055">The solution</a> is to instead do:</p> <p>(x, y, z) = (x, y, z) + (1, 2, 0)</p> <p>Which gives us:</p> <p>(x + 1, y + 2, z)</p> <p>And now all’s right with the world. This should improve the quality of mouse motion, for those that prefer an FPS experience with a keyboard and mouse. Or just like to torture themselves.</p> <h2 id="hardware-section">Hardware section</h2> <p>A recurring problem users face when running modern emulators that utilize Vulkan is the lack of a way to get helpful feedback if the program crashes. Vulkan is very picky. Any wrong step in the middle and it will refuse to start, and any Vulkan layer program can cause this. Anything from outdated screen recorders, to mod managers, performance overlays, and even the disaster code motherboard vendors call RGB software. Of particular nasty interest is the Epic Game Store’s overlay, which is reported to cause severe performance issues.</p> <p>To some extent, yuzu can detect these problems and switch to OpenGL to avoid them, but that doesn’t tell the user where the problem is. We recently found out about a cute little program the <a href="https://github.com/RPCS3/rpcs3">RPCS3</a> community has been using for some time to diagnose these problems, <a href="https://github.com/13xforever/vkdiag">VkDiag</a>. You can find its latest version <a href="https://github.com/13xforever/vkdiag/releases">here</a>.</p> <p>What this program does is list all relevant components and layers affecting Vulkan rendering and warn about potential problems in any of them.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./vkdiag1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/vkdiag1_hu2e7c463b0f5074be02033f4f68919c9b_42488_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s already been combat tested, both outdated drivers and broken layers are in its sights"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vkdiag2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/vkdiag2_hu23c9cb26618393d44e3162b48cd05e49_67613_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s already been combat tested, both outdated drivers and broken layers are in its sights"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It&#39;s already been combat tested, both outdated drivers and broken layers are in its sights</p> <p>We have started using it in our support channels with amazing success, and we recommend self-serving users to keep it in their toolkit. You never know when that OBS install you forgot to update can cause you problems, or when that RGB software decides to go rogue.</p> <h3 id="nvidia-enjoying-auto-hdr">NVIDIA, enjoying Auto HDR</h3> <p>Here’s some great news for Windows 11 users rocking HDR displays. Some time ago, GitHub user <a href="https://github.com/svonolfen">svonolfen</a> in our issue tracker found an interesting way to make Auto HDR work with NVIDIA GPUs. <a href="https://github.com/yuzu-emu/yuzu/issues/9221#issuecomment-1493392941">Here’s the link</a>. By renaming yuzu to &ldquo;Cemu&rdquo; and performing additional steps, Auto HDR is suddenly functional.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hdr.png" title=" Don’t mind the Spanish"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/hdr_hu6ba8d40391998613422fdef2398bc884_112830_600x0_resize_q90_bgffffff_box_3.jpg" alt=" Don’t mind the Spanish"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don’t mind the Spanish</p> </div> </div> <p>Cemu gets privileges, indeed. This is only available for NVIDIA Windows drivers because, at least for now, only the NVIDIA Control Panel offers the option to force a DXGI swapchain — effectively making the Vulkan program present to screen as a Direct3D one. This has a few benefits: Auto HDR works, improving dynamic range considerably, borderless optimizations are applied to yuzu, improving input lag and frame synchronization, and the G-Sync/Freesync issue is solved. It has a downside worth mentioning, it can be up to 5% slower than regular Vulkan presentation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dxgi.png" title=" Don’t forget to set up your NVIDIA control panel accordingly!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/dxgi_hudd083df4b1fb3a97f4c526c14ad62bd9_67565_960x0_resize_q90_bgffffff_box_3.jpg" alt=" Don’t forget to set up your NVIDIA control panel accordingly!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don’t forget to set up your NVIDIA control panel accordingly!</p> </div> </div> <p>While this fun renaming works fine, we also heard from Windows Insider users that future versions of the Xbox Game Bar application will allow yuzu to work with Auto HDR without doing any renaming. This will most likely require newer NVIDIA drivers to work.</p> <p>If you own an HDR-compatible monitor and want to compare the results, here’s a .jxr <a href="https://github.com/yuzu-emu/yuzu-emu.github.io/blob/hugo/site/content/entry/yuzu-progress-report-apr-2023/hdr.jxr">HDR capture</a> that the default Windows 11 photo viewer can open, and a comparable .png native <a href="https://github.com/yuzu-emu/yuzu-emu.github.io/blob/hugo/site/content/entry/yuzu-progress-report-apr-2023/sdr.png">SDR capture</a>. You will of course need HDR output enabled in both your display’s and Windows 11 settings. Notice the difference in the sky and lamps. The tonemapping isn’t perfect, but we will never get Switch games outputting native HDR anyway.</p> <p>Your writer’s simple HDR400 display with no dimming zones is enough to notice the benefits, so here’s your excuse to convince your parents/wife to buy that OLED monitor you’ve been eyeing for weeks. Zelda. In HDR.</p> <p>A Vulkan extension can be implemented in yuzu to get global support for any GPU. You can be sure I’ll be nagging our GPU devs until it gets added.</p> <h3 id="amd-delivering-on-their-promises">AMD, delivering on their promises</h3> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/#amd-2332-and-newer-drivers">Last month,</a> we mentioned that AMD introduced a regression that caused graphical corruption and crashes with some games.</p> <p>We’re happy to announce that since driver version 23.4.2 and later the issue is resolved for Vega and newer, allowing Radeon Windows users to fully benefit from the new Vulkan extensions supported by the latest drivers, reducing shader building stuttering to a minimum. Just as AMD promised, except&hellip;</p> <p>Polaris (RX 400/500 series) cards may still be unstable under some rare cases, but a fix shouldn&rsquo;t take too long to appear. In the meantime, Polaris users should stick to driver <a href="https://www.amd.com/en/support/kb/release-notes/rn-rad-win-23-3-1">23.3.1</a>, unless they want to face results like this:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./polaris.png" title=" Your whole desktop looks like this"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/polaris_hufe5215d7cc57880fe14b91b45884a4ef_662301_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Your whole desktop looks like this"></a> <p class="has-text-centered is-italic has-text-grey-light"> Your whole desktop looks like this</p> </div> </div> <p>On another topic, we reported to AMD what we suspect is the cause of the Pentelas Region vertex explosions in <code>Xenoblade Chronicles 3</code>, which also now affect the initial regions in its new expansion, <code>Future Redeemed</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pentelas.png" title=" That’s the water performing the mother of all vertex explosions (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/pentelas_huab03152bc8fb75bdbe5e3536ded27949_1372391_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" That’s the water performing the mother of all vertex explosions (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> That’s the water performing the mother of all vertex explosions (Xenoblade Chronicles 3)</p> </div> </div> <p>Since the issue affects both the official AMD and Mesa drivers indiscriminately, we suspect it’s a hardware limitation — possibly the lack of support for D24 depth formats, which many games utilize (Xenoblade games included), and both NVIDIA and Intel support.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./d24.png" title=" That’s what a hardware limitation looks like"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/d24_huab53e5604339b59563847cadd0d10b8f_14995_954x0_resize_q90_bgffffff_box_3.jpg" alt=" That’s what a hardware limitation looks like"></a> <p class="has-text-centered is-italic has-text-grey-light"> That’s what a hardware limitation looks like</p> </div> </div> <h3 id="intel">Intel…</h3> <p>As we’ve been previously reporting, <a href="https://github.com/IGCIT/Intel-GPU-Community-Issue-Tracker-IGCIT/issues/159">Intel Windows Vulkan drivers are unstable</a>. The SPIR-V compiler (the part that handles Vulkan pipeline shaders) can crash working on compute shaders and some specific shader instructions.</p> <p>We found a case where the driver crashes when compiling a shader with more than 5 cases in a switch block, or more than 5 if-else blocks of the same condition. Maybe an optimization gone wrong?</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./case.png" title=" If you uncomment out the last two cases, the driver crashes"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/case_hu685de7de1bbdd103f2089beff89e4d31_186721_491x0_resize_q90_bgffffff_box_3.jpg" alt=" If you uncomment out the last two cases, the driver crashes"></a> <p class="has-text-centered is-italic has-text-grey-light"> If you uncomment out the last two cases, the driver crashes</p> </div> </div> <p>We reported the crash to Intel six months ago, and their reply this month was:</p> <blockquote> <p>Thank you for reporting this issue. Our priority is to target the most popular games and apps to focus our efforts on providing a high quality, stable experience for the broadest set of users. We will continue to improve our software performance and compatibility throughout 2023 and beyond.</p> </blockquote> <p>So even after waiting six months with a test case provided, the reason explained, and even after pointing out where in the driver the crash happens, Intel can’t find the time to fix the issue. This is some kind of twisted joke. For comparison, when you do this with NVIDIA, they <em>hire</em> you.</p> <p>We’re left with no option but to mitigate the crashes as much as we can. To do so, Morph <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10110" data-gh-pr="10110">disabled compute shaders</a> entirely for Intel Windows drivers, ensuring games like <code>The Legend of Zelda: Breath of the Wild</code> can still boot ― even though they&rsquo;ll have gameplay issues as a result.</p> <p>This isn’t enough to solve all crashes. Some games like <code>Xenoblade Chronicles 3</code> will still crash the shader compiler. We haven&rsquo;t diagnosed this yet, but believe that it&rsquo;s likely closely related to the same issue we have already reported.</p> <p>Disabling compute shaders produces this lovely side effect on some games like <code>Super Smash Bros. Ultimate</code>:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smash.png" title=" That’s what happens when we’re forced to remove an entire pipeline stage, Intel (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/smash_hu51d3508264ab8b4e4b23d1dbf6051556_231321_946x0_resize_q90_bgffffff_box_3.jpg" alt=" That’s what happens when we’re forced to remove an entire pipeline stage, Intel (Super Smash Bros. Ultimate)"></a> <p class="has-text-centered is-italic has-text-grey-light"> That’s what happens when we’re forced to remove an entire pipeline stage, Intel (Super Smash Bros. Ultimate)</p> </div> </div> <p>For those that prefer proper rendering on Intel Windows drivers, can tolerate the random crashes, and don’t want to just use the actually working Linux Mesa drivers, <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/download/mainline-0-1414/yuzu-windows-msvc-20230429-3aaa245f7.7z">Mainline 1414</a> is currently the last version with support for compute shaders. We’re working to add a toggle that can be configured per game.</p> <p>But wait, there’s more, the fun doesn’t stop there. Reddit users discovered that Intel 12th and 13th Gen CPUs running on Windows 11 have noticeably worse frametimes than the same hardware running on Windows 10.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./intel.png" title=" What would EA say to this"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2023/intel_hu17973bff825239bcac607d1ef0000006_143964_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" What would EA say to this"></a> <p class="has-text-centered is-italic has-text-grey-light"> What would EA say to this</p> </div> </div> <p>So if you notice stutter while playing, the solution may be quite simple: perform a clean Windows 10 install!</p> <h2 id="future-projects">Future projects</h2> <p>So releasing <code>Project Y.F.C</code> in parts paid off. Blinkhawk is working on the final part of it, which includes a restructuring of the GPU accuracy settings, and a few other surprises. Stay tuned.</p> <p>You will also hear news about <code>Project Lime</code> <em>very soon!</em></p> <p>That’s all folks! Thank you for reading until the end, nothing makes us happier.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report March 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/ Mon, 10 Apr 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/ <p>Hi yuz-ers! We&rsquo;ve been working hard as usual, and this March saw improvements in performance, graphics, audio, CPU precision, input, and much more!</p> <p>Hi yuz-ers! We&rsquo;ve been working hard as usual, and this March saw improvements in performance, graphics, audio, CPU precision, input, and much more!</p> <h2 id="making-cpus-go-the-opposite-of-brrrr">Making CPUs go the opposite of BRRRR</h2> <p>One of the biggest changes this month is the set of improvements in CPU accuracy. This requires some backtracking so let’s rewind a little bit.</p> <p>Back in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/#core-timing-or-how-to-suffer-so-much-with-a-fix">July,</a> we explained how <code>CoreTiming</code> operates in its current form, using a host timer. A thread called <code>HostTiming</code> is used to process HLE events such as input and audio. However, some of these events, like audio, require a high level of timer precision to behave the way games expect, more than Windows would usually allow.</p> <p>By default, Windows only allows a precision of 1ms since the OS event loop runs at 1000Hz. This is not enough. However, devices running Linux, BSD, and MacOS don&rsquo;t face this limitation and can achieve μs (microsecond) levels of precision.</p> <p>If a game wants to run at a frametime of 16.67ms (60 FPS), you could wait for 17ms two-thirds of the time and 16ms for the remaining one-third, but this has already proved in the past to be terrible for audio accuracy. The alternative, and old method in use for Windows, is to wait for 16ms and do a busy wait for 0.67ms. During that 0.67ms, the CPU thread isn&rsquo;t doing anything and consumes power without actually working.</p> <p>Here comes the benefit of removing support for Windows 7 and 8/8.1. The Windows 10 SDK has new undocumented functions, <code>NtSetTimerResolution</code> and <code>NtDelayExecution</code>, which allow improving timer resolution down to 0.5ms. This allows yuzu to wait for 16.5ms and only spin the remaining 0.17ms, which is four times shorter than the previous default method.</p> <p>By implementing these <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9889" data-gh-pr="9889">new functions,</a> <a href="https://github.com/Morph1984">Morph</a> reduced the time the CPU spends in a spinlock, resulting in reduced CPU usage for timing-heavy games like Kirby Forgor 💀… <code>Kirby and the Forgotten Land</code>, and <code>Super Smash Bros. Ultimate</code>. The new free resources mean better performance for low core count CPUs such as quad cores, and for systems with limited power budgets such as laptops and handhelds. With this change, we measured up to a 24% reduction in CPU use or power consumption, depending on the limiting factor.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./usebug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/usebug_hu05b278de8f59bb3ffe0e7f5e9cec37a3_94425_800x0_resize_q90_bgffffff_box_3.jpg" alt="Left: old 1ms precision; Right: current 0.5ms precision. The result comes from your writer’s laptop which runs a Single Language Windows installation, so don’t mind the Spanish. Note that there is a difference in CPU use between the two results"></a> </div> <div class="column is-bottom-paddingless"> <a href="./usefix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/usefix_hu473113d7ff1ce19aa17ca6e4d3efc844_77708_800x0_resize_q90_bgffffff_box_3.jpg" alt="Left: old 1ms precision; Right: current 0.5ms precision. The result comes from your writer’s laptop which runs a Single Language Windows installation, so don’t mind the Spanish. Note that there is a difference in CPU use between the two results"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Left: old 1ms precision; Right: current 0.5ms precision. The result comes from your writer’s laptop which runs a Single Language Windows installation, so don’t mind the Spanish. Note that there is a difference in CPU use between the two results</p> <p>If you can perform more tasks in the same power envelope, you can improve performance without sacrificing battery life. Alternatively, a more common scenario for an emulator, if your ceiling is a fixed framerate, you can reduce temperatures.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./tempbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/tempbug_hu17859b2cb0ec53714f6c5c6be11154a4_45421_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is why the lap in laptop is a lie, mind the package temperature (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./tempfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/tempfix_hua495fd005016b0b81e9f4450de5e6bd7_59321_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is why the lap in laptop is a lie, mind the package temperature (Xenoblade Chronicles 3)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This is why the lap in laptop is a lie, mind the package temperature (Xenoblade Chronicles 3)</p> <p>Users reported that games have less audio stuttering thanks to the improved timer precision.</p> <p>Another nice tool that the Windows 10 SDK adds is allowing us to set yuzu as a <code>HighQoS</code> process, hinting to the Windows scheduler that if there are higher performance cores available, they should take priority. This further improves performance for current Ryzen CPUs by suggesting to use the best cores of a CCX, and for Intel 12th Gen and newer, by prioritizing P-cores (&ldquo;performance cores&rdquo;, normal cores).</p> <p>It’s heavily recommended to keep chipset drivers up to date to take the best advantage of your hardware.</p> <p>If the CPU performs in a more efficient way, how do we go even further beyond? Well, Morph figured the next step is to improve how the CPU counts time itself!</p> <p>On modern CPUs using the x86 architecture, the invariant timer is fetched with the the <a href="https://en.wikipedia.org/wiki/Time_Stamp_Counter">RDTSC</a> instruction. The thing with RDTSC is that… it isn’t accurate over longer periods. It can’t be on multicore processors.</p> <p>The small differences between what RDTSC provides as a best estimate and actual reality causes time drift in games like <code>Super Smash Bros. Ultimate</code>. You may notice this issue surfaces its ugly head as inaccurate match times. Intel 12th Gen, the most affected CPU architecture we measured (also all the way back in July), was as bad as a second off per minute.</p> <p>Morph’s <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9917" data-gh-pr="9917">solution</a> to this issue is to spawn an extra thread whose task is to take two measurements of the TSC for 10 seconds, then take that difference and apply it to know how many actual ticks have passed in those first 10 seconds. If you then divide the number of ticks by 10, you get the exact frequency the host RDTSC timer was running at.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./timerbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/timerbug_hu2ef0d7e45e56135ea721dad8f32724ad_1495707_800x0_resize_q90_bgffffff_box_3.jpg" alt="Good thing we don’t have to use old stopwatches for this (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./timerfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/timerfix_hu73bddc4153e34bd6d4a23fa1057653a0_975369_800x0_resize_q90_bgffffff_box_3.jpg" alt="Good thing we don’t have to use old stopwatches for this (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Good thing we don’t have to use old stopwatches for this (Super Smash Bros. Ultimate)</p> <p>The result is practically perfect timing on Ryzen and Intel 11th Gen and older systems, and <em>almost</em> perfect timing on 12th Gen Alder Lake systems. Having completely different cores counting time simultaneously inside the CPU is not pretty for this specific application. We can’t defeat the hybrid asymmetric nature of Intel’s design, but we managed to reduce the drift from a second per minute, to a second every 5 minutes or so.</p> <p>&ldquo;Okay, this is pretty good&rdquo; said Morph, but how can you go even deeper? The only option left is to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9982" data-gh-pr="9982">drop to assembly.</a> </p> <p>The optimization in question is currently only available for 12th Gen and newer Intel CPUs; AMD has not added support for it yet. We’re talking about <a href="https://www.felixcloutier.com/x86/tpause">TPAUSE</a> (CPUID name <code>WAITPKG</code>), a new instruction from Team Blue which allows the CPU to enter a lower power state and idle until a precise amount of time has passed.</p> <p>Some testing was required to specify the correct number of cycles for the wait period; a wrong value would reduce precision too much on one extreme, or not produce any benefit on the other. 100000 cycles was the magic number in Morph’s testing, which reduced CPU use/power consumption by up to 20%, on top of the previous benefits.</p> <p>If only Intel GPU drivers <a href="https://github.com/IGCIT/Intel-GPU-Community-Issue-Tracker-IGCIT/issues/159">worked</a>, their Xe equipped laptops/handhelds would now be very viable yuzu gaming machines… Oh well, 12th/13th Gen users running actual working GPU drivers from NVIDIA or AMD will benefit greatly from all this work.</p> <h2 id="graphical-changes">Graphical changes</h2> <p>Enough with the CPU improvements. What about graphics? Well, we have quite a bit to talk about.</p> <p>Users reported interesting colour banding on <code>STORY OF SEASONS: A Wonderful Life</code>. <a href="https://github.com/Kelebek1">Maide</a> dug deep into the issue, and identified the culprit in <code>S8_UINT</code> colour formats, like <code>D32_FLOAT_S8_UINT</code> and <code>S8_UINT_D24_UNORM</code>. With some trial and error, and some big help from the great <a href="https://github.com/bylaws">bylaws</a> (from the <a href="https://github.com/skyline-emu/skyline">Skyline</a> emulator), Maide managed to sort out the issues, providing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9896" data-gh-pr="9896">accurate colour rendering</a> without breaking other games.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/sosbug_hu5c8bcb7bb3b76444625e2a3906d5fc1e_1450072_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now you can enjoy this farming simulator, with all its vibrant hues, without having to worry about colour banding. Isn’t that a-moo-sing? (STORY OF SEASONS: A Wonderful Life)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/sosfix_hu236986598565b2900263fa0d0f4f895d_1205655_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now you can enjoy this farming simulator, with all its vibrant hues, without having to worry about colour banding. Isn’t that a-moo-sing? (STORY OF SEASONS: A Wonderful Life)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Now you can enjoy this farming simulator, with all its vibrant hues, without having to worry about colour banding. Isn’t that a-moo-sing? (STORY OF SEASONS: A Wonderful Life)</p> <p><a href="https://github.com/ameerj">epicboy</a> strikes again with his ninja updates. This time he gives some love to the <em>still thriving</em> OpenGL gang, bringing all the goodies of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9913" data-gh-pr="9913">AccelerateDMA,</a> which we discussed in the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/#project-yfc-175">last report</a>.</p> <p>This means that OpenGL users, especially those with Fermi and Kepler GPUs, can enjoy the speed boost of this pseudo-Y.F.C. 2 change, making games such as <code>Metroid Prime Remastered</code> run much faster. No more waiting for Samus to load her arm cannon.</p> <p>We strongly advise users of older hardware without good Vulkan support to upgrade to something newer, as support for OpenGL is soon nearing its End of Life. That being said, thanks to epicboy, those who can’t upgrade won’t suffer from terrible performance using the old but gold OpenGL API.</p> <p>But that’s not all, epicboy also added an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9925" data-gh-pr="9925">optimization</a> for <code>GL_SYNC_STATUS</code>, boosting performance slightly. Your writer observes a 3-5% performance increase in <code>The Legend of Zelda: Breath of the Wild</code>, one of the few games that runs faster on OpenGL with NVIDIA hardware, if you ignore the shader stuttering.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./botw.png" title=" From 54 to 57 FPS in one of the heaviest spots in the game, OpenGL still has life in it! For now… (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/botw_hue7f8ce9d3d2f3df2e8310b6792e8e6f5_2293449_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" From 54 to 57 FPS in one of the heaviest spots in the game, OpenGL still has life in it! For now… (The Legend of Zelda: Breath of the Wild)"></a> <p class="has-text-centered is-italic has-text-grey-light"> From 54 to 57 FPS in one of the heaviest spots in the game, OpenGL still has life in it! For now… (The Legend of Zelda: Breath of the Wild)</p> </div> </div> <p>bylaws came to the rescue again, pointing out that our old Vulkan scheduler implementation had some regressions <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/#graphics-and-general-bug-fixes">back in October</a> of last year, when <a href="https://github.com/liamwhite">byte[]</a> worked on making homebrew apps work with Vulkan.</p> <p>This meant that games and homebrew would have to wait for a frame to show up on screen before starting to render, which in some cases is a bad example of feedback looping at its worst.</p> <p>By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9931" data-gh-pr="9931">waiting in the background</a> for the queue to be emptied without having to wait for the frame to be presented, byte[] fixed the regression. Thanks bylaws!</p> <p>Remember that lovely game we talked about <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/#other-gpu-and-video-changes">last month?</a> The one for all ages! Totally safe to play with your family.</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> decided to make it playable, so <del>weebs</del> players around the world could enjoy the amazing gameplay of <code>Moero Crystal H</code>, by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9943" data-gh-pr="9943">fixing</a> some errors in how yuzu processed the inline index and draw texture commands.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mch.png" title=" Cultured gaming (Moero Crystal H)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/mch_hu38a690a748d339661e36473fc6c160e0_3738961_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Cultured gaming (Moero Crystal H)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Cultured gaming (Moero Crystal H)</p> </div> </div> <p>A recent system update for the Steam Deck messed up the graphics in many games. The culprit? Some issue with <code>VK_EXT_extended_dynamic_state3</code>, one of the Vulkan extensions that helps reduce shader building stutter.</p> <p>A combination of yuzu expecting NVIDIA driver behaviour, and a difference in the latest Mesa implementation on the Deck caused what you see next:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./eds1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/eds1_huaa5b610d9122d93ef767bac5c7409295_2091343_800x0_resize_q90_bgffffff_box_3.jpg" alt="Looks like someone spilled some paint on the screen (The Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./eds2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/eds2_hu473653b412ccb6ad1b2dfb0baec0c52d_3481550_800x0_resize_q90_bgffffff_box_3.jpg" alt="Looks like someone spilled some paint on the screen (The Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./eds3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/eds3_hub070a68fafb83ba685c66755b0b3e00d_2919142_800x0_resize_q90_bgffffff_box_3.jpg" alt="Looks like someone spilled some paint on the screen (The Legend of Zelda: Breath of the Wild)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Looks like someone spilled some paint on the screen (The Legend of Zelda: Breath of the Wild)</p> <p>byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9955" data-gh-pr="9955">disabled</a> the feature that caused the problem for now, but we’ll reconsider turning it on again in the future as it’s very likely Mesa <a href="https://gitlab.freedesktop.org/mesa/mesa/-/issues/8325">has already fixed the issues</a> on their end.</p> <p>Here’s a couple of important fixes for the Xenoblade fans, which Maide spent a lot of time working on.</p> <p>Shaders were broken in-game due to issues with sRGB border colour conversions in the samplers. This is a process that converts colours from one colour space to another. This would cause inaccuracies that made some checks fail on affected shaders, resulting in discarding the wrong pixels as shadows.</p> <p>We need more information to fully understand the issue, but for now, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9962" data-gh-pr="9962">ignoring</a> colourspace transformations on sRGB samplers allows for hardware-accurate rendering.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/xcbug_hu38d47cad4e7d5eef306f34cae56cb5b4_1633755_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Rex knew what the future held for him, wink wink (Xenoblade Chronicles 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/xcfix_hu59e8d7ef4855c73f1cd0f7fa32b6fe37_1652755_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Rex knew what the future held for him, wink wink (Xenoblade Chronicles 2)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Rex knew what the future held for him, wink wink (Xenoblade Chronicles 2)</p> <p>The other long-standing issue affecting the Xenoblade trilogy (well, Definitive Edition and 2 at least) has been plaguing yuzu since the legendary <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">Texture Cache Rewrite</a>. It was the random &ldquo;rainbow mode&rdquo; that could happen anytime during gameplay, or in a specific late-game cutscene in <code>Xenoblade Chronicles 2</code> that I won’t spoil for new players. If you played it in yuzu, you know which one. It makes you wonder if you’re in <a href="https://tvtropes.org/pmwiki/pmwiki.php/VideoGame/Bioshock">Rapture</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sea.png" title=" Somewhere, beyond the (cloud) sea! (Xenoblade Chronicles 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/sea_hu0c5198bc6f576610a91d09a5ece53316_8341004_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Somewhere, beyond the (cloud) sea! (Xenoblade Chronicles 2)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Somewhere, beyond the (cloud) sea! (Xenoblade Chronicles 2)</p> </div> </div> <p>Another observed problem was excessive lighting making the whole scene unreadable (especially at night with an HDR display, not a pleasant sudden flashbang).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./flashbang.png" title=" My eyes! (Xenoblade Chronicles 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/flashbang_huac2e0fba6b516d1fb16d91a384c6ff5c_473374_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" My eyes! (Xenoblade Chronicles 2)"></a> <p class="has-text-centered is-italic has-text-grey-light"> My eyes! (Xenoblade Chronicles 2)</p> </div> </div> <p>Maide found that the issue was caused by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10004" data-gh-pr="10004">replacing</a> fresh guest data with stale host data in the environment lighting cubemaps. The solution is to only copy data that has been marked as GPU-modified, following the behaviour of the <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/">Buffer Cache Rewrite</a>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/xcdebug_hu47c3e4f16c6e363287c88e1e51fe6ae5_5207444_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This isn’t 2009, we don’t need this much bloom, thank you very much (Xenoblade Chronicles: Definitive Edition)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/xcdefix_hu399dd37a469819b45d1b5cdd535252f2_4922485_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This isn’t 2009, we don’t need this much bloom, thank you very much (Xenoblade Chronicles: Definitive Edition)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This isn’t 2009, we don’t need this much bloom, thank you very much (Xenoblade Chronicles: Definitive Edition)</p> <p>With these changes, few graphical issues remain affecting the Xenoblade Chronicles saga, making it a great choice to enjoy on yuzu from start to finish. Then you can join your writer in debating over which Queen is the best.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/xc2bug_hu0c5198bc6f576610a91d09a5ece53316_8341004_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Since this issue only happens the first time the cutscene renders, I’ll cheat using bug report pics, bite me (Xenoblade Chronicles 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/xc2fix_hu0b2a198fea75b086a405a4f3829e721d_8188046_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Since this issue only happens the first time the cutscene renders, I’ll cheat using bug report pics, bite me (Xenoblade Chronicles 2)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Since this issue only happens the first time the cutscene renders, I’ll cheat using bug report pics, bite me (Xenoblade Chronicles 2)</p> <p>Newcomer <a href="https://github.com/rschlaikjer">rschlaikjer</a>, I hope I pronounced that right, has been digging deep into the texture cache, trying to figure out why a simple visual novel like <code>Tsukihime -A Piece of Blue Glass Moon-</code> would stutter when changing scenes. Maybe it’s because the game is too emotional for the emulator to handle.</p> <p>The culprit was a missing reference operator when capturing the GPU page table, which caused the table to be copied over and over again thousands of times per second. That would make anyone stutter, let alone an emulator. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9988" data-gh-pr="9988">Converting</a> the capture to a reference solved the issue, and it might also fix similar problems in other games.</p> <p>We’re glad rschlaikjer caught this bug before it got out of hand. We don’t want to end up like <a href="https://youtu.be/NPVRBa-VSMg">that chair</a>.</p> <h2 id="ui-changes">UI changes</h2> <p>Some issues are so elusive that they go unnoticed for years. Some issues are so complex that they require a deep understanding of all the layers involved to find the right solution. They frustrate many developers who give up, hoping someone else will have better luck.</p> <p>And some issues are just plain silly. Like when a game crashes because the default user profile is damaged.</p> <p><a href="https://github.com/german77">german77</a> found a simple fix for crashes in dozens of games: <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9908" data-gh-pr="9908">setting the default profile picture</a> to a real 32x32 resolution instead of 0x0. That’s it.</p> <p>Continuing to work on UI improvements, german77 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9941" data-gh-pr="9941">moved the last audio</a> setting <code>Mute audio when in background</code> to the Audio section, where it belongs. No more wandering around in General for this option.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/audiobug_hu790272569dba658cfda7ee7e661a93c9_35013_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Good, proper order"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/audiofix_hu661ab224fa27ebe25da380f4e5968a92_36082_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Good, proper order"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Good, proper order</p> <p>This next one is a great improvement for UX (user experience), and a huge relief for me personally. Before, when using per-game controller profiles, if you forgot to change your input settings before starting a game, you would lose them when the game closes and have to set them up again next time.</p> <p>epicboy <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9965" data-gh-pr="9965">fixed this annoying issue</a> and german77 merged the changes. Thank you so much for this fix.</p> <p>german77 is also working on making the profile selection applet better. The <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10006" data-gh-pr="10006">current changes</a> are just the beginning, we will keep you updated on any progress in the future.</p> <h2 id="input-improvements">Input improvements</h2> <p>Let’s talk about input, where german77 continues to shine.</p> <p>Not satisfied with the mouse and keyboard experience when <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9906" data-gh-pr="9906">playing</a> <code>Metroid Prime Remastered</code>, german77 set the default mouse sensitivity to 50% and removed the smoothing filter, improving the performance on high DPI gaming mice after getting valuable feedback from Metroid fans. He also lowered the motion threshold, clamped the rotation speed, and accumulated all input until delivery, which fixed the delay and choppiness of the previous implementation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./prime.png" title=" Have you noticed how Samus lacks a lead indicator? Her suit couldn’t spare a tiny bit more processing power for that? (Metroid Prime Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/prime_huf3f2f9748c1285d4adfe70ff1233237f_7595158_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Have you noticed how Samus lacks a lead indicator? Her suit couldn’t spare a tiny bit more processing power for that? (Metroid Prime Remastered)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Have you noticed how Samus lacks a lead indicator? Her suit couldn’t spare a tiny bit more processing power for that? (Metroid Prime Remastered)</p> </div> </div> <p>Thanks to those changes, <code>Metroid Prime Remastered</code> showed that it could be a great PC game. If only Nintendo would let it out of its dungeon.</p> <p>A common question we get is &ldquo;will this third party Switch controller work?&rdquo; The short answer is maybe, but the long answer is a bit more complicated.</p> <p>According to Nintendo’s API, Joy-Cons have two modes: active and passive. Official Joy-Cons use active mode, but some third party controllers use passive mode, usually because they don’t follow the API properly and don’t support any configuration commands. They just run with the default settings, for better or worse.</p> <p>That doesn’t mean passive controllers are useless. They still work on the Switch. But it does mean that they work differently. Active controllers update their status every 15 ms, while passive controllers only do it when something happens, such as a button press or release.</p> <p>Well, it turns out yuzu didn’t support passive mode until now! So german77’s <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9907" data-gh-pr="9907">changes</a> made a lot of third party controller users happy. That’s quite handy, considering how many unofficial controllers are out there.</p> <p>The battle with vibration goes on! While doing his usual research, german77 found out that if you have more than one player using the same type of controller, or if you use a dual Joy-Con setup with a single controller, you can end up sending two vibration commands to the same controller in a row. This can be annoying, and it also takes up the limited bandwidth of Bluetooth connections.</p> <p>The <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9939" data-gh-pr="9939">solution is simple:</a> only take the latest element in the <a href="https://www.youtube.com/watch?v=gzY8VH7eb8Y">cool vibrations</a> queue for each controller, check if the controller can handle the requested vibration, and ignore the rest.</p> <p>We all love Quality of Life changes, right? Even if they are not very flashy.</p> <p>Let’s talk about the <code>Controller Applet</code>, which is responsible for asking players to choose their input settings when the game requests it. Until now, the applet was unskippable; you had to give a valid answer to continue with your game. While this was passable, it’s bothersome and inaccurate. Some games go back to a previous menu instead of getting stuck in an endless loop if the players can’t or won’t confirm their input style.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./applet.png" title=" You shall pass!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/applet_hu4d00f2f4e4589aa2bd3acdfc36ca125a_32651_811x0_resize_q90_bgffffff_box_3.jpg" alt=" You shall pass!"></a> <p class="has-text-centered is-italic has-text-grey-light"> You shall pass!</p> </div> </div> <p>german77 solved this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9997" data-gh-pr="9997">behaviour,</a> and while at it also solved a bug where the player count wasn’t correct.</p> <p>german77 implemented the… hold on, let me catch my breath first, <code>SetNpadJoyAssignmentModeSingleWithDestination</code> service call. He <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9999" data-gh-pr="9999">implemented</a> it hoping to make <code>Let’s Get Fit</code> playable, but unfortunately there are more issues in the way.</p> <p>Changing topics to Amiibo support, a lot has happened this month.</p> <p>First of all, german77 managed to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9953" data-gh-pr="9953">write</a> the correct <a href="https://en.wikipedia.org/wiki/Cyclic_redundancy_check">CRC</a>, making Amiibo data written by yuzu compatible with the Switch; no more invalid info.</p> <p>Next, if you tried to connect a controller while scanning an Amiibo, it would not be recognized. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9981" data-gh-pr="9981">accounting</a> for this and initializing or finalizing the controller, he fixed the issue.</p> <p>And last but not least, to wrap up the Amiibo saga, Herman the German Sherman <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9995" data-gh-pr="9995">added support</a> for plain Amiibo files. Some Amiibos, like the ones themed after <code>Super Smash Bros. Ultimate</code>, can be edited without the need of keys. Now yuzu can read non-encrypted game data from your Amiibos correctly!</p> <h2 id="audio-fixes">Audio fixes</h2> <p>Maide managed to spot a bug in how the reverb pre-delay line was being read, causing problems in the output. Solving it by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9890" data-gh-pr="9890">correctly reading</a> via input instead of output gives games like <code>New Super Mario Bros. U Deluxe</code> proper audio. Now you can enjoy Mario’s voice without any echo. Mama mia!</p> <p>bylaws has been digging deep into <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9969" data-gh-pr="9969">audio synchronization,</a> improving the codebase here and there, and managing to avoid stalls by linking the guest sample tracking to the host.</p> <p>This change caused some regressions, as some games are <em>very sensitive</em> to audio scheduling requirements. Users reported popping sounds after the merge, so bylaws improved the situation by adding a constant 15 ms of <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10027" data-gh-pr="10027">latency</a> to the sample count reporting.</p> <h2 id="other-code-changes">Other code changes</h2> <p>Fire Emblem fans have been experiencing freezes in-game, and after some investigation, Morph found out that the culprit was the bounded threadsafe queue, introduced with a pull request from <a href="https://github.com/behunin">behunin</a>.</p> <p>The queue’s job is to pass events from an event producer (like the CPU cores) to an event consumer (like the GPU thread). The previous implementation, which behunin replaced, kept allocating and freeing memory, causing periodic latency spikes.</p> <p>The way to solve this issue is to turn the queue into a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9778" data-gh-pr="9778">bounded queue,</a> meaning no memory allocation is needed as there is a fixed amount of resources available. And that’s what behunin did, but the new queue implementation seemed to be buggy. Morph added a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9971" data-gh-pr="9971">simplified implementation,</a> fixing the new gameplay freezes affecting <code>Fire Emblem: Three Houses</code> and <code>Fire Emblem Engage</code>.</p> <p><a href="https://github.com/goldenx86">Your writer</a> re-enabled LTO for GCC builds, following the changes made for Windows last time, but only applying the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/10014" data-gh-pr="10014">optimizations to the core and video_core subprojects,</a> providing Linux users a nice, free performance boost.</p> <h2 id="hardware-section">Hardware section</h2> <h3 id="amd-2332-and-newer-drivers">AMD 23.3.2 and newer drivers</h3> <p>One bad and two good pieces of news.</p> <p>On the positive side, AMD has finally added support for the missing dynamic state extensions in their latest Windows driver release, which improves the shader build times and reduces the stuttering on Radeon GPUs, making them perform on par with NVIDIA.</p> <p>However, on the negative side, this driver update also introduces a serious regression:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./amd.png" title=" This can affect your entire desktop (Metroid Prime Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2023/amd_huf6c4d40ff2cbc00069403b8d4c8f6aae_7081827_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" This can affect your entire desktop (Metroid Prime Remastered)"></a> <p class="has-text-centered is-italic has-text-grey-light"> This can affect your entire desktop (Metroid Prime Remastered)</p> </div> </div> <p>Some games, such as <code>Metroid Prime Remastered</code> and <code>Pokémon Legends: Arceus</code>, trigger what seems to be an out-of-bounds crash that causes desktop corruption and a driver crash. We advise users to stay on driver version 23.3.1 or older for now. Some older Radeon cards may also benefit from using 23.2.2.</p> <p>We reported this issue to AMD and they promptly confirmed it, reproduced it, and informed us that they are working on a fix.</p> <p>Now <em>that’s</em> how you do customer support.</p> <p>Speaking of which…</p> <h3 id="doing-intels-job">Doing Intel’s job</h3> <p>While testing a crucial rendering fix for <code>The Legend of Zelda: Breath of the Wild</code> that we will discuss next month, Morph did some feature testing to investigate what makes Intel Windows drivers run so horribly.</p> <p>His findings are both expected and disappointing. The main culprit for about 95% of the crashes is a faulty compute shader stage in the drivers. Disabling compute shaders like we used to do for older Intel hardware makes most games run, but not all. We still don’t know the cause of the crashes when opening the menu in <code>Xenoblade Chronicles 3</code>.</p> <p>We’re now trying to figure out what triggers the compute shaders to crash the driver like this, but this also raises a dilemma. Should we patch the issue ourselves, making game rendering worse and letting Intel off the hook, or should we leave it broken so they have to fix it properly?</p> <p>The solution while the investigation continues is to use ol’ reliable Linux, or avoid buying hardware that relies only on Intel GPUs. Sigh.</p> <h2 id="future-projects">Future projects</h2> <p>We’re not even halfway through April and I’m already thrilled about what’s coming up in the next progress report. The devs are on fire and they’re not stopping anytime soon.</p> <p>Maide is working on more improvements for the Xenoblade series, such as fixing the cloud flickering in <code>Xenoblade Chronicles 2</code>, the particle effects in <code>Xenoblade Chronicles 3</code>, and the texture flickering that affects the whole saga and some other games. However, these fixes come at a performance cost, so he needs some help from another GPU developer to optimize them. Maybe <a href="https://github.com/FernandoS27">Blinkhawk</a> could lend a hand?</p> <p>Nintendo contributed in releasing the holy grail of Vulkan extensions, <a href="https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VK_EXT_shader_object.html">VK_EXT_shader_object</a>. This extension promises to cut down the amount of work needed to build shaders significantly, as its dependencies suggest, requiring support for all previous dynamic state extensions.</p> <p>Most likely Nintendo intends to use it for their internal emulators, maybe for &ldquo;backwards compatibility.&rdquo; Regardless of any of that, we have a lot of work ahead of us to add support for this extension.</p> <p>But enough about that. Let’s talk about some exciting projects in the works. <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gaia.jpg" title=" Flute intensifies"><img src="./gaia.jpg" alt=" Flute intensifies"></a> <p class="has-text-centered is-italic has-text-grey-light"> Flute intensifies</p> </div> </div> </p> <p>Regarding Project Gaia: it is still in development.</p> <p>Oh, and Project Lime is in release candidate status, under intense internal testing.</p> <p>That’s all folks! Thank you for sticking around until the end of this progress report.</p> <p>Thanks to Bing Chat for the terrible jokes.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report February 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/ Sun, 12 Mar 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/ <p>Hello yuz-ers! This month has seen changes across all aspects of yuzu. We have improvements in the GPU, Kernel, Services, Input, User Interface and Experience, Driver related rants, and more!</p> <p>Hello yuz-ers! This month has seen changes across all aspects of yuzu. We have improvements in the GPU, Kernel, Services, Input, User Interface and Experience, Driver related rants, and more!</p> <h2 id="project-yfc-175">Project Y.F.C. 1.75?</h2> <p>Another month, another Project Y.F.C. addendum. Introducing one of the features that was missing from the previous 1.5 release.</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> implemented host texture download acceleration for the Switch’s DMA engine (or Accelerate DMA for short).</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9786" data-gh-pr="9786">DMA acceleration</a> reduces a ton of overhead by letting the GPU handle texture downloads, improving performance considerably with games that aren’t CPU bottlenecked.</p> <p>yuzu, in the past, ran everything via the host&rsquo;s CPU and system memory, with the process of <a href="https://en.wikipedia.org/wiki/Z-order_curve#Texture_mapping">swizzling/unswizzling</a> textures being a primary task. Now this process is done on the GPU and its VRAM, saving CPU cycles and avoiding having to transfer information back to system memory, and giving us access to the vastly superior bandwidth available in a modern GPU&rsquo;s video memory.</p> <p>When you find a game that benefits from faster texture downloads, the numbers speak for themselves:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dma.png" title=" Bottleneck busters!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/dma_hu6567dee3919ef709d7b1c5f65e7c3b0a_12746_721x0_resize_q90_bgffffff_box_3.jpg" alt=" Bottleneck busters!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Bottleneck busters!</p> </div> </div> <h2 id="other-gpu-and-video-changes">Other GPU (and video) changes</h2> <p>Before going over the <em>rendering</em> changes in GPU emulation, let’s cover something we haven’t touched in a while: video decoding.</p> <p>Firstly, <a href="https://github.com/vonchenplus">vonchenplus</a> improved the speed at which <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9777" data-gh-pr="9777">video frame data</a> is copied. That is, as long as the compiler notices the optimization and makes use of it. When it works, this has the added benefit of reducing the time it takes to start playing videos.</p> <p>Next, <a href="https://github.com/Kelebek1">Maide</a> disabled multi-frame decoding, which caused a frame of delay, giving Maide the option to also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9810" data-gh-pr="9810">set the decoder to use all available CPU threads.</a> While most people don’t have issues with video decoding performance, people running old GPUs, for example AMD Polaris series (RX 400/500 cards), will use their CPU for decoding VP9 videos, as these older cards lack the required hardware decoder.</p> <p>Games such as <code>The Legend of Zelda: Skyward Sword HD</code> will provide much smoother video playback with these changes.</p> <p>Okay, enough about pre-rendered 2D frames in sequence, what about real 3D stuff? Happily, we have a bit to talk about.</p> <p><a href="https://github.com/behunin">behunin</a> is back, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9744" data-gh-pr="9744">optimizing the</a> <code>gpu_thread</code> code. The <code>gpu_thread</code> has one job and only one job, to consume its command queue. The problem is that it was also generating commands as well as consuming them. By getting rid of this undesired behaviour, the <code>gpu_thread</code> is back to only consuming commands, leaving the road open for more future fixes.</p> <p>Even from the shadows, <a href="https://github.com/ameerj">epicboy</a> still gifts us a handful of new toys. A true Eminence in Shadow.</p> <p>Avid readers may remember that <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/">MSAA image uploads</a> hold a weird spot in Switch emulation. There’s a conflict between what the Switch can do with its native NVN API, and what our available graphics APIs (OpenGL and Vulkan) allow.</p> <p>Both OpenGL and Vulkan are very restrictive regarding <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9746" data-gh-pr="9746">MSAA texture</a> uploads and copies, leaving epicboy with the only remaining tool available. Yep, you’re right! Time to use a compute shader!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./msaabug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./msaafix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Breaking the rules to get proper rendering (Sonic Forces)</p> <p>This way, rendering is accurate. Do keep in mind that this is an implementation only for OpenGL. Vulkan, as always, is much more work so it’s homework for later.</p> <p>While working on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9749" data-gh-pr="9749">fixing regressions</a> in Blinkhawk’s <a href="https://github.com/yuzu-emu/yuzu/pull/9559">cached writes pull request</a> affecting <code>Yoshi's Crafted World</code> (the game would freeze when using Normal GPU accuracy), epicboy also fixed <code>Pokémon Scarlet/Violet</code>’s missing building geometry issues.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/pokebug_hu73c38e4f9ea4f02dcb1f9e54aef1e60b_6210593_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more ghost town (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/pokefix_hu75cd442802fb4ed58ed45b66f9d0566a_6167589_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more ghost town (Pokémon Scarlet)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more ghost town (Pokémon Scarlet)</p> <p>Ahh, <a href="https://en.wikipedia.org/wiki/Adaptive_scalable_texture_compression">ASTC</a>, most of you know the struggle by now. Mobile devices like phones, tablets, Macs, the Nintendo Switch, among others, have native support for this very compressed texture format, but laptop/desktop/server GPUs don’t. This leaves the Switch emulation community struggling with ways to mitigate the slow process of decoding these textures on hardware that is not designed for such a task.</p> <p>Yes, even the weak and outdated Switch beats an RTX 4090 in this task. Bet your wallet isn’t happy about that fact.</p> <p>yuzu’s weapons in this fight so far were multithreaded CPU decoding, and GPU decoding via compute shaders, which takes advantage of the huge parallelization power of modern GPUs. Both solutions have stuttering always present while the decoding takes place, especially in new games that overly use large ASTC textures, like <code>Bayonetta 3</code> and <code>Metroid Prime Remastered</code>.</p> <p>Well, epicboy adds a new weapon to our arsenal, and oh boy it can help. At a price. Introducing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9849" data-gh-pr="9849">Asynchronous ASTC texture decoding!</a> </p> <p>For those that prefer zero ASTC related stuttering during their gameplay, this new toggle uses a background thread to decode ASTC textures while the game is being rendered. Such an approach will eliminate stuttering, but has the cost of introducing graphical glitches until the textures finish loading in.</p> <p>Here’s a comparison of asynchronous decoding with a 16 threads Ryzen 7 5800X3D (so not even the king of the hill in thread count, what matters the most for CPU decoding), vs an RTX 4090, the biggest commercially available compute monster for consumers right now.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./compute.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./async.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">GPU compute shader decoding on the left, asynchronous CPU decoding on the right (ASTRAL CHAIN)</p> <p>As you can see, while the process taking place is pretty obvious to the eye with asynchronous decoding, it’s significantly faster than the best GPU available right now. Even a 12-thread CPU would still win a drag race in the most intensive ASTC game ever, <code>ASTRAL CHAIN</code>. Users with lower thread count CPUs (like quad cores with 8 threads or lower) may need to time their results.</p> <p>You can find the option in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Decode ASTC textures asynchronously (Hack)</code>. Enabling it will also override the setting <code>Accelerate ASTC texture decoding</code> in the <code>Graphics</code> tab. This setting makes yuzu use the GPU, but enabling <code>Decode ASTC textures asynchronously (Hack)</code> will force yuzu to always use CPU decoding. So remember to disable asynchronous ASTC decode if you want to use GPU compute decoding instead.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./astc.png" title=" We recommend low CPU thread users to stick to GPU decoding"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/astc_hu0e193bbda92f82ec734bfd3be037a732_23725_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We recommend low CPU thread users to stick to GPU decoding"></a> <p class="has-text-centered is-italic has-text-grey-light"> We recommend low CPU thread users to stick to GPU decoding</p> </div> </div> <p>According to epicboy, while an asynchronous GPU compute method is possible, the rules and limitations of compute shaders hinder its potential, most likely making it barely any better than regular GPU decoding with the compute units.</p> <p>Life would be so much easier if GPU vendors properly added native ASTC support to their GPUs… Your reporter would gladly take it over useless stuff like RGB, ugly plastic shrouds, or driver DVDs.</p> <p>NVIDIA, AMD, please consider adding native ASTC support. It’s certainly more useful than generating fake frames with disgusting artifacting. Intel, you had great ASTC support in your iGPUs. Consider adding it back to future versions of Arc graphics.</p> <p>Maide has been working on trying to solve the overlapping textures glitches that can be spotted in games like <code>The Legend of Zelda: Breath of the Wild</code> and <code>Xenoblade Chronicles 3</code>. While it isn’t a perfect solution, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9802" data-gh-pr="9802">re-adding</a> the (accidentally) removed <code>invalidate_texture_data_cache</code> register helps mitigate the issue at almost any camera angle except the most oblique ones.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/botw1_hud929a3af30b958f83e93295e9ab66efe_160091_800x0_resize_q90_bgffffff_box_3.jpg" alt="We present you: New crack sealer! Move the camera and the cracks are gone! (The Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/botw2_hud5be77e327251dcb6e2045322648d1aa_148119_800x0_resize_q90_bgffffff_box_3.jpg" alt="We present you: New crack sealer! Move the camera and the cracks are gone! (The Legend of Zelda: Breath of the Wild)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">We present you: New crack sealer! Move the camera and the cracks are gone! (The Legend of Zelda: Breath of the Wild)</p> <p>Depending on the shape of the terrain, or the camera angle, the issue can surface again. But as a temporary solution, this change makes playing affected games much more tolerable. Work continues!</p> <h2 id="cpu-kernel-services-and-optimizations">CPU, kernel, services, and optimizations</h2> <p><a href="https://github.com/merryhime">Merry</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9735" data-gh-pr="9735">updated dynarmic</a> , our JIT, to version 6.4.5, solving some issues and improving compilation times. One game that benefited from this is <code>Taiko Risshiden V DX</code>, which got its load times reduced considerably.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./taiko1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/taiko1_hu04ceb0629c93b719c92fc827aaee2abd_8502303_800x0_resize_q90_bgffffff_box_3.jpg" alt="Take your time (Taiko Risshiden V DX)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./taiko2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/taiko2_hu8378888cca9f2bc69bb9acccb870b3bc_11192093_800x0_resize_q90_bgffffff_box_3.jpg" alt="Take your time (Taiko Risshiden V DX)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Take your time (Taiko Risshiden V DX)</p> <p><a href="https://github.com/liamwhite">byte[]</a> has also been going deep into the kernel code. One of his changes improves the <code>SVC wrappers</code>. But what are the wrappers? Well, games and homebrew need to talk to the kernel, and to do so they use SVC instructions, which act as an interface with the kernel.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wrapper.png" title=" The return of mspaint"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/wrapper_hud540926667c06dd6505d83e6e7ac2624_8185_932x0_resize_q90_bgffffff_box_3.jpg" alt=" The return of mspaint"></a> <p class="has-text-centered is-italic has-text-grey-light"> The return of mspaint</p> </div> </div> <p>The work of the wrapper is to translate a request from the game into a C++ call into the kernel, and then get the result from the kernel back into the game. In the past, yuzu used manually written wrappers that were very error-prone. With this change, byte[] instead <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9742" data-gh-pr="9742">automatically generates</a> the needed wrappers. This code is far more accurate, so if you find games that no longer crash or soft-lock, here’s the new code responsible for it. One such example is <code>Moero Crystal H</code> which starts booting for the first time.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mch.png" title=" Don’t judge, it’s part of the Switch’s library (Moero Crystal H)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/mch_hua44d7150bdead4d8764c4eae00e427fe_3691736_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Don’t judge, it’s part of the Switch’s library (Moero Crystal H)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don’t judge, it’s part of the Switch’s library (Moero Crystal H)</p> </div> </div> <p>This game requires more work to get proper video and gameplay rendering.</p> <p>Keeping the pursuit for accuracy, byte[] also implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9832" data-gh-pr="9832">HLE multiprocess</a> for services. Now instead of pushing the game’s requests to the services, the services wait for the requests to arrive. All this processing is done, for the most part, in what would be the emulated <code>core 3</code> of the Switch, instead of all over the place with one thread per service. Games usually only have access to cores 0 to 2, so we&rsquo;re now dedicating the last core for system service processing, just as the actual Switch operating system does!</p> <p>This part of CPU emulation is one of the main reasons we recommend at least 6 cores in our <a href="https://yuzu-mirror.github.io/help/quickstart/#hardware-requirements">hardware requirements</a>, 4 for uninterrupted emulation of the Switch’s CPU, and extras for other processes and tasks. Just a 4 core CPU will be usually overburdened. HT/SMT may help, but that will always depend on the workload at any given moment. A SMT/HT thread can’t improve performance in a significant way if the core is already saturated.</p> <p><a href="https://github.com/bunnei">bunnei</a> chimed in too, fixing a mistake in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9773" data-gh-pr="9773">memory mapping.</a> We erroneously used the (bear with me, it’s not a redundancy) system’s system resource tracking, instead of relying on the application’s resource tracking when loading programs into memory. Most games were tolerant to this, but <code>FINAL FANTASY CRYSTAL CHRONICLES Remastered Edition</code> didn’t like it, getting stuck every time the user tried to load a save. A tweak here and there and the regression is now gone!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ffcc.png" title=" Feel free to progress the game now (FINAL FANTASY CRYSTAL CHRONICLES Remastered Edition)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/ffcc_huf5d9c8baaa09e77411a4bb286bf8eeab_10743227_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Feel free to progress the game now (FINAL FANTASY CRYSTAL CHRONICLES Remastered Edition)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Feel free to progress the game now (FINAL FANTASY CRYSTAL CHRONICLES Remastered Edition)</p> </div> </div> <p>New Pokémon game update, new things to fix. Once again, <code>Pokémon Scarlet/Violet</code> is giving us a headache.</p> <p>This time, the recently released update 1.2.0 wouldn’t boot on yuzu. After investigating for a bit, <a href="https://github.com/german77">german77</a> found out that the cause was that some <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9874" data-gh-pr="9874">Bluetooth functions</a> weren’t properly implemented, causing the game to crash when attempting to start with the latest update installed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ps.png" title=" Mandatory protagonist seat (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/ps_hu81fdd4de17bb956b966609ec1ea8910d_2173145_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Mandatory protagonist seat (Pokémon Scarlet)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Mandatory protagonist seat (Pokémon Scarlet)</p> </div> </div> <p>Some code changes later, and german77 fixed the issue! Now anyone can enjoy the reduced NPC count and lower draw distance.</p> <p>Even <a href="https://github.com/goldenx86">your writer</a> tried to give a hand (emphasis on tried). <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/#cpu-requirement-changes-with-free-performance">As reported in the past</a>, we applied <code>Link-time Optimization</code> to all of yuzu’s subprojects. This meant that every section like audio, input, UI, etc. used LTO at build time, trying to squeeze out every possible bit of performance. This caused an unexpected problem: RAM consumption while building increased enough to cause our buildbot to cry for help, causing builds on our Azure DevOps CI to randomly run out of memory.</p> <p>byte[] suggested that I instead profile which subprojects would provide the most performance boosts, and to only apply LTO to those. A few rounds of toasting a CPU by building yuzu later, and it was determined that the two most obvious candidates, core and video_core, were the responsible ones for the performance boost provided by enabling LTO.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9872" data-gh-pr="9872">Partially applying LTO</a> to only the core and video_core projects not only reduced compiler RAM use, but also provided a very minor but still consistently measured performance increase. For example, <code>The Legend of Zelda: Link’s Awakening</code> increased from 257 FPS to 260 FPS. Nothing groundbreaking, but it’s a free bonus from a change that was only intended to reduce RAM use!</p> <p><a href="https://github.com/Morph1984">Morph</a> later added a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9887" data-gh-pr="9887">small but very critical fix</a> to get all this actually working. I’m a disaster, sorry.</p> <h2 id="input-improvements">Input improvements</h2> <p><code>Metroid Prime Remastered</code> introduced a serious dilemma: People want to play the game as an FPS with mouse and keyboard.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mpr.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/mpr_hu9f44dbe3c49289861f74038ea0c2431d_13024158_800x0_resize_q90_bgffffff_box_3.jpg" alt="This game is gorgeous, like Samus (Metroid Prime Remastered)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mpr2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/mpr2_hu090a9c65652d8ced4d1b2de7386a9ed6_5669207_800x0_resize_q90_bgffffff_box_3.jpg" alt="This game is gorgeous, like Samus (Metroid Prime Remastered)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This game is gorgeous, like Samus (Metroid Prime Remastered)</p> <p>The problem is that the game uses motion on top of stick input to aim, making it an interesting case for how to handle non-controller input.</p> <p>This was incentive enough to get german77 interested in giving it a try:</p> <ul> <li>First off, he fixed an issue where <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9757" data-gh-pr="9757">motion would be constantly getting recalibrated.</a> </li> <li>Next, german77 tweaked the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9815" data-gh-pr="9815">mouse scaling</a> for users running a DPI scaling higher than 100% (1.0x).</li> <li>Following up, the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9842" data-gh-pr="9842">mapping for mouse input</a> was improved. By default a mouse to stick is considered a joystick, which includes assuming deadzone and ranges that aren’t zero by default. This pull request includes some other miscellaneous changes, like fixing some UI elements not working.</li> <li>And finally, to address <code>Metroid Prime Remastered</code>’s &ldquo;Dual Stick mode&rdquo;, support for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9848" data-gh-pr="9848">dedicated motion using the mouse</a> was added. Since the game only uses two axes, this can be directly mapped 1:1 to mouse movement, making aiming a breeze!</li> </ul> <p>To use this feature, go to <code>Emulation &gt; Configure… &gt; Controls</code>, click on <code>Motion 1</code>, then click again to set the mouse to motion. Then in the Advanced tab, enable mouse panning. After that map the keys manually as if to configure an FPS.</p> <p>GitHub user <a href="https://github.com/SixelAlexiS90">SixelAlexiS90</a> provides an input profile. To use it, on yuzu go to <code>File &gt; Open yuzu folder</code> and place <a href="https://github.com/yuzu-emu/yuzu/files/10958194/MetroidPrimeRemasteredM%2BK.txt">this input profile</a> inside the <code>config\input</code> folder (make a new &ldquo;input&rdquo; folder if there isn&rsquo;t one). All that&rsquo;s left to do after that is to select the profile in yuzu&rsquo;s control settings.</p> <p>The user can adjust the sensitivity of mouse motion with the same setting used for mouse panning in <code>Emulation &gt; Configure… &gt; Controls &gt; Advanced</code></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mouse.png" title=" Remember to set sensitivity to your liking"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/mouse_hu4e9131a7dd19f835d43b029bbbe5cd1d_51055_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Remember to set sensitivity to your liking"></a> <p class="has-text-centered is-italic has-text-grey-light"> Remember to set sensitivity to your liking</p> </div> </div> <p>But did german77 focus on nothing but <code>Metroid Prime Remastered</code>? No. Continuing the work started in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/#new-joy-con-driver-and-other-input-improvements">December of 2022</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9759" data-gh-pr="9759">support for Pro Controllers</a> within the new custom “Joy-Con” driver. Since the option is experimental, it only works properly on official Switch Pro Controllers and not with third party controllers, so it’s disabled by default. Owners of <em>real</em> Pro Controllers are encouraged to enable this option, as it will provide much improved motion and HD Rumble support.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./procon.png" title=" Not the same screenshot as the previous one, I swear"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/procon_hudacbf108db642f84b89d9163ab6c8faa_51108_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Not the same screenshot as the previous one, I swear"></a> <p class="has-text-centered is-italic has-text-grey-light"> Not the same screenshot as the previous one, I swear</p> </div> </div> <p>Previous limitations, like being unable to use a Pro Controller for Amiibo detection, still exist as there’s still work to be done.</p> <h2 id="audio-improvements">Audio improvements</h2> <p>There are some interesting changes in audio emulation that many users will be happy about, let’s go one by one.</p> <p>A crash was fixed by german77 when <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9758" data-gh-pr="9758">initializing</a> <a href="https://github.com/mozilla/cubeb">cubeb</a>, our default audio library. Guess having fewer crashes is always good, right?</p> <p>Merry made an attempt at fixing a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9768" data-gh-pr="9768">rounding issue</a> in the bi-quad filter.</p> <p>While the intention of this change is to partially improve the audio quality in several games, most notably <code>Metroid Prime Remastered</code> (the game of the month), it didn’t quite hit the mark. This wasn’t enough to solve the random noise issues affecting the game, so Maide set out to investigate and found out that the audio emulation codebase was incorrectly saving the state of all different audio channels in the same address!</p> <p>As you can imagine, if the left audio channel stores some samples, the right channel does the same (overwriting what the left channel stored), and then the left channel fetches back something unexpected, the result can sound&hellip; interesting. Users described this problem in Metroid as “if someone shot a gun right by your ears”.</p> <p>Now each audio channel stores its information in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9795" data-gh-pr="9795">different memory regions,</a> avoiding any issues with overlapping access. Not only <code>Metroid Prime Remastered</code> benefits from this; both <code>Fire Emblem</code> games have shown improvements as well.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fee.png" title=" Clown Swimsuit (Fire Emblem Engage)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/fee_hu08d3944a4532940b89d0efd7a9d163eb_5307826_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Clown Swimsuit (Fire Emblem Engage)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Clown Swimsuit (Fire Emblem Engage)</p> </div> </div> <p>Another issue Maide found was a missed check causing an array index to read negative values, which is, in simple terms, “very wrong”. This was causing the audio engine to grab <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9769" data-gh-pr="9769">random chunks of memory</a> as information for mixing, crashing the audio engine, and yuzu with it.</p> <p>Solving this oopsie resolves crashes happening while playing <code>Metroid Prime Remastered</code>, and most likely others too.</p> <h2 id="ui-changes">UI changes</h2> <p>The LDN lobby window got some love from newcomer <a href="https://github.com/unfamiliarplace">unfamiliarplace</a>, adding the option to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9713" data-gh-pr="9713">hide empty rooms.</a> Nothing beats quality of life changes like this, thanks!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lobby.png" title=" Only the dankest rooms, please"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/lobby_hu21e694d61ac83f3641e0d98413345f76_62217_1001x0_resize_q90_bgffffff_box_3.jpg" alt=" Only the dankest rooms, please"></a> <p class="has-text-centered is-italic has-text-grey-light"> Only the dankest rooms, please</p> </div> </div> <p>For Discord gamers, <a href="https://github.com/SoRadGaming">SoRadGaming</a> implemented proper game images for your <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9720" data-gh-pr="9720">Discord Status!</a> The images are grabbed from our compatibility wiki, which is under a rewrite, so expect some games to be missing for now.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./discord1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/discord1_hud7fc1ca0dc4a60b969009e3226ebbd45_8631_800x0_resize_q90_bgffffff_box_3.jpg" alt="Make your friends envy you with this simple trick!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./discord2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/discord2_hu3f9b7e90483236c997e75262cc39c29b_19068_800x0_resize_q90_bgffffff_box_3.jpg" alt="Make your friends envy you with this simple trick!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Make your friends envy you with this simple trick!</p> <p>A small mistake caused the web applet to lose the ability to redraw and zoom its content when resizing the yuzu web applet window. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9761" data-gh-pr="9761">Re-adding</a> the <code>setZoomFactor</code> call fixes the scaling, allowing players to fit their Mario Manual to their needs.</p> <p>Per-game settings are very useful, but also very tricky to get right codewise. <a href="https://github.com/m-HD">m-HD</a> greets us by adding a few missing graphical settings to the list, solving conflicting issues when setting the fullscreen mode, resolution scaling, filter, and antialiasing values in the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9784" data-gh-pr="9784">per-game</a> configuration window.</p> <p>german77 then properly implemented per-game configuration support for the <code>Force maximum clocks</code> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9863" data-gh-pr="9863">setting</a> AMD GPUs <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/">benefit</a> so much from.</p> <p>While we are constantly working to improve the user experience, yuzu sometimes does crash. That’s expected of any first generation emulator, but what shouldn’t happen is not saving changes made to the configuration settings after a crash or a force close. The problem was in our Qt UI, and german77 worked to properly tell Qt to save and sync the configuration to file, avoiding any <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9817" data-gh-pr="9817">configuration change loss</a> after a force close.</p> <h2 id="general-fixes">General fixes</h2> <p><a href="https://github.com/MonsterDruide1">MonsterDruide1</a> continues to do wonders with the <a href="https://yuzu-mirror.github.io/entry/ldn-is-here/">LDN</a> code. This time, proper error handling. One of the possible errors when handling TCP connections is <code>ECONNRESET</code>, which happens when the other end closes the connection abruptly. Old-school gamers call this “rage quitting”.</p> <p>Jokes aside, when a sudden disconnection like this happens, the error used to get caught by yuzu instead of the game, causing the game to never get the notification of the client disconnection. Properly <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9843" data-gh-pr="9843">passing the error</a> through to the game allows it to handle the issue its own way instead of crashing the yuzu LDN session.</p> <p>Some improvements were done to yuzu-cmd, the command-line alternative to the default Qt UI.</p> <p>german77 added support for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9729" data-gh-pr="9729">touch inputs from mouse clicks and SDL controller input support,</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9730" data-gh-pr="9730">two parameters:</a> <code>-g</code> for specifying a game file location and <code>-u</code> for specifying a user profile.</p> <p>Your writer also showed up, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9737" data-gh-pr="9737">updating</a> the graphical filters and resolution multiplier options that were recently added to the Mainline yuzu.</p> <h2 id="hardware-section">Hardware section</h2> <h3 id="nvidia-driver-53118-its-a-good-one">NVIDIA driver 531.18, it’s a good one</h3> <p>This latest (at the time of writing) release of the NVIDIA driver, 531.18, includes support for <code>VK_EXT_extended_dynamic_state3</code>, a Vulkan extension previous readers will be familiar with. Having this extension supported means fewer shaders need to be built, resulting in a smoother experience thanks to reduced shader stuttering, and lower RAM use.</p> <p>We recommend at least Turing and newer (GTX 1600, RTX 2000-4000) users to update, as we expect this release to not fix the issues affecting Pascal and Maxwell hardware (GTX 1000 and older).</p> <h3 id="amd-ryzen-7000x3d-series-and-the-importance-of-game-mode">AMD Ryzen 7000X3D series, and the importance of Game Mode</h3> <p>AMD recently released their Zen 4 CPUs with 3D V-Cache technology, and in an effort to copy Intel in weirdness, they decided to release a top of the line asymmetric design with the 7950X3D.</p> <p>Only one of this gaming-beast CPU’s two CCDs (modules containing 8 cores each) has access to the expanded L3 V-Cache, and the decision on which one to use is up to Windows Game Bar. To our dismay, there is no hardware scheduler here. The chipset driver and a Windows toggle decide which mode is better.</p> <p>Since yuzu, and basically any other emulator, are not registered as games by Windows, the user will have to manually intervene and enable <code>Game Mode</code> in order to let the chipset driver profile performance and decide which CCD will perform the best.</p> <p>Doing this should also benefit every user, not just 7000X3D ones, as Windows uses the toggle to allocate resources (RAM, threads) to the affected program, so it’s not a bad practice at all!</p> <p>Here are the steps:</p> <p>With yuzu or any other emulator/program of choice open, press <code>Windows + G</code>, and go to the Settings cogwheel.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xbox1.png" title=" Bet you didn’t know about this extra bloat in Windows"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/xbox1_hu8147f8dc57294a8b377305e160267e22_37875_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Bet you didn’t know about this extra bloat in Windows"></a> <p class="has-text-centered is-italic has-text-grey-light"> Bet you didn’t know about this extra bloat in Windows</p> </div> </div> <p>Then enable <code>Remember this is a game</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xbox3.png" title=" And just like that, better performance!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/xbox3_hu986d78b158d988ed24c0c49f95d866d1_33102_935x0_resize_q90_bgffffff_box_3.jpg" alt=" And just like that, better performance!"></a> <p class="has-text-centered is-italic has-text-grey-light"> And just like that, better performance!</p> </div> </div> <p>That’s it!</p> <p>Now Windows will allocate resources in a smarter way, and Ryzen 7000X3D users will get the best performance out of their shiny new CPU. Testing also shows that this helps improve performance with proper P-Core and E-Core allocation on current Intel CPUs too. For older Ryzen users, the latest chipset update that enables the performance profiling for the 3D Zen4 products reportedly also improves performance slightly.</p> <p>Who can say no to free performance after two clicks, right?</p> <h3 id="intel-please-fix-your-vulkan-support">Intel, please fix your Vulkan support</h3> <p>We’re waiting for Intel to fix their SPIR-V compiler crashes on the Windows drivers. In its current state, any game can crash at any moment if you use Vulkan, and unlike AMD who solved most of their OpenGL issues with a rewrite, Intel doesn’t get a fallback option with the old graphics API, which in its current state renders almost everything in black.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./intel.png" title=" This crash can happen at any moment"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2023/intel_hu88a3df07ba3bc4406b409fcd1baf07bf_53664_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" This crash can happen at any moment"></a> <p class="has-text-centered is-italic has-text-grey-light"> This crash can happen at any moment</p> </div> </div> <p>Frustratingly, this isn’t a problem with the Mesa Linux drivers, or the old Gen9/9.5/11 iGPUs and its discontinued Windows drivers, so it’s a proper critical regression affecting the new driver branch that will have to wait until AAA native PC games are running well enough to give the developers time to focus on the “less important stuff”, like professional programs, and console emulators.</p> <h2 id="future-projects">Future projects</h2> <p>I’ve been kidnapped by our devs, so no leaks this time. I promise more for next month!</p> <p>There is one thing I’m allowed to mention, recent core timing changes have reduced CPU use by 5-20% across the board on Windows depending on the total thread count. This means better performance and reduced power consumption, especially benefiting mobile devices like laptops and handhelds. This change is already in both <a href="https://yuzu-mirror.github.io/downloads/">Mainline</a> and <a href="https://yuzu-mirror.github.io/help/early-access/">Early Access</a>, but we’ll talk more about it and other nice things next month.</p> <p>That’s all folks!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report January 2023 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/ Sat, 11 Feb 2023 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/ <p>New year, more work to do! 2023 started with a plethora of graphical changes, audio and input improvements, TAS and LAN/LDN fixes, and more! Stay tuned yuz-ers, this is just the start of what&rsquo;s to come this year!</p> <p>New year, more work to do! 2023 started with a plethora of graphical changes, audio and input improvements, TAS and LAN/LDN fixes, and more! Stay tuned yuz-ers, this is just the start of what&rsquo;s to come this year!</p> <h2 id="new-challenger-approaching">New challenger approaching!</h2> <p>During the time it took to merge last month’s <code>Project Y.F.C. 1.5</code>, several other GPU related changes had to be delayed. One change that slipped by, made by a new contributor, improved the Vulkan experience so dramatically, it almost feels like cheating… The change is simple: instead of relying on the GPU driver to store and validate the pipeline cache (a.k.a. the shaders), and having the usual suspects like the Windows AMD driver fail to store 95% of them because of some arbitrary low size limitation, <a href="https://github.com/Wollnashorn">Wollnashorn</a> decided that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9527" data-gh-pr="9527">doing it with the official Vulkan API is better.</a> </p> <p>By storing the entire pipeline cache in a custom file among yuzu’s folders, AMD GPUs running on Windows can now properly load large caches in mere seconds, as it should be. This has saved me literal hours of time while playing <code>Xenoblade Chronicles 3</code> with an RX 6600, as the game has the <em>lovely perk</em> of many heavy shaders. Booting the game with 25000 shaders used to take close to 15 minutes, with the driver only providing the first 3000 shaders or so, and the rest always being recompiled. The process now takes mere <em>seconds</em>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./shaders.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> NVIDIA and Intel are faster at shader building than AMD</p> </div> </div> <p>But this isn’t just another fix for AMD Windows users. While the objective was accomplished, the benefits didn’t stop there. As it turns out, locally stored files are much quicker to save compared to relying on the GPU driver. Possibly due to fewer checks being performed? All GPU vendors see reduced stuttering when facing new shaders!</p> <p>The usual limitations apply: the cache still asks the driver for validation, so updating it to a newer or older version will require a recompilation, and since the cache is vendor-specific, you won’t get to keep the cache if you switch to a new GPU from another vendor. (And we’re glad there are more than two options now.)</p> <p>While Wollnashorn intended this feature to be optional at first, we consider it fully stable, so it’s now enabled by default. Anyone interested in testing disabling it will find the new option in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Use Vulkan pipeline cache</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./turboui.png" title=" Vulkan only, OpenGL is not this flexible with compute work"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/turboui_hu2edc6c9bb7bd4202cdaea9d0c8cbe68f_24944_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Vulkan only, OpenGL is not this flexible with compute work"></a> <p class="has-text-centered is-italic has-text-grey-light"> Vulkan only, OpenGL is not this flexible with compute work</p> </div> </div> <p>Wollnashorn, delivering another amazing entry for the new year, implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9539" data-gh-pr="9539">support for AMD&rsquo;s FidelityFX Super Resolution (FSR) in the OpenGL backend.</a> While AMD only really intended this adapting filter to be used with Vulkan and Direct3D 12, it is actually portable to OpenGL, and provides generally superior results compared to other filters. Thanks!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fsr.png" title=" Fermi users rejoice"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/fsr_hu3d07aa01796e70406d0ee5400d145ac3_32631_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Fermi users rejoice"></a> <p class="has-text-centered is-italic has-text-grey-light"> Fermi users rejoice</p> </div> </div> <h2 id="fire-emblem-unity">Fire Emblem Unity</h2> <p>A new entry in the series, and, some core changes aside, a good one at that! The best part of this release is in the technical aspect. Gone is the clunky and slow Koei Tecmo engine. <code>Fire Emblem Engage</code> uses the much more flexible and optimized Unity engine instead.</p> <p>For us emulation fans, this means 60 FPS is achievable on very low-end hardware, and the game can be reasonably played with the framerate unlocked too. Only some animations and 2D elements experience issues with the higher framerates, something we hope the modding community can solve. We expect to see 120 and even 240 FPS mods working fine on reasonably powerful hardware.</p> <p>Another point, and maybe even more important, is shader stuttering. Koei’s engine is notoriously infamous for having bloated shaders that, without tons of work from our side, can make any GPU driver crash on timeouts. Unity, on the other hand, has much lighter shaders, allowing Vulkan’s parallel building to shine, and asynchronous shader building provides extra help, if your CPU doesn’t have enough threads to hide what little stutter remains.</p> <p>Still, new game release, new issues, and new fixes for them. So let’s list what has been done so far.</p> <p><a href="https://github.com/liamwhite">byte[]</a>, who may or may not have just discovered the Fire Emblem series, noticed an issue with the shader compiler: the only place where multisampled (MSAA) textures were actually being intentionally processed in shaders was in the <code>GLASM</code> shader backend, albeit incorrectly. In the <code>GLSL</code> backend, it was completely ignored, and in the <code>SPIR-V</code> backend, it produced an invalid combination of arguments to a <code>SPIR-V</code> instruction, which caused Mesa to abort when processing our shader. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9652" data-gh-pr="9652">Passing through multisample information</a> fixed the crash, but left more work to do&hellip;</p> <p>&hellip;which <a href="https://github.com/ameerj">epicboy</a>, one of the original authors of the shader compiler, took notice of, and came back with a rapid-fire series of fixes to address. His first fix was to continue what byte[] had started and fully <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9687" data-gh-pr="9687">implement multisampled texture fetches</a> in the <code>GLSL</code> and <code>GLASM</code> backends, cleaning up rendering of the game with those backends.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/oglbug_hu453b1ee5d04294595c79624d9719662f_899582_1024x0_resize_q90_bgffffff_box_3.jpg" alt="From Stealth to Tactical RPG (Fire Emblem Engage)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/oglfix_hu78986c70cafcc27c48dc771c20a7a2f5_2197193_1024x0_resize_q90_bgffffff_box_3.jpg" alt="From Stealth to Tactical RPG (Fire Emblem Engage)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From Stealth to Tactical RPG (Fire Emblem Engage)</p> <p>He then implemented two more changes: <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9694" data-gh-pr="9694">preventing translations of the <code>TXQ instruction</code> from producing another invalid combination of arguments,</a> and then <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9703" data-gh-pr="9703">implementing full support for multisampled images</a> with the <code>TXQ instruction</code>, with only a few minor loose ends to tidy up &ndash; which will require another cache invalidation. We preemptively apologize to all Smash players (even though it hasn&rsquo;t happened yet).</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/feebug_hufc5c20eefa6ced9a79c84224c7d5959a_7626290_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now your favorite characters won&#39;t be half-way in the Shadow Realm (Fire Emblem Engage)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/feefix_hue4bd20ffe95c9d30ba0cefda7004606d_4505202_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now your favorite characters won&#39;t be half-way in the Shadow Realm (Fire Emblem Engage)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Now your favorite characters won&#39;t be half-way in the Shadow Realm (Fire Emblem Engage)</p> <p>This fixed menu rendering in other games, such as <code>Dokapon UP!</code> and <code>Pokémon Mystery Dungeon: Rescue Team DX</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/pmdbug_hu533d8c07b8c73c14c4c3e736a365d891_2209706_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Fight fire with fire (Pokémon Mystery Dungeon: Rescue Team DX)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/pmdfix_hufc55b8aab5c685925157d8f10524aae0_2556166_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Fight fire with fire (Pokémon Mystery Dungeon: Rescue Team DX)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fight fire with fire (Pokémon Mystery Dungeon: Rescue Team DX)</p> <p>As any NVIDIA <code>Pokémon Brilliant Diamond/Shining Pearl</code> player will tell you, Unity engine games are more stable on OpenGL, one of the rare cases where the old API is preferred. We’re working to fix this issue, but for now, if you are experiencing crashes when using Vulkan with an NVIDIA GPU, try using OpenGL instead, and as an alternative, see if disabling Accelerate ASTC texture decoding helps. As always, both options can be found in <code>Emulation &gt; Configure… &gt; Graphics</code>.</p> <h2 id="turbo-modehttpswwwyoutubecomwatchvd3djvw3dsga"><a href="https://www.youtube.com/watch?v=D3djVW3dSGA">Turbo mode</a></h2> <p>If you followed previous progress reports, you may have noticed a certain pattern. Your writer has a stupid idea, and byte[] is the one that ends up listening to my rambling and makes that idea a reality. This routine worked successfully with SMAA for Vulkan, unsuccessfully with increasing the staging buffer size to take advantage of ReBAR, sadly, and this time, it <em>almost worked</em> with <code>Turbo mode</code>, or its official/boring name, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9552" data-gh-pr="9552">Force maximum clocks.</a> </p> <p>You might be able to see where this is going. <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/#vulkan-is-the-future">A year ago,</a> Patreon funding got your writer access to an RX 6500 to help with testing and debugging. That card died a horrible, premature death (and no one misses it), but before kicking the bucket, it allowed us to learn that RDNA and RDNA2 hardware from AMD suffer from serious downclocking issues if you’re not constantly shoving work to the GPU. Thankfully, due to the cryptomining crash, an RX 6600 took its place for no extra cost. In your face, miners.</p> <p>Ehem, back on topic. The card will try to idle as much as possible to save power, so if the workload is not constant, it switches to a lower clock speed, and raising the clocks again takes time. This results in lower performance. While the issue affects all GPU vendors in one way or another, only AMD suffers from up to 70% performance losses, with both Windows <em>and</em> Linux drivers. Yes, even RADV.</p> <p>Since asking the users to apply external workarounds like encoding video in the background to keep VRAM usage high or overclocking the minimum clock speed are not easy to communicate, or can count as voiding your warranty, your writer was going insane trying to find ways to cleanly solve this issue, as it seems AMD isn’t very interested in it.</p> <p>The solution came from an overclocking background again. <a href="https://github.com/ihaque/memtestCL">memtestCL</a> is a tool to test stability of video memory: you set a size, how many iterations to run, and the compute load will compare results, informing you of any errors. Running yuzu and memtestCL at the same time completely fixed the downclocking issues of AMD cards!</p> <p>Some small discussions and prototyping later, and a solution was starting to take shape. Creating and running an OpenCL/CUDA process in parallel was deemed to be too much work, and could be sent to the background by the scheduler, nullifying any gain. Instead, we decided to use Vulkan’s own compute capabilities. A useless dummy load will constantly run on the GPU, forcing it to always keep its clocks as high as possible, and with it, the power consumption.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./turboperf.png" title=" Four of the most GPU intensive games. Lower end cards like the infamous RX 6500 XT can see jumps as high as 70%"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/turboperf_hu8b0c4153ed292fec9fca4b60cf4c632b_20789_720x0_resize_q90_bgffffff_box_3.jpg" alt=" Four of the most GPU intensive games. Lower end cards like the infamous RX 6500 XT can see jumps as high as 70%"></a> <p class="has-text-centered is-italic has-text-grey-light"> Four of the most GPU intensive games. Lower end cards like the infamous RX 6500 XT can see jumps as high as 70%</p> </div> </div> <p>While this is a simple solution, it has a few drawbacks that forced us to sadly not enable this option by default:</p> <p>First, not all users want to or can run their GPUs at maximum performance. On mobile devices, it results in terrible battery life, or hitting power limits on AMD and Intel APUs, like the Steam Deck for example, with its small 15W default TDP.</p> <p>Second, low constant loads like an old game running at very high framerates, or an emulator performing dummy cycles, produce a noise known as coil whine, an electrical “purring” that varies in intensity with each GPU. Some are barely audible, others can scare their users, even if the card is under no harm.</p> <p>And third, while this is a safe option for AMD dedicated GPUs, on NVIDIA and Intel, the results are much more variable. Weaker NVIDIA cards (anything weaker than an RTX 3060) will most likely lose considerable performance with Turbo mode, while the powerful, expensive cards will see performance gains similar to AMD. The RTX 4090 in particular performs better with Turbo than even NVIDIA’s own “Prefer maximum performance” setting in their control panel.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./nvidia1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/nvidia1_hu0bc3911e6a1094c00d23383f8bba4bd2_2480363_800x0_resize_q90_bgffffff_box_3.jpg" alt="Left is default performance with an RTX 4090, middle is using the driver&#39;s &#39;Prefer maximum performance&#39;, right is yuzu&#39;s Turbo mode (Pokémon Scarlet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nvidia2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/nvidia2_hu8492deb82de8720af0fa15ad1ad75163_2156616_800x0_resize_q90_bgffffff_box_3.jpg" alt="Left is default performance with an RTX 4090, middle is using the driver&#39;s &#39;Prefer maximum performance&#39;, right is yuzu&#39;s Turbo mode (Pokémon Scarlet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nvidia3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/nvidia3_hub42a0e2d489aade2a00c5a7777072243_2486406_800x0_resize_q90_bgffffff_box_3.jpg" alt="Left is default performance with an RTX 4090, middle is using the driver&#39;s &#39;Prefer maximum performance&#39;, right is yuzu&#39;s Turbo mode (Pokémon Scarlet)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Left is default performance with an RTX 4090, middle is using the driver&#39;s &#39;Prefer maximum performance&#39;, right is yuzu&#39;s Turbo mode (Pokémon Scarlet)</p> <p>Intel is, as always, a special case. While Turbo mode certainly helps desktop Arc GPUs, integrated Xe graphics and older can only run a single queue. This means that, by design, these iGPUs can’t render and run compute tasks at the same time. While the scheduler seems to do a fantastic job, not causing any performance loss with Turbo, you still get all the drawbacks and no benefit while using Intel iGPUs.</p> <p>We have worked to resolve as many limitations as we could, but since the results are so variable between different vendors and cards, the option will remain disabled by default. We strongly recommend that everyone tests it. If it produces a performance gain in a game, it should be consistent across the board. At least all desktop AMD users, Big Chungus NVIDIA owners, and the 5 people with an Arc will benefit greatly from it. The option can be found in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Force maximum clocks</code>. …I still prefer calling it Turbo mode…</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./turboui.png" title=" Let&#39;s reuse the same pic, no one will notice it"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/turboui_hu2edc6c9bb7bd4202cdaea9d0c8cbe68f_24944_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Let&#39;s reuse the same pic, no one will notice it"></a> <p class="has-text-centered is-italic has-text-grey-light"> Let&#39;s reuse the same pic, no one will notice it</p> </div> </div> <h2 id="yet-more-gpu-changes">Yet more GPU changes</h2> <p>Starting off the new year with a bang, <a href="https://github.com/bylaws">bylaws</a> of <a href="https://github.com/skyline-emu/skyline">Skyline</a> fame returned with another round of fixes for our shader compiler project. <code>Geometry shader passthrough</code> is an NVIDIA hardware feature available on the Switch which is primarily used to select a viewport or layer without needing an actual geometry shader, and it is available to and used by yuzu with desktop NVIDIA cards. However, AMD, Intel, and other vendors don&rsquo;t support this extension, and require emulation using geometry shaders. bylaws <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9535" data-gh-pr="9535">added support for geometry shader passthrough emulation,</a> which fixed rendering issues in <code>NieR:Automata The End of YoRHa Edition</code>, <code>Marvel Ultimate Alliance 3: The Black Order</code>, <code>Pokémon: Legends Arceus</code>, and likely many other games.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/nabug_hu32c08b339fed1302669ed3070316c121_112270_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Robot shoot is pretty funny (NieR:Automata The End of YoRHa Edition)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/nafix_huf218b531e0dccaf97db6d7e80ea384a6_2312099_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Robot shoot is pretty funny (NieR:Automata The End of YoRHa Edition)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Robot shoot is pretty funny (NieR:Automata The End of YoRHa Edition)</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9556" data-gh-pr="9556">implemented the <code>draw texture method</code>,</a> another NVIDIA-exclusive feature, with both native and emulated versions. It’s like the Switch used some sort of NVIDIA GPU, hmm.</p> <p>Generally, graphics APIs like OpenGL and Vulkan require shaders and some geometry (at minimum, a triangle) defined to render a texture to the framebuffer, but the <code>draw texture method</code> bypasses this requirement and draws an axis-aligned texture to the screen with only the coordinates of the bounding rectangle. When using OpenGL on NVIDIA hardware, yuzu will try to use the host&rsquo;s draw texture function, and it will be emulated with shaders on Vulkan or other platforms. This fixes the rendering of the title screen on <code>Titan Quest</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/tqbug_hu4bd9a46e3fd58685b1bac6d4e2225543_1115010_1024x0_resize_q90_bgffffff_box_3.jpg" alt="And people ask why we &#39;make&#39; games run faster on NVIDIA hardware (Titan Quest)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/tqfix_hu3991b94497dc9404c40291579087a4f5_2983557_1024x0_resize_q90_bgffffff_box_3.jpg" alt="And people ask why we &#39;make&#39; games run faster on NVIDIA hardware (Titan Quest)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">And people ask why we &#39;make&#39; games run faster on NVIDIA hardware (Titan Quest)</p> <p>byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9608" data-gh-pr="9608">corrected a mistake in the way yuzu treated swap intervals.</a> One method for limiting framerate on the Switch is to set a number controlling how many times a frame will be presented, where presentation happens 60 times per second. A program could limit itself to 30 frames per second by setting this number to 2, 20 frames per second by setting this value to 3, and so on. yuzu mistakenly treated the swap interval as being based on powers of two, so the values of 1 and 2, corresponding to 60 and 30 frames per second, worked correctly, but a value of 3 incorrectly presented at 15 frames per second. While fixing this mistake, byte[] also added support for mod developers to use negative values as <em>multiples</em> of 60 frames per second. Let the (high-framerate) games begin!</p> <p>epicboy also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9708" data-gh-pr="9708">fixed a longstanding issue with asynchronous shader building on OpenGL,</a> forcing shaders to be fully flushed and available to the main rendering context before signalling availability. This should alleviate any persistent graphical errors exclusive to asynchronous shaders in the old API.</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> returns with another <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9559" data-gh-pr="9559">significant performance improvement</a> for the world&rsquo;s seemingly-least optimized Pokémon games. This allows them to render in our much faster, but lower-accuracy, GPU Normal mode, and implements a few related optimizations along the way. Have fun shiny hunting!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./psn.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/psn_hu13d63d1dee794d74a8c111377255bb95_7365260_800x0_resize_q90_bgffffff_box_3.jpg" alt="If you ask why all pics are in the same area, it&#39;s one of the best benchmarking spots. Normal accuracy on the left, High accuracy on the right (Pokémon Scarlet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./psh.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/psh_hud1323468cb7452db34fb670f0a0d3ff1_5484768_800x0_resize_q90_bgffffff_box_3.jpg" alt="If you ask why all pics are in the same area, it&#39;s one of the best benchmarking spots. Normal accuracy on the left, High accuracy on the right (Pokémon Scarlet)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">If you ask why all pics are in the same area, it&#39;s one of the best benchmarking spots. Normal accuracy on the left, High accuracy on the right (Pokémon Scarlet)</p> <p>Keep in mind that Normal GPU accuracy will produce vertex explosions for a frame, but only last just as long. Permanent vertex explosions be gone! High GPU accuracy will be cleaner, but slower, so pick your side.</p> <p>As one final note for the GPU section, your writer implemented a feature which had been requested for quite a while since the resolution scaler was released, but nobody had really bothered to look at until now &ndash; <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9612" data-gh-pr="9612">additional resolution options.</a> </p> <p>Now you can select from the additional options of 1.5x scaling, or 7x and 8x (if you have a death wish for your graphics card). User reports confirm that the RTX 4090 can play some games at 8x, and the RX 6950 XT doesn&rsquo;t have many problems with 7x. The odd one, 1.5x, was added because our metrics show that the most used non-iGPU cards are strong enough to have surplus performance at 1x, but are not powerful enough to handle 2x. A middle ground is ideal to get crisper graphics while keeping the 30/60FPS target, or if the user has a 1440p display. We think this should be reasonably future proof for now.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./16k.jpg" title=" Warning, don&#39;t click this image on weak devices: 16K resolution (SUPER MARIO ODYSSEY)"><img src="./16k.jpg" alt=" Warning, don&#39;t click this image on weak devices: 16K resolution (SUPER MARIO ODYSSEY)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Warning, don&#39;t click this image on weak devices: 16K resolution (SUPER MARIO ODYSSEY)</p> </div> </div> <p>Small warning, AMD and Intel hardware don&rsquo;t support textures as big as NVIDIA, so it&rsquo;s possible to hit this limit in some games and make the driver crash. If you have performance and VRAM to spare and you hit a crash, lower the multiplier.</p> <h2 id="macos-progress">macOS progress</h2> <p>Since we have been providing little snippets of a possible return for macOS support for the past few months, know that the progress is slow for now, but we have some significant results to report.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mvk.png" title=" Baby Mario steps (SUPER MARIO ODYSSEY)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/mvk_hu04c922e8e1ac176c55a993e297ad0ad4_1627953_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Baby Mario steps (SUPER MARIO ODYSSEY)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Baby Mario steps (SUPER MARIO ODYSSEY)</p> </div> </div> <p>byte[] implemented a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9528" data-gh-pr="9528">fallback for the absence of <code>nullDescriptor</code> support</a> in MoltenVK, avoiding a crash when attempting to bind buffer slots on MoltenVK.</p> <p>Then, he implemented a <em>substantial</em> refactor of how <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9530" data-gh-pr="9530">yuzu performs Vulkan feature testing,</a> making it both more streamlined and able to cope with the absence of features which yuzu currently still requires as mandatory &ndash; such as the aforementioned <code>nullDescriptor</code> feature.</p> <p>Finally, <a href="https://github.com/PCSX2/pcsx2">PCSX2</a> and <a href="https://github.com/dolphin-emu/dolphin">Dolphin</a> contributor <a href="https://github.com/TellowKrinkle">TellowKrinkle</a> helped us <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9596" data-gh-pr="9596">discover a bug in MoltenVK</a> where the number of bindings it reports as available doesn&rsquo;t correspond to the number we can actually use, and suggested a workaround, which byte[] committed, allowing trivial homebrew examples to finally begin rendering correctly. We are also able to render some simpler games, but be aware: most things don&rsquo;t work yet. Baby steps!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/mvkbug_hu46695e858d2b3c097cd4ba85a4a19e8d_611817_1024x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s hard to describe, has the performance, but lacks the features, but has modern features"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/mvkfix_hu46695e858d2b3c097cd4ba85a4a19e8d_505465_1024x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s hard to describe, has the performance, but lacks the features, but has modern features"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It&#39;s hard to describe, has the performance, but lacks the features, but has modern features</p> <h2 id="general-changes">General changes</h2> <p>byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9561" data-gh-pr="9561">triggered the scheduled mandatory Dynarmic update,</a> blessing us with <a href="https://yuzu-mirror.github.io/entry/yuzu-fastmem/">fastmem and page table support</a> for ARM64 devices, boosting performance considerably. Anyone with an ARM64 device running a “normal” GPU (not mobile-tier hardware) interested in testing yuzu, feel free to install our official <a href="https://flathub.org/apps/details/org.yuzu_emu.yuzu">Flatpak</a>.</p> <p><a href="https://github.com/german77">german77</a> stumbled upon an issue which was causing input threads to randomly crash yuzu for seemingly no reason, but only on shutdown. byte[] found that <code>CoreTiming</code> had the same logic issue that he fixed last month in the kernel code when adding <code>KHardwareTimer</code>: callbacks could be removed while in-progress, which could cause the input threads to continue using memory after it had been freed. With this code changed to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9619" data-gh-pr="9619">wait until any in-progress callbacks are finished before removal,</a> this issue should be solved for good.</p> <p>After the merge of german77&rsquo;s impressive Joy-Con driver release <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/#new-joy-con-driver-and-other-input-improvements">last month</a>, <a href="https://github.com/Morph1984">Morph</a> noticed that yuzu was often taking a significantly longer amount of time to shutdown, sometimes more than 5 seconds longer than it should have been allowed to. He discovered that this was due to sleep calls in the Joy-Con driver to poll for new devices that weren&rsquo;t being cancelled on shutdown, and with help from byte[], he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9677" data-gh-pr="9677">implemented a proper fix</a> so that they would immediately stop waiting when shutdown was signalled.</p> <p>More battles won for the Shutdown Wars, with seemingly no end in sight! It&rsquo;s starting to almost feel like a <a href="https://www.youtube.com/watch?v=HWJsY4FoSZ8">Worms</a> game.</p> <p>An interesting report from a user pointed byte[] to the visual novel <code>うみねこのなく頃に咲 ~猫箱と夢想の交響曲~</code> (Umineko no Naku Koro ni Saku - Nekobako to Musou no Koukyoukyoku), which seemed to reliably crash in fast-forward mode, but only when audio was enabled. He quickly identified that the issue was happening at the same time the audio system was temporarily stalling the game (in order to avoid dropping any samples). He had previously implemented stalling in the kernel in a way that seemed superficially reasonable, but actually completely broke the scheduler when just the right conditions were met! byte[] then <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9666" data-gh-pr="9666">reimplemented stalling more carefully,</a> avoiding breaking the conditions required by the scheduler, and preventing a deadlock due to incorrect behaviour around suspension.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./umi.png" title=" Without love, it cannot be seen (Umineko no Naku Koro ni Saku - Nekobako to Musou no Koukyoukyoku)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/umi_hu3d9bfe082e8985b3d6fa376823baecde_2011577_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Without love, it cannot be seen (Umineko no Naku Koro ni Saku - Nekobako to Musou no Koukyoukyoku)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Without love, it cannot be seen (Umineko no Naku Koro ni Saku - Nekobako to Musou no Koukyoukyoku)</p> </div> </div> <p>Users reported a regression when trying to play <code>Mario Kart 8 Deluxe</code> over LAN mode. The game would refuse to access the mode and return to the main menu. german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9543" data-gh-pr="9543">updated the implementation to match the latest reverse engineering efforts</a> and poof, back to launching blue shells at all your friends!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lan.png" title=" Hot take, only Gran Turismo gets close to this series in music quality (Mario Kart 8 Deluxe)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/lan_huf79319bbd8edffe7d326c8da4acde207_3698176_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Hot take, only Gran Turismo gets close to this series in music quality (Mario Kart 8 Deluxe)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hot take, only Gran Turismo gets close to this series in music quality (Mario Kart 8 Deluxe)</p> </div> </div> <p><a href="https://github.com/MonsterDruide1">MonsterDruide1</a> is back with <em>the good fixes</em>. This time? LDN. Game mods that add network connectivity sometimes use sockets with a timeout in order to keep the game responsive while waiting for more packets. yuzu used to hate this behaviour, spamming errors in the log, and generally just having a bad time. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9558" data-gh-pr="9558">Changing this unnecessarily cautious behaviour</a> allows network gameplay mods to work properly, for example, <a href="https://github.com/fruityloops1/smo-practice">smo-practice</a>.</p> <p><a href="https://github.com/SoRadGaming">SoRadGaming</a> suddenly showed up one day and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9661" data-gh-pr="9661">implemented IPv6 and hostname support</a> for LDN. Thanks! Now more players can enjoy their online matches, and we’re ready for the eventual death of IPv4, which is expected to happen someday in this geological era. Or maybe the next one.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dc.png" title=" Remember when domain names were free?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/dc_hu54980d73885eedb0cc5315bcd8a5baa3_6954_457x0_resize_q90_bgffffff_box_3.jpg" alt=" Remember when domain names were free?"></a> <p class="has-text-centered is-italic has-text-grey-light"> Remember when domain names were free?</p> </div> </div> <p><a href="https://github.com/merryhime">Merry</a>, taking a break from Dynarmic to play with some areas of yuzu, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9615" data-gh-pr="9615">implemented a set of fixes</a> to the audio codebase, focusing on upsampling. An off-by-one error fix should translate to in-game music not cutting off as much, and improved audio fidelity.</p> <h2 id="input-and-tas-improvements">Input and TAS improvements</h2> <p>TAS got its fair share of improvements, all thanks to MonsterDruide1 and german77. The first fix is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9540" data-gh-pr="9540">properly recording sanitized inputs,</a> instead of the raw inputs from the player. By sanitized, we mean input adjusted by range and dead zone settings. There isn&rsquo;t much use for a TAS script if what you record doesn’t correspond to what the game received originally.</p> <p>Next, yuzu, by design, can support multiple controllers per player, which can lead to multiple stick inputs overlapping (“flapping”) each other. yuzu would ignore switching to any stick input that didn’t reach full tilt. To avoid this behaviour causing problems with TAS, MonsterDruide1 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9547" data-gh-pr="9547">overrules this safety threshold value</a> for TAS-based stick input, so every movement gets registered, even the most minuscule ones right from the start. This change also adds the extra logic of returning to regular input if the TAS stick reaches a value of 0 in both axes.</p> <p>And to end the TAS changes, MonsterDruide1 also now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9565" data-gh-pr="9565">shows the progress of multiple scripts</a> when several controllers are running their own records, for example, <code>TAS state: Running 35/100, 20, 0, 40</code>. Now all players in local multiplayer matches can get their corresponding information.</p> <p>On the topic of regular input, german77 has been busy improving it, and he has implemented a couple of changes that we think many will like.</p> <p>For our keyboard and mouse fans, there’s now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9605" data-gh-pr="9605">support for mapping the mouse wheel</a> to any button. Sounds like a simple way to switch gear in <code>The Legend of Zelda: Breath of the Wild</code> to me, for example.</p> <p>german77 has been gluing his eyes to some unit tests lately trying to find out why <code>EARTH DEFENSE FORCE: WORLD BROTHERS</code> would outright ignore input in some cases. After several back and forths between yuzu and the real Switch, he found out that the stick range didn’t seem to have minimum value of -32768, the usual value expected from a 16-bit signed integer (a range of -32768 to 32767), and instead seemed to have a minimum of -32766.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./input.png" title=" Unpatched Switch consoles are invaluable for us"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/input_hucbe6861752989f16f771b240687f644f_414538_800x0_resize_q90_bgffffff_box_3.jpg" alt=" Unpatched Switch consoles are invaluable for us"></a> <p class="has-text-centered is-italic has-text-grey-light"> Unpatched Switch consoles are invaluable for us</p> </div> </div> <p>Okay, <a href="https://www.youtube.com/watch?v=VreFw1Zd020">Nintendo is as Nintendo does</a>, have it your way, we will just <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9617" data-gh-pr="9617">fix the minimum stick range</a> in our code. Problem solved, right?</p> <p>No.</p> <p>As it turns out, this is a game bug. You can get the Switch to reach -32767 under certain conditions, and <code>EARTH DEFENSE FORCE: WORLD BROTHERS</code> will <em>also</em> refuse to accept input on the real hardware. So what do we do then? german77 decided that the best solution is to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9676" data-gh-pr="9676">apply a 0.99996x multiplier</a> to the received input from the sticks, just to avoid weird games from behaving incorrectly.</p> <p>People have been complaining about poor Joy-Con reception since, well, ever, and honestly, there’s a limit to how much we can do, only Nintendo knows what Bluetooth black magic they use to get good range on the Switch. Thankfully, the new custom Joy-Con driver allows us to have more freedom on the parameters of the Bluetooth connection, and german77 discovered that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9683" data-gh-pr="9683">disabling low power mode,</a> one of the available parameters, after establishing a connection is closer to what the console does, and should help improve range to some extent.</p> <p>Our general recommendations still apply: if you’re using an Intel WiFI + BT combo chipset, turn off WiFi, and make sure to have your phone away from the BT chipset and the Joy-Cons. It’s known that off-brand generic USB dongles provide better range than WiFi + BT combo chips.</p> <p>Now for players interested in bending the game engines to their limit, or just wanting to have some extra fun (us boomers like to call this “cheating”), german77 has a gift for you. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9696" data-gh-pr="9696">Turbo button support!</a> Also known as rapidfire, this allows you to, as the name implies, repeatedly auto-press a button as fast as the game can register it.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./turbo.png" title=" For some reason, Mega Man comes to mind"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/turbo_hua42d56a9fc651d8156ee2ac6d879d7ad_75099_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" For some reason, Mega Man comes to mind"></a> <p class="has-text-centered is-italic has-text-grey-light"> For some reason, Mega Man comes to mind</p> </div> </div> <p>Enjoy finding new ways to break your games with this!</p> <h2 id="ui-changes">UI changes</h2> <p>This one has been cooking for over 2 years now, sheesh. Morph originally started working on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/4949" data-gh-pr="4949">improving high-DPI support</a> in yuzu all the way back in November of 2020. Now it’s ready, and the results are great. Users that run displays at DPI values over 100% can now see proper UI element scaling, particularly noticeable in the Controls setting window.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/dpibug_hu86207e2f48e2c076f5082e44e408393e_114891_1024x0_resize_q90_bgffffff_box_3.jpg" alt="4K display users rejoice"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/dpifix_hue0afda8b9e9934f2f7e44c1bfbef6a68_208399_1024x0_resize_q90_bgffffff_box_3.jpg" alt="4K display users rejoice"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">4K display users rejoice</p> <p>Nothing is safe from bugs in the user interface code, and Wollnashorn found an interesting one affecting LDN. The Direct Connect window asks the user for an IP and nickname.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dc.png" title=" We believe in recycling here, that includes pics"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/dc_hu54980d73885eedb0cc5315bcd8a5baa3_6954_457x0_resize_q90_bgffffff_box_3.jpg" alt=" We believe in recycling here, that includes pics"></a> <p class="has-text-centered is-italic has-text-grey-light"> We believe in recycling here, that includes pics</p> </div> </div> <p>Those settings got lost every time a game was booted. Well, the issue was that those settings were being saved on the per-game configuration files for no reason. It doesn&rsquo;t make sense to include a fundamentally global setting in the per-game settings, so <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9521" data-gh-pr="9521">removing them</a> solved the issue.</p> <p>byte[] solved an issue where accessing fullscreen would cause yuzu to crash. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9601" data-gh-pr="9601">Adjusting the behaviour of yuzu’s bootmanager</a> was enough to stop the <a href="https://github.com/yuzu-emu/yuzu/issues/9550">CRASH!!</a></p> <p>Newcomer <a href="https://github.com/SaiKai">SaiKai</a> implements one of those Quality of Life changes that you can’t live without and you can’t believe it wasn’t a thing before. Pressing and holding the hotkey assigned to lowering or raising <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9637" data-gh-pr="9637">volume will now auto-repeat,</a> making it much easier to control. Thanks!</p> <p>Per-game configuration returns to mess with us, now with the language selection. The language ComboBox index gets altered in per-game configuration, so setting the region to Korea or Taiwan would result in a crash. german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9660" data-gh-pr="9660">fixes this discrepancy</a> and solves the issue.</p> <h2 id="hardware-section">Hardware section</h2> <p>Let’s revive this section for a bit, there’s some information I’d like to discuss.</p> <h4 id="nvidia-forgetting-about-their-old-cards">NVIDIA, forgetting about their old cards.</h4> <p>We previously mentioned that the 527.XX release of drivers solved issues we previously had with Pascal and newer cards. While this was true for most issues, Pascal is still hitting some of the old problems, like crashes with ASTC texture decoding enabled. We recommend Pascal users to either disable ASTC texture decoding, or revert back to 512.95 drivers. We hope NVIDIA backports the fixes Turing and newer cards got to the old guard too.</p> <h4 id="amd-custom-drivers-are-not-good">AMD, custom drivers are not good</h4> <p>The recently released RX 7000 series, or RDNA3, are not particularly compatible with emulators right now, with yuzu not being an exception. Broken rendering and crashes were reported by early adopters.</p> <p>Sadly, we can’t focus on these products while they run a custom driver branch. Until AMD merges the RDNA3 driver with the regular Polaris to RDNA2 one we’re all used to, it’s impossible to focus efforts on trying to solve any particular issues of this new release. Sorry early adopters, you will have to wait.</p> <p>Having access to hardware that doesn’t cost NVIDIA-stupid levels would also help. AMD, please don’t take a year to release the mid and low end.</p> <p>Now, regarding unofficial custom drivers, we received reports that Amermine Zone drivers break rendering in many games. Regular drivers are perfectly fine, so just stick to official AMD releases.</p> <h4 id="intel-artificial-limitations-capping-good-hardware">Intel, artificial limitations capping good hardware</h4> <p>Your writer recently had to replace an old i3-5005U laptop because its WiFi died, but HP only allows a very limited selection of cards as replacements, and said parts are no longer in production. I’m never buying HP ever again.</p> <p>Sorry, back on topic. This was a great opportunity to get an Iris Xe GPU, so an i5-1240P was acquired. ASUS this time. As this was first hand experience for a tester with a Gen 12 Intel GPU, we now have both good and bad information to discuss.</p> <p>Let’s start with the bad, and this is something that affects many users, as it is the default configuration of most laptops.</p> <p>Intel, in their <em>infinite wisdom</em>, decided that single channel memory configurations should <a href="https://www.intel.com/content/www/us/en/support/articles/000059744/graphics.html">artificially limit the integrated GPU to the slower UHD Graphics spec</a>, reducing its EU (execution unit) count. Basically, running the GPU with half its cylinders.</p> <p>Unless the user pays the premium for a dual channel configuration, or has the option to manually add the extra SO-DIMM stick later, performance on Intel Xe devices, or “UHD Graphics”, is <em>terrible</em>. Most 3D games can’t run at playable framerates even at 0.5x handheld scaling.</p> <p>To top it out, it’s very clear that Vulkan drivers are still a weak spot with Intel hardware. It’s a lottery with each game. They may perform correctly, similar to their AMD and NVIDIA counterparts, or may have glaring issues. Some shaders, for example, outright crash the driver. We will report these issues to Intel as we find them.</p> <p>Sadly, the usual solution of just running Linux is not a fix this time. Mesa support for Gen 12 Intel graphics hardware (Xe, Arc, etc) is still in very early stages, and the performance is usually in the sub-10 FPS territory. We can’t wait to see Mesa once again show the Windows driver team how their job is done. Windows users, make sure to periodically update your drivers, as each release introduces major changes, so it’s critical to keep up. Intel is finally caring about their GPU division with the release of Arc. And finally, as a side note, Xe graphics are sensitive to the use of FSR. They lose a considerable amount of performance, so we strongly recommend using Scaleforce instead.</p> <p>Now the good parts. Getting a proper dual channel configuration not only doubles the available bandwidth, which is the most critical point of iGPU performance, but also raises the EU count to the proper Iris Xe spec you originally paid for.</p> <p>Benchmarking shows that under these conditions, Xe graphics manage to surpass Vega iGPUs in yuzu, as long as the Intel Vulkan drivers cooperate. It also shows that Xe graphics are more tolerant to SMAA than, for example, NVIDIA Pascal GPUs, being an almost free setting, performance wise. This, coupled with the better IPC of Intel CPUs, should provide an edge on budget laptops. At least, until AMD remembers that not everyone wants to pay a fortune for an RDNA2 integrated GPU and releases a refreshed low end lineup. I got tired of waiting.</p> <p>As an extra juicy bonus, unlike Arc, the Intel iGPUs still have their amazing native ASTC texture decoder. This means no delays in ASTC heavy games like <code>Luigi’s Mansion 3</code>, <code>Bayonetta 3</code>, or <code>Astral Chain</code>. The almighty RTX 4090 can’t do that.</p> <p>A small note regarding the ASTC support of Intel iGPUs. Not all texture formats used by Switch games are supported by Intel, some will still need to be specially decoded. Since these GPUs only have a single queue, Xe users should disable ASTC texture decoding from yuzu’s graphics settings. Most of the time the Xe GPU will be the bottleneck, and making it constantly switch between decoding textures and rendering the game will incur a performance loss. Letting the CPU carry this work will help graphical performance. Finally some good use for those E-Cores.</p> <p>For those that don’t fear noise or heat, tweaking the sliders in <a href="https://www.intel.com/content/www/us/en/download/17881/29183/intel-extreme-tuning-utility-intel-xtu.html?">XTU</a> is an easy way to get an extra GHz out of their CPUs while plugged in. This can help double the performance in yuzu.</p> <p>Unfortunately, Intel’s EoL status regarding Windows drivers is starting to affect compatibility with recent games, so we officially consider Gen 9/9.5/11 Intel GPUs to be out of support on yuzu. This covers Gen 6 to 11 CPUs, Skylake to Ice Lake. We will provide support and log issues for them only if they run on Linux. Or, well, macOS, once MoltenVK is fully working.</p> <h2 id="future-projects">Future projects</h2> <p>I’m still under a sort of “NDA” with the developers, so I’m not allowed to tell you what’s cooking yet, or else.</p> <p>Our spies still managed to pass along a bit of information before going dark, <code>Project Lime</code>, a co-development between bunnei, Tobi, german77, and byte[]. Stay tuned for its official announcement.</p> <p><code>Project Gaia</code> continues to progress slowly, growing closer to the internal beta testing phase. Some of its standalone features have already been tested:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gaia.png" title=" This was a performance test to see how long it takes to load a game list"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2023/gaia_hu817b4f32132f260f39f23d16e4c9ec47_109187_902x0_resize_q90_bgffffff_box_3.jpg" alt=" This was a performance test to see how long it takes to load a game list"></a> <p class="has-text-centered is-italic has-text-grey-light"> This was a performance test to see how long it takes to load a game list</p> </div> </div> <p>A bit of sad news for outdated hardware users: we have discussed plans to discontinue OpenGL. Fixes and improvements that are critical for Vulkan are becoming a chore to port to OpenGL, and, as you’ve seen with the progress on MoltenVK support, we have to worry about new devices that depend exclusively on Vulkan. It won’t be very soon, but it’s time to consider getting a GPU with Vulkan support, you know, something made within the last 11 years.</p> <p>That’s all folks!</p> <p>Thank you for reading to the end. And very special thanks to Mysterious Writer B, without their help, this article would have been seriously delayed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./byte.jpg" title=" Out of the night, when the full moon is bright, comes a horseman known as B…"><img src="./byte.jpg" alt=" Out of the night, when the full moon is bright, comes a horseman known as B…"></a> <p class="has-text-centered is-italic has-text-grey-light"> Out of the night, when the full moon is bright, comes a horseman known as B…</p> </div> </div> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report December 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/ Tue, 10 Jan 2023 12:00:00 -0300 Honghoa https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/ <p>Hello yuz-ers. What a year! We ended 2022 with more yuzu Fried Chicken, Vulkan changes, a new input driver, an exorbitant amount of kernel work, more performance, better visuals, and much more!</p> <p>Hello yuz-ers. What a year! We ended 2022 with more yuzu Fried Chicken, Vulkan changes, a new input driver, an exorbitant amount of kernel work, more performance, better visuals, and much more!</p> <h2 id="project-yfc-part-15-and-a-cache-invalidation">Project Y.F.C. part… 1.5, and a cache invalidation</h2> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> has also been working hard on his beloved project, releasing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9501" data-gh-pr="9501">Y.F.C. Part 1.5.</a> Basically an abridged version of what is expected for the full “Part 2” release. The changes in this pull request include a rework of the <code>MacroHLE</code> implementation to include various new macros for indirect draws and configurations.</p> <p>As discussed in previous articles, macros are small GPU programs that implement features like indirect and instanced draws. They must be emulated. MacroHLE (High-Level Emulation) is the process of avoiding executing a requested macro and instead translating it directly to the code that it would have generated (like an instanced or indirect draw). This works in contrast and in parallel with MacroJIT, which works by actually emulating the loops and control flow contained in macro programs in a <a href="https://en.wikipedia.org/wiki/Just-in-time_compilation">just-in-time</a> fashion.</p> <p>Now, why keep both? Well, each one performs their own specialized task. MacroHLE&rsquo;s advantage compared to MacroJIT has to do with the emulation of indirect calls. An indirect call, such as a draw, uses data generated somewhere in the GPU through some shader in order to establish the draw parameters and its draw count. Traditionally with MacroJIT we had to sync the Host GPU and Guest GPU to obtain the indirect data in order to execute the macro correctly. With MacroHLE, we create an indirect draw command in the host GPU that points to the translated address of where the GPU generated data should be. Thus skipping the syncing.</p> <p>Thanks to these improvements, yuzu now is able to more efficiently execute macros, considerably reducing CPU overhead, and without having to change any setting. What we internally like to call a “passive skill”.</p> <p>As a result of these changes, performance has been improved in several titles, including those developed by Koei Tecmo, <code>Pokémon Scarlet and Violet</code>, <code>Bayonetta 3</code>, and <code>Monster Hunter Rise</code> (with the exception of version 12.0.0, which still requires further fixes) to name a few. The crashes in <code>Fire Emblem: Warriors</code> have also been fixed. We measured a 5-20% performance boost in select titles, but the improvement may be higher on CPUs with a lot of cache. From our testing, the 5800X3D can reach over 30% in some games. The performance cost of rendering at higher resolutions was also greatly reduced.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./yfc.png" title=" R5 5600X - 2x16GB 3933MHz CL18 - RX 6600"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/yfc_hu407360582f839a91299aa44ce61b9086_19647_736x0_resize_q90_bgffffff_box_3.jpg" alt=" R5 5600X - 2x16GB 3933MHz CL18 - RX 6600"></a> <p class="has-text-centered is-italic has-text-grey-light"> R5 5600X - 2x16GB 3933MHz CL18 - RX 6600</p> </div> </div> <p>But the goodies don’t end here! Blinkhawk also added support for the <code>VK_EXT_extended_dynamic_state2</code> and <code>VK_EXT_extended_dynamic_state3</code> Vulkan extensions, reducing the amount and size of shaders needed to be built during gameplay.</p> <p>This relatively “new” pair, along with the already implemented <code>VK_EXT_extended_dynamic_state</code> and <code>VK_EXT_vertex_input_dynamic_state</code>, are the four extensions responsible for considerably reducing shader building stuttering. But as it always goes, support for these extensions in consumer GPUs is spotty at best, and a mess to support at worst. <code>State3</code> in particular is only supported by the <a href="https://developer.nvidia.com/vulkan-driver">NVIDIA Vulkan Beta</a> drivers, version 527.86 at the time of writing, and recent (late 2021 and newer) RADV Mesa drivers. We recommend anyone interested in testing how a fresh shader cache performs to give these drivers a go.</p> <p>With no alternative, implementing these extensions forced us to perform another dreaded cache invalidation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dynamic.png" title=" Proof that the best GPUs for yuzu continue to be NVIDIA for either OS, or AMD on Linux"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/dynamic_huac5e87ab1daa4478db6473d6600ae77d_8010_663x0_resize_q90_bgffffff_box_3.jpg" alt=" Proof that the best GPUs for yuzu continue to be NVIDIA for either OS, or AMD on Linux"></a> <p class="has-text-centered is-italic has-text-grey-light"> Proof that the best GPUs for yuzu continue to be NVIDIA for either OS, or AMD on Linux</p> </div> </div> <p>Most drivers cover at least 3 of the 4 extensions without issue, one way or another, with one glaring exception, AMD Windows drivers. The price of this is higher stuttering during gameplay when new shaders are being processed compared to running the same card on Linux with RADV, or using any other brand.</p> <p>A small side-note, Linux RADV users should update their Mesa version to the latest (or use a more recent distro version if needed), as support for <code>state2</code> was broken in versions before 21.2.</p> <p>As a last second change, Blinkhawk tested removing the 16-bit floating point (FP16) blacklist enforced on NVIDIA Ampere and newer GPUs (RTX 3000 series and higher). If it worked, it would have allowed them to work similarly to Turing and AMD Radeon offerings in this aspect. However, NVIDIA redesigned how their FP32 and FP16 units operate on Ampere and newer, with both providing identical performance. Unfortunately, even if it were faster, it&rsquo;d be irrelevant in the end, as FP16 on Ampere and Ada is still bugged in the drivers, producing graphical issues in many games.</p> <p>The only remaining architecture that could benefit from enabling blacklisted FP16 support is Intel on Windows, but their drivers are a dumpster fire regarding FP16. So they continue to emulate 16-bit precision with 32-bit the same way as Ampere and Ada, in this case with its always present performance loss. <em>Of course</em> the weakest architecture that could benefit the most from this change is the only one that remains broken…</p> <p>Another extra benefit of this iteration of <code>Y.F.C.</code> is that <code>Normal</code> GPU accuracy is much safer to use. Particles will continue to be better in <code>High</code>, but games like <code>Pokémon Scarlet/Violet</code>, <code>Bayonetta 3</code>, and many others can be played with <code>Normal</code> accuracy without glitches much more regularly with the big performance benefit this provides (<code>Bayonetta 3</code> in particular still needs <code>High</code> for its title screen, but gameplay is safe on <code>Normal</code>).</p> <h2 id="other-awesome-gpu-changes-and-yet-more-cache-invalidations">Other awesome GPU changes, and yet more cache invalidations</h2> <p>The month doesn’t stop there, there has been a plethora of changes worth mentioning too in our GPU codebase.</p> <p>Oh boy, <a href="https://github.com/liamwhite">byte[]</a> sure has been busy this month.</p> <p>To start off, he is responsible for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9409" data-gh-pr="9409">implementing the SMAA anti-aliasing filter</a> for our Vulkan and OpenGL backends. But that’s not the whole story, so let’s elaborate further.</p> <p><code>SMAA</code>, or enhanced subpixel morphological antialiasing, is an improvement over <a href="https://en.wikipedia.org/wiki/Morphological_antialiasing">MLAA</a> developed by the Spanish Universidad de Zaragoza and video game studio Crytek, of Crysis fame.</p> <p><a href="https://github.com/breadfish64">BreadFish</a> implemented the original OpenGL version, intending to release it as part of the <a href="https://yuzu-mirror.github.io/entry/yuzu-art/">resolution scaler</a>. As it turns out, implementing <code>SMAA</code> for Vulkan is no joke, and after being nagged by your writer, byte[] had to work 2 weeks to get it in shape.</p> <p><code>SMAA</code>, being based on <code>MLAA</code>, intends to be a post-processing (aka shader-based) option focused on quality over performance by analyzing adjacent pixels, unlike <code>FXAA</code> which just blurs the entire screen. The <code>SMAA</code> filter is implemented using render passes and it produces its best results when combined with FSR filtering. AMD recommends properly anti-aliasing the image in their official Overview Integration Guide. The results speak for themselves:</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/noaa_hue908f0f6b2436540c86aa7f674431f49_361749_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Here you can see an ideal test case for SMAA, the simple triangle of death"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/1smaa_huedf690bda4e99ac55af06fd456bd7739_379469_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Here you can see an ideal test case for SMAA, the simple triangle of death"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Here you can see an ideal test case for SMAA, the simple triangle of death</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./svnoaa.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/svnoaa_hu79520dc4751513dffa3df3ff1e263340_1171535_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ropes and power lines, the classic example for anti-aliasing testing (Pokémon Scarlet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./svfxaa.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/svfxaa_huaf80677739c1c974c725bf6e52b5913b_1198121_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ropes and power lines, the classic example for anti-aliasing testing (Pokémon Scarlet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./svsmaa.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/svsmaa_hu40d2a8459748093c0e32d8d553dc7d48_1338828_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ropes and power lines, the classic example for anti-aliasing testing (Pokémon Scarlet)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Ropes and power lines, the classic example for anti-aliasing testing (Pokémon Scarlet)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc3noaa.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/xc3noaa_hu12c9cd8179560b0492309d83c10bf4b5_278143_800x0_resize_q90_bgffffff_box_3.jpg" alt="Sprite elements in 3D games benefit from it (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc3fxaa.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/xc3fxaa_hu927f4720b6fc328452a804eb2370d856_275106_800x0_resize_q90_bgffffff_box_3.jpg" alt="Sprite elements in 3D games benefit from it (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc3smaa.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/xc3smaa_hua53a8f42219e109ec9d7cb4ecc09bb19_276508_800x0_resize_q90_bgffffff_box_3.jpg" alt="Sprite elements in 3D games benefit from it (Xenoblade Chronicles 3)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Sprite elements in 3D games benefit from it (Xenoblade Chronicles 3)</p> <p>For those interested, we used the <code>ULTRA</code> preset, testing showed a low performance loss even with a GT 1030, so we preferred to focus on quality. Only users with old integrated GPUs should avoid <code>SMAA</code>. For the rest, it’s a safe option to turn on and forget. You can find the feature in <code>Emulation &gt; Configure &gt; Graphics &gt; Anti-Aliasing Method</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/botwfxaa_hua72d1159361779e5688a2c180126e113_695738_1024x0_resize_q90_bgffffff_box_3.jpg" alt="SMAA doesn’t suffer from the horrible colour banding of FXAA (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/botwsmaa_hu3cb7005c7501afc4fc98d4f15d086c38_714089_1024x0_resize_q90_bgffffff_box_3.jpg" alt="SMAA doesn’t suffer from the horrible colour banding of FXAA (The Legend of Zelda: Breath of the Wild)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">SMAA doesn’t suffer from the horrible colour banding of FXAA (The Legend of Zelda: Breath of the Wild)</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/lowresbug_hu297de1eefde4fa5cedbb38e199ed299e_1867108_1024x0_resize_q90_bgffffff_box_3.jpg" alt="And it&#39;s a great help for users running low resolution multipliers. This example is 0.5x Bilinear alone Vs 0.5x FSR &#43; SMAA (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/lowresfix_hu33d4d1cbdb8d477978e65678bee89940_3690733_1024x0_resize_q90_bgffffff_box_3.jpg" alt="And it&#39;s a great help for users running low resolution multipliers. This example is 0.5x Bilinear alone Vs 0.5x FSR &#43; SMAA (Pokémon Scarlet)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">And it&#39;s a great help for users running low resolution multipliers. This example is 0.5x Bilinear alone Vs 0.5x FSR &#43; SMAA (Pokémon Scarlet)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./all3.png" title=" A close-up to finish (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/all3_hu0b93cac78d5b62c328d0abb5a23bfa7b_1363082_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" A close-up to finish (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> A close-up to finish (Xenoblade Chronicles 3)</p> </div> </div> <p>As a side note, NVIDIA’s version of FSR, NIS, was also tested, but the result is so ugly and over-sharpened, that we decided to keep the best option of the two, FSR.</p> <p>byte[] has also fixed a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9420" data-gh-pr="9420">problem with anisotropic filtering.</a> If users ran the RADV driver on Linux, anisotropic filtering values other than <code>Default</code> would cause a distinct &ldquo;acne-like&rdquo; rendering issue in <code>Super Mario Odyssey</code>. The issue persists at other anisotropic filtering and resolution multiplier values., but byte[] continues to work on the issue.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/off1bug_huaec446ec98515d58fbd69ce96b424f60_1018191_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The so called RADV acne (Super Mario Odyssey)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/off1fix_huec4631f796b5a363a4fe62141c36d0d6_996044_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The so called RADV acne (Super Mario Odyssey)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The so called RADV acne (Super Mario Odyssey)</p> <p>The change also addresses an issue with the buggy water rendering in <code>Super Mario Sunshine</code> with automatic anisotropic filtering on Lavapipe (Mesa, Linux), although the error still occurs at other anisotropic filtering values.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/off2bug_huc4e77688effdd6d4aeb65b49f6c88017_926147_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Kind of makes it look even older (Super Mario Sunshine)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/off2fix_hu6d7dc462849d8ec5ab969daed909cbb1_862900_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Kind of makes it look even older (Super Mario Sunshine)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Kind of makes it look even older (Super Mario Sunshine)</p> <p>byte[] also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9415" data-gh-pr="9415">corrected the semantics of data cache management operations</a> in the memory.</p> <p>Previously, when the guest requested a cache invalidation, the implementation would simply invalidate the cache on the hardware, rather than making the memory visible to the GPU as intended.</p> <p>On the side, he also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9372" data-gh-pr="9372">promoted various Vulkan Extensions to use core methods.</a> In the Vulkan API, vendor extensions are optional features provided by specific hardware vendors or drivers that may not be available on all systems. In contrast, core methods are a fundamental part of the Vulkan specification and are guaranteed to be available on all systems that support the API. Thus, promoting extensions to use core methods can improve their reliability and portability.</p> <p>byte[] made further <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9393" data-gh-pr="9393">initialization tweaks to the Vulkan API.</a> These changes included the restoration of <code>VK_KHR_timeline_semaphore</code> and <code>VK_EXT_host_query_reset</code>, which were mistakenly removed in a previous PR. He also added the flag <code>VK_INSTANCE_CREATE_ENUMERATE_PORTABILITY_BIT_KHR</code> to the <code>VkInstanceCreateInfo</code> structure for <code>MoltenVK</code> to allow <code>MoltenVK</code> to be detected as an available Vulkan device.</p> <p>Keep in mind that a lot more work is needed in order to get yuzu rendering on macOS devices. This is only early preliminary work.</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> has implemented the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9401" data-gh-pr="9401">draw manager for Maxwell3D</a> with the aim of eliminating workarounds and reorganising the drawing process to more accurately enumerate the drawing behaviour. As a result of these changes, the issue in <code>Dragon Quest Builders</code> where some 3D models were not rendering properly has been fixed.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/dbqbug_hu7604a6c9854fd93fd9ea3ab3d8c0728e_2007627_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more missing stuff! (Dragon Quest Builders)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/dbqfix_hu9a5fee0025b0488988d7c3d2121f3765_2354924_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more missing stuff! (Dragon Quest Builders)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more missing stuff! (Dragon Quest Builders)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ds.png" title=" No armour is best armour (DARK SOULS)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/ds_hu2ebb11c67e22dfde2808a3fe3a0dc478_717004_670x0_resize_q90_bgffffff_box_3.jpg" alt=" No armour is best armour (DARK SOULS)"></a> <p class="has-text-centered is-italic has-text-grey-light"> No armour is best armour (DARK SOULS)</p> </div> </div> <p>Following these changes, vonchenplus also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9406" data-gh-pr="9406">improved the code for the topology update logic</a> so that the implementation is more accurate. This change was necessary in order to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9423" data-gh-pr="9423">implement special topologies with Vulkan.</a> </p> <p>This includes support for <code>quad strips</code>, which require the use of triangles to simulate them, and the ability to simulate indexed and non-indexed modes. In non-indexed mode, a fixed mapping table is used to connect the vertices, while in indexed mode, a compute shader is used to dynamically map the original drawing indices. vonchenplus has also implemented support for line loops, which require the use of triangle lists to simulate them, and for polygons, which require the use of triangle fans.</p> <p>These changes fixed the Hero&rsquo;s path in <code>Legend of Zelda: Breath of the Wild</code>, as well as the Status Summary graphic in <code>Pokémon Scarlet and Violet</code>, and they also gave us another shader cache invalidation, yay!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/pokebug_hub8f2000f254dd66381f4f42279407863_2567699_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Don’t mess with the stats! Can’t do breeding without the stats! (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/pokefix_hu2ed312f3b0484778d47affb8361bbd5a_2693247_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Don’t mess with the stats! Can’t do breeding without the stats! (Pokémon Scarlet)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Don’t mess with the stats! Can’t do breeding without the stats! (Pokémon Scarlet)</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/botwbug_huaef779b194d81905c620c0f22f1b009c_3850902_1024x0_resize_q90_bgffffff_box_3.jpg" alt="When the Sheika GPS signal returns (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/botwfix_hu0da78fa54c9c88e5b941eda3d0fb2ba4_3934569_1024x0_resize_q90_bgffffff_box_3.jpg" alt="When the Sheika GPS signal returns (The Legend of Zelda: Breath of the Wild)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">When the Sheika GPS signal returns (The Legend of Zelda: Breath of the Wild)</p> <p>Blinkhawk has added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9383" data-gh-pr="9383">alpha to coverage and alpha to one</a> to our Vulkan backend.</p> <p><code>Alpha to coverage</code> is a multisampling technique that is used to improve the quality of transparent or partially transparent pixels. It works by blending the alpha values of multiple samples taken from the same pixel to produce a single, more accurate result. This can help to reduce aliasing and other rendering artifacts that can occur when rendering transparent pixels.</p> <p><code>Alpha to one</code>, on the other hand, is a technique that is used to improve the quality of partially transparent pixels by setting the alpha value of each pixel to a maximum of <code>1.0</code>. This can help to reduce the amount of alpha blending that needs to be performed, which can improve the performance of the rendering pipeline.</p> <p>These changes have fixed the shading of trees and grass problems when viewed up close or from a distance in <code>Pokémon Scarlet and Violet</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/alphabug_hucdeb648cb58d23bddcab0528f70d4621_4991715_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The camera isn’t more interested in that tree, you should learn from this, Dark Souls (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/alphafix_hu700ef594cb151f34e4333545157bf0dc_7195506_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The camera isn’t more interested in that tree, you should learn from this, Dark Souls (Pokémon Scarlet)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The camera isn’t more interested in that tree, you should learn from this, Dark Souls (Pokémon Scarlet)</p> <p>vonchenplus has corrected errors caused by yuzu&rsquo;s faulty detection of draw types. In the past, yuzu would set every vertex and index count register to zero after each draw to determine if the next draw would be a regular or indexed draw. <code>Xenoblade Chronicles 3</code> proves to us that these registers initiate some draw calls based on previous values. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9353" data-gh-pr="9353">Changing this behaviour</a> partially fixes the particles present in <code>Xenoblade Chronicles 3</code>. You can now more easily perform your off-seer duties.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xc3.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Meat is on the menu! (Xenoblade Chronicles 3)</p> </div> </div> <h2 id="cpu-requirement-changes-with-free-performance">CPU requirement changes, with free performance</h2> <p>We don’t usually cover compilation changes here, but this time we had to do it because it affects compatibility.</p> <p><a href="https://github.com/goldenx86">Your writer</a> (or co-writer in this progress report, my <a href="https://github.com/kurenaihana">partner</a> did most of the work this time) has been playing with compilation flags in order to get more free performance, following previous work done by Blinkhawk some time ago.</p> <p>Microsoft Visual C++ (MSVC, Visual Studio) is simple enough (we’ll talk about Linux later). You enable full program optimizations, optimize for performance instead of size, a bit here, a bit there, and you gain a nice 3%, but I wanted more. Last month, <a href="https://github.com/ameerj">epicboy</a> improved the build process, saving both time and memory. This created a “gap” big enough to enable the <em>Big One</em>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9442" data-gh-pr="9442">Link-Time Optimizations</a> (LTO), an optimization that in the past had to be discarded for eating all the available RAM of our buildbots.</p> <p>Windows testing went well and in some cases the performance uplift reached up to 12%. The problem was Linux. LTO is aggressive by nature, and there’s no guarantee that all parts of the project will react nicely to it. In this case, the problem was Qt, the UI looked completely garbled. So LTO had to go, but in its place, we now require what <a href="https://github.com/merryhime/dynarmic/">Dynarmic</a> already did for a while, <a href="https://en.wikipedia.org/wiki/X86-64#Microarchitecture_levels">x86-64-v2</a> hardware.</p> <p>GCC and Clang builds will now compile assuming the features of CPUs are compatible with the instruction sets that form part of x86-64-v2, the highest one being SSE4.2. This means the minimum CPU required for yuzu to work without crashing, in both Windows and Linux, is now the first generation of Core i-series (500-900 series), which are almost 15 years old, and the FX and APU series from AMD, which are almost 12 years old. The performance boost on GCC and Clang is up to 7%.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./lto1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/lto1_hu918e7ea11e9040fc28310e37ef5c636f_28477_800x0_resize_q90_bgffffff_box_3.jpg" alt="First system runs i7-12700H - 2x16GB 4800MHz CL40 - RTX 3080 Mobile 16GB 175W, second system runs R7 5800X3D - 2x16GB 3600MHz CL16 - RTX 4090"></a> </div> <div class="column is-bottom-paddingless"> <a href="./lto2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/lto2_hu70113885fa42d19352338a1763fd1959_28146_800x0_resize_q90_bgffffff_box_3.jpg" alt="First system runs i7-12700H - 2x16GB 4800MHz CL40 - RTX 3080 Mobile 16GB 175W, second system runs R7 5800X3D - 2x16GB 3600MHz CL16 - RTX 4090"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">First system runs i7-12700H - 2x16GB 4800MHz CL40 - RTX 3080 Mobile 16GB 175W, second system runs R7 5800X3D - 2x16GB 3600MHz CL16 - RTX 4090</p> <p>We originally wanted to enforce x86-64-v3 to get an even bigger performance boost, as well as to ensure a minimum level of performance, as any CPU lacking AVX, AVX2, and in particular, FMA, will be <em><strong>very</strong></em> slow, no matter its clock speed or core count.</p> <p>Yes, that means the 8 core Ivy Bridge Xeon you bought for 20 bucks is <em>not</em> fast enough for this task.</p> <p>The problem, however, is that doing so would leave close to 9% of the user base out of support, according to our telemetry. That many users is a considerable number, so we&rsquo;ve decided to wait until more users adopt more modern CPUs before implementing this change. We’ll re-evaluate enforcing x86-64-v3 in the future once OpenGL eventually ends up on the chopping block as well.</p> <p>While this change would also apply for Windows, MSVC is not flexible enough to let us build for x86-64-v2, it either supports SSE2, or jumps straight to the first AVX. Dynarmic already manually uses x86-64-v2 extensions, so any CPU lacking SSE4.2 is considered unstable regardless of the OS in use.</p> <p>x86-64-v4 will not be an option for many years, mainly because Intel can’t decide if AVX-512, made by themselves, is something that their users should be allowed to actually use.</p> <p>If an old-school user is so strongly set on running yuzu on decades old CPUs, the Flatpak builds are still generic, or there’s always the option of building yuzu manually, allowing you to configure any requirements.</p> <h2 id="new-joy-con-driver-and-other-input-improvements">New Joy-Con driver and other input improvements</h2> <p><a href="https://github.com/german77">german77</a> has done it again, giving us an amazing Christmas gift, a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9492" data-gh-pr="9492">new input driver for Joy-Cons</a> This is an in-house development that doesn’t rely on SDL, so it gives us much more freedom to add features that weren’t previously available.</p> <p>The basics are covered. Single and Dual Joy-Con modes are available, button, stick, motion mapping works the same as before. But that&rsquo;s not exciting, here’s all the new stuff that was added:</p> <ul> <li>When launching yuzu, the controller player LEDs will show a blinking pattern to signal that the emulator has taken control. Once you’re in game, the LEDs will reflect the player number.</li> <li>HD Rumble is fully implemented now, complete parity to pairing natively.</li> <li>The emulator can now automatically select between automatic and custom calibration profiles, avoiding stick drift (as much as the Joy-Con can physically do, we can’t fix Nintendo’s problems) and providing much more accurate motion.</li> <li>Colour reading is added, now the actual colour of the controller is reflected in the UI and in games, just like on Switch.</li> <li>Amiibos can now be loaded with the Joy-Con just like you do on the Switch.</li> <li>The Ring Controller is now fully supported, no need for external programs.</li> <li>Preliminary support for the IR camera is done, games like <code>Night Vision</code>, <code>Game Builder Garage</code>, and <code>Nintendo Labo</code> can make use of this neat feature at the base of the right Joy-Con.</li> </ul> <p>All this extra accuracy highlights a problem we didn’t often face before: PC Bluetooth connections are very easy to saturate. Cheaper/Intel bluetooth chipsets or areas with tons of interference are especially prone to this. For this reason, HD Rumble can potentially cause lag depending on the user’s specific circumstances. We recommend unmapping/disabling rumble in those cases.</p> <p>Speaking of saturation, the IR camera may be slow in some games. The reason being that we currently implement only the image transfer mode, which saves 320x240 pictures. Some games prefer faster framerates at the cost of resolution, going as low as 40x30. Once all modes are added in, the choppy framerate will disappear.</p> <p>Amiibo data writing is a work in progress.</p> <p>german77&rsquo;s desire for incredible input improvements doesn&rsquo;t end there.</p> <p>german77 implemented the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9369" data-gh-pr="9369"><code>mifare</code> service,</a> allowing games read and write plain mifare tags. Games like <code>Skylanders Imaginators</code> make use of this feature. The only feature lacking is support for encrypted read and writes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sky.png" title=" Tagging! (Skylanders Imaginators)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/sky_hu94439d4602d36c3191bb97d9b620f96a_2298233_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Tagging! (Skylanders Imaginators)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Tagging! (Skylanders Imaginators)</p> </div> </div> <p>Speaking of SDL, a recent update broke the way it handled the GUID, the identifier of several controllers, including the one integrated into the Steam Deck, causing many annoyances for Deck users. So, with no alternative on hand, german77 had to implement a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9404" data-gh-pr="9404">custom filter</a> to solve the issue.</p> <p>And lastly, as a very important quality of life change, german77 made the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9495" data-gh-pr="9495">input device list refresh automatically,</a> ensuring that yuzu detects controllers without the need for manual intervention. Goodbye tiny refresh button!</p> <p>To close the section, <a href="https://github.com/MonsterDruide1">MonsterDruide1</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9489" data-gh-pr="9489">increased the accuracy of analog sticks</a> for TAS by hardcoding the range and deadzones of the user input.</p> <h2 id="kernel-building-and-core-changes">Kernel, building, and core changes</h2> <p>With an update for Dynarmic and SDL2, byte[] enabled <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9374" data-gh-pr="9374">support for ARM64</a> compilation. This means all Switch titles can be tested on Linux ARM64 devices with compatible Vulkan drivers.</p> <p>As part of this effort, we started implementing Flatpak support for ARM64 Linux devices. This <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9419" data-gh-pr="9419">required making OpenGL optional</a> for the build process, as Flatpak’s Qt build only supports OpenGL ES, not the full fledged OpenGL 4.6 compatibility profile we require.</p> <p>Part of these changes fixed compilation for macOS, but the situation remains the same, without <code>MoltenVK</code> support, nothing will be rendered.</p> <p>epicboy implemented a series of changes with the goal of minimizing the overhead of dynamic memory allocation, a task which involves requesting memory from the operating system, and can slow-down performance in some circumstances.</p> <p>The texture cache, in particular, was a significant contributor to this issue, as it constantly allocated and then deallocated memory when transferring textures to and from the GPU. To address this problem, epicboy optimized the texture cache to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9490" data-gh-pr="9490">pre-allocate a buffer to store swizzle data</a> and reuse it whenever possible, rather than performing a dynamic memory allocation every time this was done. This change should result in reduced stuttering, as memory will now only be requested from the operating system if the buffer is not large enough to hold the data.</p> <p>epicboy also made similar changes to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9508" data-gh-pr="9508">optimise the <code>ReadBuffer</code> function</a> , which likewise takes a similar approach: instead of allocating and deallocating memory, a buffer is created once to hold data in the memory, and it only reallocates whenever it needs to grow.</p> <p>Additionally, he introduced a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9453" data-gh-pr="9453"><code>ScratchBuffer</code> class</a> to act as a wrapper around a heap-allocated buffer of memory.</p> <p>The advantage of this class lies with the fact that it eliminates the need to initialize the stored values, and the need to copy the data when the buffer needs to grow. Thus, it would help to speed up things by minimizing the amount of time spent on memory management tasks.</p> <p>german77 implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9444" data-gh-pr="9444">the <code>FreeThreadCount</code> info type,</a> which is needed by titles such as <code>Just Dance 2023 Edition</code> (although that game requires additional changes in order to work).</p> <p><a href="https://github.com/Saalvage">Saalvage</a> noticed an error in yuzu&rsquo;s kernel implementation and made the necessary changes to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9411" data-gh-pr="9411">unlock thread mutex before destruction,</a> as not doing so incurs an undefined behaviour. “Here be Dragons” and all that.</p> <p>byte[] submitted a change that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9398" data-gh-pr="9398">improves the handling of system startup failure,</a> in order to prevent deadlocks and crashes when/if the GPU initialization fails.</p> <p>He also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9474" data-gh-pr="9474">added <code>KHardwareTimer</code>.</a> This component is designed to fix an issue with incorrect event unregistration when threads request a timeout for certain operations.</p> <p>Without the fix, the threads would return successfully from the operation but fail to cancel the timeout, which would cause the timer to mistakenly fire on the thread and cancel a random unrelated operation.</p> <p>This change fixes the random hangs that have been plaguing us for months in <code>The Legend of Zelda: Breath of the Wild</code>, as well as <code>Persona 5 Royal</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./p5.png" title=" The soundtrack that steals your heart (Persona 5 Royal)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/p5_hu64069d0b4a06dbbf6748328b69d68bcf_4958703_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The soundtrack that steals your heart (Persona 5 Royal)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The soundtrack that steals your heart (Persona 5 Royal)</p> </div> </div> <p>byte[] also introduced a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9496" data-gh-pr="9496">workaround for crashes caused due to unallocated memory</a> after noticing that yuzu always used memory blocks without marking them as allocated, causing it to overlap memory used by the game. He fixed the bug by making sure we now allocate the memory before using it. This is meant to alleviate the situation while other parts of the kernel are being ironed out.</p> <p>This is more related to error handling, but counts nonetheless. byte[] added an option to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9370" data-gh-pr="9370">force the emulator to break when an invalid memory access happens.</a> This means that if/when a game explodes in the background, the emulator will crash instead of slowly eating all the available system RAM. Problems like these can be caused by emulation issues, damaged game dumps, or even some wonky mods, so it’s always a better option to avoid crashing the entire emulator, and if the user has little enough RAM, making the OS suffer.</p> <p>Along with endless silent changes that don’t get mentioned here, <a href="https://github.com/lioncash">lioncash</a> made some changes to the input code to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9389" data-gh-pr="9389">reduce memory use ever so slightly.</a> </p> <h2 id="user-interface-and-audio-changes">User interface and audio changes</h2> <p>We&rsquo;ve had some interesting user interface quality of life changes implemented! lioncash made the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9394" data-gh-pr="9394">SPIR-V shader backend element translatable,</a> so it doesn’t always show in English for everyone. The community effort working on translation can now take the label and update it accordingly.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./spirv.png" title=" We still don’t recommend using it over GLSL, but Mesa users report they enjoy it"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/spirv_hueb8a6ccf7576163a4089672b3acf10c8_11937_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We still don’t recommend using it over GLSL, but Mesa users report they enjoy it"></a> <p class="has-text-centered is-italic has-text-grey-light"> We still don’t recommend using it over GLSL, but Mesa users report they enjoy it</p> </div> </div> <p>Some months ago, with the core timing changes, we allowed users to boot games with their framerate unlocked after continuous requests from the community. As it turns out, nothing changed. Several games hate booting with unlocked framerates, and the support channels get their fair share of people asking why their game doesn’t want to boot. So, simple fix, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9425" data-gh-pr="9425">unlocked framerate at boot rights denied.</a> The hotkey to toggle unlocked framerate is <code>Ctrl + U</code> by default, only a small nuisance.</p> <p>Users reported that they couldn’t record or stream their yuzu window while in windowed mode. byte[] found the cause was setting the <code>WA_DontCreateNativeAncestors</code> Qt property for all platforms, instead of just for wayland. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9461" data-gh-pr="9461">Issue down, streamers rejoice.</a> </p> <p>Discord user piplup reported that yuzu didn’t save the device name (what you would call the console) after accessing a game’s custom configuration window. german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9466" data-gh-pr="9466">fixed the issue</a> (this particular setting lacked a custom configuration equivalent), and also fixed Qt 6 build issues while at it.</p> <p>Another very nice quality of life improvement made by german77 is making yuzu <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9467" data-gh-pr="9467">remember the last selected directory</a> for <code>Install files to NAND…</code>. If you keep your dumps in the same folder, updating your games is going to take fewer clicks now.</p> <p>byte[] managed an amazing victory in the war against crashes when closing/stopping games. He worked on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9476" data-gh-pr="9476">making shutdown not visibly freeze yuzu,</a> avoiding crashing the emulator while the game quits, and showing a nice pop-up message while at it too!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./shutdown.png" title=" We take longer than the Switch, but some games really love to take their time on console"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2022/shutdown_hu2363a0c0f90b02957b604b0be8dfff72_895045_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We take longer than the Switch, but some games really love to take their time on console"></a> <p class="has-text-centered is-italic has-text-grey-light"> We take longer than the Switch, but some games really love to take their time on console</p> </div> </div> <p><a href="https://github.com/Morph1984">Morph</a> helped make this possible by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9477" data-gh-pr="9477">hiding button dialog boxes,</a> allowing for the creation of the dialog overlay byte[] added.</p> <p>Another battle fought on this front is related to homebrew apps. byte[] is responsible for <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9486" data-gh-pr="9486">making them quit properly</a> now too.</p> <p><a href="https://github.com/ChrisOboe">ChrisOboe</a> suddenly shows up with a glorious quality of life fix for the terminal-based yuzu-cmd build. Marking the build as a “Windows” application instead of a “Console” one <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9485" data-gh-pr="9485">ensures that no empty command line window pops up</a> needlessly. This can help streaming programs set up to run specific games with yuzu-cmd, as this prevents the sudden empty black box from appearing in front of other windows.</p> <p>For our single audio change of this month, <a href="https://github.com/Kelebek1">Maide</a> properly <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9455" data-gh-pr="9455">signals a buffer event on audio stops,</a> fixing an early softlock that affected the <code>Pokémon Brilliant Diamond/Shining Pearl</code> games.</p> <h2 id="future-projects">Future projects</h2> <p>We’re only a few days into 2023 and we already want to publish the next progress report. So much has happened in such a short time!</p> <p>Also, Blinkhaw, bunnei, and byte[] are up to something, and we can’t wait to tell you more. And yes, there will be yet more cache invalidations. All in the name of progress.</p> <p>That’s all folks! Expect a few but <em>very</em> critical Vulkan improvements next time, hope to see you then!</p> <p>⭐⭐⭐ Grande Messi</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report November 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ Sat, 10 Dec 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ <p>As a dear friend likes to say, meowdy yuwu-zers! This month is special: a report detailing the uphill battle for the release of new titles in the goliath franchise that is Pokémon, adventures on <em>new architecture</em> lands, and a list of fixes and improvements that were made along the way. Fasten your seat-belts, here we go!</p> <p>As a dear friend likes to say, meowdy yuwu-zers! This month is special: a report detailing the uphill battle for the release of new titles in the goliath franchise that is Pokémon, adventures on <em>new architecture</em> lands, and a list of fixes and improvements that were made along the way. Fasten your seat-belts, here we go!</p> <h2 id="psa-for-nvidia-users-almost-a-flawless-victory">PSA for NVIDIA users (almost a flawless victory)</h2> <p>Before we move on to what everyone wants to hear about (just a new Pokémon game, nothing special 😉), we have very exciting news to announce! NVIDIA driver version <code>527.37</code> finally solves all known driver related regressions on Pascal and newer hardware! And to make it better, it affects all cards actively supported by NVIDIA. From the GT 1010 to the RTX 4090, there are no more driver related graphical issues (it&rsquo;s only our fault for now&hellip; until NVIDIA strikes again), exactly how the cards used to perform with driver version <code>472.12</code> all the way back in September 2021.</p> <p>Sadly, Maxwell users (900 series and older) will have to remain on version <code>512.95</code> to avoid frequent device loss errors when using Vulkan, but for those with GPUs newer than 8 years, there’s no longer a need to stick to old driver versions. Feel free to update to the latest release!</p> <p>Here are links for the <a href="https://www.nvidia.com/download/driverResults.aspx/197300/en-us/">desktop</a> and <a href="https://www.nvidia.com/download/driverResults.aspx/197301/en-us/">laptop</a> GPUs respectively.</p> <h2 id="guess-whos-back">Guess who’s back</h2> <p>It’s finally here. <del>For better or worse.</del></p> <p>Adopting some of the new gameplay elements introduced with <code>Pokémon Legends: Arceus</code>, <code>Pokémon Scarlet/Violet</code> has been unleashed upon the world! This time with ultra-realistic tree textures, and NPCs walking at 5 FPS.</p> <p>Fun new gameplay aside, this release has been quite the challenge for yuzu. It doesn’t help that the game has problems running natively on the Switch to begin with. Low performance, storage related stuttering, and memory leaks being some of them. However, while exposing several issues in yuzu, their corresponding fixes have helped other games in unexpected ways!</p> <p>When the game first released, it didn’t render anything in yuzu at all, which is not good. Something needed to be done. <a href="https://github.com/vonchenplus">vonchenplus</a> was the first to answer, and identified that this was due the game&rsquo;s use of <code>gl_Layer</code>, and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9253" data-gh-pr="9253">added support for it in the shader compiler.</a> You will hear more about this <code>gl_Layer</code> &ldquo;character&rdquo; later.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./poke.png" title=" One thing is for sure, the graphics have definitely improved (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/poke_hufab2aaefdfad9ad55d2b04ea9b4dbe7d_7438763_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" One thing is for sure, the graphics have definitely improved (Pokémon Scarlet)"></a> <p class="has-text-centered is-italic has-text-grey-light"> One thing is for sure, the graphics have definitely improved (Pokémon Scarlet)</p> </div> </div> <p>With this change, the game starts to render and the team can focus on finding, documenting, and fixing any other bugs that show up.</p> <p>A limitation was quickly found by the community, <code>gl_Layer</code> depends on having driver support for the <code>GL_ARB_shader_viewport_layer_array</code> extension in OpenGL, or the Vulkan equivalent, <code>VK_EXT_shader_viewport_index_layer</code>.</p> <p>While most GPU drivers do indeed support these extensions, the NVIDIA drivers don&rsquo;t for Maxwell V1 and older cards. This means users trying to run <code>Pokémon Scarlet/Violet</code> on GPUs older than the 900 series wouldn’t get the game to display anything on screen, in either graphics API and any shader backend. Must be part of the promised package that included Vulkan support for Fermi, pure smoke.</p> <p>The way <a href="https://github.com/liamwhite">byte[]</a> solved this limitation is by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9363" data-gh-pr="9363">translating the gl_Layer assignments with geometry shaders,</a> basically a brute-forced hardware accelerated way to replicate the missing extensions on older hardware. This results in proper rendering for the decade-old Geforce Fermi, Kepler, and Maxwell V1 series GPUs, in either OpenGL and Vulkan. Now an extra 6% of users can play the game.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./710.png" title=" The test subject, anyone can cook"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/710_hu8c2402d631bb13d469462a2ae1387e78_33155_388x0_resize_q90_bgffffff_box_3.jpg" alt=" The test subject, anyone can cook"></a> <p class="has-text-centered is-italic has-text-grey-light"> The test subject, anyone can cook</p> </div> </div> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./710fix.png" title=" Old but gold! (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/710fix_hu7c7687573c1fbc6a9174df733368ff31_2193637_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Old but gold! (Pokémon Scarlet)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Old but gold! (Pokémon Scarlet)</p> </div> </div> <p>Let’s switch for a second to CPU related issues. There were reports that certain moves like <code>Tail Whip</code> could cause the opposing Pokémon to outright vanish, or that changing directions very quickly could cause a soft-lock. Even simple map traversal could cause crashes.</p> <p>What do you do when all issues seem totally unrelated and random? You blame the CPU precision, of course!</p> <p>More, ahem, precisely, in what optimizations are enabled by default. The offending option turned out to be <code>Inaccurate NaN handling</code>, an optimization made to improve the performance of some rooms in <code>Luigi’s Mansion 3</code>. <a href="https://github.com/FernandoS27">Blinkhawk</a> updated the <code>Auto</code> setting for CPU accuracy to skip this optimization.</p> <p>For anyone wishing to restore the performance for <code>Luigi’s Mansion 3</code>, we recommend using the per-game settings feature. Right click the game, go to <code>Properties</code>, <code>CPU</code> tab, set CPU accuracy to <code>Unsafe</code>, and make sure <code>Inaccurate NaN handling</code> is enabled, as shown in the example below:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lm3.png" title=" The per-game settings window is a pathway to knowledge many consider... Unnatural"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/lm3_hua76c220c228272dbd677440de1112106_203517_902x0_resize_q90_bgffffff_box_3.jpg" alt=" The per-game settings window is a pathway to knowledge many consider... Unnatural"></a> <p class="has-text-centered is-italic has-text-grey-light"> The per-game settings window is a pathway to knowledge many consider... Unnatural</p> </div> </div> <p>We strongly recommend using a global setting of <code>Auto</code> CPU accuracy, and only implement custom/unsafe settings on a per game basis, never globally. Games WILL break with unsafe settings.</p> <p>Now going back to GPU related issues, AMD has its own share of problems, as it always does. Users were quick to point out that the game looked as though the director of Breaking Bad produced it, seemingly rendering like a yellow/orange filter was applied. This issue is for the history books, as both the official AMD drivers (the Windows driver, amdvlk, and AMDGPU-PRO) <em>and</em> mesa (RADV) share the same behaviour.</p> <p>Let’s provide some context. The default shader backend of Vulkan, <a href="https://en.wikipedia.org/wiki/Standard_Portable_Intermediate_Representation">SPIR-V</a>, describes the special properties variable decorations have. Usually, a fragment shader’s input variables are set as <code>smooth</code>, interpolating the values between each vertex. But sometimes you end up with a value that is constant across all vertices in a triangle. There’s no need to waste computational power smoothing anything in a case like this, so you can set the variable as <code>flat</code> instead. Both the official AMD and RADV drivers think that the previously mentioned <code>gl_Layer</code> input in the fragment shader needs to be decorated as flat, or they treat it as a constant zero across the triangle, instead of the value set in the vertex shader. Jury is out on this, we reported the issue to AMD.</p> <p>A normal Vulkan program would never find itself in this situation because the GLSL compiler always decorates <code>gl_Layer</code> as flat. The NVIDIA driver doesn’t make this assumption and doesn’t treat <code>gl_Layer</code> as a constant zero, regardless of the presence of the decoration.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/amdbug_hu627e2791b0f8f0c2c31853d342cd0aff_1576120_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wasn&#39;t this game based in Spain? (Pokémon Scarlet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/amdfix_hua56cca2548670be4e8be446729e22404_1972689_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wasn&#39;t this game based in Spain? (Pokémon Scarlet)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Wasn&#39;t this game based in Spain? (Pokémon Scarlet)</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9260" data-gh-pr="9260">By adding the missing flat decoration,</a> byte[] allows Radeon users to view the proper beautiful blue skies, in both Windows and Linux.</p> <p>Ping-ponging back to CPU bugs: Even with all the work so far, <code>Pokémon Scarlet/Violet</code> could periodically crash. This gave us a sense of dread we haven’t felt since the release of <code>Pokémon Sword/Shield</code>. Thankfully, our fear was unfounded, as only Windows users reported this issue. Linux users, for example Steam Deck users, didn’t crash at all. This gave us the needed hook to reel the line of the cause, which ended up being a problem in dynarmic, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9271" data-gh-pr="9271">a stack misalignment in one of the memory accessors.</a> A quick call to <a href="https://github.com/merryhime">Merry</a> over the red phone, and the crashing is no more.</p> <p>Back to the GPU, and this one was really annoying. Your writer had to do an all-nighter running tests with <a href="https://github.com/bunnei">bunnei</a> to figure it out.</p> <p>NPCs and characters could encounter vertex explosions at random, and while using <code>High</code> GPU accuracy would mitigate the problem to a certain extent, it was still very common in cities, particularly in the academy. To make it even uglier, those vertex explosions were permanent at specific camera angles.</p> <p>After a few dozen rounds of regression testing, the root cause was found in one of the changes introduced by <code>Project Y.F.C.</code>, so Blinkhawk took over and implemented the proper changes, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9312" data-gh-pr="9312">fixing some buffer cache and engine upload issues.</a> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ver1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ver1_hu39d4dd418dd2251d00b84c879344a8fe_574734_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s like our personal curse, seems to happen with every release (Pokémon Scarlet &amp; Violet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ver2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ver2_hu9169d1c10ca5c3887aa6ad8b36596f0e_646063_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s like our personal curse, seems to happen with every release (Pokémon Scarlet &amp; Violet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ver3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ver3_hu9c1032922415a6208f9dcd056c4abff0_1353816_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s like our personal curse, seems to happen with every release (Pokémon Scarlet &amp; Violet)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ver4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ver4_hu6584179436b88ef2860ed5279ed95614_3612901_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s like our personal curse, seems to happen with every release (Pokémon Scarlet &amp; Violet)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It&#39;s like our personal curse, seems to happen with every release (Pokémon Scarlet &amp; Violet)</p> <p>While the NPC vertex explosions are fixed, some geometry pop-up issues remain. Homework for later. Now any vertex related glitch only lasts one frame and should go away once the relevant shader gets cached. Also, as a bonus, <code>Pokémon Legends: Arceus</code> can now be played at <code>Normal</code> GPU accuracy without encountering vertex explosions, making good on our <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/#a-new-legend">promise to fix it</a>! This can greatly increase performance on the older Pokémon title. One more thing to scratch off the list. That buffer cache rewrite is still needed though.</p> <p>CPU&rsquo;s turn again, or rather memory in this case. byte[] fixed <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9279" data-gh-pr="9279">a silly mistake in the cheat engine</a> that caused it to crash when using speedhack cheats.</p> <p>Quick, back to the GPU! Or more precisely, a change to the user defaults.</p> <p>As you may know from previous reports, Vulkan has a tendency to break when the user installs outdated screen recorders, overlays, or bloatware that messes with the Vulkan layers. This leads people to still use the OpenGL API, which is not only considerably slower for <code>Pokémon Scarlet/Violet</code> (over three times slower in some cases), but also run the <code>GLASM</code> shader backend, an NVIDIA exclusive feature which is not particularly good with recent game releases, <code>Scarlet/Violet</code> not being an exception.</p> <p>yuzu used to default to <code>GLASM</code> so NVIDIA users could enjoy lower shader compilation related stuttering, as OpenGL’s default shader backend, <code>GLSL</code>, is irritatingly slow in this aspect. The problem with this approach is that the <code>GLASM</code> backend (assembly shaders) was developed as an experiment, and its two primary maintainers have moved on from the project, with one literally &ldquo;turning green with envy.&rdquo; No one on the team is taking the time to maintain a backend that has decades old and difficult-to-parse documentation, no debug tools, only partially helps a single GPU vendor, and has its advantages negated by a superior alternative, Vulkan.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/glasm_hu19e490b0b342323686dd76fc09ceef70_2230448_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Lavender Town? (Pokémon Violet)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/vulkan_hud42eea0b9e014b9cbf1f9e1c8cdc18e1_2122461_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Lavender Town? (Pokémon Violet)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Lavender Town? (Pokémon Violet)</p> <p>Assembly shaders were a useful alternative while Vulkan was in early development, but now it’s just dead weight taking precious development time that could be used to improve Vulkan instead.</p> <p>This problem is far more common than <a href="https://github.com/goldenx86">your writer</a> would like, so for those NVIDIA users with the <em>special superpower</em> to always break Vulkan, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9318" data-gh-pr="9318">OpenGL will default to GLSL now.</a> The option to use GLASM will remain available, as Fermi users love it due to their chronic lack of Vulkan support.</p> <p>To finish the changes implemented this month regarding this flawed best-seller, bunnei fixed an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9320" data-gh-pr="9320">assert spam in the audio suspend process.</a> This change not only cleans up logs, it has the potential to improve performance to a degree.</p> <p>That’s all for this November’s list of Pokémon fixes and improvements. More work is in development, as there is still stuff to fix, so while we wait let’s end this section with some recommendations we found to get the best experience while playing:</p> <ul> <li>NVIDIA, Intel, and AMD users <a href="https://community.citra-emu.org/t/recommended-settings/319349">must run the latest driver versions</a>.</li> <li><code>High</code> GPU accuracy ensures proper rendering of vegetation and buildings. Missing graphics? Switch to High.</li> <li>Handheld mode improves performance considerably over Docked.</li> <li>Gym trials may require switching to Handheld mode for stability, this could be a game issue as it is known to have memory leaks on console. Later game updates seem to solve this.</li> <li>4 core/8 thread users seem to improve performance by a good margin by disabling SMT/HT.</li> <li>Installing the latest game update improves performance and stability over long gameplay sessions.</li> </ul> <h2 id="graphical-fixes">Graphical fixes</h2> <p>Back to the usual agenda, games in general.</p> <p>vonchenplus found an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9167" data-gh-pr="9167">issue in how yuzu handles tessellation shaders</a> which causes black backgrounds in <code>The Legend of Heroes: Trails from Zero</code>.</p> <p>Why would you want to use tessellation shaders for 2D content in an RPG?</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tfz.png" title=" A tessellated 2D background, in all its glory (The Legend of Heroes: Trails from Zero)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/tfz_hu487d13b97fb1e58c580004258168629e_1370237_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" A tessellated 2D background, in all its glory (The Legend of Heroes: Trails from Zero)"></a> <p class="has-text-centered is-italic has-text-grey-light"> A tessellated 2D background, in all its glory (The Legend of Heroes: Trails from Zero)</p> </div> </div> <p>Immediately after implementing the change, we noticed that games didn’t render correctly, and it wasn’t the fix’s fault. In cases like this, a cache invalidation is not only recommended, but needed. <a href="https://github.com/gidoly">gidoly</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9175" data-gh-pr="9175">updated the cache version number,</a> invalidating all previous caches, and causing a large disturbance in the Net, as if thousands of Smash players suddenly cried out in terror and were suddenly silenced.</p> <p>One of the important changes that didn’t make it in time for the first part of <code>Project Y.F.C.</code>, Blinkhawk&rsquo;s series of GPU related changes and fixes, is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9194" data-gh-pr="9194">improving the handling of ASTC texture mipmap uploads.</a> </p> <p>The original implementation rendered the ASTC mipmaps directly. What actually happens on the Switch is that the NVIDIA driver uploads to its 2D engine first. The incorrect implementation caused severe texture corruption in many cases, most commonly in games running Unreal Engine 4.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ue4bug_huf39c332adf1cbbd8ebb3e688b6142c00_2096089_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Fluffy (Yoshi&#39;s Crafted World)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/ue4fix_hu047a7c844e888f76b6171f529752c5a9_2323378_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Fluffy (Yoshi&#39;s Crafted World)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fluffy (Yoshi&#39;s Crafted World)</p> <p>The list is long, so here’s a selection of games that were improved with this change:</p> <ul> <li><code>Blue Fire</code></li> <li><code>A Hat in Time</code></li> <li><code>The Witcher 3: Wild Hunt Complete Edition</code></li> <li><code>Darksiders III</code></li> <li><code>Diablo II Resurrected</code> (character hair)</li> <li><code>DRAGON QUEST XI S: Echoes of an Elusive Age – Definitive Edition</code></li> <li><code>Life is Strange: True Colors</code></li> <li><code>Yoshi's Crafted World</code></li> <li><code>F.I.S.T.: Forged In Shadow Torch</code></li> <li><code>Digimon Story Cyber Sleuth: Complete Edition</code></li> <li><code>Grand Theft Auto: The Trilogy – The Definitive Edition</code></li> </ul> <p>Working on improving OpenGL stability, vonchenplus <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9216" data-gh-pr="9216">reimplemented the inline index buffer binding,</a> making the OpenGL implementation match the Vulkan one. This solves certain cases where OpenGL would crash when using non-unified memory mode.</p> <p>Here’s an interesting one. If a game had bad performance on a specific system and produced too low of framerates at boot, it could hang due to a lost wakeup. Since the &ldquo;secret project&rdquo; byte[] was working on was a platform slower than a normal gaming PC (more on this in the next section), byte[] blasted this limitation to the Dark World, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9244" data-gh-pr="9244">allowing everyone to be able to boot their game dumps.</a> </p> <p>A problem we reported a couple of times already, and AMD confirmed to be working on, was crashes happening in <code>Xenoblade Chronicles 3</code> with Vulkan, thanks to improving the precision of our MacroJIT code. Since it became clear that more time was needed to solve this issue on the driver side, byte[] managed to implement a workaround, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9252" data-gh-pr="9252">an HLE multi-layer clear mechanism</a> which bypasses this driver-level limitation. This way, the game remains playable in Vulkan for AMD on Windows.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xc3.png" title=" Always has great title screen music (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/xc3_hu9d02021296f8f574b41ac717cf358ded_5376262_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Always has great title screen music (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Always has great title screen music (Xenoblade Chronicles 3)</p> </div> </div> <p>Here’s an interesting find from one of our <em>old</em> testers. If you run <code>The Legend of Zelda: Breath of the Wild</code> in its base 1.0.0 version, recent changes caused distant trees to have a black flicker. This behaviour was not present in an updated game, but a glitch is a glitch, and it deserves attention.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./botwbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./botwfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The old result (left) has been reduced to 10 FPS to avoid triggering sensitive readers (The Legend of Zelda: Breath of the Wild)</p> <p>vonchenplus found out that the order of the drawing commands was wrong in this case, and implemented a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9288" data-gh-pr="9288">more conservative drawing trigger mechanism.</a> No other game is known to be affected by this change, but if there is, it’s fixed!</p> <p>Your writer has been trying to slowly learn the ropes and decided to take on some small projects. Too bad he’s also an idiot…</p> <p>The result of too many hours of suffering is the addition of a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9276" data-gh-pr="9276">sharpening slider for the FSR filter.</a> Also known by its long name, <code>AMD FidelityFX Super Resolution 1.0.2</code>. However, it prefers being called FSR between friends.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./slider.png" title=" Emulation &gt; Configure &gt; Graphics"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/slider_hucfc36f7c0b1cd7fc7ac866457bb84be5_29408_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Emulation &gt; Configure &gt; Graphics"></a> <p class="has-text-centered is-italic has-text-grey-light"> Emulation &gt; Configure &gt; Graphics</p> </div> </div> <p>This allows the user to pick how much they want to sharpen a specific game. Personal preference applies here, for example, <code>The Legend of Zelda: Breath of the Wild</code> may look great at 100% sharpening, but that same value may be too much for <code>Pokémon Scarlet</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/fsr0_hu90bedbb6daabd24e50218af911c7dbbd_3334580_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Seems to help with distant objects (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/fsr100_hufc3ecd9149e60703ff9742acb0c26050_5010805_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Seems to help with distant objects (The Legend of Zelda: Breath of the Wild)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Seems to help with distant objects (The Legend of Zelda: Breath of the Wild)</p> <p>Test it to your preference and use the per-game profiles to make the most out of it. Thank you <a href="https://github.com/lat9nq">toastUnlimited</a> for helping me with the per-game support.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pgfsr.png" title=" Right-click &gt; Properties &gt; Graphics"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/pgfsr_hucf7658c83282cbfe5b1a75e1814261b2_203962_902x0_resize_q90_bgffffff_box_3.jpg" alt=" Right-click &gt; Properties &gt; Graphics"></a> <p class="has-text-centered is-italic has-text-grey-light"> Right-click &gt; Properties &gt; Graphics</p> </div> </div> <p>Our own Poyo enjoyer, <a href="https://github.com/Morph1984">Morph</a>, with help from byte[], worked on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9307" data-gh-pr="9307">improving the usage bits</a> Vulkan demands of the device’s supported formats, while at it also adding a new format to the list, <code>R16_SINT</code>. One of the “improved” games from this change is <code>Xenoblade Chronicles: Definitive Edition</code>. While the game complained about missing a texture format, graphics don’t seem to have changed.</p> <h2 id="cpu-kernel-and-debugger-changes">CPU, kernel, and debugger changes</h2> <p>Let’s address the elephant in the room, which byte[] has been feeding tons of peanuts lately. yuzu now supports being <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9198" data-gh-pr="9198">built and run on ARM64 devices!</a> </p> <p>Of course, hardware requirements remain the same: at least 8GB of RAM and an OpenGL 4.6 compatibility profile/Vulkan 1.2 plus specific extensions GPU driver is required. This means that yuzu can run on, for example, Asahi Linux on an M1 Apple MacBook Air, but by using Lavapipe, Mesa’s CPU rendering Vulkan driver, which of course results in very slow performance.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./asahi.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/asahi_huc39f009729c1859ab20cfb4a7c9d7ff3_2908059_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is what&#39;s possible right now (Mario Kart 8 Deluxe &amp; Super Mario Galaxy)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./asahi2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/asahi2_hubcb2ed02bc0c836498abce2c3db3eed3_1937355_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is what&#39;s possible right now (Mario Kart 8 Deluxe &amp; Super Mario Galaxy)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This is what&#39;s possible right now (Mario Kart 8 Deluxe &amp; Super Mario Galaxy)</p> <p>This initial implementation adds support for 32-bit games only. As for 64-bit games (the most common), <a href="https://github.com/merryhime/dynarmic/pull/719">an update needs to be merged to Dynarmic</a>. Once it’s out, there will be no restrictions on which games can be executed.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./asahi64.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/asahi64_hua3a04fa1f7372b85c7a5f3cd1589199c_2025847_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is what will be possible in the near future (Super Mario 3D World &#43; Bowser&#39;s Fury, Super Mario 3D All-Stars, &amp; Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./asahi642.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/asahi642_hua3a04fa1f7372b85c7a5f3cd1589199c_1370853_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is what will be possible in the near future (Super Mario 3D World &#43; Bowser&#39;s Fury, Super Mario 3D All-Stars, &amp; Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./asahi643.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/asahi643_hua3a04fa1f7372b85c7a5f3cd1589199c_1565057_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is what will be possible in the near future (Super Mario 3D World &#43; Bowser&#39;s Fury, Super Mario 3D All-Stars, &amp; Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This is what will be possible in the near future (Super Mario 3D World &#43; Bowser&#39;s Fury, Super Mario 3D All-Stars, &amp; Super Mario Odyssey)</p> <p>Further improvements by byte[] includes <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9215" data-gh-pr="9215">corrections on atomic store ordering</a> to improve stability, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9234" data-gh-pr="9234">implement data cache management operations,</a> and the most fun one, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9289" data-gh-pr="9289">fix compilation for Apple Clang,</a> allowing yuzu to run directly on macOS!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./macos.png" title=" If only Apple wasn&#39;t a reptilian company and offered Vulkan support"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/macos_hub63e5780ce9cf37386e68ab10609a70b_2023798_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" If only Apple wasn&#39;t a reptilian company and offered Vulkan support"></a> <p class="has-text-centered is-italic has-text-grey-light"> If only Apple wasn&#39;t a reptilian company and offered Vulkan support</p> </div> </div> <p>We have a very long road ahead to fully support macOS, but a journey of a thousand miles begins with a single step, says the old man.</p> <p>Outside of venturing into new architecture seas, byte[] also contributed a few general changes too.</p> <p>Switch games can be weird. For example, <code>MONSTER HUNTER RISE</code> has some fundamental love for opening services. After a recent refactor, our kernel emulation incorrectly used a process per session, and this could lead to running out of slab heap, resulting in a hard crash. As a workaround while byte[] refactors services to have a process tree accurate to the Switch, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9224" data-gh-pr="9224">the extraneous processes have been removed,</a> keeping stability in check.</p> <p>The fight for proper kernel emulation rages on, and bunnei raises the bar by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9173" data-gh-pr="9173">implementing most of the Switch’s firmware 15.X.X features.</a> This brings memory management improvements (must resist making a boomerang joke), which should result in improved stability and slightly better resource usage. While no game seems to specifically improve with this change, future games targeting the latest firmware versions will certainly benefit. Nothing better than avoiding future headaches!</p> <h2 id="services-input-and-audio-changes">Services, input, and audio changes</h2> <p>On the last day of the month, when we cut the list of pull requests that will make it into this article, Morph contacts your writer asking for one last addition. And it was one important addition. Morph <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9348" data-gh-pr="9348">improved the stubs</a> for the <code>Submit</code>, <code>GetRequestState</code>, and <code>GetResult</code> service functions, allowing <code>Splatoon 3</code> to boot while a network connection was configured for LAN/LDN play.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./sp31.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/sp31_hud4e527aa1187a4e8a18daf7be14d0a38_1301030_800x0_resize_q90_bgffffff_box_3.jpg" alt="While now you can join rooms, the game is not stable yet (Splatoon 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sp32.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/sp32_hu23d14baff80246b288a1e37040afda31_358509_800x0_resize_q90_bgffffff_box_3.jpg" alt="While now you can join rooms, the game is not stable yet (Splatoon 3)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">While now you can join rooms, the game is not stable yet (Splatoon 3)</p> <p>A lot more work is required to make this game fully playable, but fixing boot related issues is always a great start.</p> <p><a href="https://github.com/jbeich">jbeich</a> is back in action, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9181" data-gh-pr="9181">ensuring that yuzu is compatible with BSD systems!</a> This change adds support for previous additions and fixes that were only considering Linux at the time. A separate pull request deals with <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9178" data-gh-pr="9178">making BSD compatible with the changes required to run the LDN services.</a> </p> <p>As part of byte[]’s efforts to get yuzu running on macOS, he and toastUnlimited had to make some changes to fit the platform’s special needs. First, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9304" data-gh-pr="9304">assigned the menuRole property for actions to improve Cocoa support,</a> and then toastUnlimited <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9308" data-gh-pr="9308">changed the Vulkan check on other platforms to behave closer to how the check for Windows works,</a> improving the compatibility with the macOS file manager. <a href="https://github.com/german77">german77</a> joins the fun, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9322" data-gh-pr="9322">making changes to ensure reading SDL events doesn&rsquo;t crash on macOS.</a> </p> <p>Regarding input in general, german77 went to infinity and beyond with yuzu’s multitouch detection, raising the 16-finger limit to, well, infinite! As part of this change, he also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9191" data-gh-pr="9191">tuned the response speed of touches,</a> which were a little bit too fast, resulting in missing input. As a result <code>Mini Motorways</code> is far more playable now!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./motor.png" title=" C&#39;mon, touch it! (Mini Motorways)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/motor_hu6e14be7ef1299e0c6e6266903438c8d2_690582_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" C&#39;mon, touch it! (Mini Motorways)"></a> <p class="has-text-centered is-italic has-text-grey-light"> C&#39;mon, touch it! (Mini Motorways)</p> </div> </div> <p>Amiibos also got some love from german77. The first example is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9219" data-gh-pr="9219">implementing the NFC</a> <code>IUser</code> service, which fixes the NFC detection in <code>Ultra Kaiju Monster Rancher</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./monster.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/monster_hu92acb6174bb58187f93869f8f8ed1078_992256_800x0_resize_q90_bgffffff_box_3.jpg" alt="And it&#39;s still a premium feature on most phones (Ultra Kaiju Monster Rancher)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nfc.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/nfc_hue1384523ff10ef2eb45b12531358b4b4_457325_800x0_resize_q90_bgffffff_box_3.jpg" alt="And it&#39;s still a premium feature on most phones (Ultra Kaiju Monster Rancher)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">And it&#39;s still a premium feature on most phones (Ultra Kaiju Monster Rancher)</p> <p>Next, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9238" data-gh-pr="9238">implemented the</a> <code>cabinet applet</code> (Amiibo manager window). This new settings window allows the user to register, format, and delete game data from their Amiibos, while also displaying any additional data available. This first implementation will only show up when a game requests it, a manual UI option will be added in the future.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cabinet.png" title=" Images optional for now (Shovel Knight)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/cabinet_hu9cba8f604ddb04d6f0f25d84b9e8ea91_191899_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Images optional for now (Shovel Knight)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Images optional for now (Shovel Knight)</p> </div> </div> <p>On the audio side of things, <a href="https://github.com/Kelebek1">Maide</a> has been working on solving out-of-bounds crashing issues related to how the emulator and the Switch handle audio buffers. Here’s the thing, the game decides how many buffers it wants to use, and has the freedom to use the buffers as it pleases. As Maide says: “Put voice A in buffer 1 with voice B in buffer 2, mix them together into buffer 3. Put voice C in buffer 4 and mix buffer 3 and 4 into buffer 5, etc.” At the end of the line, if you need to output to 2 channels, only two final buffers will be used, for 6 channels, 6 buffers, but there is no order to those selected buffers, no rule says that they must be buffer 0 and 1. yuzu operated under the assumption that games would use buffers 0 to 5 for output, and that has been the case for the majority of games, but as always, there are exceptions, one being <code>The Legend of Zelda: Skyward Sword HD</code>. This particular game uses something similar to 8/9/12/13/10/11 for its 6 buffer outputs, or in proper hexadecimal values, 8/9/C/D/A/B.</p> <p>The previous implementation took the first buffer as a starting point, buffer 0, and added +1 to fill the remaining 5 slots. That’s definitely not valid for <code>Skyward Sword</code>, the moment you want to access a buffer that is not part of those 6 first consecutive buffers, you get a crash for getting out-of-bounds, and this happens even with the first actual output buffer, at 8! Fixing this behaviour by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9297" data-gh-pr="9297">checking the highest buffer and adding +1</a> stops the game from crashing, and should also have the benefit of not outputting weird sounds, as the correct buffers will be selected.</p> <p>As most of you know, our current file system emulation is far from ideal. Morph’s <code>Project Gaia</code> should address most issues we have with it once his rewrite is finished. In the meantime, there’s nothing against fixing existing problems with it, and <a href="https://github.com/v1993">v1993</a> provides a huge hand by addressing a case that could be invisible to the user, and really annoying as a result. The emulator can auto-generate some of the keys required to decrypt and run Switch games. The problem is that those auto-generated keys are sometimes worse than those the user provided during the dumping process, yet they still took precedence. v1993 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9324" data-gh-pr="9324">flips this behaviour,</a> solving cases of games refusing to boot due to this conflict.</p> <h2 id="user-interface-improvements">User interface improvements</h2> <p>Localization is an ongoing effort, and anyone can contribute <a href="https://www.transifex.com/yuzu-emulator/yuzu">here</a>. This time the community added support for another language, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9166" data-gh-pr="9166">Ukrainian!</a> This addition is possible thanks to the work done by <a href="https://github.com/Docteh">Docteh</a> and GillianMC. Keep at it guys, we&rsquo;re all with you.</p> <p>Docteh also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9180" data-gh-pr="9180">fixed the translation of pop-up warnings</a> that show up when trying to remove game content.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./removebug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/removebug_hu58771770a5d292e3dab0e8d3cf564808_6430_800x0_resize_q90_bgffffff_box_3.jpg" alt="Como corresponde"></a> </div> <div class="column is-bottom-paddingless"> <a href="./removefix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/removefix_huf59b189dcf9220d3c511adcd7578112b_5337_800x0_resize_q90_bgffffff_box_3.jpg" alt="Como corresponde"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Como corresponde</p> <p>No one wants to lose their saves, especially not if it&rsquo;s the user’s own fault. As per the request of one such user, toastUnlimited added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9247" data-gh-pr="9247">a warning pop-up when a user attempts to delete a user profile.</a> Because, yes, deleting a profile includes deleting its saves.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./delete.png" title=" The UI must also protect the users from themselves"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/delete_hu3e69e745207a32d103274b096f992b9d_25714_405x0_resize_q90_bgffffff_box_3.jpg" alt=" The UI must also protect the users from themselves"></a> <p class="has-text-centered is-italic has-text-grey-light"> The UI must also protect the users from themselves</p> </div> </div> <p>epicboy surprised everyone by slamming the front door open, throwing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9273" data-gh-pr="9273">per-game input profile support</a> in our faces, and leaving, refusing to elaborate further. A real Chad.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./input.png" title=" Right-click game &gt; Properties &gt; Input Profiles"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2022/input_hu80ed239af2ff3d7350dfbffea818058c_221107_902x0_resize_q90_bgffffff_box_3.jpg" alt=" Right-click game &gt; Properties &gt; Input Profiles"></a> <p class="has-text-centered is-italic has-text-grey-light"> Right-click game &gt; Properties &gt; Input Profiles</p> </div> </div> <p>This feature uses previously created input profiles, make sure to create some in <code>Emulation &gt; Configure... &gt; Controls</code> beforehand.</p> <h2 id="future-projects">Future projects</h2> <p>There’s a <em>lot</em> going on behind closed doors, but it’s too early to start teasing you. We can confirm that both <code>Project Gaia</code> and <code>Project Y.F.C. Part 2</code> are progressing healthily, but those are not the only important changes in the oven.</p> <p>Personally, I’m helping implement SMAA, but what started as just a rebase of <a href="https://github.com/breadfish64">BreadFish&rsquo;s</a> OpenGL implementation ended up being more than a week of extra work dealing with the Vulkan implementation, taking precious time from the already busy schedule byte[] has. Sorry! But the result was worth it. We&rsquo;ll talk about it next month, as it didn&rsquo;t make the cut for this report&rsquo;s timeframe.</p> <p>That’s all folks! Thank you so much for giving us a bit of your time, and we hope to see you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report October 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/ Sun, 06 Nov 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/ <p>Greetings, dear yuz-ers! What a month we&rsquo;ve had. A dozen graphical fixes, big kernel changes, audio, input and amiibo fixes, and more! Don’t touch that dial, because we&rsquo;re just getting started!</p> <p>Greetings, dear yuz-ers! What a month we&rsquo;ve had. A dozen graphical fixes, big kernel changes, audio, input and amiibo fixes, and more! Don’t touch that dial, because we&rsquo;re just getting started!</p> <h2 id="graphics-and-general-bug-fixes">Graphics and general bug fixes</h2> <p>Let’s start with the meaty part. New month, new games to fix!</p> <p><code>Persona 5 Royal</code>, one of two blockbuster releases this month, launched with some mysteriously black battle scenes in Vulkan. <a href="https://github.com/vonchenplus">vonchenplus</a> identified this as missing support for special OpenGL-style clear commands which are not supported by the Vulkan specification, and added a workaround to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9127" data-gh-pr="9127">skip clearing</a> in this case. More work remains to be done to properly implement these clears in Vulkan, but this allows the game to be playable.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/p5bug_hu70b6252cafdfd587f77ef6e45d0b9367_298497_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Joker, no stealing the screen! (Persona 5 Royal)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/p5fix_hu4e3541e1ae773713050071ae6084ed24_6317375_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Joker, no stealing the screen! (Persona 5 Royal)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Joker, no stealing the screen! (Persona 5 Royal)</p> <p>Longtime graphics contributor <a href="https://github.com/FernandoS27">Blinkhawk</a> <a href="https://www.youtube.com/watch?v=sOnqjkJTMaA">has returned from the dead</a> to fix games. The other major release of this month, <code>Bayonetta 3</code>, came out, and to users&rsquo; dismay, it did not work in yuzu. After defeating the services issue causing it to freeze, Blinkhawk investigated and fixed a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9155" data-gh-pr="9155">rendering issue</a> causing it to appear white in Vulkan.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/bayobug_hu45d21ab551aa801c1a6b94ba1230ed18_5147991_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Is this Paradiso? (Bayonetta 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/bayofix_huc55dabb8f8429dfd415b29f8885c6757_6449703_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Is this Paradiso? (Bayonetta 3)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Is this Paradiso? (Bayonetta 3)</p> <p>A new challenger approaches! Or rather, a new showing from some older games, <code>Super Mario Sunshine</code> and <code>Super Mario Galaxy</code>. While rendering bugs were fixed in Vulkan, and OpenGL with the GLSL backend, they are now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9011" data-gh-pr="9011">fixed with the NVIDIA-exclusive GLASM backend,</a> as <a href="https://github.com/liamwhite">byte[]</a> finally acquired some NVIDIA hardware for testing and development.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/smgbug_hu11bde774a40d69b8d6e140756398885c_1807271_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Best. Music. Ever! (Super Mario Galaxy)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/smgfix_hu11bde774a40d69b8d6e140756398885c_1838581_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Best. Music. Ever! (Super Mario Galaxy)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Best. Music. Ever! (Super Mario Galaxy)</p> <p>An NVIDIA card is not the only new hardware acquired by byte[] this month. He also acquired an Intel Arc A770 16GB, and used it to track down a driver issue. Despite passing all of our validation tests, the Vulkan driver is unable to compile the ASTC decoder used by yuzu, and yuzu unconditionally compiles it at startup. Therefore, byte[] has <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9097" data-gh-pr="9097">skipped compiling it if CPU decoding for ASTC is used</a> instead, and filed a <a href="https://github.com/IGCIT/Intel-GPU-Community-Issue-Tracker-IGCIT/issues/159">report to Intel for their reference</a>. This allows yuzu to boot games in Vulkan when using the Intel Arc Windows Vulkan drivers.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./arc.png" title=" Blue Player joins the fray! (Super Mario 3D World &#43; Bowser&#39;s Fury)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/arc_hu2c06d98d1a4e9dd82a14bc1020a34051_1500543_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Blue Player joins the fray! (Super Mario 3D World &#43; Bowser&#39;s Fury)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Blue Player joins the fray! (Super Mario 3D World &#43; Bowser&#39;s Fury)</p> </div> </div> <p>byte[] also found and investigated two issues with the macro JIT this month. The macro JIT is an optimization which recompiles small programs that are uploaded to the GPU to control drawing into native machine code. The first issue he resolved allowed homebrew applications using the <a href="https://github.com/devkitPro/deko3d">deko3d</a> rendering API to finally <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9005" data-gh-pr="9005">become visible with the macro JIT enabled.</a> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./deko1.png" title=" Better than NVN, it&#39;s free!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/deko1_hu7b467937bd5f198bc6ae3bb495c9c6cd_83868_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Better than NVN, it&#39;s free!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Better than NVN, it&#39;s free!</p> </div> </div> <p>The second issue was causing <code>MONSTER HUNTER RISE</code> to fail to render most scene elements. yuzu has had a workaround in Mainline for <a href="https://github.com/yuzu-emu/yuzu/pull/6598">over a year!</a> However, this papered over this issue, which is why it took so long to get fixed. byte[] fixed this issue as well, and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9010" data-gh-pr="9010">now all is working as intended</a> &ndash; there are no more known issues with the macro JIT!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/mhrbug_hu03d323d73736d1a5e3af75734a00a1e7_2000108_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Someone put a world in my ocean (MONSTER HUNTER RISE)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/mhrfix_hu6a35ec48ce698871487f46b2631600be_2868038_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Someone put a world in my ocean (MONSTER HUNTER RISE)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Someone put a world in my ocean (MONSTER HUNTER RISE)</p> <p>Unfortunately, fixing the accuracy issues in the macro JIT has caused <code>Xenoblade Chronicles 3</code> to crash at boot with official AMD Vulkan drivers used on Windows and opt-in on Linux (amdvlk). This issue previously manifested with the macro JIT disabled, and occurs due to a crash that happens when submitting a clear command. We have reported this as a driver issue to AMD, and they have confirmed they&rsquo;re looking into the issue. While we wait for the fix, using OpenGL while running the game on 2x scaling can be a workaround.</p> <p>Speaking of <code>MONSTER HUNTER RISE</code>, Blinkhawk contributed another fix for the rendering in this game, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9025" data-gh-pr="9025">implementing the ASTC 10x5 format.</a> Grainy textures begone!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/mhr2bug_hue90c2878a79b76938c2cb9c110b5745b_16673870_1024x0_resize_q90_bgffffff_box_3.jpg" alt="ASTC acne, begone! (MONSTER HUNTER RISE)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/mhr2fix_hu057f38f689771d7d562815e741e6a202_13573321_1024x0_resize_q90_bgffffff_box_3.jpg" alt="ASTC acne, begone! (MONSTER HUNTER RISE)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">ASTC acne, begone! (MONSTER HUNTER RISE)</p> <p>byte[] found that while he was debugging graphical issues, yuzu would frequently crash after the merge of <code>Project Y.F.C.</code> He narrowed it down to some code that was improperly ported from our friends at the <a href="https://github.com/skyline-emu/skyline">Skyline emulator</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9049" data-gh-pr="9049">and implemented a fix,</a> finally allowing him to debug without worrying about the game&rsquo;s rendering speed causing any issues. Now, a user’s PC performance won’t be a cause for crashes.</p> <p><a href="https://github.com/Kelebek1">Maide</a> and <a href="https://github.com/Morph1984">Morph</a> were on top of two regressions from the merge of the <a href="https://github.com/yuzu-emu/yuzu/pull/8766">3D registers pull request</a> from a few months ago. Morph found that the merge was causing many shaders to be recompiled unintentionally, and narrowed it down to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9067" data-gh-pr="9067">a different default value for the tessellation parameters in the register definitions.</a> </p> <p>Meanwhile, Maide and byte[] worked together to find a strange rendering problem affecting <code>Luigi's Mansion 3</code>, and finally found the issue in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9048" data-gh-pr="9048">the values of the stencil mask registers.</a> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/lm3bug_hu9d3861468cfa2ca527f5a037e7a93f2b_1978432_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi saw how much an RTX 4090 costs (Luigi&#39;s Mansion 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/lm3fix_huda576a16d2dff33c9280e25d04032998_1981810_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi saw how much an RTX 4090 costs (Luigi&#39;s Mansion 3)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Luigi saw how much an RTX 4090 costs (Luigi&#39;s Mansion 3)</p> <p>vonchenplus found an issue with how a compute shader for <code>TRIANGLE STRATEGY</code> was being compiled by yuzu&rsquo;s own shader recompiler project, and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9126" data-gh-pr="9126">implemented a fix by deleting a broken optimization pass,</a> returning blocky rendering to normal.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/prbug_hufb89c357575796870da78540a4934255_1207919_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Project Rectangle, I mean, TRIANGLE STRATEGY"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/prfix_hue7489fc5838bb17e24719286badb4b35_1162584_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Project Rectangle, I mean, TRIANGLE STRATEGY"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Project Rectangle, I mean, TRIANGLE STRATEGY</p> <p>Still on a roll, vonchenplus also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9084" data-gh-pr="9084">implemented 1D texture copies.</a> Normally, the guest driver (the GPU driver included with each game) has to provide what kind of texture type is in use in memory, but thanks to the previously mentioned open documentation NVIDIA provides, we now know that there is a way to set the correct kind when the memory is initialized. The end result is much improved rendering in <code>Snack World: The Dungeon Crawl - Gold</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/sw2bug_hu0ebd0927efbb8a54b75275b8a7117327_813760_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Almost looks like a 3D TV without glasses (Snack World: The Dungeon Crawl - Gold)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/sw2fix_hudf11827914d14ba1e6b39122e6150faf_712120_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Almost looks like a 3D TV without glasses (Snack World: The Dungeon Crawl - Gold)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Almost looks like a 3D TV without glasses (Snack World: The Dungeon Crawl - Gold)</p> <p>With Blinkhawk back, the team can finally start nagging him to fix his changes, more specifically, <code>Project Y.F.C.</code> Part 1. After <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9095" data-gh-pr="9095">addressing some semaphores and cache flush regressions,</a> Blinkhawk fixed the remaining glitches affecting the ink logic in <code>Splatoon 2</code> and the models flickering in the ATM in <code>Animal Crossing: New Horizons</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./blink.png" title=" Long vacations"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/blink_hub3e91b1f15a290fc4c26e750cbfc2125_396873_500x0_resize_q90_bgffffff_box_3.jpg" alt=" Long vacations"></a> <p class="has-text-centered is-italic has-text-grey-light"> Long vacations</p> </div> </div> <p>byte[]&rsquo;s kernel and services work this month has been focused on getting homebrew running, but this also fixed some graphical issues. The first major accomplishment was getting homebrew to run consistently in the first place. byte[] noticed that launching homebrew in yuzu would often cause the entire emulator to lock up in almost 50% of attempts - but only when using Vulkan. After enabling validation layers, and some careful investigation of the messages, he found and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9016" data-gh-pr="9016">fixed a subtle race condition in Vulkan queue submission,</a> finally enabling homebrew apps to work reliably with Vulkan.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./deko2.png" title=" You could say that unit tests are at the heart of emulation development"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/deko2_hu37d4a6e830bf85251543c818f4dac0ca_23620_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" You could say that unit tests are at the heart of emulation development"></a> <p class="has-text-centered is-italic has-text-grey-light"> You could say that unit tests are at the heart of emulation development</p> </div> </div> <p>vonchenplus has also been on the ball with homebrew support this month, gifting yuzu corrected support for instanced draws and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9112" data-gh-pr="9112">the zany inline index 3D registers,</a> fixing <a href="https://github.com/switchbrew/switch-examples">gpu_console</a> and allowing the <code>Sonic 1 (2013)</code> homebrew game to render in yuzu. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9140" data-gh-pr="9140">The usual slate</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9163" data-gh-pr="9163">of regressions</a> associated with these types of changes, this time affecting <code>Super Mario 64</code>, <code>Super Mario Galaxy</code>, <code>Xenoblade Chronicles 3</code>, and <code>Animal Crossing: New Horizons</code>, have also been identified and fixed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./console.png" title=" gpu_console, one of the examples available"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/console_hu5a83b585c401ce31574847fb2d088389_23656_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" gpu_console, one of the examples available"></a> <p class="has-text-centered is-italic has-text-grey-light"> gpu_console, one of the examples available</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./sanic.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Yes Doctor, all the nostalgia directly to my bloodstream (Sonic 1 2013)</p> </div> </div> <p>Finally, byte[] implemented a fix for the intense, seizure-inducing flickering produced when launching homebrew from the homebrew menu when Vulkan is enabled, which <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9154" data-gh-pr="9154">was caused by not recreating the images intended for presentation.</a> Now, you can launch console homebrew from the homebrew menu, just like on the Switch!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hbmenu.png" title=" Emulating hacked consoles is so hot right now"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/hbmenu_huc3b745715e0dd5e3b0b66de38069a3ef_258586_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Emulating hacked consoles is so hot right now"></a> <p class="has-text-centered is-italic has-text-grey-light"> Emulating hacked consoles is so hot right now</p> </div> </div> <p>Switching topics to a minor (but quite annoying) issue, we have a quality of life improvement from byte[]. In the past, writing screenshots taken in yuzu to disk would noticeably block rendering the game. The user would perceive this as a relatively short freeze (the length of this freeze varies according to the size of the resolution multiplier used). byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9024" data-gh-pr="9024">made this fully asynchronous,</a> allowing for smooth gameplay even during particularly intensive photo shoots.</p> <h2 id="cpu-kernel-services-and-core-fixes">CPU, Kernel, services, and core fixes</h2> <p>A fix for CoreTiming accuracy from a few months ago, as part of <a href="https://github.com/yuzu-emu/yuzu/pull/8650">Pull Request #8650</a>, was added to intentionally waste CPU cycles until a certain amount of time had passed, due to extremely poor support in Windows for high precision timing events. But in Linux, this fix isn&rsquo;t needed, as Linux natively supports high-precision delays. byte[] modified the behavior, allowing Linux users to take advantage of this and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9040" data-gh-pr="9040">lower the high CPU usage.</a> Remember when we say that yuzu is faster on Linux? This is a great example of what we mean.</p> <p><code>No Man's Sky</code> was released and our tester, <a href="https://github.com/Law022">Law</a>, found that it could boot with auto-stubbing enabled. byte[] investigated the log file and stubbed the previously unimplemented calls, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9032" data-gh-pr="9032">CheckFriendListAvailability</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9033" data-gh-pr="9033">GetCacheStorageSize,</a> allowing <code>No Man's Sky</code> to boot.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./nms.png" title=" Still the best screensaver"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/nms_hudee1a27772151d7dd0352748ca0d8a37_3822232_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Still the best screensaver"></a> <p class="has-text-centered is-italic has-text-grey-light"> Still the best screensaver</p> </div> </div> <p><code>Bayonetta 3</code>&rsquo;s release caused some issues that were tricky to track down. Your resident <a href="https://github.com/bunnei">bunnei</a> rabbit properly implemented <code>ListOpenContextStoredUsers</code>, and the related <code>StoreOpenContext</code> which is used to set stored opened user profiles. <code>ListOpenContextStoredUsers</code> was causing <code>Bayonetta 3</code> to crash on startup. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9157" data-gh-pr="9157">Fixing the stubs</a> allowed the game to finally boot, and while it is now playable, it is quite slow still. Stay tuned for performance optimizations that will benefit this game!</p> <p><a href="https://github.com/german77">german77</a> took part in the fun, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9149" data-gh-pr="9149">stubbing the SetRecordVolumeMuted service,</a> allowing the game to boot.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bayo.png" title=" Hot protagonists in your area (Bayonetta 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/bayo_hu0c72031b3f0b7fc4d66bbb1b33bade81_11308440_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Hot protagonists in your area (Bayonetta 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hot protagonists in your area (Bayonetta 3)</p> </div> </div> <p>Another notable release from bunnei this month was the start of the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9071" data-gh-pr="9071">multiprocess project.</a> Since the very beginning, yuzu has only ever supported a single-process architecture, as games only ever use one process on the Switch. However, to help improve yuzu&rsquo;s accuracy for Switch software, yuzu has been focusing on getting key operating system features working, and one of the most important is multiprocess support, since this corresponds to how Switch software actually works.</p> <p>byte[] and bunnei have been hard at work getting certain prerequisites available for multiprocess support. One of those is <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9055" data-gh-pr="9055">support for server sessions,</a> needed for the <code>nx-hbloader</code> homebrew. This is used on the Switch to launch homebrew, and is needed for homebrew that do not work when launched directly from their NRO file.</p> <p>Additionally, byte[] needed to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9137" data-gh-pr="9137">fix several services,</a> as the previous stub implementations had assumed that they would never be torn down. With these changes, and the associated graphical fixes, <code>nx-hbloader</code> and <code>nx-hbmenu</code> now finally work as intended! To use them, you can extract <code>hbl.nsp</code> and <code>hbmenu.nro</code> from your Atmosphere installation. Place <code>hbmenu.nro</code> in yuzu&rsquo;s SD card directory, and then launch <code>hbl.nsp</code>, and the homebrew menu will boot.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./hbmenu.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> They launch now (Homebrew menu and Sonic 1 2013)</p> </div> </div> <p>Let’s talk about amiibos. Amiibo data is stored both encrypted and as plain data. To access the encrypted portion, a key dump is required, but not all games use the encrypted portion and are just fine with the plaintext available. For those cases, german77 now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9113" data-gh-pr="9113">marks amiibos as read-only if no key dumps are available.</a> This won’t replace dumping your amiibo keys if a game needs it, but many games will be fine with just a basic level of read-only detection.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./amiibo2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/amiibo2_hu673f3184c019c07e20b3905f6904d0a3_2492816_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Gidoly and german77 for the pics!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./amiibo3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/amiibo3_huc67195a9687146858b729bddf7575dab_2156306_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Gidoly and german77 for the pics!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./amiibo1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/amiibo1_hu56affa5b5837bc78d3253b326b30462a_964278_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Gidoly and german77 for the pics!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Thank you Gidoly and german77 for the pics!</p> <h2 id="input-improvements">Input improvements</h2> <p>yuzu performs vibration tests every time a game initializes a controller for vibration, but the problem (there’s always a problem) is that some controllers take longer than others to respond. Previously, a fixed 15ms delay was implemented, because some controllers simply needed that much time to respond. If the game performs successive vibration tests, the game is delayed until the controller responds, which results in a reduced framerate, for example, from 60 to 32 FPS. All that performance being lost waiting on a bad quality controller is a tragedy.</p> <p>So, a better middle ground is needed. Thankfully, german77 came up with a much smarter solution. Instead of repeating the test each time, it’s better to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9107" data-gh-pr="9107">cache it the first time and return that same result afterwards.</a> A nice, free, performance boost for those of us who use generic controllers.</p> <p>Newcomer <a href="https://github.com/ZwipZwapZapony">ZwipZwapZapony</a> (love the name) <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9008" data-gh-pr="9008">fixed a copy-paste oopsie in how left and right controller colours are identified.</a> Thank you!</p> <h2 id="audio-changes">Audio changes</h2> <p>Have you ever noticed how in motherboard BIOS/UEFI settings, the <code>Auto</code> option seems to do nothing, and instead simply reflects the first option available in the list? Well, we cheated exactly like that for years. The <code>Auto</code> audio backend option only selected <code>cubeb</code> every time by default. The shame. Maide found out that some audio devices incur a huge latency when using <code>cubeb</code>, so he decided to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9039" data-gh-pr="9039">perform a latency test</a> and select either <code>cubeb</code> or <code>SDL</code> based on the results.</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> then <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9080" data-gh-pr="9080">addressed a regression</a> caused by this change, avoiding a crash.</p> <p>New Switch firmware versions usually come with their fair share of new services and additions, so in an effort to avoid potential problems in future games, Maide <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9096" data-gh-pr="9096">implemented some new parameters</a> that Nintendo added to their audio core with firmware 15.0.0.</p> <h2 id="user-interface-improvements">User interface improvements</h2> <p>Some users prefer displays closer to the <a href="https://en.wikipedia.org/wiki/Golden_ratio">golden ratio</a>, the glorious 16:10 aspect ratio. While Switch games are not intended to be played outside the standard 16:9 aspect ratio, some users are fine with stretching the image to fill their whole display, even if it means some slight distortion. This has been increasingly popular with the release of the Steam Deck, which uses a 16:10 display, sporting a 1280x800 resolution. There’s also the option of the community coming up with different aspect ratio mods for each game, allowing for proper use of those nice extra pixels. german77 took the time to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9047" data-gh-pr="9047">add this new option to the aspect ratio list,</a> which you can find in <code>Emulation &gt; Configure… &gt; Graphics &gt; Aspect Ratio</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./aspectratio.png" title=" I&#39;m personally not a fan of stretching, long live the black bars"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/aspectratio_hu897d613ee5e25ea00cdc7c50b4d11918_33658_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" I&#39;m personally not a fan of stretching, long live the black bars"></a> <p class="has-text-centered is-italic has-text-grey-light"> I&#39;m personally not a fan of stretching, long live the black bars</p> </div> </div> <p><a href="https://github.com/Docteh">Docteh</a>, Morph, and <a href="https://github.com/lioncash">lioncash</a> (who diverted some time from the usual, making sure all PRs submitted to yuzu are sane) had their <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9076" data-gh-pr="9076">fair share</a> of fixing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9079" data-gh-pr="9079">spelling mistakes.</a> Happens to the best of us.</p> <p>In an effort to help reduce user confusion while we rework our compatibility reports, Docteh added a new option to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9091" data-gh-pr="9091">hide the compatibility rating column</a> from the game list by default. Anyone interested in reverting it back can find it in <code>Emulation &gt; Configure… &gt; General &gt; UI &gt; Show Compatibility List</code>. Keep in mind, reports will not be accurate while we work to implement the new report system.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./compat.png" title=" We&#39;re working to solve all those Not Tested reports"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/compat_hu93a0a4b5bed7d1d43b0f76014c5e629f_30643_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We&#39;re working to solve all those Not Tested reports"></a> <p class="has-text-centered is-italic has-text-grey-light"> We&#39;re working to solve all those Not Tested reports</p> </div> </div> <p>Not everyone prefers to have their games listed in English in the game list, many would rather have them in their native language, or at least another option from the official languages the Switch supports. vonchenplus worked to solve this, and now yuzu <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9115" data-gh-pr="9115">prioritizes displaying the games in the user selected language.</a> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/langbug_hue5b55727134c674acfd9ba92877441dc_100962_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Even if working online forces you to constantly use English, reading in your native language is always the best"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/langfix_hu89985859550801d08ecb12c6b111b36c_99088_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Even if working online forces you to constantly use English, reading in your native language is always the best"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Even if working online forces you to constantly use English, reading in your native language is always the best</p> <h2 id="hardware-section">Hardware section</h2> <p>This section will be short this month as most things are in progress!</p> <h4 id="amd-wip">AMD, WIP</h4> <p>As we said previously, we got confirmation from AMD that they are looking into the cause for the crashes at boot now affecting <code>Xenoblade Chronicles 3</code>, along with other previously reported fixes.</p> <p>Future drivers will be fun to test.</p> <h4 id="nvidia-one-step-closer">NVIDIA, one step closer</h4> <p>We’re making some slow progress in the matter of stability problems affecting Maxwell and Pascal cards. It’s too early to promise anything, so we’ll keep you updated. In the meantime, if you MUST run the latest drivers, use OpenGL.</p> <p>Hopefully the next mid-range cards won&rsquo;t be the same cost as an entire PC.</p> <h4 id="intel-arc-lets-go">Intel Arc, let’s go!</h4> <p>With games now working on Vulkan thanks to byte[], we only need proud owners of Team Blue cards reporting issues on our GitHub. Message to Intel: there are sales outside of Europe, China, and the USA. Please start shipping already so your writer can start testing…</p> <p>This goes for you too, GabeN.</p> <h2 id="future-projects">Future projects</h2> <p>With all the regressions caused by the first part of <code>Project Y.F.C.</code>, Blinkhawk has started providing internal testers with the first test builds of some of the changes Part 2 will include. As with any first try, there are of course regressions, but some long-standing issues are already fixed in these builds, so expect more news in future articles.</p> <p>Not forgetting our file system rewrite, <code>Project Gaia</code>, Morph implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9082" data-gh-pr="9082">support for the incoming save data path structure.</a> Work on <code>Gaia</code> continues, some roadblocks were hit, slowing progress down, but Morph pushes on.</p> <p>Special thanks to Mysterious Writer B for their big help while your writer is half dead dealing with classes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./byte.png" title=" He&#39;s Vengeance. He&#39;s the Night"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2022/byte_hu4fdc8c014ba453285cd368aaef52271b_297921_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" He&#39;s Vengeance. He&#39;s the Night"></a> <p class="has-text-centered is-italic has-text-grey-light"> He&#39;s Vengeance. He&#39;s the Night</p> </div> </div> <p>That’s all folks! Thank you for your time and see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report September 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/ Tue, 18 Oct 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/ <p>Hello yuz-ers! We have so much to talk about this month. From game fixes, input changes, and quality of life improvements, to new gameplay options available to everyone!</p> <p>Hello yuz-ers! We have so much to talk about this month. From game fixes, input changes, and quality of life improvements, to new gameplay options available to everyone!</p> <h2 id="project-london-open-source-online-local-wireless-emulation">Project London: open-source, online Local Wireless emulation</h2> <p>As promised in the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/#future-projects">previous progress report</a>, and explained in its <a href="https://yuzu-mirror.github.io/entry/ldn-is-here/">dedicated article</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8876" data-gh-pr="8876">LDN support is here and available to all users!</a> Enjoy pwning some noobs in your favourite games. But before we explain the how, let&rsquo;s cover some theory.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./comm.png" title=" Available multiplayer methods on the Nintendo Switch"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/comm_huff96b8f7a7fc024f356f04fe93630f03_69367_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Available multiplayer methods on the Nintendo Switch"></a> <p class="has-text-centered is-italic has-text-grey-light"> Available multiplayer methods on the Nintendo Switch</p> </div> </div> <p>The Nintendo Switch offers 4 methods for multiplayer gameplay:</p> <ul> <li>Good, old, couch <em>local multiplayer</em>. While this normally only refers to people in the same physical room, the community has been enjoying the benefits of remote access streaming, with services like <a href="https://parsec.app/">Parsec</a>, to play online with the lowest possible latency.</li> <li>Local Area Network (LAN) multiplayer. This is when multiple Switches connect to the same local network. This option has been emulated and available in yuzu <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/#lan-party-time">for quite a while now</a>. It’s limited to very few games, and it doesn’t have good tolerance for lag.</li> <li>LDN multiplayer, more commonly known as Local Wireless, the star of this section. This is when one Switch hosts a session over the built-in Switch WiFi hardware while others connect to it as guests. The trick here is that nothing stops emulators from using a server infrastructure to host rooms so users from anywhere in the world, including locally, can join and smash each other. This method is far more supported by games than LAN.</li> <li>Nintendo Online. This is the paid Nintendo service to play online, which also includes other bonuses such as official emulators to play older titles. We have no plans to offer support for Nintendo Online in the near or far future.</li> </ul> <p><code>Project London</code> includes full support for LDN, with room hosting and joining, and revamps our LAN support to use the new LDN code in place.</p> <p>Now, let&rsquo;s get to the fun part: how to use it!</p> <p>A user can launch the <code>Public Room Browser</code> by selecting the <code>Multiplayer</code> option in the Menu Bar and then selecting <code>Browse Public Game Lobby</code>, or by clicking the status bar tip in the bottom right labeled <code>Not Connected. Click here to find a room!</code></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ldn.png" title=" The new Multiplayer submenu"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/ldn_hu7175ff7b2eb91374673bdfa695e80555_93209_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The new Multiplayer submenu"></a> <p class="has-text-centered is-italic has-text-grey-light"> The new Multiplayer submenu</p> </div> </div> <p>From there, double-clicking a room will allow the user to join it. Keep in mind, the <code>Preferred Game</code> is just a suggestion and there is no hard restriction on which games can be played in a room. Please keep this in mind when joining public lobbies and be courteous to your fellow yuz-ers! Any rooms that are user-hosted may enforce this by kicking players or locking their room.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./rooms.png" title=" A lock means it&#39;s a password protected room"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/rooms_hue60721399f28e0fbba6e5f3ce5a390fc_65542_905x0_resize_q90_bgffffff_box_3.jpg" alt=" A lock means it&#39;s a password protected room"></a> <p class="has-text-centered is-italic has-text-grey-light"> A lock means it&#39;s a password protected room</p> </div> </div> <p>Speaking of user-hosted rooms, the <code>Create Room</code> option in the <code>Multiplayer</code> menu allows users to host their own rooms, with custom player limits and optional password security. Some ports need to be forwarded in the host’s router/modem configuration, so please <a href="https://yuzu-mirror.github.io/help/feature/multiplayer/">follow our guide here</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./create.png" title=" Feel free to host any game you want!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/create_hu54a1fac684774618b57eb35732721216_10220_609x0_resize_q90_bgffffff_box_3.jpg" alt=" Feel free to host any game you want!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Feel free to host any game you want!</p> </div> </div> <p>Once a player joins a room, they can chat with other members, see the game they are running, and very importantly, the game versions other players are using. Most games tend to only work when all players run the same game update version, so remember to dump the latest from your Switch!</p> <p>It’s not mandatory to join a room before starting a game in yuzu, but it is recommended. At the moment, only LAN supports connecting with real Switches. LDN is yuzu to yuzu only, but we’re working to include native Switch support for LDN sometime in the future.</p> <p>So far, very few games have issues with LDN. Only <code>Super Mario Maker 2</code>, <code>Mario Golf: Super Rush</code> and <code>DRAGON BALL FighterZ</code> have been reported as incompatible. Any other local wireless compatible game should work fine, but don’t be shy to report any issues should you discover them.</p> <p>One bit of info, <code>Super Smash Bros. Ultimate</code> has a hardcoded 6 frames of delay when playing over LDN. This is supposedly to “help buffer” the latency expected from online and WiFi gameplay. While the ideal solution is to play in local multiplayer with Parsec (no forced delay on local play), not everyone has good upload speeds to host, or is comfortable with giving remote access to their computer.</p> <p>An alternative is available: run the game at 120 FPS, reducing the delay to only 3 frames instead. For this, all users in the room must do two things:</p> <ul> <li>Install the 120 FPS mod <a href="https://cdn.discordapp.com/attachments/402001453381713920/1018356262582354091/120.rar">available here</a>. Right click the game in yuzu’s game list and select <code>Open Mod Data Location</code>, then place <em>the folder</em> of the compressed file in the location that yuzu opens.</li> <li>Set game speed to 200%. This can be set on a per game basis with custom configurations. Right click the game in yuzu’s list like before and select <code>Properties</code> &gt; <code>General</code> tab &gt; set the <code>Limit Speed Percent</code> to a blue enabled value (this means it’s a custom value, ignoring the default one) &gt; change it to 200%.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./200.png" title=" Reducing input lag by running things faster, life hacks"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/200_hudae14893eef76f918f7841cf613e59fc_215839_902x0_resize_q90_bgffffff_box_3.jpg" alt=" Reducing input lag by running things faster, life hacks"></a> <p class="has-text-centered is-italic has-text-grey-light"> Reducing input lag by running things faster, life hacks</p> </div> </div> <p>Some GPU power is required to sustain 120 FPS, as such, our minimum hardware recommendations may not cut it (an RX 550 falls under 100 FPS in 1v1 fights), but modern low/mid-end hardware should be fine. Testing also shows that AMD Windows drivers can only reach framerates higher than 60 if the display supports it. We reported the issue to AMD, hopefully in the future this doesn’t force users to get high refresh rate monitors.</p> <p>And that’s it! Join rooms, both in yuzu and in game, and fight! Or trade those Pokémon, your call. This endeavour was possible thanks to the <a href="https://github.com/spacemeowx2/ldn_mitm">ldn_mitm project</a> who provided us a licence exemption, and the work done by <a href="https://github.com/FearlessTobi">Tobi</a> and <a href="https://github.com/german77">german77</a>, along with the testers (your writer included) who never had so much fun crashing games in the name of progress.</p> <p>After the Mainline release, Linux users reported that LDN rooms refused to work on some Linux distributions. The issue is in how the SSL package is distributed. <a href="https://github.com/lat9nq">toastUnlimited</a>, taking reference from a previous pull request from <a href="https://github.com/Docteh">Docteh</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8933" data-gh-pr="8933">fixed the issue</a> so now all supported operating systems can enjoy LDN.</p> <p>Some users reported crashes when playing <code>Pokémon Sword/Shield</code>. While we implement the correction for it, make sure that a valid network device is selected in <code>Emulation &gt; Configure… &gt; System &gt; Network &gt; Network Interface</code>. The crash seems to happen when <code>None</code> is set as the network interface.</p> <h2 id="graphic-changes">Graphic changes</h2> <p>NVIDIA OpenGL users may have seen some strange graphical glitches in games like <code>Dragon Quest Builders</code>, <code>SNACK WORLD: THE DUNGEON CRAWL</code>, and <code>Pixel Game Maker Series Werewolf Princess Kaguya</code> due to an oversight in yuzu&rsquo;s handling of the performance-enhancing <code>vertex_buffer_unified_memory</code> extension. <a href="https://github.com/vonchenplus">vonchenplus</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8874" data-gh-pr="8874">swooped in with a fix,</a> and these games now render as they should.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/dqbug_huef721249acbf2db39da2db79a1ff2a65_1524189_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Dragon Quest Builders"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/dqfix_hu8d02d1a6edae1c33455c4701644b42bd_1494905_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Dragon Quest Builders"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Dragon Quest Builders</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/swbug_hud4ebf80b2ce7ca03d3ee3115f9191e21_944274_1024x0_resize_q90_bgffffff_box_3.jpg" alt="SNACK WORLD: THE DUNGEON CRAWL"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/swfix_hu46cc418325e7b3189b22cad67649576a_2284039_1024x0_resize_q90_bgffffff_box_3.jpg" alt="SNACK WORLD: THE DUNGEON CRAWL"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">SNACK WORLD: THE DUNGEON CRAWL</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/wpbug_hu7f463b46cb3cc19e398fad21dedde735_140078_954x0_resize_q90_bgffffff_box_3.jpg" alt="Pixel Game Maker Series Werewolf Princess Kaguya"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/wpfix_hu351ec4e02531791fde51bfda25c59166_158786_950x0_resize_q90_bgffffff_box_3.jpg" alt="Pixel Game Maker Series Werewolf Princess Kaguya"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pixel Game Maker Series Werewolf Princess Kaguya</p> <p>Users may have noticed an intriguing square moon in <code>Live a Live</code>. This is caused by the texture cache not correctly synchronizing ASTC textures that the game is using to all layers, so vonchenplus added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8910" data-gh-pr="8910">a workaround to avoid filling the extra invalid layers with an error colour,</a> which changes the moon back to the round shape we all love.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/lalbug_hua1ad5e98a8e435eee6637f11d72f15a7_1429085_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Not exactly a Red Moon, dood! (Live a Live)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/lalfix_hu67a5e6e0a6586bff5e33e48c63f90ff9_1431297_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Not exactly a Red Moon, dood! (Live a Live)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Not exactly a Red Moon, dood! (Live a Live)</p> <p>Some systems, like Steam, don&rsquo;t like yuzu&rsquo;s behaviour of spawning a new process to check for working Vulkan support. toastUnlimited updated the Vulkan checker with a configuration option to, well, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8930" data-gh-pr="8930">stop checking,</a> allowing those systems to function the same as with older yuzu builds.</p> <p>After three months of regression solving and the usual nasty delays, <code>Project Y.F.C.</code> Part 1 is finally merged to Mainline! You can find more information about it, as well as what’s expected in the near future for Part 2 <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/#part-1-of-project-yfc">here</a>.</p> <p>One regression remains, for now. It affects certain puzzles in the single player mode of <code>Splatoon 2</code>. While Part 2 is in development, users affected by this problem should stick to <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/tag/mainline-0-1190">Mainline version 1190</a>.</p> <p>We mentioned last month about trying to push more aggressive <code>Staging Buffer</code> values in order to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8987" data-gh-pr="8987">benefit GPU users that can enable Resizable BAR/Smart Access Memory</a> (or ReBAR/SAM). While the option did get merged briefly with Mainline 1189, users quickly reported both big performance gains and losses, with no correlation to which GPU/CPUs were in use. This change seems to be very platform specific, and the average tilts towards performance losses, so <a href="https://github.com/liamwhite">byte</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/9027" data-gh-pr="9027">reverted it.</a> </p> <p>It’s been a while since <a href="https://github.com/Morph1984">Morph</a> dabbled in graphics work. <code>.hack//G.U. Last Recode</code> was unable to boot due to excessive vsync event calls. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8992" data-gh-pr="8992">Limiting the event to only once per display</a> allows this <code>.hack</code> to finally boot and play.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hack.png" title=" .hack//G.U. Last Recode"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/hack_hu20bfdc29d8a0eb7a7f5acaddafd90613_1862147_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" .hack//G.U. Last Recode"></a> <p class="has-text-centered is-italic has-text-grey-light"> .hack//G.U. Last Recode</p> </div> </div> <h2 id="audio-changes">Audio changes</h2> <p>The cleanup for <code>Xenoblade Chronicles 3</code> from last month continues this month with <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8842" data-gh-pr="8842">a new audio pull request</a> from <a href="https://github.com/Kelebek1">Maide</a>. This fixed the audio desynchronization issue that some users were having during cutscenes. Previously, Maide&rsquo;s audio implementation sometimes had issues with the game audio producing samples too quickly for the host audio backend (SDL or Cubeb) to be able to play in time. Now, if the game starts producing too many samples, it will be temporarily paused until the audio backend catches up.</p> <p>Maide also implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8878" data-gh-pr="8878">a relatively large cleanup of the audio system</a> and how it relates to pausing and shutdown. Before <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8878" data-gh-pr="8878">Pull Request 8842,</a> the audio system had its own timer system for dealing with the backend that ran independently of yuzu&rsquo;s timer system, <code>CoreTiming</code>. Now that the synchronization issues when doing this were fixed, Maide removed the custom timer system to now run everything through <code>CoreTiming</code>, which correctly handles pausing and shutdown. The scaffolding for the audio system to be aware of pausing and shutdown was therefore no longer needed, and could be deleted.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xc3.png" title=" Xenoblade Chronicles 3"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/xc3_hu69b689d71cf26f302995cedb0f46f51b_4962705_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Xenoblade Chronicles 3"></a> <p class="has-text-centered is-italic has-text-grey-light"> Xenoblade Chronicles 3</p> </div> </div> <p>These audio changes did, however, come with a minor regression. In multi-core mode, timer callbacks are run on their own thread, which allows them to execute independently of the CPU cores. However, because yuzu tries to be deterministic in single-core mode, every timing callback and every emulated processor instruction in this mode is run from a single host thread. In single-core mode, this prevents the timer callbacks from being effectively paused, which causes the audio service to try to continuously pause the game to catch up. Maide worked around this issue by simply <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8941" data-gh-pr="8941">not pausing if single-core mode is enabled.</a> </p> <p>For once, Maide was not the only contributor to work on audio! vonchenplus noticed that the new <code>HwOpus</code> service, which is a service for optimized playback of Opus audio, didn&rsquo;t implement any of the multi-stream functionality needed for <code>Dragon Quest X</code> to boot. He <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8915" data-gh-pr="8915">added one new function that the game needed,</a> <code>GetWorkBufferSizeForMultiStreamEx</code>, and the game booted.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dqx.png" title=" Dragon Quest X"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/dqx_hu41d8fcfe0a1384c3f07b4f564e6a7756_1214289_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Dragon Quest X"></a> <p class="has-text-centered is-italic has-text-grey-light"> Dragon Quest X</p> </div> </div> <h2 id="core-emulation">Core emulation</h2> <p>yuzu is slowly but surely improving its ability to run homebrew applications. So when the team discovered that the <a href="https://github.com/HarbourMasters/Shipwright">Ship of Harkinian</a> homebrew (a PC port of <code>The Legend of Zelda: Ocarina of Time</code>) did not work correctly in yuzu, we were intrigued and tracked it down to a single missing service implementation. <a href="https://github.com/german77">german77</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8855" data-gh-pr="8855">added support for the <code>pl:s service</code>,</a> which is used for loading fonts, and the game now boots and renders, with frame interpolation up to 60 fps working correctly.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./oot.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Pure nostalgia, right click and enable audio (Ocarina of Time, Ship of Harkinian)</p> </div> </div> <p>In the realm of our &ldquo;other architecture&rdquo; news, <a href="https://github.com/liushuyu">liushuyu</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8904" data-gh-pr="8904">modified yuzu&rsquo;s CMake setup to be partly compatible with the ARM64 architecture.</a> This allows building the <code>yuzu-room</code> LDN server application for ARM64. Pi server, anyone?</p> <p>Stay tuned for future news regarding yuzu on ARM64&hellip;</p> <h2 id="input-changes">Input Changes</h2> <p>One of the longstanding issues with yuzu&rsquo;s input emulation was motion controls not working after the controller reconnects. Thanks to german77, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8847" data-gh-pr="8847">this has now been fixed.</a> This was happening because yuzu was only checking for motion controls when the controller first connected, but not on subsequent reconnections. Ensuring that yuzu checked for motion controls on every reconnection resolved this issue.</p> <p>Over the years, yuzu&rsquo;s input emulation had been missing support for emulating the popular <code>Pokéball Plus</code> controller. In his efforts to reverse engineer this, german77 found that most meaningful features for it were locked behind Nintendo Switch Online (NSO). Although this made him lose interest in it, he <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8934" data-gh-pr="8934">partially implemented support</a> for emulating this controller (including motion controls), thus opening it up for others to improve upon. For now, you can select this in <code>Pokémon Let's Go, Pikachu/Eevee!</code> and use it like any other controller, but loading data from it or writing data to it is NOT supported.</p> <p>Last month&rsquo;s Amiibo emulation support work also saw <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8955" data-gh-pr="8955">major improvements and bug fixes.</a> With these changes, Amiibo keys are now a mandatory requirement to read/write any data. This also fixed Amiibo support in games like <code>Shovel Knight</code> and <code>Super Smash Bros. Ultimate</code> among others.</p> <p>A minor <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8863" data-gh-pr="8863">bug within GameCube controller</a> input mapping which led to GC triggers overwriting the <code>ZL/ZR</code> buttons was fixed. And to further complement this fix, german77 also made <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8864" data-gh-pr="8864">analog input buttons toggleable</a> for extended usability.</p> <p>Accessibility is both very important and, sadly, very easy to ignore too. For example, something simple: what if a user needs more time to map buttons individually? In an effort to help with this particular case, the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8880" data-gh-pr="8880">button mapping timer duration</a> has been increased from <code>2.5 seconds</code> to <code>4 seconds</code>.</p> <h2 id="ui-changes">UI Changes</h2> <p>We also had a variety of UI improvements from multiple contributors this month.</p> <p>The old SD card icon has been <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8902" data-gh-pr="8902">replaced with a new colourful microSD Card icon</a> by <a href="https://github.com/Dev-draco">Dev-draco</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sdicon.png" title=" Small details matter"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/sdicon_hu99d2a21b9008005112f4252ecb6589c1_66289_848x0_resize_q90_bgffffff_box_3.jpg" alt=" Small details matter"></a> <p class="has-text-centered is-italic has-text-grey-light"> Small details matter</p> </div> </div> <p><a href="https://github.com/Tachi107">Tachi107</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8945" data-gh-pr="8945">fixed a few minor typos</a> within the yuzu source code.</p> <p>german77 modified the ordering of the input profiles saved in <code>Emulation &gt; Configure... &gt; Controls</code>. They are now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8948" data-gh-pr="8948">sorted by name.</a> </p> <p>While the colourful theme has been the default for a while, some icons remained in a &ldquo;Default&rdquo; theme directory. But as grabbing icons from other themes isn&rsquo;t supported on linux, this was broken. Docteh fixed this by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8906" data-gh-pr="8906">moving all the icons to the colourful theme.</a> </p> <p>Since the <code>Debug</code> configuration tab was getting crowded, Docteh <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8854" data-gh-pr="8854">made it scrollable.</a> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./scrollbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/scrollbug_hue8d6377963aa9cdd4a850f945f0b7544_44404_800x0_resize_q90_bgffffff_box_3.jpg" alt="While this change also helps Windows users, Linux users will benefit the most from it"></a> </div> <div class="column is-bottom-paddingless"> <a href="./scrollfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/scrollfix_hu21be59e2df39711675ccaea042170a85_45234_800x0_resize_q90_bgffffff_box_3.jpg" alt="While this change also helps Windows users, Linux users will benefit the most from it"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">While this change also helps Windows users, Linux users will benefit the most from it</p> <p>Docteh also fixed the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8909" data-gh-pr="8909">broken help page hyperlink on the <code>TAS</code> configuration window</a> .</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tas.png" title=" People seem to forget that blue underlined text indicates a hyperlink intended to be clicked"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/tas_hu7c6e3e866942815073ff422be603e4e5_15741_444x0_resize_q90_bgffffff_box_3.jpg" alt=" People seem to forget that blue underlined text indicates a hyperlink intended to be clicked"></a> <p class="has-text-centered is-italic has-text-grey-light"> People seem to forget that blue underlined text indicates a hyperlink intended to be clicked</p> </div> </div> <h2 id="miscellaneous">Miscellaneous</h2> <p>For a long time, any yuzu bug reports from Windows users had to be manually reproduced and investigated by the team. Linux users had the option of providing stack traces, but there wasn&rsquo;t an easy way for Windows users to provide similar debug info.</p> <p>To overcome this, toastUnlimited implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8682" data-gh-pr="8682">support to create Windows crash dumps within yuzu</a> itself. This allows any layman on Windows to easily obtain a crash dump without jumping through various developer intended hoops. But since this feature has a big performance impact, this was added behind an option in the <code>Debug</code> settings for users to access. You can find it in <code>Emulation &gt; Configure… &gt; General &gt; Debug &gt; Create Minidump After Crash</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./minidump.png" title=" Only use it if you want to debug a game or to pass the file to a developer, the performance loss is significant!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2022/minidump_hue6772e17a7e0f057b05a0c467ce5a5d9_36487_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Only use it if you want to debug a game or to pass the file to a developer, the performance loss is significant!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Only use it if you want to debug a game or to pass the file to a developer, the performance loss is significant!</p> </div> </div> <p>Since the dumps use modern Windows SDK features, there’s a risk that this change can break compatibility with older Windows options. yuzu only officially supports Windows versions 10 1803 and newer. And Linux, of course. It&rsquo;s faster than Windows.</p> <h2 id="hardware-section">Hardware section</h2> <h4 id="amd-radeon-when-increasing-accuracy-produces-crashes">AMD Radeon, when increasing accuracy produces crashes</h4> <p>Users started reporting crashes when booting up <code>Xenoblade Chronicles 3</code> on AMD Radeon GPUs running official AMD drivers (either the Windows driver, or the Linux amdvlk driver). We’re investigating the amdvlk source code to find the reason, and already notified AMD with all the relevant information we have.</p> <p>The cause seems to be improvements in Macro JIT&rsquo;s accuracy. Testing has shown that even with older driver and yuzu versions, disabling the MacroJIT speedhack causes the official AMD Vulkan drivers to crash, so it sadly checks out that improving its accuracy gives the same result now.</p> <p>Affected users can try running <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/tag/mainline-0-1188">Mainline 1188</a>, or just run the game using OpenGL. The Mesa RADV driver is unaffected.</p> <h4 id="nvidia-one-source-of-crashes-down-more-remain">NVIDIA, one source of crashes down, more remain</h4> <p>We have merged the <a href="https://github.com/yuzu-emu/yuzu/pull/8849">multithreaded ASTC CPU decoder</a> mentioned last month, so we strongly recommend NVIDIA Maxwell and Pascal (GTX 745/750, 900, and 1000 series) users to disable ASTC decoding if you run the latest drivers.</p> <p>You can find the option in <code>Emulation &gt; Configure... &gt; Graphics &gt; Accelerate ASTC Texture Decoding</code>, enabling this setting uses the GPU to decode, while disabling it uses the CPU instead. As a bonus, now this option can be a performance boost on systems with very weak integrated GPUs, like old laptops with MX series Geforce hardware, or any Intel iGPU, where the CPU would do a faster job dealing with ASTC decoding. Testing has shown that Geforce MX 500 and Radeon Vega 7+ tier GPUs are slightly faster using the GPU for decoding. On affected NVIDIA hardware, the performance decrease while decoding ASTC textures is minimal. Avoiding a crash, for example, when opening the map in <code>The Legend of Zelda</code> games is arguably far more important.</p> <p>Crashes caused by recent driver updates remain, but your writer continues to harass an NVIDIA driver developer daily (I only need to get into Intel to do the same to all three vendors now). This leads us to recommend the 472/473 series of drivers for Maxwell and Pascal hardware to ensure the best performance and compatibility with yuzu. There&rsquo;s nothing wrong with using the latest drivers, but until these crashes are resolved, expect instabilities and graphical glitches with them. Turing, Ampere, and Ada hardware (1600, 2000, 3000, and 4000 series) exhibit some weird behaviour but are much more stable on the (at the time of writing) latest 520/522 series of drivers when compared to their older brothers.</p> <p>One wonders how long Maxwell and Pascal will continue to be supported by NVIDIA drivers.</p> <h4 id="intel-arc-support">Intel ARC support</h4> <p>No news yet on Vulkan support for these new &ldquo;AV1 video decoder cards&rdquo; from Intel that can also work as a GPU. Low availability has made it difficult to get our hands on one, but it&rsquo;s something we want to solve ASAP.</p> <p>OpenGL is &ldquo;functional&rdquo; right now, but Intel continues to be the worst vendor regarding OpenGL support on Windows, so the experience is pretty bad. Linux Mesa drivers are reported to work correctly, and with good performance, in both OpenGL and Vulkan.</p> <p>Speaking of AV1, for now we&rsquo;ve been using h.264 encoding for the videos embedded in our articles, as it is both widely supported and very lightweight in regards to hardware requirements. Would you prefer if we switched to AV1 from now on? It can be a big battery drain on devices without dedicated hardware decoders, but it would allow for even lower bitrates while keeping a similar level of quality, something datacapped users have complained about in the past. Let us know on Reddit, our <a href="https://community.citra-emu.org/c/yuzu-news/15">forums</a>, or our <a href="https://discord.gg/u77vRWY">Discord server</a> what you would prefer!</p> <h2 id="future-projects">Future projects</h2> <p>For once, we don’t have much to say in this section. Or maybe I should say, we don’t want to start generating hype for new projects just yet.</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> has started working on Part 2 of <code>Project Y.F.C.</code>, as previously mentioned, and the rest of the GPU gang (Byte[], Maide, vonchenplus) is also busy with some top secret changes (for now, your writer has a reputation to uphold) to improve both rendering accuracy and performance.</p> <p>Having the first part of <code>Y.F.C.</code> merged to Mainline opens the floodgates to many projects that were on hold until now. We will discuss these in more detail in the next progress report.</p> <p>Special thanks to Mysterious Writer B for their help with this progress report, and to CaptV0rt3x who came to aid at a moment’s notice.</p> <p>That’s all folks! As always, many thanks for your time. We hope to see you in the next article!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report August 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/ Fri, 16 Sep 2022 10:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/ <p>Welcome back, yuz-ers! August was a month packed with progress. A plethora of graphical changes, kernel and file system improvements, and more work pumped into network emulation. Next slide, please!</p> <p>Welcome back, yuz-ers! August was a month packed with progress. A plethora of graphical changes, kernel and file system improvements, and more work pumped into network emulation. Next slide, please!</p> <h2 id="graphical-changes">Graphical changes</h2> <p>This month included a number of notable fixes for July&rsquo;s blockbuster release, <code>Xenoblade Chronicles 3</code>. While <code>Xenoblade Chronicles 3</code> did technically work on release day in yuzu, it took us some time to work out the stability issues.</p> <p>The first of these, mentioned last month, was a fix for yuzu&rsquo;s shader recompiler. yuzu does not use a GLSL compiler to generate SPIR-V, the Vulkan shader language. Instead, it generates SPIR-V directly, which is much faster, but has more potential for error. In this case, the shader recompiler failed to declare some variables in the SPIR-V shaders, and left references to them as null, causing the shaders to crash the driver when compiling. <a href="https://github.com/Kelebek1">Maide</a> and <a href="https://github.com/liamwhite">byte[]</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8667" data-gh-pr="8667">quickly found and fixed the problem,</a> allowing the game to run in Vulkan on release day.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wotah.png" title=" Wotah! (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/wotah_hu9b16d26ec86601a68294c90f0a6593ac_1771797_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Wotah! (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Wotah! (Xenoblade Chronicles 3)</p> </div> </div> <p>The set of pipelines used by <code>Xenoblade Chronicles 3</code> is huge, with many pipeline caches clocking over 15000 entries after extended gameplay. With all graphics backends, yuzu precompiles shaders before the game starts, and doesn&rsquo;t allow starting it before compilation is finished. With OpenGL on GLSL, compilation takes over a full minute to complete with a pipeline cache as large as the ones generated by <code>Xenoblade Chronicles 3</code>. To make matters worse, you previously could not cancel out of the process while it was compiling. If you tried, yuzu would freeze up and continue to wait for the compilation to finish before allowing you to close the game. byte[] resolved this minor UX annoyance <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8678" data-gh-pr="8678">by having the shader compiler check for cancellation after each shader is compiled,</a> allowing compilation to instantly be stopped at any time.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./muppet.png" title=" Name&#39;s Kermit the Frog, pleased to meet you (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/muppet_hu6740546b0f7f5758521004d648a5bab8_1803543_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Name&#39;s Kermit the Frog, pleased to meet you (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Name&#39;s Kermit the Frog, pleased to meet you (Xenoblade Chronicles 3)</p> </div> </div> <p><code>Xenoblade Chronicles 3</code>&rsquo;s massive set of pipelines also causes problems for emulation. Because yuzu tries to give you as stutter-free an experience as it can, it tries to load all known pipelines into memory before you even start playing. This might be a reasonable proposition if a game had just a few thousand pipelines. However, keeping Xenoblade&rsquo;s 15000+ distinct pipelines all in memory simultaneously causes the memory usage in the GPU driver to skyrocket. <a href="https://github.com/cemu-project/Cemu">Cemu</a> users of old may remember facing a similar issue when using NVIDIA GPUs.</p> <p>To this end, byte[] looked for any issues in yuzu that might be causing the GPU driver to hold on to more memory than it needs to. byte[] noticed that OpenGL tracks individual objects for shader source code in addition to just for compiled shaders. Properly <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8684" data-gh-pr="8684">allowing these shader source code objects to be freed</a> reclaims a substantial amount of wasted memory. Users can expect much lower VRAM and RAM usage now while running OpenGL and <a href="https://www.youtube.com/watch?v=i1ojUmdF42U">suffering emotional damage</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ears.png" title=" That&#39;s a big snuffin&#39; difference (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/ears_huef3a6b387ca035a070cadaca5bb717df_5364630_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" That&#39;s a big snuffin&#39; difference (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> That&#39;s a big snuffin&#39; difference (Xenoblade Chronicles 3)</p> </div> </div> <p>One advantage yuzu&rsquo;s OpenGL backend has had for <code>Xenoblade Chronicles 3</code> for some time was stability. It didn&rsquo;t really crash. However, Vulkan was another story. Even after the initial Vulkan shader fixes previously mentioned, the game would still randomly crash during cutscenes. byte[] was able to reliably reproduce the issue and found that yuzu was receiving some invalid references in the GPU processing. Whether or not this was something the game was legitimately doing, or just an emulation bug, he identified that yuzu could avoid the crash by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8700" data-gh-pr="8700">passing <code>VK_NULL_HANDLE</code> for an image view,</a> instead of trying to create an image view for a null image, which was guaranteed to crash.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cooking.png" title=" Vulkan no longer cooks itself (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/cooking_hu3a8c82acf712f3084aa1a310f20d8b15_2578239_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Vulkan no longer cooks itself (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Vulkan no longer cooks itself (Xenoblade Chronicles 3)</p> </div> </div> <p>AMD users on Windows were left in the dark about Vulkan support for <code>Xenoblade Chronicles 3</code> for a bit. One of our testers, <a href="https://community.citra-emu.org/u/GoldenX86">your writer</a>, obtained a log with Vulkan validation errors, and determined that the crash was due to trying to use some vertex formats that were not supported by the Windows driver. However, they were supported by <code>RADV</code>, the Linux Mesa driver. byte[] additionally identified a case of the opposite, where a format was supported by the Windows driver but not RADV, and implemented a generic workaround that would <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8702" data-gh-pr="8702">substitute a compatible format for both cases,</a> fixing multiple crashes at once.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./stretching.png" title=" Progressively getting fit (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/stretching_hu833de69a26967440b5f51f5cfef38cbb_2356017_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Progressively getting fit (Xenoblade Chronicles 3)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Progressively getting fit (Xenoblade Chronicles 3)</p> </div> </div> <p>A few GPU changes not related to Xenoblade also made it in this month.</p> <p>After years, since the beginning of our <a href="https://yuzu-mirror.github.io/entry/yuzu-vulkan/">Vulkan backend</a>, yuzu finally added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8735" data-gh-pr="8735">support for VSync in Vulkan</a> by new contributor <a href="https://github.com/djrobx">djrobx</a>. As described by the pull request adding it, if the emulation and display are very close to precise sync, there can be fits of juddering when the newly generated frames don&rsquo;t decisively fall as next to be displayed. This change allows yuzu to completely synchronize frames with the monitor refresh rate, preventing any juddering. Thank you very much!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vsync.png" title=" No more tearing, Vulkan edition"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/vsync_hu9bbe6b4c139d55474a75590909b4db45_18484_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" No more tearing, Vulkan edition"></a> <p class="has-text-centered is-italic has-text-grey-light"> No more tearing, Vulkan edition</p> </div> </div> <p><a href="https://github.com/merryhime">Merry</a>, the author of <a href="https://github.com/merryhime/dynarmic">dynarmic</a> (and a real life White Mage), implemented an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8739" data-gh-pr="8739">optimization for the process of converting between tiled and untiled images</a> for the GPU. This doesn&rsquo;t impact the performance of games very much, as they generally avoid converting between tiled and untiled images, but it significantly improves the performance of homebrew apps, which convert every frame to display to the console.</p> <p>On the topic of unusual techniques, <a href="https://github.com/vonchenplus">vonchenplus</a> implemented support for a legacy OpenGL format called <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8752" data-gh-pr="8752">rectangle textures.</a> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/ractanglebug_huf3e0d0252e70b934214f6ab7afad0b08_21890_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Legacy features seem to be popular with some game studios"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/rectanglefix_hue0e67f9ecf4a3d5d1c66b25c993ceb1b_83348_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Legacy features seem to be popular with some game studios"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Legacy features seem to be popular with some game studios</p> <p>As a side effect of this change, a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8837" data-gh-pr="8837">pipeline cache purge</a> had to be issued by <a href="https://github.com/Morph1984">Morph</a>.</p> <p>You may be thinking, but aren&rsquo;t all textures rectangles? That is true, but the thing making rectangle textures distinct is that they are indexed in shaders with coordinates from 0 to their width/height &ndash; texel coordinates, instead of 0 to 1 &ndash; normalized coordinates. This mode is not very useful, so it is a surprise to see it still used by games. This change fixed a lot of rendering issues in <code>Fast RMX</code> and <code>The Touryst</code> (two games using the same engine).</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/tourystbug_hube2e4c5ddeb9abdad0ebbe69c18c5c5b_310583_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more vacations in the Abyss (The Touryst)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/tourystfix_hu021a11d0ea4b10169d80ed9d54975626_2369783_1024x0_resize_q90_bgffffff_box_3.jpg" alt="No more vacations in the Abyss (The Touryst)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more vacations in the Abyss (The Touryst)</p> <p>In the case of <code>Fast RMX</code>, disabling <code>DYNAMIC CAMERA EXPOSURE</code> in its in-game graphic settings fixes an overbright rendering bug. Testing shows that OpenGL seems to be more stable for this title.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rmx.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/rmx_hu18e17d1d3a95221cebf264da522b9dec_2651389_800x0_resize_q90_bgffffff_box_3.jpg" alt="F-Zero for Switch when, Nintendo? (FAST RMX)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./settings.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/settings_hu8b1067c5db0f98e37c3ea88af8210962_138256_800x0_resize_q90_bgffffff_box_3.jpg" alt="F-Zero for Switch when, Nintendo? (FAST RMX)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">F-Zero for Switch when, Nintendo? (FAST RMX)</p> <p>Also focusing on homebrew, vonchenplus implemented support for a few things needed to get the <a href="https://www.retroarch.com/">RetroArch</a> homebrew working inside yuzu. Yup, more &ldquo;emulator in emulator&rdquo; shenanigans.</p> <p>The first step is the <code>clkrst</code> service, used to control clock speeds on the console, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8794" data-gh-pr="8794">which was stubbed</a> to allow RetroArch to boot. Emulation of clock speed is not very meaningful for yuzu, so it’s not a loss. The second is a specialty behaviour by <code>switch-mesa</code>, which uses a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8795" data-gh-pr="8795">different framebuffer crop</a> and appears halfway down the screen without proper emulation.</p> <p>While preparing the <code>Project London</code> changes for release, <a href="https://github.com/FearlessTobi">Tobi</a> found some issues with <code>Rocket League</code> that were preventing it from working properly. byte[] found that it could boot in single core, but the game had terrible rendering in Vulkan. To do this, byte[] added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8791" data-gh-pr="8791">support for the <code>R16G16B16X16</code> format</a> used by the game, fixing the rendering issues. Still, more work is needed to make this game playable on yuzu.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/rocket_hub83c58b644658e2ab1a0ded776aedeb4_883677_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The better League (Rocket League)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/rocketfix_hu04d07afbaac9d0e8d6a82020147a9def_902531_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The better League (Rocket League)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The better League (Rocket League)</p> <p>Working on his Magnum Opus, byte[] also implemented a workaround for a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8074" data-gh-pr="8074">previous performance fix</a> to <code>Super Mario Galaxy</code> and <code>Super Mario Sunshine</code>. While the performance fix should have been regression-free, since it was a bug in the buffer cache, many games needed the <em>less</em> accurate behaviour from before the change. <code>Mario + Rabbids Kingdom Battle</code>, <code>Splatoon 2</code>, and <code>Super Smash Bros. Ultimate</code> all had some extra flickering that was introduced after this pull request, so byte[] made the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8819" data-gh-pr="8819">feature, <code>pessimistic flushing</code>, optional,</a> and disabled by default, since most games were unaffected.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pessimistic.png" title=" Feel free to test it, but expect a performance loss"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/pessimistic_hu37b9bec963ed2d950324df482bc07efd_18657_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Feel free to test it, but expect a performance loss"></a> <p class="has-text-centered is-italic has-text-grey-light"> Feel free to test it, but expect a performance loss</p> </div> </div> <p>Finally on the list for GPU changes this month, <a href="https://github.com/german77">german77</a>, along with <a href="https://github.com/bylaws">bylaws</a> from the <a href="https://github.com/skyline-emu/skyline">Skyline emulator</a>, added <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8809" data-gh-pr="8809">emulation for the viewport swizzling extensions</a> used by some games. These were supported by NVIDIA GPUs with an extension, but not AMD or Intel GPUs, and so a few games would appear to render upside down or flipped. Games like <code>Street of Rage 4</code>, <code>Celeste</code>, <code>Axiom Verge</code>, and many others are now playable on AMD and Intel!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/celestebug_hu4671c920dc7ec2f5045d38082e491579_6636398_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A new meaning for inverse climbing (Celeste)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/celestefix_hud9b5d0638a3d145fb9181fe12c3bb540_6451837_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A new meaning for inverse climbing (Celeste)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">A new meaning for inverse climbing (Celeste)</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/axiombug_hu37af1c5615100fb3b9d579bb147c5582_71099_1024x0_resize_q90_bgffffff_box_3.jpg" alt="There should be a difficulty mode called upside-down (Axiom Verge)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/axiomfix_hu67a7eabb122ef7ef67a4896278828451_70688_1024x0_resize_q90_bgffffff_box_3.jpg" alt="There should be a difficulty mode called upside-down (Axiom Verge)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">There should be a difficulty mode called upside-down (Axiom Verge)</p> <h2 id="cpu-kernel-and-file-system-emulation">CPU, kernel, and file system emulation</h2> <p>We have some good news for users <em>still</em> running out-of-support versions of Windows! Thanks to <a href="https://github.com/merryhime/dynarmic/issues/701">an investigation</a> done by <a href="https://github.com/vladkosi">vladkosi</a>, Merry was able to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8745" data-gh-pr="8745">implement the required changes in fastmem</a> to support Windows versions older than Windows 10 version 1803 again.</p> <p>While this is great news for the Windows 7 gang, it does not change our position regarding operating system version support: only Linux, Windows 10 version 1803, and newer are <em>officially</em> supported. Time will tell what happens to compatibility with older Windows versions after future changes to Vulkan and memory management are implemented, but for now, they work for a while longer.</p> <p>But the good news doesn&rsquo;t end there. Here are some changes intended to help the modding community!</p> <p>In the past, inline comments added to <code>pchtxt</code> mods weren’t allowed, as we parsed the text in a way that made them incompatible. Morph now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8755" data-gh-pr="8755">delimits the hexadecimal value string,</a> allowing modders to add comments. For example:</p> <pre tabindex="0"><code>Before: here to here v v 12345678 12345678 // comment ^ ^ After: here to here </code></pre><p>Our current file system emulation can be considered spaghetti code due to old guesses made when less information was available, and patchwork done by developers that are no longer contributing to the project. There’s no way to sugar-coat it, this is the main reason Morph has been working so hard for over a year on <code>Project Gaia</code>, a full rewrite of the current virtual file system implementation.</p> <p>Meanwhile, some further patchwork can be done to reduce the headaches developers and modders currently endure. For example, <code>Build IDs</code> are padded by a bunch of zeroes, and modders are more used to the short form without including the irrelevant zeroes at the beginning. To remedy this, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8790" data-gh-pr="8790">parses the Build ID string using fmt</a> to dynamically add the required zeroes when needed.</p> <p>Continuing to focus on improving RetroArch’s experience in yuzu, vonchenplus discovered that recursively calculating the size of the files when parsing the directories has a negative effect on performance, in this case perceived as “loading times” when booting a game with the emulator (inside an emulator). <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8804" data-gh-pr="8804">Simply ignoring this information</a> is a good way to improve the user experience. Note that this change doesn’t help in running native Switch games on yuzu, it only provides faster load times for RetroArch.</p> <h2 id="ui-changes">UI changes</h2> <p>People have been asking for stronger audio volume in yuzu for a long time, and Maide delivers. Now, if the user goes to <code>Emulation &gt; Configure… &gt; Audio</code>, they can <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8756" data-gh-pr="8756">set the volume up to 200%,</a> really cranking it to 11!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./audio.png" title=" Don&#39;t wake up your neighbours"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/audio_hu57ee97ab1623c08ae597527811b107fa_15103_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Don&#39;t wake up your neighbours"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don&#39;t wake up your neighbours</p> </div> </div> <p>Something to keep in mind is that some games have their volume tuned up to the output they are using. A game may be louder in handheld over docked, for example, so don’t stress your poor ears.</p> <p>Part of yuzu’s code is still based on <a href="https://citra-emu.org/">Citra</a>, even some sections that are no longer relevant, or have become outdated over the years. Cleaning up code is a boring but necessary part of any project, more so for open source ones, and yuzu is no exception. One feature that was very useful in the early days is loading ELF binaries. Instead of dealing with XCI and NSP dumps, back in the early days, devs dumped and extracted the whole file structure of the game, and loaded the ELF binary directly, in a similar way to how on Windows the user opens a .exe file to load a program.</p> <p>Some years down the line and not only is this feature <a href="https://www.youtube.com/watch?v=6R3ouGNcACQ">tarnished out of grace</a>, but it also stopped working. Since it’s not a priority at the moment, and it can lead to user confusion, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8701" data-gh-pr="8701">removed it from the File dropdown.</a> </p> <p>Asian Language Windows users noticed that the Size column in the game list and the Speed Percent setting displayed <em>very weird</em> characters.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bad1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/bad1_hu79208407563cb82ad3331de27693caec_6276_800x0_resize_q90_bgffffff_box_3.jpg" alt="Alien numbers"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bad2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/bad2_hu0a1e44f83f25c9ac8dc3a1cdaa1de7eb_22796_800x0_resize_q90_bgffffff_box_3.jpg" alt="Alien numbers"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Alien numbers</p> <p>Of course this isn’t acceptable, so <a href="https://github.com/Docteh">Docteh</a> implemented the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8715" data-gh-pr="8715">necessary changes</a> to workaround this issue in Windows.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./digits.png" title=" Much better"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/digits_hu02a8c1e4bcbbe85c4cdc27c803125f08_48588_750x0_resize_q90_bgffffff_box_3.jpg" alt=" Much better"></a> <p class="has-text-centered is-italic has-text-grey-light"> Much better</p> </div> </div> <p>Adding to the list of Asian-language-only UI bugs, if a user started yuzu, for example, in Chinese and then switched to English, the Filter bar at the bottom and the game list columns at the top would remain untranslated, refusing to switch. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8797" data-gh-pr="8797">Forcing Qt to retranslate</a> these objects solves the issue, making Docteh happy.</p> <p>Docteh implemented <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8741" data-gh-pr="8741">a couple more UI fixes</a> as well, cleaning up the About dialog and making the default Port number in the Direct Connect UI ignore translations.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/aboutbug_hu0345f5c995b7b9ad74d7d70a0c848a09_46549_625x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu About dialog changes"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/aboutfix_hu02fc52c7e6f03ce6ef7413599029fe36_46862_634x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu About dialog changes"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">yuzu About dialog changes</p> <p>Users complained that the Controller Profile drop down list&rsquo;s character limit was too short, inhibiting their creativity. german77 stepped up and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8783" data-gh-pr="8783">increased the character limit.</a> </p> <h2 id="input-improvements">Input improvements</h2> <p>UI navigation with a controller is a relatively recent addition to yuzu, so there is room for improvement. For example, users reported that if the &ldquo;Prompt for user on game boot&rdquo; feature is enabled, controller inputs will be able to navigate the options and start the game, but it won’t be able to actually change the profile or cancel the boot process. Newcomer <a href="https://github.com/jonesyUK">jonesyUK</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8716" data-gh-pr="8716">solves both issues</a> with a bit of Qt magic. Thank you!</p> <p>Some users prefer to depend on <a href="https://github.com/Ryochan7/DS4Windows">DS4Windows</a> instead of yuzu’s native support for game controllers. While there is a good reason for that, it’s a simple way to have a single app handle XInput emulation, it can also lead to some interesting issues german77 discovered. For example, current versions of DS4Windows can’t handle two subsequent vibration commands, producing (depending on the person you ask) an uncomfortable, constant vibration. To solve this brrrrrracing issue, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8722" data-gh-pr="8722">added a small delay</a> so the app doesn’t skip the stop signal.</p> <p>On a more colourful topic, and with the intention of fixing a bug with <code>Mario Party Superstars</code>, german77 spent many hours cooking <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8724" data-gh-pr="8724">how to properly emulate controller colours,</a> with a side dish of fixing battery level icons too!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./colour.png" title=" Art Attack!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/colour_huca6e1bc483f36eea0a1f3e0d0d2b97d9_46018_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Art Attack!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Art Attack!</p> </div> </div> <p>Navigate to <code>Emulation &gt; Configure… &gt; Controls &gt; Advanced</code> and go to town!</p> <p>And to close this section out, we have to own up to an oopsie on our side. With the initial implementation of IR camera support, the output was saved to storage. Every single video frame as an individual image file… This led to TONS of files being written to disk, making navigation with the file manager a pain, and eating a lot of free storage. Oops. german77 acted quickly and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8805" data-gh-pr="8805">moved the output to a buffer.</a> </p> <p>If any user suffered from this and can’t remove the files, open the Command Prompt or Terminal, navigate to the Pictures folder, and run <code>del IMG_00*.jpg</code> to wipe them all out in a single blow.</p> <h2 id="hardware-section">Hardware section</h2> <h4 id="intel-arc-joins-the-fun">Intel ARC joins the fun</h4> <p>We received information that early adopters of A380 Intel GPUs had issues running their games using Vulkan. Since this hardware is not globally available yet, it’s not easy for our developers and testers to get their hands on it, so please <a href="https://github.com/yuzu-emu/yuzu/issues">post issues in our GitHub</a> including <a href="https://yuzu-mirror.github.io/help/reference/log-files/">log files</a>, or contact us on our <a href="https://community.citra-emu.org/c/yuzu-support/14">forums</a> or our <a href="https://discord.gg/u77vRWY">Discord server</a>. We’ll ask for more information, if needed, to find the reason for this. Hurray for the early adopter woes.</p> <h4 id="amd-making-use-of-opengl">AMD, making use of OpenGL</h4> <p>Users with AMD GPUs reported that specific points in <code>Xenoblade Chronicles 3</code> always resulted in vertex explosions. A workaround for this is to run the game with OpenGL and a 2X resolution multiplier, get past the area, save, and swap to Vulkan.</p> <p>Why the oddly specific 2X resolution multiplier? For the same reason our performance chart last month had no results for <code>Xenoblade Chronicles 2</code> on this new OpenGL driver, it leads to a driver related crash. 2X works around this crash and AMD has been properly alerted to this issue. No news from them so far, but since we got access into their Vanguard beta testing program, we’ll tell you as soon as the fix is out in a public driver. The game is not that much slower under OpenGL now, but shader stuttering will always be significantly better under Vulkan.</p> <p>We recommend more emulator developers to <a href="https://www.amd.com/en/technologies/amd-vanguard-program">apply to Vanguard</a>, as the indirect approach of the built-in driver bug report tool is not ideal for the specific needs of console emulators.</p> <h4 id="nvidia-making-us-go-compute-ourselves">NVIDIA making us go compute ourselves</h4> <p>We confirmed that at least a big part of the crashes affecting Maxwell and Pascal GPUs by the current 516.XX series of drivers is caused by some driver change in compute shaders, which resonates with our compute shader based ASTC texture decoder. As a solution, and to avoid this problem in the future as it isn’t the first time an NVIDIA driver update broke it, we’re considering <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8849" data-gh-pr="8849">switching to a multithreaded CPU decoder</a> developed by Morph.</p> <p>The cause for the shadow flickering on KOEI games is still under investigation.</p> <h2 id="future-projects">Future projects</h2> <p>The delays in merging <code>Project Y.F.C.</code> don’t only affect Mainline users, they also impede progress in development. In another example of Hell freezing over (no one expected AMD fixing OpenGL), NVIDIA of all people <a href="https://github.com/NVIDIA/open-gpu-doc/blob/master/classes/3d/clb197.h">open sourced some documentation</a> (partially of course, this is NVIDIA we’re talking about, they’re so closed source they don’t even get fresh air). This includes proper names for Maxwell 3D registers, completely new registers, and even previously unknown values. Maide has been <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8766" data-gh-pr="8766">checking, replacing, and cleaning a lot of code</a> thanks to this new official information, but the merge for this change will have to wait. No game fixes are expected out of this, but the clean-up and ease of understanding is very much worth it.</p> <p>An interesting experiment that will benefit all users in a few bandwidth-starved games like <code>The Legend of Zelda: Breath of the Wild</code>, <code>Xenoblade Chronicles 3</code>, and <code>SHIN MEGAMI TENSEI V</code>, among others, is increasing the size of Vulkan’s stream buffer size. Testing shows a performance boost of 10-50% depending on the system, even without ReBAR support, which limits the buffer size to 256MB. Having access to all available VRAM opens the possibility for even higher gains!</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/128mb_hu89551c5991c851b2a467c8f57e18aea4_5185881_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Look at the performance difference! (Xenoblade Chronicles 3)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/2048mb_hud35586cb054dc366c6cc08bd21ed03e6_5182032_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Look at the performance difference! (Xenoblade Chronicles 3)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Look at the performance difference! (Xenoblade Chronicles 3)</p> <p>After too much nagging from your writer, byte[] implemented a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8861" data-gh-pr="8861">draft to easily test the feature with a slider,</a> but the final goal is to manage it dynamically, so don’t expect to see this feature as a UI option in an official release.</p> <p>Working on the finishing touches for <code>Project London</code>, Tobi has not been passive at all:</p> <ul> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8685" data-gh-pr="8685">Adding the ability to proxy socket packets,</a> which includes custom rooms with local network support, including LAN games, not only LDN.</li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8731" data-gh-pr="8731">Stubbing and adding some required data types.</a> </li> <li><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8822" data-gh-pr="8822">Improvements to the in-progress room feature.</a> </li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ldn.png" title=" The most fun ever doing internal testing"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/ldn_hu5594f4f1617a2b19e143e59b13f02f75_740564_493x0_resize_q90_bgffffff_box_3.jpg" alt=" The most fun ever doing internal testing"></a> <p class="has-text-centered is-italic has-text-grey-light"> The most fun ever doing internal testing</p> </div> </div> <p>Oh! How could we almost forget? <code>Project London</code>, LDN support, is <em>finally</em> out now! More information in <a href="https://yuzu-mirror.github.io/entry/ldn-is-here/">the dedicated article</a> and <a href="https://yuzu-mirror.github.io/help/feature/multiplayer/">Multiplayer Guide</a>. We’ll recap the release in the next Progress Report.</p> <p>That’s all folks! Thank you so much for sticking with us, and I hope to see you all next time!</p> <p>Special thanks to Mysterious Writer B for your help on this article!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./byte.png" title=" The suspense bites me"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2022/byte_huc6f8aabfc4b8e37d4e793847b36a158d_74441_162x0_resize_q90_bgffffff_box_3.jpg" alt=" The suspense bites me"></a> <p class="has-text-centered is-italic has-text-grey-light"> The suspense bites me</p> </div> </div> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> New Feature Release - Local Wireless Multiplayer https://yuzu-mirror.github.io/entry/ldn-is-here/ Sun, 11 Sep 2022 01:40:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/ldn-is-here/ <p>Hey there, yuz-ers! The MOST awaited feature of yuzu, Local Wireless Multiplayer (LDN), is finally here! So what are you waiting for? Time to grab your friends and jump right in!</p> <p>Hey there, yuz-ers! The MOST awaited feature of yuzu, Local Wireless Multiplayer (LDN), is finally here! So what are you waiting for? Time to grab your friends and jump right in!</p> <h2 id="what-is-this">What is this?</h2> <p>The Nintendo Switch console supports various multiplayer options. Among these, the following options are useful when you want to play multiplayer with other Switch consoles. <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./multi.png" title=" Table indicating yuzu&#39;s supported Switch multiplayer modes"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/multi_hu869c27aee01372f02c54db3ba004767e_10375_603x0_resize_q90_bgffffff_box_3.jpg" alt=" Table indicating yuzu&#39;s supported Switch multiplayer modes"></a> <p class="has-text-centered is-italic has-text-grey-light"> Table indicating yuzu&#39;s supported Switch multiplayer modes</p> </div> </div> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Switch_Conn.png" title=" Graphic demonstrating the key differences between the three wireless modes"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/Switch_Conn_huff96b8f7a7fc024f356f04fe93630f03_69367_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Graphic demonstrating the key differences between the three wireless modes"></a> <p class="has-text-centered is-italic has-text-grey-light"> Graphic demonstrating the key differences between the three wireless modes</p> </div> </div> <article class="message has-text-weight-semibold"><div class="message-body"><p> The Switch's HorizonOS uses the LDN service for all Local Wireless communication. <br> This is why Local Wireless Multiplayer can also be referred to as LDN Multiplayer. </p></div></article> <p>Thanks to the incredible efforts of our developers <a href="https://github.com/FearlessTobi">FearlessTobi</a> and <a href="https://github.com/german77">german77</a>, Local Wireless Multiplayer in yuzu is no longer a dream! Special thanks to <a href="https://github.com/spacemeowx2/">spacemeowx2</a> and <a href="https://github.com/spacemeowx2/ldn_mitm/graphs/contributors">all the contributors</a> of the <a href="https://github.com/spacemeowx2/ldn_mitm">ldn_mitm</a> project. Without their extensive reverse-engineering of the <code>LDN</code> service, and the gracious <a href="https://github.com/spacemeowx2/ldn_mitm#licensing">license exemption</a> for yuzu, this would not have been possible.</p> <br> <article class="message"><div class="message-header"> <p>⚠️ Attention</p> </div> <div class="message-body"><p style="color:white;"> <b>Currently, Local Wireless Multiplayer (LDN) is only supported between instances of yuzu.<br> Multiplayer between yuzu and a real Switch or between yuzu and other emulators is not supported!</b> </p></div></article> <h2 id="where-can-you-get-it">Where can you get it?</h2> <p>The Local Wireless Multiplayer feature is now available in the latest version of the Early Access release. We will be working to polish this feature and make this available to the Mainline builds soon.</p> <article class="message has-text-weight-semibold"><div class="message-body"><p> If you're using the yuzu installer, you'll automatically be updated to the latest build.<br> If you're <b>not</b> using the yuzu installer, please download it from our <a href= https://yuzu-mirror.github.io/downloads/>Download</a> page. <br> <br> We highly recommend using our installer to always stay up to date on both Mainline and Early Access builds. </p></div></article> <h2 id="local-wireless-ldn-multiplayer">Local Wireless (LDN) Multiplayer</h2> <p>yuzu&rsquo;s Local Wireless multiplayer (LDN) differs a little bit when compared to the Nintendo Switch. The Switch console uses the <code>LDN</code> service to scan for other Switch consoles using Wi-Fi and connects all players. Here, one player would act as the <code>host</code> and all others would connect to it.</p> <p>yuzu, on the other hand, employs virtual rooms to allow players to create and join game lobbies within said rooms. Since this emulates the Switch&rsquo;s ability to do local wireless multiplayer, it does NOT rely on Nintendo’s servers and does NOT require a Nintendo Account. While on a real Switch, you’d be limited to the people in your immediate vicinity, yuzu boasts a complex server/client infrastructure that forwards a game’s wireless communication across the internet.</p> <p>In order to connect with other players, players simply need to join the same room within yuzu’s Public Room Browser. But, before opening the Public Room Browser, you will have to first configure your network interface in yuzu.</p> <p>You can find this setting under <code>System -&gt; Network</code> and you need to select your internet connection from the drop-down as shown below.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./network_interface.png" title=" yuzu&#39;s Network Interface configuration"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/network_interface_hu41aaa099594271375a47d12cfb274570_11910_976x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu&#39;s Network Interface configuration"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu&#39;s Network Interface configuration</p> </div> </div> <p>Out of the box, we provide you with an assortment of public rooms hosted across the world by yuzu. Creating and joining rooms is extremely easy in yuzu and can be done in just a few clicks.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./room_browser.png" title=" yuzu&#39;s Public Room Browser"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/room_browser_hu11eff3d42fc80a17318dbb0419957603_77039_898x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu&#39;s Public Room Browser"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu&#39;s Public Room Browser</p> </div> </div> <p>If you’re a <a href="https://community.citra-emu.org/signup">Verified User</a>, you can create your very own public room for people to join. These public rooms can be seen by anyone using the Public Room Browser, but you can also password protect them to restrict users&rsquo; access. Verified Users will have their forum nickname and profile picture populated in the chatroom. <br></p> <article class="message"><div class="message-header"> <p>⚠️ Reminder</p></div> <div class="message-body"><p style="color:#eed202;"> <b>When hosting a room, remember to port forward or your friends won’t be able to connect!</b> </p></div></article> <p>If you prefer not to sign up for our platform, you aren’t out of luck! Unverified Users still have the ability to create unlisted rooms, directly connect to unlisted rooms, and can join any yuzu hosted room.</p> <p>Do note that Verified Users will have their privileges revoked for violating any yuzu policies while in the room chatroom. Please respect the <code>Preferred Game</code> listed in publicly hosted rooms, as even unrelated games will add to the bandwidth load.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./room_chat.png" title=" Public Room chat and moderation features"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/room_chat_huc504af3cabc8ae1facf6e05edf53552d_41876_809x0_resize_q90_bgffffff_box_3.jpg" alt=" Public Room chat and moderation features"></a> <p class="has-text-centered is-italic has-text-grey-light"> Public Room chat and moderation features</p> </div> </div> <article class="message has-text-weight-semibold"><div class="message-body"><p> You can use these rooms for LAN mode games as well — instead of ZeroTier or Hamachi.</b> </p></div></article> <p>Please visit <a href="https://yuzu-mirror.github.io/help/feature/multiplayer/">our multiplayer guide</a> for further help with Hosting, Port Forwarding, Authentication, and Moderation of your publicly hosted rooms.</p> <h2 id="development">Development</h2> <p>FearlessTobi began development by leveraging the existing virtual rooms infrastructure from <a href="https://citra-emu.org">Citra</a>. Due to code similarities between yuzu and Citra, this tried-and-tested infrastructure easily became the foundation of this feature.</p> <p>Now that the virtual rooms were taken care of, Tobi moved onto the <code>LDN</code> service and its protocols. Using the research and code from the <a href="https://github.com/spacemeowx2/ldn_mitm">ldn_mitm</a> project, he implemented the necessary changes for yuzu instances to communicate with each other over these virtual rooms. During this process, Tobi put an extra emphasis on ensuring no personal data, such as IP addresses, was leaked to the other room members.</p> <p>As the feature slowly matured, Tobi began utilizing yuzu&rsquo;s internal team of testers to verify the feature across several titles for compatibility and performance validation.</p> <p>With the multiple testing iterations, various bugs and glitches were found. german77 relied on his own reverse-engineering and hardware tests to debug these issues, which then made it easy for the team to fix these various problems. He also made several UI fixes to improve its usability and brought the codebase up to yuzu standards.</p> <h2 id="compatibility">Compatibility</h2> <p>Please note that as this is the initial release of the feature, some games may have some limitations. We hope to slowly fix these over the course of the next few months.</p> <p>yuzu&rsquo;s Local Wireless Multiplayer was tested by our team of Testers and Support staff across a small set of popular titles. Their compatibility findings are as follows:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./compat.png" title=" List of yuzu-tested multiplayer titles"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/compat_huf92e5188d926f34b5f7738d6648a4772_63075_730x0_resize_q90_bgffffff_box_3.jpg" alt=" List of yuzu-tested multiplayer titles"></a> <p class="has-text-centered is-italic has-text-grey-light"> List of yuzu-tested multiplayer titles</p> </div> </div> <h2 id="screenshots">Screenshots</h2> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./acnh1.jpg" title=""><img src="./acnh1.jpg" alt="Animal Crossing: New Horizons"></a> </div> <div class="column is-bottom-paddingless"> <a href="./acnh2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/acnh2_hu8658004eb70e3ee100c8f2e89ea467e1_7566808_800x0_resize_q90_bgffffff_box_3.jpg" alt="Animal Crossing: New Horizons"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Animal Crossing: New Horizons</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./splatoon2_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/splatoon2_1_hucc3954b5bd1d5e5a1773ef89f301f6d3_1652509_800x0_resize_q90_bgffffff_box_3.jpg" alt="Splatoon 2"></a> </div> <div class="column is-bottom-paddingless"> <a href="./splatoon2_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/splatoon2_3_hu05b004da05f19c435ce8a907bd919a2d_3175440_800x0_resize_q90_bgffffff_box_3.jpg" alt="Splatoon 2"></a> </div> <div class="column is-bottom-paddingless"> <a href="./splatoon2_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/splatoon2_2_hu64baf9ece831394f0847f41b8bfd211c_2752489_800x0_resize_q90_bgffffff_box_3.jpg" alt="Splatoon 2"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Splatoon 2</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mk8d_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/mk8d_1_hue735e0fbd974e54c7096d3e34a7e428a_12185179_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mk8d_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/mk8d_2_hub6d5a5c034e0fc9b975aa3e181120fa4_13216770_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mario Kart 8 Deluxe</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./arceustrade1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/arceustrade1_hu3910d9d70a0f87fad6b5d88cf3978de9_2183358_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Legends: Arceus"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arceustrade2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/arceustrade2_hu3910d9d70a0f87fad6b5d88cf3978de9_1833664_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Legends: Arceus"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arceustrade3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/arceustrade3_hu77fb7300e56ab38924c181c177ef6a2f_1347618_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Legends: Arceus"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon Legends: Arceus</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./lm3_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/lm3_1_hua669f8d605631391353c8a49515939dc_3402001_800x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi&#39;s Mansion 3"></a> </div> <div class="column is-bottom-paddingless"> <a href="./lm3_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/lm3_2_hude23b105cffabfe0df4b71d37518cec0_3404512_800x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi&#39;s Mansion 3"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Luigi&#39;s Mansion 3</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ssbu_ldn_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/ssbu_ldn_2_huf1ceb1dae74e0fdf7d7fe5777e8520ff_5333797_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Smash Bros. Ultimate"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ssbu_ldn_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/ssbu_ldn_3_hu0b4b518219c7f472c12e15fc6fb37ddd_7253147_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Smash Bros. Ultimate"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ssbu_ldn_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/ssbu_ldn_1_hu5bd954edf72b37a7bcc8e76323e5ed9a_7892025_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Smash Bros. Ultimate"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Smash Bros. Ultimate</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./PLG_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/PLG_1_hu08be93e48dc9a537b7cfcb864f0dcb6b_1765792_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./PLG_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/PLG_2_hu7ea0e00104ef9010e0523b4b8386ece4_825191_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./PLG_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/PLG_3_huc962c3fb60113b966e6aca473bdae0a9_1951329_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Let&#39;s Go: Pikachu/Eevee"></a> </div> <div class="column is-bottom-paddingless"> <a href="./PLG_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/PLG_4_hud6e753102e729856b0ad23bdbbd3ad61_1969516_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Let&#39;s Go: Pikachu/Eevee"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon Let&#39;s Go: Pikachu/Eevee</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bdsp_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/bdsp_1_hufaade000003fcec1e377fa9af2e25342_14586510_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./bdsp_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/bdsp_2_hu0f80ec23f486f811a92d50517b2fff69_11041179_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bdsp_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/bdsp_3_hu6001c4f4214abf11c18292727dbd142a_874879_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Brilliant Diamond/Shining Pearl"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bdsp_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/bdsp_4_hu5d54ccd90d782363b6fed77dc0c7a210_12882253_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Brilliant Diamond/Shining Pearl"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon Brilliant Diamond/Shining Pearl</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Diablo3_LDN_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/Diablo3_LDN_1_hue9d535ca1e1c3243f0efa875b30436e2_1723115_800x0_resize_q90_bgffffff_box_3.jpg" alt="Diablo III : Eternal Collection"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Diablo3_LDN_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/Diablo3_LDN_2_hu23f5a4d4554a627f4c8d7eb64da8fb40_2039605_800x0_resize_q90_bgffffff_box_3.jpg" alt="Diablo III : Eternal Collection"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Diablo III : Eternal Collection</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cowabunga.png" title=" Teenage Mutant Ninja Turtles: The Cowabunga Collection"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/cowabunga_hu2077788e857ed51cda07048d6d6e0baa_5292740_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Teenage Mutant Ninja Turtles: The Cowabunga Collection"></a> <p class="has-text-centered is-italic has-text-grey-light"> Teenage Mutant Ninja Turtles: The Cowabunga Collection</p> </div> <div class="column has-text-centered"> <a href="./monster_hunter_ultimate.png" title=" Monster Hunter Generations Ultimate"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/monster_hunter_ultimate_hu6880063c5f25d3761b755aa2353ff75e_15124939_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Monster Hunter Generations Ultimate"></a> <p class="has-text-centered is-italic has-text-grey-light"> Monster Hunter Generations Ultimate</p> </div> <div class="column has-text-centered"> <a href="./kirby_dream_buffet.png" title=" Kirby&#39;s Dream Buffet"> <img src="https://yuzu-mirror.github.io/entry/ldn-is-here/kirby_dream_buffet_hu4f26c6ef460b3a44ea8a239e5d7bdba9_5893554_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Kirby&#39;s Dream Buffet"></a> <p class="has-text-centered is-italic has-text-grey-light"> Kirby&#39;s Dream Buffet</p> </div> </div> <h2 id="fin">Fin</h2> <p>As with any new update, we&rsquo;ve tested the feature internally, but our efforts can&rsquo;t compare to the community as a whole. We could have easily missed an edge case or some weird bug or issue among the vast collection of games with Local Wireless.</p> <p>Test any and all games! Poke, prod, and play! Please break this release if you can! With your help, we can make yuzu the best it can be. Please reach out to us on our <a href="https://discord.gg/u77vRWY">Discord</a> and report any bugs you find, so that we can quickly address them.</p> <p>That&rsquo;s all we have for now, until next time! Happy emulating! <br><br></p> <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> Progress Report July 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/ Mon, 15 Aug 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/ <p>Hello yuz-ers, what a month we&rsquo;ve had! Great graphical changes, an amazing audio rewrite, preliminary work on LDN support, testing new OpenGL drivers, and plenty of fixes! Continue reading to find out more.</p> <p>Hello yuz-ers, what a month we&rsquo;ve had! Great graphical changes, an amazing audio rewrite, preliminary work on LDN support, testing new OpenGL drivers, and plenty of fixes! Continue reading to find out more.</p> <h2 id="part-1-of-project-yfc">Part 1 of Project Y.F.C.</h2> <p>Since we’ve been teasing you for months (and we will continue to do so) in previous articles, you know <a href="https://github.com/FernandoS27">Blinkhawk</a> has been working on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8467" data-gh-pr="8467">a bunch of miscellaneous GPU related fixes and performance improvements.</a> While we will have more information in a dedicated article in the near future, please enjoy the following brief overview.</p> <p>As the scope of the project grew, the team decided to split it in two parts, with the released first part focusing more on game fixes and improving accuracy. While that doesn’t mean part 1 doesn’t already improve performance, part 2 will focus exclusively on it.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/hades_hu553015f1d31be7c428c7f3e0029817ed_1880483_800x0_resize_q90_bgffffff_box_3.jpg" alt="Becoming playable! (Hades &amp; Mario Golf: Super Rush)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./golf.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/golf_hu1b2e51634300dbc5ef6679130f285912_3536365_800x0_resize_q90_bgffffff_box_3.jpg" alt="Becoming playable! (Hades &amp; Mario Golf: Super Rush)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Becoming playable! (Hades &amp; Mario Golf: Super Rush)</p> <p>This story started <a href="https://www.youtube.com/watch?v=6IXecLOXWR4">many moons ago</a>. The awesome devs working on <a href="https://github.com/skyline-emu/skyline">Skyline Emulator</a> finished implementing their <code>NVDRV</code> service (NVIDIA Driver service) and they offered it to us, as it is much more accurate than our old implementation.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/yokaibug_hu7699248f0aa2f7ec8a531f272b994029_243559_1024x0_resize_q90_bgffffff_box_3.jpg" alt="YO-KAI WATCH 4, before and after"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/yokaifix_hu508d7d4a163217ee0cd4b0823a75b47c_1895775_1024x0_resize_q90_bgffffff_box_3.jpg" alt="YO-KAI WATCH 4, before and after"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">YO-KAI WATCH 4, before and after</p> <p>The implemented changes in part 1 of Project Y.F.C. include:</p> <ul> <li>Full rework of the GPU driver, based on the reverse-engineering and code from Skyline Emulator with full permission from the respective team.</li> <li>Full rework of GPU memory management.</li> <li>Initial implementation of GPU Channels, fixing <code>Super Smash Bros. Ultimate</code> “World of Light” mode, <code>Deltarune</code>, and several other games.</li> <li>Bug fixes and performance improvements to the GPU DMA engine.</li> <li>Several fixes for Vulkan, the GPU Buffer Cache, and the Shader Decompiler, all of which affect multiple games.</li> <li>Reworked host frame presentation to be considerably smoother (improves <code>Xenoblade Chronicles</code> games).</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./wol.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/wol_hud3553d01153c1265e8d1b665e5c94112_2609033_800x0_resize_q90_bgffffff_box_3.jpg" alt="The World of Light single-player mode is now playable! (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./wol2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/wol2_hu13375a4a4d27cfa2874dfea1f070ddc9_2937762_800x0_resize_q90_bgffffff_box_3.jpg" alt="The World of Light single-player mode is now playable! (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The World of Light single-player mode is now playable! (Super Smash Bros. Ultimate)</p> <p>A large list of critical changes like this, sadly, brings regressions with it. We’re working to resolve these regressions, but Blinkhawk is busy with IRL things, so expect a delay to see these changes implemented into Mainline while we sort things out and pave the way for part 2. (Remember: you can check the hovercard or the PR itself to see its merge status!)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./witcher.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/witcher_hu4ae4f5e3e5045ffbaceb0240ec1a3253_4407778_800x0_resize_q90_bgffffff_box_3.jpg" alt="Not all games are in perfect shape... yet! (The Witcher 3: Wild Hunt)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./plaid.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/plaid_huc383c270b3ec45b7a90b8af20275c777_5795880_800x0_resize_q90_bgffffff_box_3.jpg" alt="Not all games are in perfect shape... yet! (The Witcher 3: Wild Hunt)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Not all games are in perfect shape... yet! (The Witcher 3: Wild Hunt)</p> <h2 id="project-andio">Project Andio</h2> <p>Not a name we&rsquo;ve mentioned before, right? Well, it was a surprise for us as well! <a href="https://github.com/Kelebek1">Maide</a> is behind this wonderful gift: <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8545" data-gh-pr="8545">an almost complete rewrite of yuzu’s audio engine.</a> </p> <p>The main driving force behind this project was to resolve the multi-year old issues that have accumulated thanks to our very old initial audio implementation. yuzu was missing many playback features, such as audio effects. But the old code was too hard to maintain, making it impossible to keep up with the Switch&rsquo;s updates over the years.</p> <p>Here is a before and after of <code>Metroid Dread</code> while underwater. You can notice the effects missing in the first recording, as if Samus was just out in the open.</p> <audio preload="auto" controls> <source src="./audiobug.mp3" type="audio/mpeg"> <a href="./audiobug.mp3">Download the audio instead</a> </audio> <audio preload="auto" controls> <source src="./audiofix.mp3" type="audio/mpeg"> <a href="./audiofix.mp3">Download the audio instead</a> </audio> <p>Cleaner code allows developers to more easily stay up to date (the current implementation uses the changes introduced in firmware version 14.0.0), and should help introduce changes found by reverse engineering in the future.</p> <p>The list of fixes is so large, it’s practically countless. While over 15 official issues were fixed, it’s impossible to know how many undocumented issues have been resolved.</p> <p>We plan to have a dedicated article for Andio in the near future where we will dig deeper into the changes introduced.</p> <p>All users can enjoy the benefits of Project Andio, available in both Mainline and Early Access!</p> <h2 id="preliminary-work-on-project-london">Preliminary work on Project London</h2> <p>Yes, <a href="https://github.com/bunnei">bunnei</a>, it’s London.</p> <p>For those that didn’t catch on to the name, Project <strong>L</strong>on<strong>d</strong>o<strong>n</strong> is our work to get LDN (Local Wireless) support into yuzu, including hosted rooms for online connectivity.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8541" data-gh-pr="8541">Such rooms, and their corresponding user interface,</a> are what <a href="https://github.com/yuzu-emu/yuzu/pull/8541">Tobi</a> has been working on.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lobby.png" title=" Multiplayer rooms can be created, with chat functionality."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/lobby_hu3125b5f4232f90738dcf0a73557b5620_94194_820x0_resize_q90_bgffffff_box_3.jpg" alt=" Multiplayer rooms can be created, with chat functionality."></a> <p class="has-text-centered is-italic has-text-grey-light"> Multiplayer rooms can be created, with chat functionality.</p> </div> </div> <p>The implementation is based on <a href="https://citra-emu.org/">Citra</a>, and while it’s already perfectly functional, it won’t be available for users until the network backend is ready.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./puyo.png" title=" How&#39;s SEGA nowdays? (Puyo Puyo Tetris)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/puyo_hu1414f042b03477e6adac9237a1ea3c0a_909291_820x0_resize_q90_bgffffff_box_3.jpg" alt=" How&#39;s SEGA nowdays? (Puyo Puyo Tetris)"></a> <p class="has-text-centered is-italic has-text-grey-light"> How&#39;s SEGA nowdays? (Puyo Puyo Tetris)</p> </div> </div> <p>Thankfully, as you can see above, internal testing has been positive under ideal conditions, so the “only” remaining work is tweaking and bug fixing. If only it were that simple…</p> <p>An online service like this requires the transfer of network packets, so <a href="http://enet.bespin.org/">ENet</a> is added as a dependency.</p> <p>Stay tuned for future improvements on this work in progress!</p> <h2 id="core-timing-or-how-to-suffer-so-much-with-a-fix">Core timing, or how to suffer so much with a fix</h2> <p>It has been an eventful month for a long-maligned corner of the yuzu codebase, generally referred to in hushed tones among developers as CoreTiming. CoreTiming may be the cause of many timing-related emulation issues in yuzu.</p> <p>While reviewing Project Andio, Blinkhawk noted that one of his longstanding open pull requests, which implemented a more precise version of CoreTiming, fixed some audio corruption regressions in emulated games, and even fixed some games that were previously having issues with freezing, such as <code>Mario Strikers: Battle League</code>. With the new audio code being almost ready to go at that point, the team decided to get this pull request rebased and merged so we could have a new audio system without any regressions. The new CoreTiming implementation would use multiple host threads to wait for events, and should have been much better in theory.</p> <p>However, it didn&rsquo;t fix everything. Maide found that there were still some lingering issues with audio callbacks not looping as precisely as they needed to. In yuzu, looping events previously used CoreTiming to reschedule themselves for an exact number of milliseconds after their execution, instead of when they were intended to be executed. This caused significant drifting and issues with the new audio renderer. The usual victims were the most affected, users running CPUs with only 4 threads.</p> <p>To fix this, Maide <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8561" data-gh-pr="8561">reworked the way looping events were handled.</a> Now, CoreTiming automatically computes the correct time to reschedule a looping event, making the implementation significantly more precise for those types of events. With the change to looping events in, and noticing that the other changes Blinkhawk had added were causing serious regressions, the team opted to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8531" data-gh-pr="8531">remove the multi-threaded host CoreTiming implementation,</a> and then <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8591" data-gh-pr="8591">most of Blinkhawk&rsquo;s new implementation entirely,</a> as it was still causing serious performance problems for a subset of users.</p> <p>But that wasn&rsquo;t all that changed for timing this month. Intel Alder Lake (Gen. 12) CPU users on Windows have long been reporting noticeable clock drift in <code>Super Smash Bros. Ultimate</code>, but it got a lot worse since the NVNFlinger rewrite a few months ago. As previously reported, the resident bunnei rabbit mostly fixed this issue in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8428" data-gh-pr="8428">a follow-up pull request</a> which restored the (inaccurate) behaviour of the old implementation, and the clock drift issue improved significantly for those users.</p> <p>Maide, not content to just improve audio, discovered that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8650" data-gh-pr="8650">the way yuzu&rsquo;s NVNFlinger implementation was waiting on buffers would drift,</a> due to the same problem that was previously fixed in CoreTiming! Instead of reimplementing the fix here as well, he modified NVNFlinger to use a timing callback, which fixed the drifting issues in SSBU, and also resolved many longstanding issues with frametime inconsistency. This also provides a significant performance boost in many games due to keeping the frametime presentation consistent, and allows <code>Fire Emblem Warriors: Three Hopes</code> to be playable.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ftold.png" title=" Jumpy, visible stuttering"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/ftold_hua81e2c515a533b913e3b9beb4c56a2f2_18984_298x0_resize_q90_bgffffff_box_3.jpg" alt=" Jumpy, visible stuttering"></a> <p class="has-text-centered is-italic has-text-grey-light"> Jumpy, visible stuttering</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ftnew.png" title=" Flat, smooth as silk"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/ftnew_hud2400d24186dbdc91813b26ca3839176_19423_298x0_resize_q90_bgffffff_box_3.jpg" alt=" Flat, smooth as silk"></a> <p class="has-text-centered is-italic has-text-grey-light"> Flat, smooth as silk</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./few3h.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/few3h_hu2a9bd98e5ed99a709257f29fa00a941c_5227404_800x0_resize_q90_bgffffff_box_3.jpg" alt="Time to smash those attack buttons (Fire Emblem Warriors: Three Hopes)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./3hopes.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/3hopes_huf0f87ddc0e9ea7a8259be69fbb31664d_9313875_800x0_resize_q90_bgffffff_box_3.jpg" alt="Time to smash those attack buttons (Fire Emblem Warriors: Three Hopes)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Time to smash those attack buttons (Fire Emblem Warriors: Three Hopes)</p> <p>Finally, <a href="https://github.com/BreadFish64">BreadFish64</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8543" data-gh-pr="8543">implemented a way to read the exact TSC frequency of the host CPU.</a> The <code>TSC</code> (timestamp counter) is a high precision timer measuring the number of base clock ticks performed by an Intel or AMD processor since boot. CoreTiming uses this value to emulate the ARM physical count register, which performs a similar role as the <code>TSC</code> for ARM devices, like the Switch. Getting the exact <code>TSC</code> frequency, as opposed to just estimating it, allows CoreTiming to avoid drifting due to mismatch between the host frequency, which depends on your CPU and the guest clock frequency, which is fixed to 19.2MHz.</p> <p>More precision and faster boot times are never a bad thing!</p> <h2 id="kernel-changes">Kernel changes</h2> <p>While using the new debugger on games and homebrew, <a href="https://github.com/comex">comex</a> spotted an issue causing yuzu to miss breakpoints in code that had already been run, or hit breakpoints which had already been deleted. <a href="https://github.com/merryhime">Merry</a> investigated and discovered an inaccuracy in <a href="https://github.com/merryhime/dynarmic">Dynarmic&rsquo;s</a> caching of code blocks. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8571" data-gh-pr="8571">Fixing the cache clearing and calculating block hashes correctly</a> fixes the issues with breakpoints being hit.</p> <p>comex also observed an issue with watchpoints, where resuming execution after breaking on a watchpoint would seemingly fail to resume with the correct state. <a href="https://github.com/liamwhite">byte[]</a> investigated the issue and found that it happened when Dynarmic failed to update the PC register inside watchpoint callbacks. Merry fixed this issue again by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8569" data-gh-pr="8569">completely rewriting Dynarmic&rsquo;s support for watchpoints,</a> now breaking immediately when necessary and avoiding almost all of the performance penalty of enabling watchpoints. Nice!</p> <p>byte[] has also been hard at work fixing various kernel issues and inconsistencies throughout June, and this month is no exception. This time around, while searching for the source of a mysterious freezing bug in <code>Super Mario Galaxy</code>, he rewrote the entire scheduler and brought it in line with the current state of the art in reverse engineering of the Switch kernel. This fixed issues in a number of games, but most notably fixed the freezing issues users had in <code>Mario Strikers: Battle League</code> (once you use an <a href="https://github.com/piplup55/switch-mods/blob/master/mario%20strike%20battle%20league/cutscene%20skip.7z?raw=true">intro-skipping mod</a>), and allowed <code>Mononoke Slashdown</code> to boot for the first time.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./strikers.png" title=" Some graphical bugs are expected for now (Mario Strikers: Battle League)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/strikers_hu11462cc00946767b41fbf8fedf0cae7a_9350957_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Some graphical bugs are expected for now (Mario Strikers: Battle League)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Some graphical bugs are expected for now (Mario Strikers: Battle League)</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mononoke.png" title=" Mononoke Slashdown"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/mononoke_hub24703ee76271d54d42213edce3ebe7c_1363543_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Mononoke Slashdown"></a> <p class="has-text-centered is-italic has-text-grey-light"> Mononoke Slashdown</p> </div> </div> <p>While preparing the new scheduler for release, byte[] also noticed an inefficiency in the way guest threads were being emulated. To fix it, he changed the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8532" data-gh-pr="8532">process of starting fibers</a> to use support for C++ language features, and significantly simplified the implementation.</p> <h2 id="gpu-changes">GPU changes</h2> <p>Last month, <a href="https://github.com/behunin">Behunin</a> contributed a new GPU queue implementation intended to improve the performance of submission handling from the emulated game. Some time after this, freezing issues in <code>Fire Emblem: Three Houses</code> started cropping up. After a long trail of hunting, byte[] thought the issue had been found and fixed by pull requests <a href="https://github.com/yuzu-emu/yuzu/pull/8483">#8483</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/8538">#8538</a>, but more careful debugging revealed that the cause of the freeze was unfortunately from the new GPU queue implementation! <a href="https://github.com/Morph1984">Morph</a> stepped up and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8542" data-gh-pr="8542">reverted the use of the new queue implementation,</a> finally fixing the issue, at least for now.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./feth.png" title=" Don&#39;t ask (Fire Emblem: Three Houses)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/feth_huef8e9d78076a23ffe918e2775e859418_2065159_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Don&#39;t ask (Fire Emblem: Three Houses)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don&#39;t ask (Fire Emblem: Three Houses)</p> </div> </div> <p><code>Xenoblade Chronicles 3</code>, one of the most anticipated Switch releases in a while, released, and to the dismay of the yuzu community, would crash on boot when using Vulkan. Due to differences in time zones, Maide was our first developer to lay hands on the new game, with byte[] lagging behind. Maide found that there were some Vulkan shaders that crashed the GPU driver when they were compiled. yuzu is different from most Vulkan programs, and it directly generates shaders in binary format to respond to the needs of the game&rsquo;s shaders, which can cause problems when the way yuzu translates a shader is different from the way a GLSL compiler would translate it. byte[] quickly helped Maide identify the sources of these shader compilation crashes and, together, fixed both <code>FSwizzleAdd</code> and <code>ConvertDepthMode</code>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8667" data-gh-pr="8667">allowing users to run the game in Vulkan.</a> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc31.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/xc31_hu1f38d650cefdc3f0c5fd81c50d62ee2a_2550775_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Night for the amazing pics! (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc32.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/xc32_hu2542c0ec1bbb7c9949db9ad2ae887d74_2491462_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Night for the amazing pics! (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc33.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/xc33_hu5b25b5d5660cdb132ee46f0088e9fe4a_2656943_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Night for the amazing pics! (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc34.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/xc34_hu7d0f3d0a9d170e01f2b23be9e765d43f_2707690_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Night for the amazing pics! (Xenoblade Chronicles 3)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/xc3_hu6d47ae15be31a6df0d7b93f43f8a45c0_2303265_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Night for the amazing pics! (Xenoblade Chronicles 3)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Thank you Night for the amazing pics! (Xenoblade Chronicles 3)</p> <p>We’re aware that AMD Radeon GPUs running on Windows still experience crashes with Vulkan at boot. This is because those drivers lack support for the <code>VK_FORMAT_R16G16B16_SFLOAT</code> texture format. We implemented an alternative path emulating this format with a similar one to solve this issue. We’ll cover it more deeply in the next progress report, along with several other bugfixes for this amazing game.</p> <p>Another of the various issues affecting this new release is an absurd level of memory usage when running in OpenGL. yuzu, in the past, cleaned shader sources after dealing with the shader. Now, for some reason, this game manages to skip that check. In order to improve the ridiculous memory usage, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8684" data-gh-pr="8684">implemented</a> <code>glDetachShader</code>, a more “official” way to achieve the same result. While this doesn’t solve the issue entirely, testing shows a 5GB reduction in RAM usage from just a single code line addition.</p> <p>Let’s stay on the subject of GPU emulation for a bit longer. In a past Progress Report, we explained how <a href="https://github.com/lat9nq">toastUnlimited</a> <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/#vulkan-by-default">implemented a status check system</a> to ensure good Vulkan compatibility when opening yuzu for the first time.</p> <p>The original implementation worked by running a small Vulkan instance at boot, detecting if it crashed, and saving the result in the configuration file. On the next boot after the crash, yuzu informs the user and locks itself to only offer OpenGL. This required two boots to get the whole picture, and a manual intervention by the user was needed to re-enable Vulkan as an option, pressing a button in yuzu’s configuration.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8564" data-gh-pr="8564">This new approach</a> uses a child process that is only tasked with starting the Vulkan loader. If the child process crashes, the parent process marks the currently running instance of yuzu as not being Vulkan compatible. This has the benefit of only having to run yuzu once to detect the current status. If the user solves the issue (updating the drivers or any Vulkan layer application causing issues), only restarting yuzu is needed as nothing is changed in the configuration files now.</p> <p>This change helps users identify issues and stop potential crashes, but the general recommendations still apply: manually update your GPU drivers (never trust Windows Update), and keep any application that runs an overlay or records the screen updated to their latest version.</p> <p>Moving on to more specific game fixes not related to GOAT <code>Xenoblade Chronicles 3</code>, our resident Kirby clone, Morph, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8528" data-gh-pr="8528">implemented a texture format</a> <code>MONSTER HUNTER RISE</code> has been asking for: <code>ASTC_10x6_UNORM</code>. That’s right, another <code>ASTC</code> format. Your GPU will hate you while decoding it.</p> <p>This doesn’t solve the rendering bugs we face with this game, but it makes things look a bit better!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mhr.png" title=" Rise ye Tarnished! Wait, wrong game (MONSTER HUNTER RISE)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/mhr_hu523de584624e16ec57cabea12cfabfd8_13543388_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Rise ye Tarnished! Wait, wrong game (MONSTER HUNTER RISE)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Rise ye Tarnished! Wait, wrong game (MONSTER HUNTER RISE)</p> </div> </div> <h2 id="linux-flatpak-discover-and-appimage-fixes">Linux Flatpak (Discover) and AppImage fixes</h2> <p>While Flatpak is not the recommended way for our users to enjoy their favourite Switch titles on Linux, due to lower performance and some missing desktop integration features, it is a great option for many Linux users who have Flatpak installed by default and want a low-friction way to get access to yuzu. It has been the preferred choice by Steam Deck users since its release. As the reports from users rolled in, the team fixed some notable Flatpak-exclusive regressions this month.</p> <p>But why were these issues Flatpak-exclusive, and not found in the regular Linux AppImage builds? Flatpak enables extra checks in the C++ standard library, which are aimed to catch buffer overflow errors before they happen, intending to help with debugging. Unfortunately, if a check fails, it causes yuzu to instantly crash, which makes it more difficult to debug the issue from yuzu&rsquo;s log files alone.</p> <p>The switch to Vulkan by default caused games which used any CPU-based rendering to crash. If a game wants to render an image to the screen from the CPU, instead of the GPU, it will first convert the image into an optimized layout that the Switch GPU understands, and then ask the GPU to render the optimized image. To deal with this, yuzu undoes this layout conversion and uploads the data to the host GPU for presentation. byte[] discovered that due to the size of the optimized layout and the unoptimized layout being different, a subspan used in unoptimizing the layout would overflow and cause the check to fail. The fix was simple: just <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8611" data-gh-pr="8611">use the optimized size for the converted layer,</a> since it would always be larger.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wetbear.png" title=" Thanks Wetbear for the pic!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/wetbear_hu64246610b2b8e4fe9286df23c0424922_2639713_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Thanks Wetbear for the pic!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Thanks Wetbear for the pic!</p> </div> </div> <p>It wouldn&rsquo;t be a proper yuzu pull request without a seemingly unrelated regression. <code>Pokémon: Let's Go, Pikachu!/Eevee!</code> had a strange performance regression caused by byte[]&rsquo;s previous change, where the framerate when attempting to play with Pikachu or Eevee would drop to approximately 7 frames per second. byte[] investigated it and found that using the larger size caused the process of re-optimizing a frame for the game to read back to be much slower, since it was now dealing with a much larger image. He then fixed it by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8658" data-gh-pr="8658">using different sizes for the optimized and unoptimized images,</a> finally putting these foolish performance issues to rest.</p> <p>Project Andio introduced a few new regressions in the Flatpak builds as well. One of these was fixed in the pull request itself before it was merged.</p> <p>When decoding buffers which were input from the emulated game, it was possible for a span operation to overflow. Maide fixed this by being more careful about handling the sample buffers when decoding input. From user reports, there were still crashes, and Maide found an issue with <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8657" data-gh-pr="8657">the <code>DepopPrepare</code> command, causing another overflowing span.</a> Fixing this finally allowed users to enjoy the Flatpak builds once more. Flatpak Linux users rejoice!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./flathub.png" title=" Simple and convenient"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/flathub_hu93dad4de9ab9c1d1ea1e243b5eca0496_493724_982x0_resize_q90_bgffffff_box_3.jpg" alt=" Simple and convenient"></a> <p class="has-text-centered is-italic has-text-grey-light"> Simple and convenient</p> </div> </div> <p>Flatpak isn&rsquo;t the only one to get a piece of the cake, AppImage receives some love too!</p> <p>Vulkan detection is not only a Windows issue, it can also happen in <a href="https://www.linuxfoundation.org/">free land</a>. toastUnlimited found out that the <code>libQt5Multimedia</code> library causes issues with Vulkan in AppImage builds. Since the library is used, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8642" data-gh-pr="8642">excluding <code>libwayland-client</code></a> is the workaround in place for now. We’ll evaluate the user response we get from this change and consider keeping it or removing <code>libQt5Multimedia</code> altogether.</p> <p><a href="https://github.com/Docteh">Docteh</a> started working on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8625" data-gh-pr="8625">improving the environment variables</a> used in our build process to give AppImages a proper title bar. Once this work is finished, the title bar should look identical to Windows builds.</p> <h2 id="input-improvements">Input improvements</h2> <p>A unique feature of the Nintendo Switch is the capability to use infrared cameras installed in the right Joy-Con. The main function of the cameras is to detect shapes and measure the distance to objects, but it can also be used to transmit a feed to a screen, letting you turn your Joy-Con into a heat-seeking monstrosity. <a href="https://en.wikipedia.org/wiki/Fox_(code_word)">Fox-2</a>!</p> <p>Interested in adding this awesome feature to yuzu, and providing full support for games like <code>Game Builder Garage</code> or the <code>Nintendo Labo</code> collection, <a href="https://github.com/german77">german77</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8636" data-gh-pr="8636">emulated the clustering processor</a> required to let the games access the camera on the Joy-Cons or any camera the user wants to provide, even if it is a desktop capture obtained from OBS Studio.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ir.png" title=" While this looks like a homebrew app, it&#39;s in fact the real IR interface Nintendo provides for its games"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/ir_huaac3600f1f56f00fca4184664fcb0c82_76718_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" While this looks like a homebrew app, it&#39;s in fact the real IR interface Nintendo provides for its games"></a> <p class="has-text-centered is-italic has-text-grey-light"> While this looks like a homebrew app, it&#39;s in fact the real IR interface Nintendo provides for its games</p> </div> </div> <p>Users wanting to play with this setting can find it in <code>Emulation &gt; Configure… &gt; Controls &gt; Advanced tab &gt; Infrared Camera</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./camera.png" title=" What a sleek little menu"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/camera_hue3c4a4e01684251287742af58e76e685_59073_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" What a sleek little menu"></a> <p class="has-text-centered is-italic has-text-grey-light"> What a sleek little menu</p> </div> </div> <p>This work doesn’t include the moment processor required by <code>1-2-Switch!</code> just yet.</p> <p>Steam Deck users reported having issues when using external controllers, but not while using the integrated Deck controls. toastUnlimited hopped onto the issue and found that the reason is the included prerelease <a href="https://www.libsdl.org/">SDL2</a> version we’ve been using. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8607" data-gh-pr="8607">Reverting to a slightly older version</a> solved the issue.</p> <p>A recent and very interesting community effort is to focus on adding online functionality to single player games, allowing for fun co-op opportunities not possible in the original game. <code>Super Mario Odyssey</code> recently received a <a href="https://github.com/CraftyBoss/SuperMarioOdysseyOnline">mod that allows for this online functionality</a>, and the one thing keeping yuzu from supporting it was the on-screen keyboard lacking a way to input an IP address! Luckily, Morph was on the case and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8633" data-gh-pr="8633">implemented the necessary symbols</a> to input the required IPv4 addresses by the online mod.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smoo.png" title=" Up to 10 people at once! (Super Mario Odyssey)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/smoo_huc9331193ae607db33d607c719a5abf78_104460_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Up to 10 people at once! (Super Mario Odyssey)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Up to 10 people at once! (Super Mario Odyssey)</p> </div> </div> <p><a href="https://github.com/Link4565">Link4565</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8598" data-gh-pr="8598">implemented some required fixes</a> in yuzu’s network services to improve compatibility with this awesome mod. Thank you very much!</p> <p>Have fun ruining Bowser’s wedding!</p> <h2 id="ui-changes">UI changes</h2> <p>A small regression from the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/#project-kraken">input rewrite</a> revealed itself just now. The WebApplet’s input bit was assumed incorrectly, causing user input to be completely ignored. Thankfully, Morph <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8536" data-gh-pr="8536">found the reason</a> and implemented the fix.</p> <p>Last month, Docteh <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/#ui-changes">renamed</a> the status bar’s DOCKED status (redundancy, yeah!). For consistency, <a href="https://github.com/goldenx86">this dumb writer</a> decided to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8610" data-gh-pr="8610">do the same for the Controls configuration window,</a> for consistency.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dock.png" title=" Boring change, who is responsible for this?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/dock_hu08b23143df39a653b5bd1af6aa474c0f_71817_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Boring change, who is responsible for this?"></a> <p class="has-text-centered is-italic has-text-grey-light"> Boring change, who is responsible for this?</p> </div> </div> <p>Sometimes something &ldquo;functioning as designed&rdquo; can look stalled from the user’s point of view due to how the UX (user experience) is presented, ask any new Linux user for example. In this case, when loading an application, the shader progress bar at boot would appear stuck if a game was started with no previous pipeline cache or if a homebrew was booted. Since this leads to confusion, byte[] decided that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8622" data-gh-pr="8622">it’s better to reset the status bar</a> than let it remain stuck until the program finishes loading. As said before, the devil is in the details.</p> <p>One of the available configurable hotkey options in <code>Emulation &gt; Configure… &gt; General &gt; Hotkeys</code> is <code>Audio Volume Up/Down</code>. Users have requested to tune the curve in how volume is changed so that it’s more sensitive at lower values. Human hearing senses volume logarithmically instead of linearly, so it makes perfect sense. german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8656" data-gh-pr="8656">added incremental steps</a> the closer you are to 0% volume as a way to better copy how our flesh and bone bodies perceive the world.</p> <h2 id="general-bugfixes-and-improvements">General bugfixes and improvements</h2> <p>A beautiful feature of tightly integrated systems is their wonderful control over suspend and resume, and the Steam Deck is no exception. If you&rsquo;ve ever experienced issues with suspend and resume, you know what I mean. Experienced developer <a href="https://github.com/devsnek">devsnek</a> wants to help yuzu take advantage of this feature over the course of three <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8585" data-gh-pr="8585">different</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8592" data-gh-pr="8592">pull requests.</a> This includes <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8581" data-gh-pr="8581">emulating the actual suspend/resume mechanic of the Switch,</a> as some games make use of it as one of their gameplay features. With these changes, users can suspend their games by simply pressing the power button of the Deck, exactly like on a Switch.</p> <p>For those of us living in remote places, suffering from terrible ISPs, or both (FML), we have fantastic news! toastUnlimited reduced the size of each yuzu download by around 24MB by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8686" data-gh-pr="8686">only including what specifically belongs to yuzu</a> in its source. Those interested in building the bundled source that comes with the installer must now run <code>git submodule update --init --recursive</code> in order to be able to compile the project.</p> <h2 id="hardware-section">Hardware section</h2> <p>This is a new section to communicate and discuss new relevant bugs, fixes, and findings related to specific hardware that can affect the user experience within yuzu.</p> <h4 id="nvidia-missing-the-perfection-that-47212-was">NVIDIA, missing the perfection that 472.12 was</h4> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/#psa-for-amd-radeon-users-and-nvidia-tags-along">We mentioned last month</a> how the 516 series of drivers is detrimental to Maxwell and Pascal users, making Vulkan unstable. We’re still debugging the issue, as it isn’t easy to catch, but a possible cause is suspected: GPU accelerated <code>ASTC</code> texture decoding. If you own a Maxwell or Pascal GPU, must remain on the latest driver update, and want to test if you can make Vulkan stable again, try disabling <code>Accelerate ASTC Texture Decoding</code> in <code>Emulation &gt; Configure… &gt; Graphics</code>. Please report your results on our <a href="https://community.citra-emu.org/c/yuzu-support/14">forums</a> or <a href="https://discord.gg/u77vRWY">Discord server</a>.</p> <p>Another known issue caused by the 516 series of drivers is some funny flickering on trees in KOEI TECMO games like <code>Hyrule Warriors: Age of Calamity</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./aocbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./aoc.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Day time party! NVIDIA Vulkan Left: 516.94 &amp; Right: 512.95 (Hyrule Warriors: Age of Calamity)</p> <p>These issues could either be regressions or undocumented behaviour changes, possibly caused after following the API specification more rigorously.</p> <p>There are also performance related issues affecting users with G-SYNC/FreeSync displays, causing low framerates (usually games get stuck at 24-30 FPS). We have a few ways to bypass this issue:</p> <ol> <li>Unfocus and refocus yuzu’s window each time you boot a game.</li> <li>In yuzu, disable <code>View &gt; Single Window Mode</code>.</li> <li>Enable <code>Exclusive Fullscreen</code> from <code>Emulation &gt; Configure.. &gt; Graphics &gt; Fullscreen Mode</code>. Then just play your games in fullscreen by pressing F11.</li> </ol> <p>The root of the problem is caused by some bad combination of running a Qt window inside another window, and NVIDIA’s way of detecting the framerate of windowed applications. Removing any of the two factors solves the low framerate while still taking advantage of Variable Refresh Rate.</p> <h4 id="amd-opengl-25-years-in-the-making">AMD OpenGL, 25 years in the making</h4> <p>Hell froze over, pigs learned to fly, and starting with the Windows driver version 22.7.1, AMD introduced a completely new OpenGL driver, making Radeon cards on Windows viable options to use both APIs, not just cool kid Vulkan. Performance is close to 100% higher, or more in some titles, and many rendering bugs are fixed. But why write about it, let the numbers do the talking:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./perf.png" title=" Thank you RodrigoTR!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/perf_hubbcafc88b9eb4d988aaf49af90e647b8_19658_706x0_resize_q90_bgffffff_box_3.jpg" alt=" Thank you RodrigoTR!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Thank you RodrigoTR!</p> </div> </div> <p>Wow! That&rsquo;s a lot of numbers, let&rsquo;s try to make it easier to digest:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/xc2_hu762aa5cd87c55a3553e758974a1cf8dc_20004_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/botw_hud8302d4632dd168a138b4fbd1a777498_21666_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/smo_hu460e6fd7005df3bca3bb131c98ccd891_20811_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./psw.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/psw_hu061ce1f6bdb355e4b8e9781546a20a9b_19839_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pla.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/pla_hu5b74151c2b48ef1ff74e130361980226_20032_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./md.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/md_hucc9421ffacdc81e8c3d7ff401360aee4_19566_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mk8.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/mk8_hua0fb0dc58641dddafda589d40e62039c_20410_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks toastUnlimited!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Thanks toastUnlimited!</p> <p>We&rsquo;re not experts in the benchmarking area, so hopefully the above graphs help.</p> <p>Above are results of an RX 6600 and a GTX 1660 SUPER running a few games in OpenGL and Vulkan. 22.6.1 represents the old infamous OpenGL driver, 22.7.1 is of course the new driver. Linux is represented by Mesa 22.1.3 running radeonsi with the amdgpu kernel module for OpenGL, and RADV for Vulkan. NVIDIA is running its latest (at the time of writing) Windows driver. Remaining relevant hardware used is a 5600X and 16GB of RAM at 3600MHz. The RX 6600 was running at PCIe 4.0 8x with Smart Access Memory enabled, although that won’t make a difference, more on that later. Operating systems used are Windows 11 and Manjaro Linux, both up to date and on their respective default stable branches. yuzu is on Mainline 1112, with GPU accuracy set to normal to make GPU driver bottlenecks easier to measure, 1X resolution multiplier, and Default value for Anisotropic Filtering.</p> <p>A single regression under investigation and reported to AMD aside (<code>Xenoblade Chronicles 2</code> crashes loading Abble’s Fountain, the measuring spot, could be caused by some driver thread crash), performance is now very close to Vulkan numbers, be it either from AMD or NVIDIA.</p> <p>It’s now perfectly valid for a Radeon user to switch to OpenGL if a specific game requires it, like for example with <code>Xenoblade Chronicles 3</code>, or a Unity/Unreal Engine based game (<code>SHIN MEGAMI TENSEI V</code>). As a bonus, while not being very stable, the SPIR-V shader back-end can be used on games with “simple” shaders like <code>Super Smash Bros. Ultimate</code> or <code>Super Mario Odyssey</code>, making shader building much more tolerable when compared to GLSL, giving it a performance much closer to the Nvidia-only GLASM.</p> <p>Another lesson learned from this is that some games, like <code>Legend of Zelda: Breath of the Wild</code>, just outright prefer NVIDIA&rsquo;s mature OpenGL driver. Ara ara.</p> <p>Lastly, to end this Red Team section. <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/#vulkan-is-the-future">In the past</a>, we reported a way to defeat RDNA2’s overcorrecting power manager in order to get decent framerates. This method, while simple, has a downside: It’s an overclock. Or at least counts as one.</p> <p>We found an alternative that should be more globally applicable. The trick this time is to make the driver force high clocks on a more important section of the GPU when speaking about emulation performance in general: GPU VRAM. All this while keeping the warranty in check.</p> <p>The process is simple, make the integrated video encoder work in the background while yuzu (or any other emulator) runs. This is easily achieved from Radeon Software by going to <code>Settings &gt; Record &amp; Stream</code> and enabling <code>Instant Replay</code>. Intel/Linux owners should be able to reach similar results by instead using the Xbox Game Bar or <a href="https://obsproject.com/forum/resources/instant-replay.575/">setting OBS to keep a buffer</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./instantreplay.png" title=" A driver toggle for power management would be so much simpler"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2022/instantreplay_hu7426388f49d367d9cd8b476a588b23cb_142540_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" A driver toggle for power management would be so much simpler"></a> <p class="has-text-centered is-italic has-text-grey-light"> A driver toggle for power management would be so much simpler</p> </div> </div> <p>After this, in yuzu enable Exclusive Fullscreen from <code>Emulation &gt; Configure.. &gt; Graphics &gt; Fullscreen Mode</code>. Then just play your games in fullscreen by pressing F11. This step can be avoided if you also enable <code>Record Desktop</code>, but please keep in mind this will increase your power consumption even while idling.</p> <p>The performance gains are the same as with the previous overclocking method, up to 73% in GPU bottlenecked titles.</p> <p>RX 6500 XT and RX 6400 users, since you lack a video encoder in the first place, refer to our original method mentioned at the start, or ask for a refund.</p> <h4 id="intel-killing-support-for-2-year-old-hardware">Intel, killing support for 2 year old hardware</h4> <p>Intel <a href="https://community.intel.com/t5/Graphics/Graphics-Driver-Support-Update-for-10th-Generation-and-Older/m-p/1403969/thread-id/108899">recently announced</a> that their Windows driver for Gen. 9, Gen. 9.5, and Gen. 11 GPUs (that is any CPU based on the 14nm Skylake architecture and all its many marketing renames, plus Ice Lake) is now in “legacy software support”, which in layman&rsquo;s terms means they are officially dead. While this doesn’t affect yuzu immediately, any new Vulkan features we add in the future could potentially break functionality in a similar way to what happened with old AMD GCN hardware last year. This leaves integrated Intel GPU users with a single alternative, Linux, which offers support for even older hardware. For example, an ancient HD Graphics 4400 <em>can</em> run yuzu with the Mesa drivers.</p> <p>Users should consider learning how to use Linux if a hardware upgrade is not a viable option in the near future, Mesa has always offered better performance for Intel GPUs.</p> <h2 id="future-projects">Future projects</h2> <p>Part 2 of <code>Project Y.F.C.</code> is a bit delayed for now, real life issues as previously mentioned, but its feature list and expected progression is laid out.</p> <p><code>Project London</code> is progressing in a healthy fashion, we loved the internal testing done so far.</p> <p>And a possibility has just recently started to open for even better GPU performance in the (not so near) future. <code>GPU fastmem</code> is one of the features that <a href="https://github.com/ReinUsesLisp">Rodrigo </a> had to leave for later, before passing the torch and moving onto “greener sides”.</p> <p>The main roadblock holding <code>GPU fastmem</code> back was driver support, which is now a mostly solved issue. We <em>only</em> need to start talks with the AMD, Intel, and the AMD Linux kernel module developers to ask for some increased limits. Once those obstacles are out of the way, yuzu should, for example, be able to take partial advantage of Resizable BAR/Smart Access Memory, helping reduce PCIe bottlenecks, and should help improve particle rendering to make GPU accuracy a less critical performance setting. No pressure, Blinkhawk!</p> <p>That’s all folks! This one turned out to be longer than expected. Thank you for staying until the end, and we hope to see you again next month! Thank you NazD for the summary pic!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> New Feature Release - Installer for Linux https://yuzu-mirror.github.io/entry/yuzu-linux-installer/ Thu, 11 Aug 2022 23:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-linux-installer/ <p>Hey there, yuz-ers! Guess what? We&rsquo;ve got some news to share. We&rsquo;re excited to announce that the yuzu installer now supports Linux! Let&rsquo;s jump right in!</p> <p>Hey there, yuz-ers! Guess what? We&rsquo;ve got some news to share. We&rsquo;re excited to announce that the yuzu installer now supports Linux! Let&rsquo;s jump right in!</p> <h2 id="whats-happening">What&rsquo;s happening?</h2> <p>As we mentioned, the yuzu installer is available for Linux. The installer will distribute <code>AppImages</code> of Mainline and Early Access builds for our Linux users.</p> <p>You can now download the new installer from our <a href="https://yuzu-mirror.github.io/downloads/">Downloads page</a>.</p> <p>(Note: Early Access builds require a subscription to our <a href="https://www.patreon.com/yuzuteam">Patreon</a>. We appreciate any and all support!)</p> <h2 id="why">Why?</h2> <p>When we originally released our installer, our user base was predominantly composed of Windows users. Although a weak excuse, that&rsquo;s why the installer&rsquo;s Linux compatibility wasn&rsquo;t a priority for us then.</p> <p>But, over the years we&rsquo;ve seen consistent growth in the number of our Linux users and realized that we had to ensure that they reaped the benefits of the installer too. We&rsquo;re so happy our Linux community continues to expand and support us.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./install.png" title=" It&#39;s never a bad idea to pick both builds"> <img src="https://yuzu-mirror.github.io/entry/yuzu-linux-installer/install_hu5dcf227fba91978a12ac3beb2e9de572_63010_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It&#39;s never a bad idea to pick both builds"></a> <p class="has-text-centered is-italic has-text-grey-light"> It&#39;s never a bad idea to pick both builds</p> </div> </div> <p>Thanks to the efforts of <a href="https://github.com/lat9nq">toastUnlimited</a>, who implemented Linux compatibility for the installer, we&rsquo;re now able to address this long overdue feature request.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./download.png" title=" Remember, we update daily!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-linux-installer/download_hub6fa30b43e7cb4a31c8ce470d3023c04_45543_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Remember, we update daily!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Remember, we update daily!</p> </div> </div> <h2 id="fin">Fin</h2> <p>As with any new update, we&rsquo;ve tested the installer internally, but our efforts can&rsquo;t compare to the community as a whole. We could have easily missed an edge case or some weird bug or issue. So, please reach out to us on our <a href="https://discord.gg/u77vRWY">Discord</a> and report any bugs you find, so that we can quickly address them.</p> <p>That&rsquo;s all we have for now, until next time! Happy emulating!</p> <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> Progress Report June 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/ Sun, 10 Jul 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/ <p>Dear yuz-ers, we had fantastic progress during June! Driver bugs are being squashed, there are kernel and CPU improvements, UI and input changes, and more!</p> <p>Dear yuz-ers, we had fantastic progress during June! Driver bugs are being squashed, there are kernel and CPU improvements, UI and input changes, and more!</p> <h2 id="psa-for-amd-radeon-users-and-nvidia-tags-along">PSA for AMD Radeon users (and NVIDIA tags along)</h2> <p>Let’s begin with a driver bug we <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/#graphical-changes-driver-issues-and-the-nostalgia-bliss-that-is-the-good-old-64">mentioned last month</a>. The Vulkan extension <code>VK_KHR_push_descriptor</code> finally arrived for AMD hardware with driver version 22.5.2 for Windows, but it wasn’t stable. Radeon users would tell you that any game would crash in Vulkan after updating. To mitigate this, <a href="https://github.com/lat9nq">toastUnlimited</a> implemented an extension block for the specific Vulkan driver version AMD reports for 22.5.2 (and its equivalent Linux AMDVLK package), 2.0.226.</p> <p>Skip forward a month and the new 22.6.1 driver is released with <code>VK_KHR_push_descriptor</code> fixed! But, and there is a but, the new driver reports the same Vulkan version, 2.0.226, which forces our devs into a dilemma. Since the extension block can only work with what the GPU driver reports, the Vulkan driver version in this case, we can either keep the block and ensure compatibility with older broken drivers, or remove the block and force users to update to the current (at the time of writing) 22.6.1 driver. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8518" data-gh-pr="8518">We opted to do the latter,</a> as it keeps the codebase cleaner, and there is some evidence that suggests this may fix input lag issues found when using FreeSync displays.</p> <p>To be specific, AMD Radeon users with cards still supported by AMD (Polaris and newer) must update to the latest video driver, 22.6.1 or newer, in order to get proper Vulkan support. Users with older cards out of support (GCN 1 to GCN 3) don’t have to worry, that hardware already can’t update to newer drivers (custom drivers can’t update Vulkan to add new extensions either), and yuzu will use the slower code path that works without requiring support for <code>VK_KHR_push_descriptor</code>.</p> <p>Okay, that covers Radeon users. Let’s talk about the greener side. With the release of the 516.XX NVIDIA driver series, there seems to be a performance boost for Turing and Ampere GPUs running under Vulkan (that’s 3000, 2000, and 1600 series cards). Great, but it has a price.</p> <p>Maxwell and Pascal users (1000, 900, 750, and 745 series cards) will experience device loss crashes some minutes into running games in Vulkan. A device loss basically means the driver pulling the plug for some reason. Until we find the cause of this issue and either implement a fix or report it to NVIDIA, Maxwell and Pascal users should stick to 512.XX drivers.</p> <p>It’s always boring to start an article with a bunch of warnings, but this is one of the few tools we have available to reach as many affected users as possible.</p> <h2 id="graphical-changes">Graphical changes</h2> <p>We should be covering the release of the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8467" data-gh-pr="8467">first part of <code>Project Y.F.C.</code></a> here, but due to schedule issues it was moved to the next report. We&rsquo;re sorry for the inconvenience and we&rsquo;ll make sure to cover it in the next article. The good news is that besides yuzu Fried Chicken, there have been other fun GPU improvements to report.</p> <p><a href="https://github.com/behunin">Behunin</a> is back with a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8413" data-gh-pr="8413">very interesting optimization for our <code>gpu_thread</code>,</a> <a href="https://github.com/rigtorp/MPMCQueue">“a bounded multi-producer multi-consumer concurrent queue”</a>. This delivers a small 1 or 2 FPS performance boost, but more importantly, better recovery times after load related stuttering spikes.</p> <p>The beloved <code>The Elder Scrolls V: Skyrim</code>, once considered the benchmark for open world gaming, until better games came out that is, can now boot! <a href="https://github.com/skyline-emu/skyline">Skyline emulator</a> developer <a href="https://github.com/bylaws">bylaws</a> found the reason this classic refused to boot until now: <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8414" data-gh-pr="8414">the assumed behaviour of the first value</a> of the GPU related <a href="https://en.wikipedia.org/wiki/Semaphore_(programming)">semaphore</a> was wrong, it should perform a release instead of returning a constant zero. Now, thanks to this great find by bylaws, the Dovahkiin can finally wake up in that cart.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./skyrim.png" title=" Yes, we&#39;re finally awake (The Elder Scrolls V: Skyrim)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/skyrim_hu5352b2bd96b5b488ecde8fabe24a48e0_2840093_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Yes, we&#39;re finally awake (The Elder Scrolls V: Skyrim)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Yes, we&#39;re finally awake (The Elder Scrolls V: Skyrim)</p> </div> </div> <p>You can see we have some rendering issues to solve.</p> <p>One of our recent important rendering changes was the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/#graphical-changes-and-optimizations">NVFlinger rewrite</a>, who would have guessed that coding an implementation closer to the Switch would result in a smoother gaming experience?</p> <p>However, after its release, user reports mentioned timing and frame pacing issues in games like <code>Super Smash Bros. Ultimate</code>. Match time would pass increasingly slower, around a second longer per minute on Ryzen systems, and exacerbated with Intel Alder Lake CPUs (12th gen).</p> <p>The solution <a href="https://github.com/bunnei">bunnei</a> arrived to, contrary to what one would think, is to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8428" data-gh-pr="8428">implement a <em>less accurate</em> behaviour.</a> yuzu is multithreaded, and very heavily so (even if it doesn’t show up in CPU % usage graphs), and a 100% accurate implementation of NVFlinger would not be sensitive enough for the emulator’s requirements.</p> <p>Weird CPU architectures aside, while the issue is solved, Intel Alder Lake users are recommended to run the latest BIOS and chipset driver versions. Check your motherboard/laptop support sites for these updates.</p> <p>While still on the topic of NVFlinger goodies, we present a highly requested feature! Veteran users will remember that during its single threaded days, yuzu would allow control over game speed. With the arrival of multicore, known at the time as <a href="https://yuzu-mirror.github.io/entry/yuzu-prometheus/">Project Prometheus</a>, this feature was only available in single core mode, to the chagrin of many people. How time flies!</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8508" data-gh-pr="8508">yuzu now has control over the frame time calculation,</a> allowing a new method to unlimit the framerate regardless of the CPU emulation mode! You can find the option in <code>Emulation &gt; Configure… &gt; General &gt; Limit Speed Percent</code>. Needless to say, if you want to make a game run faster, the game should allow it, and you must have the hardware performance to reach the new target speed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./speed.png" title=" No visual change compared to previous versions, but completely new functionality"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/speed_hu8d70aea3dec927e0d3a183edff1ca53a_21188_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" No visual change compared to previous versions, but completely new functionality"></a> <p class="has-text-centered is-italic has-text-grey-light"> No visual change compared to previous versions, but completely new functionality</p> </div> </div> <h2 id="debugger">Debugger</h2> <p>Now, we&rsquo;re going to dive into a bit of developer paradise here.</p> <p>A few months ago, yuzu developer <a href="https://github.com/liamwhite">byte[]</a> found himself trying to debug some game issues in yuzu involving <a href="https://www.youtube.com/watch?v=-z99PKe7kOA">a certain Welsh cat</a>, among others. Unfortunately, he soon ran into more trouble, as it was exceedingly difficult to view the internal states of games and watch or modify their behaviour without needing to extensively hack up yuzu.</p> <p>The source of the pain was not having any way to use a debugger with the emulated games.</p> <p>Originally, yuzu inherited a <code>GDB-compatible debugger interface</code> from <a href="https://citra-emu.org">Citra</a>, but it was lacking many important features. And even that had to be deprecated during <a href="https://yuzu-mirror.github.io/entry/yuzu-prometheus/">Project Prometheus</a> (multicore emulation) because of its inherent shortcomings.</p> <ul> <li>It only worked with single core mode</li> <li>It was <em>slow</em> - it could sometimes take 30+ minutes to boot a game, particularly if you had any logging scripts</li> <li>It had some significant code quality issues</li> </ul> <p>After being removed during the Prometheus rewrite, yuzu did not have <em><strong>any</strong></em> debugger interface for a long time.</p> <h3 id="wait-what-is-gdb-again">Wait, what is GDB again?</h3> <blockquote> <p style="color:cyan;">The GNU Debugger (GDB) is a portable debugger that runs on many Unix-like systems and works for many programming languages, including Ada, C, C++, Objective-C, Free Pascal, Fortran, Go, and partially others.</p> <p>&ndash; <a href="https://en.wikipedia.org/wiki/GNU_Debugger"><em>Wikipedia</em></a></p> </blockquote> <p>With GDB, you can:</p> <ul> <li>Step through code on an instruction-by-instruction basis</li> <li>Modify memory and registers on-the-fly</li> <li>Even completely replace sections of running code dynamically</li> </ul> <p>Thus, you can see how extremely useful having a <code>GDB-compatible debugger interface</code> is, for developers and mod creators alike, as you can now debug games, homebrew, and game mods without having to fiddle with the console every single time.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gdb1.png" title=" A 32-bit example, in this case Super Mario Galaxy"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/gdb1_hu89d5ef38f8c23b467d91e540df40ebba_417683_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" A 32-bit example, in this case Super Mario Galaxy"></a> <p class="has-text-centered is-italic has-text-grey-light"> A 32-bit example, in this case Super Mario Galaxy</p> </div> </div> <h3 id="challenges">Challenges</h3> <p>After the old debugger interface had been deprecated, a few members of the community forked it and continued to patch and maintain it. A few notable ones are <a href="https://github.com/Hedges/yuzu">Hedges</a> and <a href="https://github.com/astrelsky/yuzu">astrelsky</a>. It was thanks to these forks that byte[] was able to add <a href="https://github.com/yuzu-emu/yuzu/pull/8000">initial support for the Wii Hagi emulator</a> in yuzu.</p> <p>However, he was soon faced with a much more annoying problem. <a href="https://github.com/yuzu-emu/yuzu/pull/8148">Recent changes to yuzu&rsquo;s CPU emulation</a> were causing Super Mario Galaxy to <a href="https://en.wikipedia.org/wiki/Deadlock">deadlock</a>. This issue only happened in multicore mode, right after the end of the first video cutscene. He was out of ideas and needed a functional debugger to continue investigating the issue.</p> <p>Since the old debugger interface didn&rsquo;t support multicore mode, byte[] had to start from scratch. Motivated by his drive to figure out the issue, byte[] began working towards a new GDB-compatible debugger interface for yuzu and he had very specific goals:</p> <ul> <li>It should work</li> <li>It should quickly get out of the way, so he could focus more on the root cause</li> </ul> <p>As the saying goes, &ldquo;the first step is always the hardest&rdquo;. And for byte[], indeed it was; his biggest challenge: &ldquo;Not knowing where to start&rdquo;.</p> <p>byte[] had the networking code written and working, but did not initially understand how to tie it with the threading code. After some healthy brainstorming sessions with other devs, he eventually figured out solutions for the challenges he was facing.</p> <h3 id="changes">Changes</h3> <p>Since he was starting from scratch, byte[] took the opportunity to make some sorely needed improvements to the interface.</p> <p>The old debugger interface was based on &ldquo;stepping&rdquo; the emulated CPU core. <code>Stepping</code> here means executing one instruction of the emulated program at a time.</p> <p>This posed a number of problems because almost all games have multiple threads, and if you are stepping and a thread asks to wait, then another thread can start running in its place in the same CPU core, with all the state changed. This breaks continuity and can even crash the debugger.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8394" data-gh-pr="8394">The new debugger interface</a> overcomes this by performing debug stepping on threads instead of stepping the emulated CPU core. In yuzu&rsquo;s context, when a thread is stepped, the debugger will ask the thread to step, then the Dynarmic interface will detect this condition and tell Dynarmic to step it, and when the thread has been scheduled again, it will mark that the thread stepped and notify the debugger again.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gdb2.png" title=" Super Mario Odyssey, in gibberish form"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/gdb2_hu881e36d07d8d1637c29563b58620d48d_121505_938x0_resize_q90_bgffffff_box_3.jpg" alt=" Super Mario Odyssey, in gibberish form"></a> <p class="has-text-centered is-italic has-text-grey-light"> Super Mario Odyssey, in gibberish form</p> </div> </div> <h3 id="what-are-the-benefits">What are the benefits?</h3> <p>Apart from this, we have a few more notable quality-of-life (QoL) additions. The debugger interface is now thread-stable, edge cases in stepping and pausing are now handled, and it has tons of useful debugging features, like:</p> <ul> <li>Support for both 32-bit and 64-bit code</li> <li>Ability to modify any memory and registers at any time</li> <li>Readout of guest thread names</li> <li>Support for unlimited numbers of instruction breakpoints</li> <li>Support for up to 4 memory watchpoints</li> </ul> <h2 id="ui-changes">UI changes</h2> <p>When talking about user interface and experience, you can always count on <a href="https://github.com/Docteh">Docteh</a>.</p> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/#general-bugfixes-and-ui-changes">In a repeat of what Morph fixed back in February</a>, Docteh found out that after a crash, the yuzu main window may reopen in some kind of borderless fullscreen… <em>thing</em>. The culprit was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8400" data-gh-pr="8400">the <code>UILayout\geometry</code> value in yuzu’s qt-config.ini file.</a> A slap in the face and the issue should be gone for good. Ouch.</p> <p>With the intention of helping new users adapt to yuzu, Docteh <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8405" data-gh-pr="8405">renamed the status bar</a> <code>DOCK</code> text (which used to only change colour to reflect its status) to <code>DOCKED/HANDHELD</code>. Now the current emulated status is clearer, and users won’t confuse it when using dark or light themes. Making things easier to understand must never be underestimated. Car makers should try it someday.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./dockbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/dockbug_hu80643cd51cad0f4c1bf57e7967bf0065_1865_800x0_resize_q90_bgffffff_box_3.jpg" alt="The devil is in the details"></a> </div> <div class="column is-bottom-paddingless"> <a href="./dockfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/dockfix_hu45af5b43c13e176b2b54bf3f99776ffd_2225_800x0_resize_q90_bgffffff_box_3.jpg" alt="The devil is in the details"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The devil is in the details</p> <p>Translation bugs always manage to slip by. The first time yuzu is opened, it will display a big folder with a plus icon, asking the user to add the location of their game dumps. The text of this message failed to re-translate if the user changed the interface language from <code>Emulation &gt; Configure… &gt; General &gt; UI &gt; Interface Language</code>. Solving this <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8449" data-gh-pr="8449">took a couple of changes in how the window handles re-translation.</a> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./addbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/addbug_hud2a2efa4f5c891ba26d5b0a2d9321050_27408_800x0_resize_q90_bgffffff_box_3.jpg" alt="Good way to learn another language!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./addfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/addfix_hu4636cbb4c5d1ba72c28f38b2c3d0ac79_24909_800x0_resize_q90_bgffffff_box_3.jpg" alt="Good way to learn another language!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Good way to learn another language!</p> <p>Docteh is also sneaking <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8427" data-gh-pr="8427">some preliminary work for migrating to Qt6</a> in the future. The <code>QDesktopWidget</code> class is <a href="https://doc.qt.io/qt-5/qdesktopwidget.html">now officially deprecated</a>, so <code>QScreen</code> takes its place.</p> <p>Additionally, some classes affecting the Web Applet were also deprecated, so <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8477" data-gh-pr="8477">some tweaks were in order to ensure future compatibility.</a> Hopefully Qt6 will mean the return of the Web Applet by default?</p> <p>Once we’re ready to migrate, this should provide better dynamic DPI scaling, allowing 4K display users to finally understand what is going on in the control settings window, for example.</p> <h2 id="input-improvements">Input improvements</h2> <p>Input is <a href="https://github.com/german77">german77’s</a> speciality, a “diamond in the rough” that is being polished one PR at a time, for eternity….</p> <p>Continuing the work with <code>Ring Fit Adventure</code>, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8487" data-gh-pr="8487">stubbed the <code>PerformSystemButtonPressingIfInFocus</code> service</a> , solving an SVC (Supervisor Call) crash which occurred when pressing ZL or ZR.</p> <p>With the official Switch update for the firmware version 13.2.0, Nintendo implemented a new <code>GetVibrationDeviceInfo</code>. While german77 worked on implementing those changes, one game in particular refused to work, <code>de Blob</code>. When this game sends a controller disconnect signal, it uses a <code>-1</code> value, which is invalid as only unsigned values are accepted on the Switch. Maybe it’s an emulation issue somewhere, or this game just loves to do this and the Switch just accepts invalid values. Regardless, our solution is to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8492" data-gh-pr="8492">replicate this peculiar behaviour.</a> The end result is <code>de Blob</code> now gets in-game!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./deblob2.png" title=" de Blob 2"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/deblob2_hu50cd847777931ce576a197f60a8340df_1512288_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" de Blob 2"></a> <p class="has-text-centered is-italic has-text-grey-light"> de Blob 2</p> </div> </div> <h2 id="kernel-and-cpu-changes">Kernel and CPU changes</h2> <p>Possibly the most silent part of yuzu’s code, but also the most critical. Kernel emulation is the engine block that keeps all parts working together in harmony, so you can expect that changing even a small part of it can have ripple effects anywhere. One must tread carefully, heh, thread carefully. Sorry, not sorry.</p> <p>Anyway, byte[] has been particularly busy this month in this delicate area, screwdriver in hand and not fearing anything. Several changes include getting up to date with the latest reverse engineering findings, but there’s more.</p> <p>To help with pause and resume functionality, he has <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8457" data-gh-pr="8457">implemented KProcess suspension,</a> “the kernel mechanism intended for this” as the pull request explains. Clean pause and resume is always a blessing when you have to leave the PC to do something else.</p> <p>While working on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8388" data-gh-pr="8388">simplifying guest pauses</a> for single core and multicore emulation, byte[] discovered that if asynchronous GPU emulation and multicore CPU emulation were disabled (something we strongly recommend against, but it’s a valid option for CPU thread starved users, or FX users), a race condition would happen when initializing the CPU and GPU threads. Several single threads still are multiple threads. Hammer in hand, byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8476" data-gh-pr="8476">implemented some barriers</a> to fix this specific crash.</p> <p>Pause is the word of the week, and this time, it could make a specific game crash. The old StallCPU behaviour would wait for all thread execution to stop. It was slow, but safe. <code>Fire Emblem: Three Houses</code> would get into a GPU thread race condition with the new method. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8483" data-gh-pr="8483">Telling the kernel to wait for all threads to stop on pause</a> avoids the crash.</p> <p>If, for some reason, yuzu would jump to an invalid address, emulation would hang and the log would get spammed with infinite amounts of <code>Unmapped Reads</code>. Fixing this required work on both Dynarmic and yuzu, resulting in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8490" data-gh-pr="8490">stopping ReadCode callbacks to unmapped addresses.</a> </p> <p><a href="https://github.com/shadowninja108/exlaunch">exlaunch</a> is a framework for injecting C or C++ code into Switch applications and modules. exlaunch can work on unpatched units, allowing developers to “go to town” with it. yuzu didn’t support it, but <a href="https://github.com/comex">comex</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8504" data-gh-pr="8504">implemented the required functionality</a> to have it up and running. Thank you!</p> <p>Newcomer <a href="https://github.com/DCNick3">DCNick3</a> joins the fray! For their first brawl, they <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8473" data-gh-pr="8473">implemented the <code>ExitProcess</code> SVC,</a> which allows homebrew apps to gracefully exit on close.</p> <h2 id="issues-with-third-party-antiviruses">Issues with third-party antiviruses</h2> <p>Users have recently reported crashes starting with Mainline version 1075 and newer. The cause seems to be third-party antiviruses, more specifically ESET/ NOD32. A <a href="https://help.eset.com/ees/8/en-US/idh_hips_main.html">HIPS</a> false positive is issued, sandboxing yuzu and blocking its access to the system page file. Basically, if fastmem is unable to secure 4GB of page file to work (or 6GB if the extended memory option is enabled), the emulator will crash.</p> <p>Three options are available to solve this for now:</p> <ul> <li>The user can disable fastmem from yuzu’s settings, the setting is in <code>Emulation &gt; Configure… &gt; General &gt; Debug</code>, from there, enable the option labeled as <code>Enable CPU Debugging</code> at the bottom, and from the CPU tab, disable both <code>Enable Host MMU Emulation</code> options near the bottom. This will produce a performance loss that can reach up to 30% on some games.</li> <li>Add a HIPS exception to both yuzu folders, <code>%appdata%\yuzu</code> and <code>%localappdata%\yuzu</code>. User reports show mixed results with this approach.</li> <li>Outright uninstall ESET and use Windows Defender instead.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./fastmem1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/fastmem1_hu5bb7061befbfda8019af1f450f35aebb_30173_800x0_resize_q90_bgffffff_box_3.jpg" alt="Here are image examples on how to reach the required options"></a> </div> <div class="column is-bottom-paddingless"> <a href="./fastmem2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2022/fastmem2_hu7ec8ad1b0bffc68567e26485de3e2907_34238_800x0_resize_q90_bgffffff_box_3.jpg" alt="Here are image examples on how to reach the required options"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Here are image examples on how to reach the required options</p> <h2 id="future-changes">Future changes</h2> <p>toastUnlimited has been working on <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8455" data-gh-pr="8455">making yuzu compatible to be compiled with</a> <a href="https://clang.llvm.org/">LLVM Clang</a> under <a href="https://www.mingw-w64.org/">MinGW-w64</a>. There are multiple reasons to consider this approach:</p> <ul> <li>The default compiler we use for Windows builds, MSVC, is currently unstable on its latest 2022 version, forcing us to revert to version 2019, and making yuzu lose some compiler optimizations in the process, losing a bit of performance.</li> <li>GCC 12, the default Linux compiler yuzu uses, has optimization errors and problems with some warnings, making it unviable at the moment.</li> <li>Clang allows for aggressive optimizations that should provide good performance boosts. One example is <a href="https://polly.llvm.org/">Polly</a>.</li> <li>Along with GCC, LLVM makes it much easier to produce code optimized for the SSE4.2 instruction set. That’s right Core 2 Duo users, you’re next in line for the chopping block.</li> </ul> <p>The main reason we haven’t switched to this new system by default is <code>Project Gaia</code>, or, well, the lack of Gaias currently. Some of its changes are mandatory to get Clang builds up and running on Windows. While this pull request is completed, its full implementation will be on hold until Gaia is out, which isn’t far away now.</p> <p>Get a kettle, boil some <a href="https://www.youtube.com/watch?v=XE6DT9y7L-w">wotah</a>, and make yourself a cuppa tea, because <code>Project London</code> has bloody began.</p> <p>That’s all folks! Thank you for staying until the end. See you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report May 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/ Sun, 12 Jun 2022 17:50:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/ <p>Greetings yuz-ers. This time around, we&rsquo;re covering small and incremental improvements to yuzu. Rest assured, we also have some major rewrites and improvements in the works, and we&rsquo;ll touch on those near the end. Roll the tape!</p> <p>Greetings yuz-ers. This time around, we&rsquo;re covering small and incremental improvements to yuzu. Rest assured, we also have some major rewrites and improvements in the works, and we&rsquo;ll touch on those near the end. Roll the tape!</p> <h2 id="end-of-support-for-eol-windows-versions">End of support for EOL Windows versions</h2> <p>Let’s first address the elephant in the room, shall we?</p> <p>While working on dynarmic and kernel emulation, including improving the compatibility of 4 thread CPU systems, we made changes to <a href="https://github.com/merryhime/dynarmic">dynarmic</a> and <a href="https://yuzu-mirror.github.io/entry/yuzu-fastmem/">fastmem</a> that broke support for Windows 10 revision 1803 and older, including Windows 7 and Windows 8/8.1.</p> <p>While fastmem was only ever designed to work with newer operating systems, the changes to dynarmic breaking support for older Windows versions was purely accidental. That being said, it is yet another sign of the times, and that a pre-Windows 10 experience in yuzu will continue to become more subpar. Due to our focus on improving accuracy, stability and performance, it doesn&rsquo;t make much sense to divert time and resources onto maintaining old and out of support operating systems. From Mainline version 991 and onward, only Windows 10 revision 1809 and newer, Windows 11, and Linux, will be the officially supported operating systems.</p> <p>This decision is reinforced by the lack of GPU driver support on EOL systems (which affects Vulkan support going forward), inconsistencies in the maximum path length (critical for file system emulation improvements), as well as worse memory handling on a kernel level, which is required to properly emulate the Switch and its subsystems.</p> <p>Not forcing the developers to divert their time into supporting dated platforms (which they no longer use), means that they can instead focus on improving the core emulation components.</p> <p>Finally, projects like <a href="https://www.reddit.com/r/emulation/comments/utbpmm/dolphin_has_dropped_support_for_windows_7_and_8/">Dolphin</a> have already followed the same path, and for the same exact reasons.</p> <p>A 13 years old Windows is old enough to drive in some places.</p> <p>For those that still prefer to not upgrade, <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/download/mainline-0-990/yuzu-windows-msvc-20220419-a5e7c5330.zip">Mainline 990</a> and older will work just fine.</p> <h2 id="vulkan-by-default">Vulkan by default</h2> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/#vulkan-is-the-future">As previously discussed</a>, we have to circumvent issues like OEM-locked drivers (so common on Intel hardware, <a href="https://www.intel.com/content/www/us/en/support/articles/000056629/graphics.html">it has its own official procedure</a>) and broken third party software limitations (outdated screen recorders are a common cause of broken rendering) in order to provide a smooth experience with Vulkan as the default API.</p> <p>The two main causes for Vulkan related crashes when trying to boot a game or opening yuzu’s configuration are:</p> <ul> <li>Broken Vulkan layers on HUD and screen recording software could cause issues when yuzu and drivers add support for new Vulkan extensions. Keeping software up to date is the only way to prevent this issue from happening.</li> <li>Outdated GPU drivers that lack the required features to run Vulkan. This is usually caused by relying on Windows Update to provide the drivers instead of manually installing the latest version, or Intel laptop vendors providing locked custom (meaning nerfed) drivers that are never updated. If possible, always install the latest GPU driver manually, don&rsquo;t rely on Windows Update.</li> </ul> <p>Thankfully, we have a new system that can workaround those issues that are outside of our control. yuzu will now perform a Vulkan check at boot.</p> <p>If the check passes, yay!, you can use Vulkan or OpenGL and select which API to use, or in Vulkan’s case, which device to run yuzu with, as always from the Graphics section in configuration.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ok.png" title=" Check passes, Vulkan works!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/ok_hu060632948ee766e2c6b683b8f6abc1f0_27406_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Check passes, Vulkan works!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Check passes, Vulkan works!</p> </div> </div> <p>If this check fails, a warning will be displayed the next time you launch yuzu. If this happens, you will only be able to use OpenGL as the graphics API. You will still have the option to pick the shader backend (GLSL, GLASM, SPIR-V) that best suits your needs.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./error.png" title=" Oh oh.."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/error_hu52c71340793d0651a178fa8b24ae732a_11156_502x0_resize_q90_bgffffff_box_3.jpg" alt=" Oh oh.."></a> <p class="has-text-centered is-italic has-text-grey-light"> Oh oh..</p> </div> </div> <p>For those that happen to land in this situation, a button labeled &ldquo;Check for Working Vulkan&rdquo; at the bottom of the Graphics settings window will show up, allowing to retest Vulkan support.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./button.png" title=" Once you manage to solve the issue, click on the button at the bottom!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/button_hu078d2922eb11e223c8543036866385ed_30252_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Once you manage to solve the issue, click on the button at the bottom!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Once you manage to solve the issue, click on the button at the bottom!</p> </div> </div> <p>Thanks to <a href="https://github.com/lat9nq">toastUnlimited</a>, gone is OpenGL as the default graphics API. Out with the old, in with the new. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8393" data-gh-pr="8393">Long live King Vulkan.</a> </p> <p>Going forward, Vulkan will be the top priority for our developers, but they will still continue to support OpenGL. OpenGL users are recommended to use the GLSL shader backend, as GLASM and SPIR-V will receive limited support from now on.</p> <h2 id="graphical-changes-driver-issues-and-the-nostalgia-bliss-that-is-the-good-old-64">Graphical changes, driver issues, and the nostalgia bliss that is the good old 64</h2> <p>This past month, <a href="https://github.com/liamwhite">byte[]</a> continued the wave of improvements for <code>Super Mario 3D All-Stars</code>. This time, he noticed a bug in the DMAcopy (<a href="https://en.wikipedia.org/wiki/Direct_memory_access">direct memory access</a>) of the Nintendo Switch’s GPU.</p> <p><code>DMACopy</code> is a mechanism that many games use to send texture data to the GPU, it handles the format conversion from &ldquo;pitch&rdquo; (pixels on a line by line basis) to &ldquo;tiled&rdquo; (gridded) images. This process works by writing the pitch image data into GPU memory accessible by the DMA engine. Next, a DMAcopy is requested through the DMA engine driver, converting the image data into a separate buffer accessible by the GPU. This buffer will then be used as the texture on the final draw.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8313" data-gh-pr="8313">After fixing <code>bytes_per_pixel</code>,</a> <code>Super Mario Galaxy</code> now has proper lens flare.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/dmabug_hu66a4afef5972719d1ed7eab961798f6c_1554411_1024x0_resize_q90_bgffffff_box_3.jpg" alt="RTX On? (Super Mario Galaxy)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/dmafix_hu0da96a8e5ab8b25bfe6509f334eae667_1544381_1024x0_resize_q90_bgffffff_box_3.jpg" alt="RTX On? (Super Mario Galaxy)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">RTX On? (Super Mario Galaxy)</p> <p>byte[] also improved the way OpenGL interprets face flips depth, <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/#saving-princess-peach-yet-again">replacing the previously reported fix</a>. The face flips used by Super Mario 3D All-Stars and the Nintendo 64 emulation are an uncommon configuration on the GPU. The previous implementation had bad rendering in OpenGL, a complete black screen.</p> <p>While this wasn&rsquo;t an issue while using Vulkan (performance aside), now <code>Super Mario 64</code> and <code>Super Mario Galaxy</code> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8314" data-gh-pr="8314">are playable in both graphics APIs.</a> Fermi GPU users rejoyce.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sm64.png" title=" It&#39;s-a Mario, now running fast in OpenGL! (Super Mario 64)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/sm64_hu64a80edddeca83606cb90a9eb338897b_323109_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It&#39;s-a Mario, now running fast in OpenGL! (Super Mario 64)"></a> <p class="has-text-centered is-italic has-text-grey-light"> It&#39;s-a Mario, now running fast in OpenGL! (Super Mario 64)</p> </div> </div> <p>One of the important parts of yuzu&rsquo;s graphical emulation is the need to translate small sets of GPU instructions, called <code>macros</code>. yuzu uses a Just-in-Time (JIT) compiler to execute these macros in a performant way. It provides a performance boost of about 10% over interpretation in most cases.</p> <p>byte[] found that due to emulation inaccuracies, sometimes a macro could try to access a parameter that was too far outside the bounds of what it was supposed to be accessing. This could crash the emulator without a single trace as to why in some cases. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8319" data-gh-pr="8319">One less reason for annoying crashes.</a> </p> <p>Additionally, byte[] added the option to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8320" data-gh-pr="8320">dump all macros</a> used by a game for debugging purposes.</p> <p>But why are macros important enough to merit their own dump mechanism?</p> <p>Turns out, the <code>Nintendo 64</code> emulator (<em>totally not outside Nintendo&rsquo;s Terms of Service</em>), included with the <code>Nintendo Switch Online</code> (NSO) subscription, reassigns the same macros multiple times, each time with different code. yuzu incorrectly appended the new code to the end of the macro in this case, instead of replacing the existing code. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8328" data-gh-pr="8328">Properly clearing that code</a> on upload address assignments allows the NSO Nintendo 64 emulator to be playable. Time to re-enjoy those classics!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./n64.png" title=" We need more games with the atmosphere of The Legend of Zelda: Majora&#39;s Mask"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/n64_hu3e5d7017f416b7c90161ad71f2fb778d_1921077_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We need more games with the atmosphere of The Legend of Zelda: Majora&#39;s Mask"></a> <p class="has-text-centered is-italic has-text-grey-light"> We need more games with the atmosphere of The Legend of Zelda: Majora&#39;s Mask</p> </div> </div> <p>Future graphical fixes for the NSO Nintendo 64 emulator will be part of <code>Project Y.F.C.</code>. AMD and Intel users are free to run Vulkan without concerns, but NVIDIA users are recommended to use OpenGL.</p> <p>Polaris AMD Radeon users (RX 400 and RX 500 series) reported that drivers 22.3.2 and newer caused crashes on multiple games, most notably <code>The Legend of Zelda: Breath of the Wild</code> and <code>Animal Crossing: New Horizons</code>.</p> <p><a href="https://www.amd.com/en/support/kb/release-notes/rn-rad-win-vulkan">Driver patch notes mentioned</a> implementing the <code>VK_KHR_workgroup_memory_explicit_layout</code> Vulkan extension. The quick conclusion would be that AMD released a broken extension on the new drivers, which wouldn&rsquo;t be the first time, but that wasn’t the case. The issue only affects Polaris GPUs, and the extension is available to newer architectures too, like Vega or RDNA2 (we don’t talk about <del>Bruno</del> RDNA1).</p> <p>After a few debugging sessions we found out that yuzu’s implementation of VK_KHR_workgroup_memory_explicit_layout assumes that all compatible GPUs support 16-bit integer operations. While this was the case for all compatible GPUs previous to AMDs implementation of the extension, the Polaris architecture is notorious for its lack of the more recently popular 16-bit precision support (shows its age, you could say, Polaris is 6 years old by now), and as expected, forcing a GPU to do something it doesn’t support will result in a crash, hurray.</p> <p>toastUnlimited <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8369" data-gh-pr="8369">disabled the extension</a> on Polaris GPUs while we wait for our dedicated GPU devs to have the time to implement a proper fix. We plan to allow the extension to work with old-school 32-bit precision in the future.</p> <p>While still on the subject of AMD Windows Vulkan drivers, we have to talk about another extension issue. Since driver version 22.5.2, support was added for <code>VK_KHR_push_descriptor</code>, an old extension that has been working in every other driver for the past 5 years, be it Intel, NVIDIA or Mesa.</p> <p>While we don&rsquo;t yet know the root cause of the issue, only AMD&rsquo;s Windows drivers crash when calling VK_KHR_push_descriptor. As this extension is critical to the entire rendering process, any AMD GPU would crash on any game.</p> <p>It seems that this time around, AMD may have simply released a broken implementation of the extension. This extension previously worked with yuzu&rsquo;s Vulkan implementation without issue. If that’s the case, it’s AMD’s turn to solve the issue. In the meantime, toastUnlimited <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8379" data-gh-pr="8379">blocked the extension</a> on the affected AMD Vulkan driver versions.</p> <p>Elsewhere on the GPU emulation front, <a href="https://github.com/asLody">asLody</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8311" data-gh-pr="8311">implemented stencil fixes when two faces are disabled.</a> This should improve rendering for some games that natively use OpenGL.</p> <h2 id="hle-improvements">HLE Improvements</h2> <p>Moving onto the subject of HLE emulation, a <em>very dear</em> section for <a href="https://github.com/bunnei">bunnei</a>. The dev team has been working hard at improving the accuracy and performance of yuzu&rsquo;s kernel emulation.</p> <p>This time around, a big change was made with how games and the emulated OS can &ldquo;lock resources&rdquo;. This improves emulation performance with literally every game, and to a varying degree, on any CPU. Let&rsquo;s dive in.</p> <p>In software engineering, a <a href="https://en.wikipedia.org/wiki/Spinlock">spinlock</a> is a lock that causes a thread trying to acquire it to simply wait in a loop (&ldquo;spin&rdquo;) while repeatedly checking whether the lock is available.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./spinlock.png" title=" Example of a spinlock, simple but gets the job done"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/spinlock_hu08da9b70050cc353010c81ce0708e7fd_9334_895x0_resize_q90_bgffffff_box_3.jpg" alt=" Example of a spinlock, simple but gets the job done"></a> <p class="has-text-centered is-italic has-text-grey-light"> Example of a spinlock, simple but gets the job done</p> </div> </div> <p>There exists another synchronization primitive with a similar function, <a href="https://en.wikipedia.org/wiki/Mutual_exclusion">the mutex</a>.</p> <p>The word &ldquo;mutex&rdquo; stands for an object providing <code>MUTual EXclusion</code> between threads. A mutex ensures that only one thread has access to a critical section or data by using operations like a lock and unlock. A critical section is a shared resource that many threads want to access. While there is no issue if multiple threads want to read the same critical section, no new thread can modify the section until the previous thread finishes its own writing. Under this scenario, the first thread locks the section, and will remain that way until the lock is released.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mutex.png" title=" Example of a mutex"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/mutex_hub85333b2121adf9723216f8d2bad2b7c_8845_895x0_resize_q90_bgffffff_box_3.jpg" alt=" Example of a mutex"></a> <p class="has-text-centered is-italic has-text-grey-light"> Example of a mutex</p> </div> </div> <p>In theory, when a thread tries to lock a mutex and it does not succeed (for example because the mutex is already locked), it will be paused. The operating system will then take the opportunity to schedule an available and ready thread to run in its place. The paused thread will continue to sleep until it is able to acquire the mutex. This may happen once the current thread holding the mutex lock releases it.</p> <p>Consequently, threads &ldquo;spinning&rdquo; to acquire the lock will waste (perhaps precious) system resources. While the Switch&rsquo;s own operating system uses spinlocks, this drain on resources can be problematic when emulating on lower-end hardware. Using the host operating system (Windows or Linux) mutex allows yuzu to continue emulation tasks on other available threads.</p> <p>Helpfully, most modern operating systems use hybrid mutexes and hybrid spinlocks. The spinlock approach would work fine on systems with threads to spare. However, for emulation, we need many threads (for UI, audio, GPU emulation, logging, etc.), so this approach is not quite ideal, especially on CPUs with low core/thread counts.</p> <p>Thus <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8172" data-gh-pr="8172">by moving from spinlocks to mutexes,</a> we were able to improve how yuzu runs on systems with low core counts. Our testing results showed that yuzu is now much more usable on 4 thread systems, solving stability issues on 4 cores/4 threads CPUs (most notably in <code>Pokémon Sword/Shield</code>), and substantially improving performance on (previously completely non-viable) 2 cores/4 threads CPUs.</p> <p>The best news for the low-end gang!</p> <h2 id="ui-changes">UI changes</h2> <p>Pivoting towards user interface improvements, <a href="https://github.com/Docteh">Docteh</a>, who is becoming a regular here, has been very helpful with some translation holes we had for a while.</p> <p>For example, the Custom RTC setting had several issues if the Windows system locale was set in certain languages, making it either display incorrectly (for example lacking the AM/PM indicator), or completely unusable. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8291" data-gh-pr="8291">Fixing the display format</a> allows Custom RTC to show up correctly in any language now.</p> <p>The Network tab in <code>Emulation &gt; Configure… &gt; System</code> could remain untranslated after changing languages. This was a simple case of forgetting to include the tab in the translations, so Docteh <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8293" data-gh-pr="8293">fixed the oopsie</a> and the lone Network tab now displays as it should.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/netbug_hu61c98d18f810b65ecdf8680a43f1bccb_7099_550x0_resize_q90_bgffffff_box_3.jpg" alt="Netto-kun. Now I want a Battle Network Legacy Collection, c&#39;mon CAPCOM!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/netfix_hu228f2822ed3d7adfcacc05441424ecc6_5901_550x0_resize_q90_bgffffff_box_3.jpg" alt="Netto-kun. Now I want a Battle Network Legacy Collection, c&#39;mon CAPCOM!"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Netto-kun. Now I want a Battle Network Legacy Collection, c&#39;mon CAPCOM!</p> <p>For a while now, the layout of yuzu&rsquo;s About dialog, particularly on Linux, has had some issues. While we&rsquo;ve attempted to fix it in the past, these attempts would have an adverse effect on the Windows builds, and vice versa. Via qtcreator, Docteh <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8339" data-gh-pr="8339">fixed the About dialog UI file,</a> and removed an old warning caused by the original .png image. Thanks Docteh for taking the time to properly address the issue once and for all!</p> <h2 id="controller-changes">Controller changes</h2> <p><a href="https://github.com/german77">german77</a> is the undisputed king of this section again. He continues the endless quest of providing the best user input experience possible.</p> <p>german77 noticed that motion continued reporting data even when disabled, causing <code>Pokémon Let’s Go, Eevee/Pikachu!</code> to spam <code>StopSixAxisSensor</code> errors in the logs. While working on this, he also noticed a missing parameter, <code>delta_time</code>. Its proper implementation allows yuzu to have an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8308" data-gh-pr="8308">accurate motion refresh rate,</a> equal to the Switch.</p> <p>In an all-in-one pull request, german77 made <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8368" data-gh-pr="8368">several input changes,</a> including:</p> <ul> <li>Add proper error handling for several <a href="https://en.wikipedia.org/wiki/Human_interface_device">HID</a> functions</li> <li>Improve previous implementations to match more closely to native hardware.</li> <li>Implement functions needed by <code>Nintendo Switch Sports</code>, <code>EnableSixAxisSensorUnalteredPassthrough</code>, <code>IsSixAxisSensorUnalteredPassthroughEnabled</code>, <code>LoadSixAxisSensorCalibrationParameter</code>, <code>GetSixAxisSensorIcInformation</code>, <code>ResetIsSixAxisSensorDeviceNewlyAssigned</code>.</li> </ul> <p>While we&rsquo;ve made some great progress here, <code>Nintendo Switch Sports</code> will be unplayable on yuzu until we rework our audio and make some much needed GPU fixes too. While audio and perfect rendering may not seem critical to playability, games often are quite unstable if these are not accurate. Rest assured, we&rsquo;re working on these and will have more to share soon!</p> <p>Changing game genres, <code>Arcaea</code> was reported as having issues with touch-release emulation. Turns out this game checks for the reported touch position on release, and some input drivers lose their position data after release. Additionally, multi-touch was found to not work properly on touch screens.</p> <p>After performing basically <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8372" data-gh-pr="8372">a mini-rewrite of the touch emulation,</a> german77 fixed both issues.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./arcaea.png" title=" Osu! but better? (Arcaea)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/arcaea_hu4cd4b38ff79f8f13cad9c27532d9a8a3_644868_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Osu! but better? (Arcaea)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Osu! but better? (Arcaea)</p> </div> </div> <p>One of the hurdles when working with a near endless amount of different controllers is the different quality of implementations they have. Since yuzu used to wait for the controller to respond after sending a vibration signal, slow controllers could stall the whole emulator, causing severe stuttering. To counter this, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8374" data-gh-pr="8374">moved vibration to a queue in a separate thread,</a> allowing yuzu to move along with emulation, letting your controller make its best effort. This is just another example of how emulation can often be improved by moving blocking operations to asynchronous background threads to improve overall usability. In fact, yuzu uses dozens of threads for emulation, which is all the more reason why eliminating spinlocks really helps things to run as smooth as butter!</p> <h2 id="future-projects">Future projects</h2> <p>While <code>Project Y.F.C.</code> was slightly stalled due to some NVFlinger regressions, these have since been resolved and will be covered in the next progress report! Under <a href="https://github.com/FernandoS27">blinkhawk</a>&rsquo;s lead, <code>Project Y.F.C.</code> is making great progress and is on track to release soon. As a reminder, <code>Project Y.F.C.</code> is an overhaul of various parts of our GPU emulation, fixing many inaccuracies and improving both performance and compatibility.</p> <p><a href="https://github.com/Kelebek1">Maide</a> is up to something. (Hint: if you check the previous progress reports, you&rsquo;ll notice a common theme with their pull requests)</p> <p>And toastUnlimited is working on getting MinGW Clang builds for Windows, which could potentially be faster than the MSVC builds we’re using now. This work is tied with the release of <code>Project Gaia</code>, so it will take a bit.</p> <h2 id="bonus-track">Bonus track</h2> <p>As an extra bonus, gidoly, one of our team members recently got his hands on a Ryzen 5800X3D, giving us the chance to compare it to a regular 5800X fixed at 4.5GHz so only the extra cache should be relevant.</p> <p>Here are the results!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./chart.png" title=" Still the best upgrade path for a Zen1 user"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2022/chart_hu8907aa0ad023796d4a11d95038aaec00_34457_1007x0_resize_q90_bgffffff_box_3.jpg" alt=" Still the best upgrade path for a Zen1 user"></a> <p class="has-text-centered is-italic has-text-grey-light"> Still the best upgrade path for a Zen1 user</p> </div> </div> <p>While the 5800X is manually forced to a 4.5GHz frequency, the 5800X3D naturally tops out at a 4.45GHz clock speed, the results are respectable, but nothing amazing. Pokémon Brilliant Diamond certainly loves the extra cache, while Metroid Dread is punished by its extra latency.</p> <p>That’s all folks! As always, thank you for your support, and we hope that you enjoyed this summary of our recent progress. See you next month! Until then, keep on emulating, and let us know what we can do to make yuzu the best possible emulation experience!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report April 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/ Wed, 11 May 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/ <p>Hello yuz-ers, the month of April has been amazing! We&rsquo;ll discuss CPU and Kernel performance improvements, several GPU emulation changes, UI tweaks, and more!</p> <p>Hello yuz-ers, the month of April has been amazing! We&rsquo;ll discuss CPU and Kernel performance improvements, several GPU emulation changes, UI tweaks, and more!</p> <h2 id="saving-princess-peach-yet-again">Saving Princess Peach yet again</h2> <p>Continuing his work to better support the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/#the-vulkan-emulator">official</a> GameCube/Wii and Nintendo 64 emulators (codenamed <code>Hagi</code> and <code>Hovercraft</code> respectively), <a href="https://github.com/liamwhite">byte[]</a> has introduced several new PRs to further improve the compatibility of the titles included within <code>Super Mario 3D All-Stars</code>.</p> <p>byte[] first implemented support for GLSL in <code>Super Mario Sunshine</code>, as not everyone can run Vulkan. This is achieved by adding <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8133" data-gh-pr="8133">support for indirect addressing</a> in OpenGL.</p> <p>This change doesn’t include support for GLASM at the moment, since our developers aren&rsquo;t too fond of having to deal with NVIDIA assembly shader code. Imagine being asked to fix an issue in a car engine, and the only given tools for the job are a rock and a stick.</p> <p>However, that was only half the battle. Proper OpenGL support for <code>Super Mario Sunshine</code> and <code>Super Mario Galaxy</code> required solving an old limitation we had with the aging API: broken Z scale inversion.</p> <p>Most Switch games use either OpenGL, the popular free graphics API, or NVN, the proprietary NVIDIA API exclusive to the console. Arguably, NVN is much closer to OpenGL than Vulkan in how it operates.</p> <p>The Tegra X1 GPU on the Switch is flexible enough to allow the coordinate system to be changed at the discretion of the game developer. While most games will behave closer to what OpenGL expects, with the Z-axis facing away from the camera, <code>Hagi</code> and <code>Hovercraft</code> emulated games (which render using Vulkan and is exclusive to a tiny handful of titles on the Switch) have the coordinates inverted and the Z-axis facing into the camera, the way Vulkan games would expect to natively render.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./coords.png" title=" byte[]&#39;s Z-axis diagram"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/coords_hu011e3b6002ce5d6c4d9c9cfa80e7bb0c_488229_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" byte[]&#39;s Z-axis diagram"></a> <p class="has-text-centered is-italic has-text-grey-light"> byte[]&#39;s Z-axis diagram</p> </div> </div> <p>This was not an issue if you wanted to play <code>Super Mario Galaxy</code> or <code>Super Mario Sunshine</code> in yuzu with yuzu&rsquo;s Vulkan backend, as the behaviour matched with what the game expected. But if you tried to play using OpenGL instead, yuzu would not correctly interpret that the faces were flipped due to the Z scale inversion, and thus rendered only the back faces of objects.</p> <p>The solution is very simple, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8149" data-gh-pr="8149">flip the front faces</a> when the Z-axis is inverted.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/zbug_hu24bebf020b8a793382dd1c5eee278d8e_579994_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Welcome to the Shadow Realm Resort (Super Mario Sunshine)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/zfix_hu1bc895e5123ba9e90b2491b15f0d19a6_826174_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Welcome to the Shadow Realm Resort (Super Mario Sunshine)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Welcome to the Shadow Realm Resort (Super Mario Sunshine)</p> <p>Next in line, you may have noticed that <code>Super Mario Sunshine</code> rendered with a black bar at the bottom. This is because the Wii and GC games natively use an aspect ratio different to the usual 16:9 we’re used to. Instead, the games render at a 5:3 aspect ratio. <code>Super Mario Galaxy</code> informs the system to explicitly crop the screen to its native resolution of 1920x1012, but <code>Super Mario Sunshine</code> does not, so yuzu previously did not attempt to crop the game, resulting in a conspicuous black bar at the bottom of the render.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./crop.png" title=" Diagram of the cropping process"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/crop_huf26066373aa26fcf1f1a5877845077e7_892449_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Diagram of the cropping process"></a> <p class="has-text-centered is-italic has-text-grey-light"> Diagram of the cropping process</p> </div> </div> <p>While the game proportions in <code>Super Mario Sunshine</code>, arguably, appear more correct with the black bar, that’s not how Nintendo intended the game to be played. For accuracy’s sake, byte[] interprets the game&rsquo;s implicit crop request, which stretches the image to match the native 1920x1080 resolution of the Switch, both <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8150" data-gh-pr="8150">for Vulkan</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8152" data-gh-pr="8152">for OpenGL</a> .</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/cropbug_hudc081bf1a5cf3a4b44a38a8af8a2ae92_866650_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Do not adjust your set (Super Mario Sunshine)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/cropfix_huadedc02863de5ac48affc3bd387b6b9d_919840_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Do not adjust your set (Super Mario Sunshine)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Do not adjust your set (Super Mario Sunshine)</p> <p>In the previous report, we mentioned how S8D24 &lt; &gt; ABGR8 texture conversions allow <code>Super Mario Galaxy</code> star bits to behave correctly. Well, it’s <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8161" data-gh-pr="8161">OpenGL’s turn</a> to join the fun.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./s8d24.png" title=" S8D24 to ABGR8 texture conversion diagram"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/s8d24_hu2cf31ebff3d166158da98fdd2b0d6137_352507_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" S8D24 to ABGR8 texture conversion diagram"></a> <p class="has-text-centered is-italic has-text-grey-light"> S8D24 to ABGR8 texture conversion diagram</p> </div> </div> <p>We mentioned last month how <code>Super Mario 64</code> had special requirements to start running on yuzu. Most games compile their code <code>ahead-of-time</code> (<a href="https://www.youtube.com/watch?v=DeYTBDQnQZw">AOT</a>), that is, before being shipped to you. The Operating System’s job is to execute that precompiled binary code, and then you&rsquo;re playing games.</p> <p><code>Super Mario 64</code>, on the other hand, runs <code>just-in-time</code> (JIT), to make it easier to develop the <code>Hovercraft</code> emulator, and to allow reusing the same <code>Hovercraft</code> binary for different games. The <code>Hovercraft</code> emulator loads a native Nintendo 64 ROM of Super Mario 64, and then its JIT compiler takes the ROM and translates the original <a href="https://en.wikipedia.org/wiki/MIPS_architecture">MIPS</a> (the architecture of the Nintendo 64’s CPU) instructions into <a href="https://en.wikipedia.org/wiki/AArch64">AArch64</a> (the Switch’s CPU architecture) instructions on the fly. Only then will the operating system execute the game code.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./jitsrv.png" title=" Ahead-of-time versus Just-in-time compilation diagram"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/jitsrv_hu121ead1ae3493f3cb1a4ed8f8f9ae1fb_446756_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Ahead-of-time versus Just-in-time compilation diagram"></a> <p class="has-text-centered is-italic has-text-grey-light"> Ahead-of-time versus Just-in-time compilation diagram</p> </div> </div> <p>This is similar to how yuzu translates AArch64 instructions into AMD64 instructions with the assistance of <a href="https://github.com/merryhime/dynarmic">Dynarmic</a>.</p> <p>The JIT service, which is required to use JIT compilation on retail titles, is a functionality that yuzu didn’t have implemented, simply because no other game had ever needed it. Additionally, there were some obstacles to implementing it in a direct way, since it requires calling custom code supplied by the game, something which was never needed by any previous service implementation. So, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8164" data-gh-pr="8164">some preliminary stubs aside</a> , byte[] <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8199" data-gh-pr="8199">implemented the HLE JIT service</a> to allow the <code>Hovercraft</code> emulator to function and <code>Super Mario 64</code> to boot.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8261" data-gh-pr="8261">In a separate PR</a> , byte[] adds documentation of how the JIT service interface operates. This should help other open source projects, if needed.</p> <p>Of course, this wasn’t enough to get <code>Super Mario 64</code> playable, as there were rendering issues to solve as well.</p> <p>It’s never that simple… but let&rsquo;s try to explain it simply. Nintendo Switch games bundle their own individual GPU driver with each game. This is done to increase compatibility, you don&rsquo;t need to update every console in the world if a driver version has an issue.</p> <p>For unknown reasons, either the <code>Hovercraft</code> emulator or the bundled GPU driver reports Vertex Buffers that are simply too large, especially when compared to what the game actually uses. Whether it&rsquo;s an issue in the included emulator or just a driver bug, we can&rsquo;t know for certain, but we do need to work around this problem.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vb.png" title=" Erroneous Vertex Buffer size diagram"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/vb_hubfccfabcd42e2b30ae544ea5d39da01d_322414_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Erroneous Vertex Buffer size diagram"></a> <p class="has-text-centered is-italic has-text-grey-light"> Erroneous Vertex Buffer size diagram</p> </div> </div> <p>So, instead of using the insane reported buffer size, byte[] says NO! and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8205" data-gh-pr="8205">uses the backing memory size</a> instead.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sm64.png" title=" It&#39;s-a him! (Super Mario 64)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/sm64_hua15ba76a00c50f932f525a23ef382dc2_811090_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It&#39;s-a him! (Super Mario 64)"></a> <p class="has-text-centered is-italic has-text-grey-light"> It&#39;s-a him! (Super Mario 64)</p> </div> </div> <p>Performance on Vulkan is not stellar for now, but you can finally enjoy all 3 of the <code>Super Mario 3D All-Stars</code> games with both APIs.</p> <p>Lastly, <a href="https://github.com/Morph1984">Morph</a> implemented a fix to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8135" data-gh-pr="8135">keep the web applet open in the foreground</a> , as the <code>Super Mario 3D All-Stars</code> games require it or else they would crash a few minutes into gameplay.</p> <h2 id="general-graphical-fixes">General graphical fixes</h2> <p>Following up on last month&rsquo;s NVFlinger rewrite, <a href="https://github.com/bunnei">bunnei</a> continued to track issues and bug reports. He fixed the reported issues and further cleaned up the code to improve code quality. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8137" data-gh-pr="8137">See the code changes for the NVFlinger rewrite here</a> .</p> <p><code>Xenoblade Chronicles 2</code> and <code>Hyrule Warriors: Age of Calamity</code> would experience interesting issues which were caused by the new <code>GPU Garbage Collector</code> introduced as part of <code>Project Y.F.C.</code>. We talked about those changes back in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/#other-graphical-fixes">January</a>.</p> <p>As you can see on the top bar below, <code>Xenoblade Chronicles 2</code> would use exorbitant amounts of VRAM in OpenGL (top bar). The bottom bar shows the result after the fixes were implemented.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xc2bug.png" title=" Not the best way to test your whole VRAM (Xenoblade Chronicles 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/xc2bug_hu7a84c3271db9d1bac0f1b9601a9cf3f2_122361_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Not the best way to test your whole VRAM (Xenoblade Chronicles 2)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Not the best way to test your whole VRAM (Xenoblade Chronicles 2)</p> </div> </div> <p><code>Age of Calamity</code> would display <em>interesting</em> graphics at random intervals:</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/aocbug_hu942eef340fec1890ea1d25bfc881f2d4_4114328_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This is why you don&#39;t blast Caramelldansen too hard (Hyrule Warriors: Age of Calamity)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/aocfix_huad5f052a726c12217f09553d9e7a7821_5511877_1024x0_resize_q90_bgffffff_box_3.jpg" alt="This is why you don&#39;t blast Caramelldansen too hard (Hyrule Warriors: Age of Calamity)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This is why you don&#39;t blast Caramelldansen too hard (Hyrule Warriors: Age of Calamity)</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8128" data-gh-pr="8128">fixed the regressions</a> and both games are back in business.</p> <p>Often times in emulation, when you fix one issue, another pops up. The cropping fix byte[] implemented for <code>Super Mario 3D All-Stars</code> had the lovely unintended side effect of breaking rendering for homebrew apps in Vulkan. Thankfully, Morph added the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8267" data-gh-pr="8267">magic line to the code</a> that solves this regression.</p> <h2 id="skyline-framework-part-3">Skyline framework: Part 3</h2> <p>There has been important progress in getting the <a href="https://github.com/skyline-dev/skyline">Skyline</a> modding framework working. <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/#skyline-framework-part-1">Here are</a> the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/#skyline-framework-part-2">two links</a> if you missed our previous progress reports on the subject.</p> <p><a href="https://github.com/tech-ticks">tech-ticks</a> has been quite busy <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8171" data-gh-pr="8171">working on the finishing touches</a> . The latest changes include:</p> <ul> <li>Better <code>LayeredExeFs</code> support, which results in easier mod distribution and self-updating capabilities.</li> <li>Support for the <code>SO_KEEPALIVE</code> socket option, which allows the Skyline TCP logger to operate.</li> <li>Implementation of <a href="https://en.wikipedia.org/wiki/Domain_Name_System">DNS</a> address resolution, which is required by plugins that use HTTPS requests.</li> </ul> <p>We must mention that while Skyline kernel support is basically finished, bugs in yuzu’s codebase prevent proper operation of the modding framework. For example, due to underlying emulation issues, <a href="https://github.com/Raytwo/ARCropolis">ARCropolis</a> won’t work until <code>Project Gaia</code> is finished, and some of the changes previously mentioned need some fine tuning from our part to function properly.</p> <p>There’s yet more work to do, but we’re a lot closer. We can see the finish line!</p> <h2 id="ui-improvements">UI improvements</h2> <p><a href="https://github.com/merryhime">Merry</a>, the core developer of <code>Dynarmic</code>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8140" data-gh-pr="8140">made some changes to the add-ons game properties window</a> , improving column widths.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./addonbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/addonbug_hu7b89f2732e4eb8c168587ce59f398091_200930_800x0_resize_q90_bgffffff_box_3.jpg" alt="Low resolution users will like this"></a> </div> <div class="column is-bottom-paddingless"> <a href="./addonfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/addonfix_hu0dc15269830fe03b0a329c7f4c3acba8_178327_800x0_resize_q90_bgffffff_box_3.jpg" alt="Low resolution users will like this"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Low resolution users will like this</p> <p>The hotkeys configuration window <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8141" data-gh-pr="8141">also got some love</a> , changing the minimum column width.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hotkeybug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/hotkeybug_hufd8486e0770079540cc29a11365945b0_37784_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s also great for GNOME users"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hotkeyfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/hotkeyfix_hu60621202df59d675bec4b212e571e580_37829_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s also great for GNOME users"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It&#39;s also great for GNOME users</p> <p>Both changes are extremely beneficial for bloated or size unoptimized desktop environments, like GNOME Shell.</p> <p><a href="https://github.com/Tachi107">Tachi107</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8142" data-gh-pr="8142">fixed some embarrassing typos in our logging</a> , and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8225" data-gh-pr="8225">updated the About yuzu window</a> to properly mention our new licence, <code>GPLv3.0+</code>. The <code>+</code> is there because we want to leave the door open for newer revisions.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./about.png" title=" Screenshot of the yuzu About box"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/about_hue145afe29afd72898e44ad72926e772a_19715_623x0_resize_q90_bgffffff_box_3.jpg" alt=" Screenshot of the yuzu About box"></a> <p class="has-text-centered is-italic has-text-grey-light"> Screenshot of the yuzu About box</p> </div> </div> <p>Not stopping there, Taichi <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8283" data-gh-pr="8283">performed some cleanup and made improvements to Flatpak builds</a> , including using proper app ID, fixing some typos, and adding a launch parameter to make yuzu use the dedicated GPU by default on Linux instead of the integrated GPU.</p> <p><a href="https://github.com/Docteh">Docteh</a> has also helped considerably in improving yuzu’s UI.</p> <p>With a bit of manual thinkering, they managed to bypass some Qt limitations in order to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8190" data-gh-pr="8190">display more readable hyperlinks</a> in our dark themes.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hyperlinkbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/hyperlinkbug_huff390c1cab454e61cd3719e2f7130746_7606_800x0_resize_q90_bgffffff_box_3.jpg" alt="People seem to have forgotten what hyperlinks are for, just click them!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hyperlinkfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/hyperlinkfix_hu0a40698ab9183e4b67b34324ac9d8765_7607_800x0_resize_q90_bgffffff_box_3.jpg" alt="People seem to have forgotten what hyperlinks are for, just click them!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">People seem to have forgotten what hyperlinks are for, just click them!</p> <p>Thanks to a report from GillianMC in our <a href="https://discord.gg/u77vRWY">Discord server</a>, Docteh found out that some quirks in the Qt API caused the compatibility status of listed games to not be translated. The cause lies in QObject, you can find the specific details in the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8204" data-gh-pr="8204">pull request’s description</a> . Now the status is properly reported in the corresponding language.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./compatbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/compatbug_hu80e649c842cedd702797503bf4104132_12890_800x0_resize_q90_bgffffff_box_3.jpg" alt="Example in Spanish"></a> </div> <div class="column is-bottom-paddingless"> <a href="./compatfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/compatfix_hu638e0a2d2260d7b5ba1326acd1de0462_12914_800x0_resize_q90_bgffffff_box_3.jpg" alt="Example in Spanish"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Example in Spanish</p> <p>Similarly, D-Pad directions also didn’t translate properly. The same suspect, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8224" data-gh-pr="8224">once again</a> . Someone, please send a warrant asking for the detention of Carmen Sandiego.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hatbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/hatbug_huc1536013c1c98686bb7fb1f0260820a4_3808_800x0_resize_q90_bgffffff_box_3.jpg" alt="Example in French"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hatfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/hatfix_hu90cfb4dac4ffa1e9aaf53f198b9c4b9c_3889_800x0_resize_q90_bgffffff_box_3.jpg" alt="Example in French"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Example in French</p> <h2 id="kernel-and-cpu-emulation-changes">Kernel and CPU emulation changes</h2> <p>Let&rsquo;s begin with two changes that happened in March.</p> <p>Our resident bunnei rabbit continued his work on rewriting yuzu&rsquo;s kernel memory management to make it accurate to the latest system updates. This time, he tackled and revamped <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7974" data-gh-pr="7974">how the kernel code memory is mapped and unmapped</a> .</p> <p>Code memory support, in the context of the Switch, allows games and apps to load and unload smaller parts of their code on the fly. Thanks to these changes, <code>Super Smash Bros. Ultimate</code> no longer causes memory access issues while loading/unloading NROs, making the game stable for long play sessions.</p> <p>bunnei also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8013" data-gh-pr="8013">migrated slab heaps for the guest (Switch) kernel objects</a> from host heap memory to emulated guest memory. With this change, yuzu&rsquo;s memory layout is now more closely matching the console.</p> <blockquote> <p>A slab represents a contiguous piece of memory. A heap is a general term used for any memory that is allocated dynamically and randomly.</p> </blockquote> <p>The slab heap is the space used to store guest kernel objects. By moving these away from the host (PC) heap memory (RAM) to emulated guest (Switch) memory, we can ensure that the kernel objects never go beyond the system limits and cause memory leaks on the host (PC).</p> <p>Thread local storage (TLS), the mechanism by which each thread in a given multithreaded process allocates storage for thread-specific data, was also rewritten making it accurate to the latest HorizonOS behaviour.</p> <p>With these changes, we have now completely fixed the kernel memory object leaks that affected a few games, but went largely unnoticed, due to the previous implementation allowing unlimited allocations.</p> <p>Back to the list of April changes, bunnei also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8122" data-gh-pr="8122">reimplemented how yuzu handled thread allocation</a> for HLE service interfaces.</p> <blockquote> <p>Services are system processes running in the background which wait for incoming requests. The Switch&rsquo;s HorizonOS has various services that perform various tasks e.g Audio, Bluetooth, etc.</p> </blockquote> <p>Previously, we used to allocate one host thread per HLE service interface because -</p> <ul> <li>some service routines need to potentially wait a long time for completion, like network or filesystem access, and</li> <li>we don&rsquo;t support guest thread rescheduling from host threads.</li> </ul> <blockquote> <p>A thread which is blocked will have to wait until the action that blocked it, such as I/O or simply sleeping for some amount of time, completes.</p> </blockquote> <p>The issue with this approach was that since it&rsquo;s the host (Windows or Linux) that schedules the service threads, yuzu could create weird behaviour particularly on systems with hardware limitations due to the spawning one thread per service and the sheer number of service implementations we emulate.</p> <p>With the rewrite, yuzu now has a single &ldquo;default service thread&rdquo; that is used for 99% of the service methods that are non-blocking. For the services that are time-sensitive and for those that need blocking, we still allow thread creation (e.g. Audio, BSD, FileSystem, nvdrv)</p> <p>This brings down the service thread count from double digits to single digits, thus improving stability and consistency - especially on systems with less cores. Users with 4 thread CPUs (either 2 cores + HT/SMT, or 4 cores) should see performance and stability improvements in most games.</p> <p>Another battle for proper shutdown behaviour is fought and won. yuzu currently does not emulate multi-process capabilities of the HorizonOS kernel, because it is not required to emulate any games. However, the multi-process APIs that are used by games still need to be managed in the way they expect. All HorizonOS services have a port (for both client and server) that is used as a channel of communication between the game process and service process. A session is opened for each communication interface for them both and they are managed by their respective kernel objects. When the game closes the client port, the service closes the server port, and everything is shut down.</p> <p>The issue with our previous implementation was that yuzu wasn&rsquo;t properly tracking all the <code>KServerPort</code> and <code>KServerSession</code> objects for each service. And because of this, the services weren&rsquo;t properly getting closed, which in turn was causing further issues.</p> <p>This originally worked fine, but was regressed when we migrated guest kernel objects to emulated guest memory, as we mentioned previously. bunnei figured out the issue and quickly <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8165" data-gh-pr="8165">reimplemented how we track these kernel objects</a> .</p> <p>By having a single place where we can register/unregister open ports and sessions, we can now keep better track of these kernel objects. And by ensuring that they are closed when we tear down all services and kernel, we get much better emulation shutdown behaviour.</p> <h2 id="input-changes-and-general-bugfixes">Input changes and general bugfixes</h2> <p>If the user sets a very high DPI value for their mouse while using mouse panning, the cursor may be able to escape the rendering window. <a href="https://github.com/IamSanjid">IamSanjid</a> implemented the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8170" data-gh-pr="8170">required fixes</a> , including better centering timings to solve this issue. Thanks!</p> <p><a href="https://github.com/german77">german77</a> has several fixes ready for us.</p> <p>Let’s begin with an interesting one. yuzu’s screenshot capture feature allows an easy way to save moments at the resolution the scaler is currently set at. The hotkey for screenshot capture could be spammed, leading yuzu to a crash if several requests for screenshots were sent. This could be worsened if the rendering resolution was set to a high value. To solve this, yuzu now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8192" data-gh-pr="8192">ignores new requests while a capture is being processed</a> , and prints a warning in the log.</p> <p>There’s always room for improvements in emulation, as nothing is ever truly complete. This time, german77 focuses on inaccuracies found in our input emulation.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8222" data-gh-pr="8222"><code>IsSixAxisSensorFusionEnabled</code> is implemented</a> by reverse engineering all Sixaxis functions, and it was verified by comparing with unit test homebrew results done on the Switch. This should potentially improve motion accuracy.</p> <p>The <a href="https://en.wikipedia.org/wiki/Human_interface_device">HID</a> service in charge of handling input commands, among other things, used to operate by copying its assigned shared memory and reporting back the changes. This leads to mismatches or delays in the input process, and can potentially make games read completely incorrect data.</p> <p>Obviously this isn&rsquo;t ideal, so german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8229" data-gh-pr="8229">gets rid of the memory duplication</a> and uses the ever magical <a href="https://en.wikipedia.org/wiki/Pointer_(computer_programming)">* pointers</a> to access the shared memory directly instead. This can fix bugs affecting countless games, with the biggest example being the <code>Pokémon: Let’s Go</code> games having a hard time detecting controllers.</p> <p>Hotkey presses will now be <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8249" data-gh-pr="8249">triggered by using a queue</a> . This has the benefit of not having to wait for the UI to respond, reducing their delay.</p> <p>Analog sticks <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8272" data-gh-pr="8272">got some love</a> , with a couple of important changes in their mapping:</p> <p>The default maximum range is now set to 95%, to ensure that games get to use the whole range. This change, for example, avoids characters walking when the stick is at certain angles in games like <code>Pokémon Legends: Arceus</code>. The minimum range was lowered from 50% to 25%, providing greater precision, particularly for people trying to play racing games with a matching wheel. Auto-center correction is stronger now, avoiding drifting without having to rely on stronger dead-zone values. Individual axis values can be manually deleted now if buttons were mapped manually.</p> <p>Previously, only Player 1 could automatically reconnect a controller by pressing a button. Other players only could do so when using a keyboard. german77’s pull requests aims to solve that, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8277" data-gh-pr="8277">allowing any of the remaining 7 players to reconnect their controller</a> . No privileges for those higher in the hierarchy anymore.</p> <p>This change is under testing at the time of writing, as it could potentially cause regressions. Be sure to use the status hovercard to check back in a few days!</p> <h2 id="future-projects">Future projects</h2> <p><code>Project Y.F.C.</code> is not far away from releasing its first part of two planned.</p> <p><code>Project Gaia</code> continues to progress slowly but surely, now causing some previously broken games to finally boot for the first time.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./gaia1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/gaia1_hu35d1be56a961cc79c1a88247157dfff6_1164824_800x0_resize_q90_bgffffff_box_3.jpg" alt="Minecraft and Mortal Kombat 11 are now booting!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./gaia2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2022/gaia2_hu2cb5fe3a1ec835efa71da23f08cb2df0_1479341_800x0_resize_q90_bgffffff_box_3.jpg" alt="Minecraft and Mortal Kombat 11 are now booting!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Minecraft and Mortal Kombat 11 are now booting!</p> <p>That’s all folks! We&rsquo;re still playing catch up with some kernel and CPU optimization changes, so expect a more extensive section next time. Thank you for the company, see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report March 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/ Sun, 10 Apr 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/ <p>Hi yuz-ers, glad to have you back. This month, we discuss an emulator inside an emulator, parts of Project Y.F.C. being added, graphical fixes for old and new titles, and more!</p> <p>Hi yuz-ers, glad to have you back. This month, we discuss an emulator inside an emulator, parts of Project Y.F.C. being added, graphical fixes for old and new titles, and more!</p> <h2 id="psa-for-nvidia-users-part-4">PSA for NVIDIA users: Part 4</h2> <p>Yes, there is more. This time we have a blessing and a curse.</p> <p>While the latest 5XX.XX series drivers fixed tessellation issues affecting <code>Luigi’s Mansion 3</code> and improved performance in Vulkan, they also introduced a crash when blitting MSAA images, meaning that running games like <code>Monster Hunter Rise</code>, <code>Rune Factory 5</code>, <code>Sonic Colors Ultimate</code>, and several others at resolutions different than native would result in a crash.</p> <p>Thankfully, <a href="https://github.com/ameerj">epicboy</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8076" data-gh-pr="8076">works around the issue by using 3D helpers</a> like what&rsquo;s been done for AMD and Intel drivers.</p> <p>Now, to be fair, blitting MSAA images is against the Vulkan specification, so NVIDIA is in the right to no longer allow it. It’s just a bummer to have that sudden change in behaviour with something that was previously allowed and working. Proper documentation would help a lot here.</p> <p>Tagging along, a PSA for AMD users too: the latest drivers, 22.3.2 and later, which add support for the <code>VK_KHR_workgroup_memory_explicit_layout</code> extension, break fishing in <code>Animal Crossing: New Horizons</code> and can possibly make other games crash. Revert to 22.3.1 if you find such a regression.</p> <h2 id="the-vulkan-emulator">The Vulkan emulator</h2> <p><a href="https://github.com/liamwhite">byte[]</a>, a newcomer to yuzu but in no way a novice at the art, arrived with a very interesting <code>Pull Request</code>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8000" data-gh-pr="8000">implementing <code>Wii Hagi</code> emulator support</a> into yuzu.</p> <p>This <em>official Nintendo emulator</em> (totally not outside their own ToS, they swear) is what allows the titles contained inside <code>Super Mario 3D All-Stars</code> to work. This means getting <code>Super Mario Galaxy</code> and <code>Super Mario Sunshine</code> playable, with <code>Super Mario 64</code> support coming at a later date, as this game needs a complete JIT service implementation.</p> <p>byte[] didn’t stop there, several other changes were also implemented.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8024" data-gh-pr="8024">Implementing SPIR-V shader support for register-addressed const buffer accesses</a> , which also includes the <code>LDC.IS</code> access mode (the variant of an instruction), allows Mario to retain his body in this dimension in <code>Super Mario Sunshine</code> and <code>Super Mario Galaxy</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/invisbug_hu763db60562e7431d741e474cb33831e9_842277_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Sunshine"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/invisfix_hu210fc3c316e6d949e9270c97007878f2_870067_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Sunshine"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Sunshine</p> <p> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/smgbug_hu4a6d78110a25f2935f94ec83dc45a735_1922116_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Galaxy"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/smgfix_huda84b0cf2b9bed47f69dbb5af34972dc_2044525_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Galaxy"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Galaxy</p> <p><code>Super Mario Galaxy</code> uses a combination of the depth buffer and stencil buffer to “see” the objects behind the star pointer used to shoot star bits. That’s right, a texture determines game physics.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8030" data-gh-pr="8030">Properly handling that S8D24 &lt; &gt; ABGR8 texture conversion</a> solves incorrect collisions with the poor star bits. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8036" data-gh-pr="8036">A later fix solves issues with NVIDIA drivers</a> .</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./texturebug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./texturefix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No star bits for you until you finish your homework (Super Mario Galaxy)</p> <p>A shader miscompilation (a bad assumption on yuzu’s part, oops) caused interesting black holes in Sunshine. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8038" data-gh-pr="8038">Fixing the oopsie</a> provides Delfino Plaza with the intended “shading”, and most likely silently solves issues in other games too.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/miscompbug_hu15e9df6f48c7a686988c35c3f8e205bc_1237789_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Sunshine"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/miscompfix_huafc7823c970b9f867d0385abf4669780_1696186_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Sunshine"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Sunshine</p> <p>And finally, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8074" data-gh-pr="8074">fixing a bottleneck in the buffer cache</a> eliminates slowdowns and helps improve performance by up to approximately 4.5x in Galaxy. Again, this could have a positive impact on other games, but don’t expect it to be similarly significant.</p> <p><a href="https://github.com/merryhime">Merry</a> updated <a href="https://github.com/merryhime/dynarmic">dynarmic</a> to the latest version to provide better support for <code>Super Mario Galaxy</code>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8054" data-gh-pr="8054">adding support for accelerated SHA256 CPU instructions</a> , among other changes. This avoids softlocking Galaxy at the final level.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./creditbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./creditfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This toad sure likes to talk a lot (Super Mario Galaxy)</p> <h2 id="poyo">POYO!</h2> <p><code>Kirby and the Forgotten Land</code> turned out to be one of the best platformers in recent times, and also quite a challenge for our devs.</p> <p>epicboy got the ball rolling by solving geometry pop-ins that were very noticeable throughout gameplay.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./popbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./popfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That tree just pops! (Kirby and the Forgotten Land)</p> <p>This was achieved by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8023" data-gh-pr="8023">improving the accuracy of the constant buffer uploads</a> . This change also had the added benefit of fixing rendering issues in <code>Monster Hunter Rise</code>, making it playable.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./rise.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/rise_hu1218022d5259f5a47fc6447c95800f12_6708297_800x0_resize_q90_bgffffff_box_3.jpg" alt="Such pretty locations (MONSTER HUNTER RISE)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rise2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/rise2_hu8321bf6be2d8083b0a41a0fda15681df_3352427_800x0_resize_q90_bgffffff_box_3.jpg" alt="Such pretty locations (MONSTER HUNTER RISE)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./rise3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/rise3_hud5b6e0053a9bde22fcf6b64c9372f703_3423188_800x0_resize_q90_bgffffff_box_3.jpg" alt="Such pretty locations (MONSTER HUNTER RISE)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Such pretty locations (MONSTER HUNTER RISE)</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/risebug_hud606da8061d2701b4aae3dc715205d4c_860387_1024x0_resize_q90_bgffffff_box_3.jpg" alt="From Monster to Monster Hunter (MONSTER HUNTER RISE)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/risefix_hud606da8061d2701b4aae3dc715205d4c_945776_1024x0_resize_q90_bgffffff_box_3.jpg" alt="From Monster to Monster Hunter (MONSTER HUNTER RISE)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From Monster to Monster Hunter (MONSTER HUNTER RISE)</p> <p>Another issue that we were quickly made aware of is that NVIDIA hardware would consume VRAM like crazy, to the point of filling up even high-end hardware in minutes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./kirbyvram.png" title=" PC requirements: RTX 3090? Not on our watch!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/kirbyvram_hud7eeda6704823645461d58ef32a64ebd_3129_481x0_resize_q90_bgffffff_box_3.jpg" alt=" PC requirements: RTX 3090? Not on our watch!"></a> <p class="has-text-centered is-italic has-text-grey-light"> PC requirements: RTX 3090? Not on our watch!</p> </div> </div> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8093" data-gh-pr="8093">Unmapping pre-existing rasterizer memory before the memory range was mapped</a> solves the issue and allows NVIDIA users to not need RTX 3090 levels of hardware to have a good experience.</p> <p>However, epicboy issues a PSA that this pull request may introduce regressions that are being investigated, and that VRAM consumption is further improved by using the Disable Dynamic Resolution mod <a href="https://github.com/yuzu-emu/yuzu/wiki/Switch-Mods">available on our site</a>.</p> <p>epicboy also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8116" data-gh-pr="8116">fixed an svc break crash that would occur if the game was run with Asynchronous GPU Emulation enabled</a> , an option that should always remain enabled.</p> <p>And finally, an off-by-one error in the stream buffer was responsible for causing vertex explosions. The solution is to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8127" data-gh-pr="8127">simplify the implementation of stream buffers</a> . As the new implementation can only feed a single upload request at a time, this may provide a small performance loss in some cases, but it’s sure to fix several other games in the process.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/poyobug_hu9750d6444b724c56cf9088a84ca862ea_2819821_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A look inside Kirby&#39;s powers? (Kirby and the Forgotten Land)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/poyofix_huc74b3803554f4c3f4a532fbbdf073f6e_10646570_1024x0_resize_q90_bgffffff_box_3.jpg" alt="A look inside Kirby&#39;s powers? (Kirby and the Forgotten Land)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">A look inside Kirby&#39;s powers? (Kirby and the Forgotten Land)</p> <p>AMD Radeon users may experience more stuttering than usual when running this game, depending on the specific GPU they have. This is because the available Windows AMD drivers don&rsquo;t offer support for the <code>VK_EXT_vertex_input_dynamic_state</code> extension, which helps reduce the shader count by 3 times the original amount. The Mesa RADV support for the extension is broken in RDNA2 hardware, as reported last month, so it remains blacklisted along with the Intel Windows support. NVIDIA hardware and older AMD GPUs on Linux offer proper support and enjoy the significantly reduced shader count, and the associated reduced stuttering when building their cache. CPU thread count will be critical here, at least until AMD adds official support for the extension.</p> <h2 id="graphical-changes-and-optimizations">Graphical changes and optimizations</h2> <p><a href="https://github.com/bunnei">bunnei</a> has the highlight of this month with the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8050" data-gh-pr="8050">rewrite of the <code>NVFlinger</code> implementation</a> , a part of <code>Project Y.F.C.</code>.</p> <p><code>NVFlinger</code> is the service in charge of presenting to the display, so any improvement in this area will bring more stable frametimes, perceived as less stuttering even when the frame rate count stays at a solid 60 FPS.</p> <p>Our original implementation was basically guess work done back in 2018, and it was lacking in <em>several</em> areas. For example, yuzu would block threads until the last frame was ready to be presented. This obviously leads to undesired stuttering unrelated to system performance.</p> <p>The new implementation is on par with the Nintendo Switch, based on the <a href="https://source.android.com/">Android Open Source Project</a>. This means yuzu changes its licence from GPLv2+ to GPLv3+ to accommodate the Apache 2.0 licence AOSP uses.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./abzubug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./abzufix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">ABZU</p> <p>Games like <code>ABZU</code> and <code>DRAGON BALL FighterZ</code> improve considerably, but other games like <code>Xenoblade Chronicles 2</code> require fixes that are still in testing in <code>Project Y.F.C.</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./dbzbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./dbzfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">DRAGON BALL FighterZ</p> <p>Enjoy the smooth as butter gameplay!</p> <p><a href="https://github.com/asLody">asLody</a> has been working on optimizing the <code>LOP3-LUT</code> shader instruction with the objective of improving performance and helping with getting <code>Hades</code> to work. Sadly, this first implementation caused some issues.</p> <p><a href="https://github.com/degasus">degasus</a>, which you may know from <em>a certain</em> <a href="https://dolphin-emu.org/?nocr=true">Dolphin emulator</a>, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7989" data-gh-pr="7989">managed to implement a patch</a> , which later turned into its own pull request, that solved the issues and achieved the same level of optimization.</p> <p>This is not enough to get <code>Hades</code> running. <code>Project Y.F.C.</code> will take care of that in the near future, but it’s a small global performance boost that mostly benefits low-end GPUs. It also provides easier to read code when performing maintenance.</p> <p>We documented our problems with video decoding on Linux Flatpak builds in previous progress reports. A check was added to avoid crashes, but in the process, Windows builds got stuck on CPU decoding! Users with low thread CPUs could immediately tell the difference during video playback.</p> <p>By simply <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8066" data-gh-pr="8066">disabling this check on Windows</a> , Windows builds can again enjoy the extra performance gained from decoding via GPU. If video playback feels smoother, you now know the reason! Thanks epicboy!</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> started work on improving yuzu’s Vulkan error handling.</p> <p>This is a very common issue caused mostly by very outdated GPU drivers installed by Windows Update, or custom slower drivers provided by laptop manufacturers that are used to lie on battery life metrics or keep up with cheapened cooling solutions. This most commonly affects Intel GPUs, but Vega based Radeon GPUs can also suffer from it occasionally.</p> <p>Another popular reason for this issue, as mentioned in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/#ui-changes">previous reports</a>, is outdated Vulkan injectors breaking support altogether. Software like OBS Studio, OBS Streamlabs, Bandicam, Action!, Overwolf, GShade, iCUE, MSI Afterburner, or <em>anything</em> with an overlay that injects into Vulkan can completely break rendering if it is outdated, or the developers don’t keep up with recent Vulkan releases.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7986" data-gh-pr="7986">toast’s fixes solve 2 different scenarios</a> . Changing the behaviour of how yuzu handles both GPU instance creation and rendering instance creation helps avoid direct-to-desktop crashes caused by outdated drivers or broken Vulkan injectors.</p> <p>There’s more work to do, but this lets us get closer to offering Vulkan as the default graphics API in the future.</p> <p>epicboy found out that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8106" data-gh-pr="8106">avoiding a doubly locked mutex</a> fixes a crash when using Extreme GPU accuracy on the OpenGL backend, making it a safe option for those aiming for the most possible accurate rendering. This option is only accessible from <code>Emulation &gt; Configure... &gt; Graphics &gt; Advanced</code>.</p> <p>He also includes an <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8068" data-gh-pr="8068">optimization focused on eliminating <code>if(false) {…}</code> branches in the shader code</a> . This has the added benefit of reducing shader build times ever so slightly. Hey, less shader stuttering is less shader stuttering!</p> <h2 id="not-all-changes-benefit-everybody">Not all changes benefit everybody</h2> <p>In an effort to reduce RAM use in yuzu, Merry tested <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8016" data-gh-pr="8016">reducing the size of the code caches</a> in dynarmic. During internal testing, the change proved to be perfectly fine, a small reduction of memory use with no side effects.</p> <p>Once the result went live, users started to complain, reports of sudden stuttering affecting <code>Super Smash Bros. Ultimate</code> were in all communication channels.</p> <p>Dynarmic has to emulate whatever instruction a CPU lacks, and that takes more cache space. Older hardware, for example Skylake based CPUs (gen. 10 and older) or early first and second generation Ryzen CPUs, would not only have smaller caches, but would also lack support for some instructions more modern CPUs provide.</p> <p>Once the cache runs out, a recompilation happens. This results in impressive lag spikes experienced during Smash battles a few seconds into the match.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8070" data-gh-pr="8070">Reverting the change</a> was all that was needed to solve the issue. Happy Smashing!</p> <h2 id="general-bugfixes">General bugfixes</h2> <p>Recent Nintendo Switch firmware updates changed the behaviour of the inline on-screen keyboard. <a href="https://github.com/Morph1984">Morph</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8041" data-gh-pr="8041">updated yuzu’s emulated equivalent</a> to match the new versions, allowing games from the <code>Monster Hunter</code> series to be playable without having to transfer a save file after character creation was finished.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./osk.png" title=" The hardest part of starting any new game, character naming... (MONSTER HUNTER RISE)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/osk_hub08388841b4d7ada59b895ed87374468_256835_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The hardest part of starting any new game, character naming... (MONSTER HUNTER RISE)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The hardest part of starting any new game, character naming... (MONSTER HUNTER RISE)</p> </div> </div> <p>Morph also worked on <code>MiiEdit</code>, the applet for Mii creation that <a href="https://github.com/german77">german77</a> started working on last month. Morph’s changes <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8031" data-gh-pr="8031">add support for games requiring older firmware versions</a> .</p> <p>Our holy war against crashes at shutdown continues to rage on. Merry <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7999" data-gh-pr="7999">fixed a deadlock on exit that was hidden in the logging thread</a> . It’s like the Hydra, you cut off one head and two new heads appear.</p> <p>toastUnlimited has been having fun working on improving yuzu-cmd.</p> <p>Adding the <code>-c</code> or <code>--config</code> argument will allow the user to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8025" data-gh-pr="8025">specify a custom location for a configuration file</a> . This can be useful for game specific settings.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8026" data-gh-pr="8026">Extended memory layout support was added</a> .</p> <p>SDL2 has a limitation in that it doesn’t automatically resize the “rendering canvas” when you enter in fullscreen mode. yuzu previously used the resolution of the native game, so either 1280x720 in undocked mode and 1920x1080 in docked mode. With this change, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8027" data-gh-pr="8027">the resolution of the desktop will be used instead</a> , allowing proper exclusive fullscreen support, and letting the scaling filters display as they should.</p> <p><a href="https://github.com/v1993">v1993</a> applied some changes to the sockets (LAN and LDN) service, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8028" data-gh-pr="8028">allowing inexact address length values</a> . This prevents crashes on <code>Minecraft</code> v1.12.1, as the game passes zero as the value for the address length.</p> <p>toastUnlimited gave us a simple, but really important, quality of life change, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8035" data-gh-pr="8035">disabling the <code>Web Applet</code> by default</a> . This was necessary due to many games having issues with it. The <code>Web Applet</code> is responsible for blocking controller input, and not many users are interested in the tutorials the service is mostly used for, so it’s a sacrifice worth the small loss. For anyone interested, the Web Applet can be re-enabled from <code>Emulation &gt; Configure… &gt; General &gt; Debug &gt; Disable Web Applet</code>.</p> <p>And continuing on the topic of quality of life changes, yuzu will now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8107" data-gh-pr="8107">save the fullscreen status</a> for future boots. Close or stop a game while in fullscreen and the emulator will automatically maximize for you when you start the next one!</p> <p>german77 couldn’t let a month pass without contributing a pull request! He’s fighting to make <code>Flip Wars</code> compatible. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8120" data-gh-pr="8120">Correctly adding a Signal event on <code>AcquireNpadStyleSetUpdateEventHandle</code></a> makes the game playable.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./flip1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/flip1_hucd64bd324f9cb8fd56d94b5de118b0bf_769360_800x0_resize_q90_bgffffff_box_3.jpg" alt="Flip Wars"></a> </div> <div class="column is-bottom-paddingless"> <a href="./flip2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/flip2_hu50d37d954a8dcd6e79d683d3f2da44af_2128867_800x0_resize_q90_bgffffff_box_3.jpg" alt="Flip Wars"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Flip Wars</p> <h2 id="future-projects">Future projects</h2> <p>Merry is testing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/8089" data-gh-pr="8089">adding a <code>Paranoid</code> CPU accuracy</a> , an option not for the faint of heart! It would disable most optimizations (but not fastmem) with the main purpose of aiding in CPU optimization debugging, but we all know it will be used for extra comfort if there is CPU performance to spare.</p> <p><code>Project Gaia</code> is experiencing some minor delays caused by new additions Nintendo made in recent firmware updates.</p> <p>And regarding <code>Project Y.F.C.</code>, we’re measuring performance increases, as well as getting games to render for the first time:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hades.png" title=" It&#39;s one hell of a game! (Hades)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2022/hades_hu751a721e2f4c16eaae789b68aa59514d_6378114_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It&#39;s one hell of a game! (Hades)"></a> <p class="has-text-centered is-italic has-text-grey-light"> It&#39;s one hell of a game! (Hades)</p> </div> </div> <p><a href="https://www.youtube.com/watch?v=b9434BoGkNQ">That’s all folks!</a> Thank you for staying with us, and see you next month!</p> <p>We will include relevant kernel changes in the next report.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report February 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/ Tue, 15 Mar 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/ <p>Glad to have you here, yuz-ers! This month, we&rsquo;re proud to showcase a ton of kernel changes that finally fix long standing bugs, massive performance improvements, UI and input changes, and more!</p> <p>Glad to have you here, yuz-ers! This month, we&rsquo;re proud to showcase a ton of kernel changes that finally fix long standing bugs, massive performance improvements, UI and input changes, and more!</p> <p>But first, we present to you: a heavily requested feature. Not for yuzu, but for our articles.</p> <p>While we try to only discuss changes that are currently available in Mainline builds, due to time constraints or delays, we sometimes list pull requests that will be in Early Access for a few extra days after the release of a progress report.</p> <p>To allow for accurate status reports, <a href="https://github.com/liushuyu">liushuyu</a> implemented hovercards that we writers can then add to links for pull requests. If you place the mouse over the dotted hyperlink, you will be able to see the current status, title, number, and merge date of a PR. Try it <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7969" data-gh-pr="7969">here!</a> .</p> <p>The different possible statuses are:</p> <ul> <li>Red: Pull request closed, it won’t be part of any build</li> <li>Purple: Merged to master, it already is on Mainline, or will be in 24 hours at most (if our buildbot doesn’t die in the process!)</li> <li>Green: Pull request open, not yet added to Mainline unless it has the <code>mainline-merge</code> tag, check the pull request link to confirm</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./merge.png" title=" There are a few more, but these 3 are the most important"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/merge_hu81935222040418684ec4c29d151e6ed8_1270_125x0_resize_q90_bgffffff_box_3.jpg" alt=" There are a few more, but these 3 are the most important"></a> <p class="has-text-centered is-italic has-text-grey-light"> There are a few more, but these 3 are the most important</p> </div> </div> <p>You can come back to the articles at any time from now on to see if a feature has been merged to Mainline already, as these cards will update dynamically accordingly. Keep in mind that this is not an immediate process. A merged pull request will be added to Mainline in the next autobuild, so it may take up to 24 hours to see a status change on this site.</p> <p>With that out of the way, let’s get started!</p> <h2 id="graphical-fixes-and-how-to-increase-performance">Graphical fixes, and how to increase performance</h2> <p>Due to problems with the RADV drivers on Linux, using the Vulkan API would crash yuzu when run on AMD&rsquo;s RDNA2 graphics cards. Most notably, this problem affected the Steam Deck, as reported by users who tried testing yuzu on their devices.</p> <p>It was determined that the crash happened because of <code>VK_EXT_vertex_input_dynamic_state</code>, a Vulkan extension used to minimize the number of pipeline objects needed during the shader compilation process. These structures are massive, and sometimes, a game may want to change only a small portion of the contents held in them, such as the vertex input state. Using this extension allows the API to dynamically change these members in the structure with a simple function call, eliminating the need to create a whole new object, thus, reducing the amount of resources used by the operation.</p> <p>While this bug is being resolved upstream, <a href="https://github.com/ameerj">epicboy</a> pushed a PR to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7953" data-gh-pr="7953">blacklist the extension</a> on RDNA2 devices running RADV drivers, so yuzu does not outright crash.</p> <p>But there was still one more driver with problems for us out there.</p> <p>Mesa&rsquo;s ANV driver on Linux does not support the texture format <code>VK_FORMAT_B5G6R5_UNORM_PACK16</code>, and this caused yuzu to crash when running a game that made use of it, such as <code>Bowser's Fury</code>. To bypass this problem, <a href="https://github.com/voidanix">voidanix</a> implemented a solution that emulates <code>BGR565</code> textures by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7913" data-gh-pr="7913">swizzling the RGB565 format</a> instead.</p> <p>In a similar vein, <a href="https://github.com/Morph1984">Morph</a> implemented a <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7948" data-gh-pr="7948">missing vertex format</a> , used by the title <code>パワプロクンポケットR</code> (Power Pro Kun Pocket R).</p> <p><a href="https://github.com/asLody">asLody</a> also implemented a missing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7939" data-gh-pr="7939">framebuffer format</a> , this time used by <code>Yo-kai Watch 4</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ykw4.png" title=" The original name is technically 妖怪ウォッチ4 ぼくらは同じ空を見上げている (Youkai Wotchi Bokura wa Onaji Sora wo Miageteiru)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/ykw4_hu687f3e679a861732c6db5baff0f9fd2a_889030_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The original name is technically 妖怪ウォッチ4 ぼくらは同じ空を見上げている (Youkai Wotchi Bokura wa Onaji Sora wo Miageteiru)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The original name is technically 妖怪ウォッチ4 ぼくらは同じ空を見上げている (Youkai Wotchi Bokura wa Onaji Sora wo Miageteiru)</p> </div> </div> <p>Another fix by this developer was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7930" data-gh-pr="7930">adding missing semaphore operations</a> for <code>MaxwellDMA</code>, used by <code>Legend of Zelda: Breath of the Wild</code> and <code>Pokémon Legends: Arceus</code>.</p> <h2 id="kernel-changes-and-how-to-tame-smash">Kernel changes, and how to tame Smash</h2> <p>Continuing with the ongoing work on the kernel, <a href="https://github.com/bunnei">bunnei</a> has <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7956" data-gh-pr="7956">revamped the kernel memory manager</a> to make it more compatible with the latest system updates.</p> <p>One neat setting that came along with these changes is the ability for yuzu to support different memory layouts, such as the &ldquo;6 GB extended memory layout&rdquo;, used in developer units (a feature requested by the modding community).</p> <p>Some mods can utilize more RAM than the Switch can provide, mainly high resolution texture replacements. To solve this issue, bunnei <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7932" data-gh-pr="7932">added a toggle to enable the extended 6GB memory layout</a> that real developer kits would have available. Those extra 2GB will allow heavy mods to work without issues. You can find the setting in <code>Emulation &gt; Configure… &gt; General &gt; Extended memory layout (6GB DRAM)</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./6gb.png" title=" Mod away!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/6gb_hu216ad3ff93f856274df4c4bc00b0494d_21287_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Mod away!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Mod away!</p> </div> </div> <p>Don’t expect it to make a difference in emulation performance, games will not care if the emulated console has more than 4GB, they only care about having enough free memory for their operations.</p> <p>bunnei has also been improving the accuracy of the page table management by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7835" data-gh-pr="7835">migrating locks to using emulated guest locks</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7919" data-gh-pr="7919">improving the mapping and unmapping of physical memory</a> .</p> <p>As always, the biggest motivator behind this work is increasing the accuracy of our implementation, while also fixing any bugs that may have been hiding there these past years.</p> <p><a href="https://github.com/merryhime/dynarmic">Dynarmic</a>, our ARM JIT recompiler, also got a number of new optimizations and bugfixes this month.</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> corrected the fencing logic for the serialization of memory store/load operations in Dynarmic&rsquo;s <code>x64</code> code emitter, and subsequently <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7827" data-gh-pr="7827">updated the submodule</a> to bring these changes into yuzu&rsquo;s codebase. This fixed the freezes that affected <code>Pokémon Legends: Arceus</code>.</p> <p>While investigating the stability issues of <code>Super Smash Bros. Ultimate</code>, bunnei and <a href="https://github.com/merryhime">Merry</a> found that the problem was caused by an error in the <code>SpaceRemaining</code> function, used to calculate the remaining space available for JITed code in a cache block.</p> <p>Dynarmic splits these code blocks in two regions, named <code>near</code> and <code>far</code>. This scheme aims to minimize L1 CPU cache misses by keeping &ldquo;hot&rdquo; code in <code>near</code> readily available for execution, while &ldquo;cold&rdquo; code is pushed into the <code>far</code> region. Due to a bug in the way the remaining space was being computed, the <code>near</code> region would overflow into the <code>far</code> region, overwriting &ldquo;cold&rdquo; code with &ldquo;hot&rdquo; code. The CPU would then attempt to run the &ldquo;cold&rdquo; code that was previously there, and crash horribly on the try.</p> <p>Ultimately (no pun intended), this translated as crashes after a few matches in <code>SSBU</code>, since that was the time it took to run out of space and overflow the cache. By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7955" data-gh-pr="7955">correcting the comparisons</a> used to compute this value, the devs were finally able to mitigate one of the longest-standing problems surrounding this title.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smash.png" title=" We did so many CPU fights to test these changes... (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/smash_hu33dedfc804962c1d3954a4b503d0d770_4222381_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We did so many CPU fights to test these changes... (Super Smash Bros. Ultimate)"></a> <p class="has-text-centered is-italic has-text-grey-light"> We did so many CPU fights to test these changes... (Super Smash Bros. Ultimate)</p> </div> </div> <p>Merry has also been busy <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7959" data-gh-pr="7959">implementing support for a new CPU optimization</a> , which makes the emulation of ARM exclusive access instructions through the use of <code>cmpxchg</code> (compare and exchange) instruction of the <code>x64</code> architecture.</p> <p>The ARM instruction set contains instructions that can exclude access to a memory address, so that only some instructions — a pair, in this case: one for reading values, and another for writing them — can operate safely in a multicore environment, without the interference of instructions from other threads, who may also want to access the same value in memory.</p> <p>It achieves this by marking the address &ldquo;for exclusive access&rdquo; after reading the value in memory, so that an &ldquo;exclusive&rdquo; store instruction only writes into this address if it is marked with this flag. A &ldquo;normal&rdquo; store instruction, on the other hand, was designed to always clear this flag after writing. Thus, the exclusive instructions can use this information to know when the value in the memory address was altered by a non-exclusive instruction, and restart the whole job again, until the operation succeeds.</p> <p>ARM is able to control this behaviour through a piece of hardware called the <code>Exclusive Monitor</code>. But emulating these instructions accurately on the <code>x64</code> architecture can be very difficult, given the complex nature of testing and debugging in a multithreaded environment. Thus, their previous implementation was rather conservative and inefficient, to ensure concurrency.</p> <p>It is possible, however, to approximate the original behaviour through the use of <code>cmpxchg</code>, which compares the value in the memory address with a reference, and if they match, it writes a new value into it. Thus, one can use the value in a memory address as the reference, and later write another value into the same address if, and only if, the stored value matches the reference. Relying on the semantics of this instruction, exclusive memory reads and writes can be inlined into the JITed code and speed up their execution.</p> <p>Titles that make extensive use of these exclusive instructions, such as <code>Pokémon Legends: Arceus</code>, should see a slight increase in performance.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gnv.png" title=" Some Nvidia numbers"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/gnv_hu031b920913cda4a15e9e505b14a4a745_18511_600x0_resize_q90_bgffffff_box_3.jpg" alt=" Some Nvidia numbers"></a> <p class="has-text-centered is-italic has-text-grey-light"> Some Nvidia numbers</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gamd.png" title=" Some AMD numbers"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/gamd_hu5bd339f16121d2108953bd3b0271a5ca_18611_600x0_resize_q90_bgffffff_box_3.jpg" alt=" Some AMD numbers"></a> <p class="has-text-centered is-italic has-text-grey-light"> Some AMD numbers</p> </div> </div> <h2 id="general-bugfixes-and-ui-changes">General bugfixes and UI changes</h2> <p><a href="https://github.com/german77">german77</a> did some work on the UI to spice things up.</p> <p>He <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7859" data-gh-pr="7859">improved SDL battery level detection</a> , realigned some of the UI elements in the control settings, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7839" data-gh-pr="7839">and gave us new, prettier battery symbols!</a> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/batteryold_hu1b447a384d095bffc43d3390e3981dbe_16709_563x0_resize_q90_bgffffff_box_3.jpg" alt="Cute and simple!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/batterynew_huc99b7214778d6d76dacce74353a323fe_17108_563x0_resize_q90_bgffffff_box_3.jpg" alt="Cute and simple!"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Cute and simple!</p> <p>german77 also <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7861" data-gh-pr="7861">added new hotkeys</a> by popular request. Joining the fray are Docked/Undocked (for controllers), Window Adapting Filter, GPU accuracy (switches between normal and high), and mute/unmute audio.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hotkeys.png" title=" Once you master the hotkey-jutsu, no one will be able to stop you"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/hotkeys_huc1381fca4fd8c43a8516c1b256e6e6f8_30152_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Once you master the hotkey-jutsu, no one will be able to stop you"></a> <p class="has-text-centered is-italic has-text-grey-light"> Once you master the hotkey-jutsu, no one will be able to stop you</p> </div> </div> <p>Another highly requested fix was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7867" data-gh-pr="7867">improving Amiibo support</a> . Our old code wasn’t very accurate, leading to several games failing. While there is room for improvement, this new implementation is far more accurate and should allow stable use of Amiibo dumps in most games now.</p> <p>We also want to announce that native support for NFC scanning of physical Amiibos is being worked on! We&rsquo;ll have more information to share as progress is made.</p> <p>Morph fixed a weird issue that’s been appearing lately. Under some circumstances, after reopening yuzu, the window would be a maximized borderless&hellip; <em>thing</em>. As it turns out, for some reason the configuration file was not resetting the frameless flag after closing yuzu. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7849" data-gh-pr="7849">Forcing a removal of the flag</a> at each boot solves the issue.</p> <p><a href="https://github.com/Kelebek1">Maide</a> added a very useful feature to modders and anyone interested in the internals of their games. Previously, yuzu dumped the base <code>exeFS</code>, which only includes data from the base game, missing any new addition from updates or DLCs. Instead, by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7899" data-gh-pr="7899">dumping the patched <code>exeFS</code></a> , like <a href="https://github.com/EliEron">EliEron</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/4341" data-gh-pr="4341">suggested in the past</a> , users will have access to update files!</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> found out that <code>Splatoon 2</code> crashes when accessing the inventory in the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/#lan-party-time">LAN lobby</a>. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7887" data-gh-pr="7887">Stubbing the <code>IsUsbFullKeyControllerEnabled</code> function</a> is all that was needed. Splat your friends with impunity!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./splat.png" title=" With all that ink evaporating into the atmosphere, rain must be fantastic"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/splat_hu896e4077958fe533550673b66c087324_1927747_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" With all that ink evaporating into the atmosphere, rain must be fantastic"></a> <p class="has-text-centered is-italic has-text-grey-light"> With all that ink evaporating into the atmosphere, rain must be fantastic</p> </div> </div> <p>For retro gaming fans, both toastUnlimited and german77 have fixes for the SNES and NES emulators included with the Nintendo Switch Online service (yes, you can dump and play those offline too). <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7878" data-gh-pr="7878">Stubbing<code>mnpp:app</code></a> solves crashes, and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7877" data-gh-pr="7877">updating the process revision</a> of our audio emulation allows the official emulators to work properly on yuzu.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./nes.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/nes_hu20193fa9101533b62712b42e963af3d5_336412_800x0_resize_q90_bgffffff_box_3.jpg" alt="Our team members are big Earthbound fans"></a> </div> <div class="column is-bottom-paddingless"> <a href="./snes.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/snes_hu51783114a5a6ec7c1424706cbcbf0294_370523_800x0_resize_q90_bgffffff_box_3.jpg" alt="Our team members are big Earthbound fans"></a> </div> <div class="column is-bottom-paddingless"> <a href="./snes2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/snes2_hub0cad61f3fb342b7f38217e06536e2fe_365080_800x0_resize_q90_bgffffff_box_3.jpg" alt="Our team members are big Earthbound fans"></a> </div> <div class="column is-bottom-paddingless"> <a href="./snes3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/snes3_hude0d62fd26080349fd830f29239c08ad_431990_800x0_resize_q90_bgffffff_box_3.jpg" alt="Our team members are big Earthbound fans"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Our team members are big Earthbound fans</p> <h2 id="input-improvements">Input improvements</h2> <p>As it happens each month, german77 dominates this section.</p> <p>As a way to test how strong the current rumble setting is, you can now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7842" data-gh-pr="7842">force the controller to vibrate</a> by pressing any button while the Configure Vibration window is open.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./rumble.png" title=" Joy-Con goes BRRRR"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/rumble_hu98406571c687dd5d809a40dddaa0e281_24212_421x0_resize_q90_bgffffff_box_3.jpg" alt=" Joy-Con goes BRRRR"></a> <p class="has-text-centered is-italic has-text-grey-light"> Joy-Con goes BRRRR</p> </div> </div> <p>Gamepads have drift, not only in the exaggerated fashion Joy-Cons are known for, but every gamepad has a certain degree of drifting to it. To hide this, consoles auto-center their sticks.</p> <p>On yuzu, one of the limitations of <a href="https://www.libsdl.org/">SDL</a> is that it will only read the factory calibration on a Nintendo official controller, skipping any user calibration profile that may be available. We counter this by auto-centering at boot, but sticks can still go anywhere they like, so german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7860" data-gh-pr="7860">adds an option to manually center each axis</a> as an additional option. Just right click any direction of a stick in our controller settings.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./center.png" title=" Just one right click away"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/center_hu6f1668d6259bb6aafd0e6765bc48fac0_5597_198x0_resize_q90_bgffffff_box_3.jpg" alt=" Just one right click away"></a> <p class="has-text-centered is-italic has-text-grey-light"> Just one right click away</p> </div> </div> <p>Support was added to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7900" data-gh-pr="7900">allow mapping the Enter key</a> , which previously just restarted the mapping process.</p> <p>toastUnlimited <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7851" data-gh-pr="7851">added support for motion inputs</a> to <code>yuzu-cmd</code>, our terminal version of the executable. Terminal warriors can now enjoy some Just Dance too.</p> <h2 id="improving-emulation-to-not-use-emulation">Improving emulation to not use emulation</h2> <p><a href="https://github.com/xerpi">xerpi</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7866" data-gh-pr="7866">implemented the 32 bit version</a> of the <code>OutputDebugString</code>, <code>CreateCodeMemory</code>, and <code>ControlCodeMemory</code> supervisor calls. Thanks!</p> <p>xerpi’s help has a bigger objective in mind than just helping some little-known Switch emulator. They’re developing <a href="https://github.com/xerpi/vita2hos">vita2hos</a>, a translation layer to run <code>PlayStation Vita</code> apps and games natively on the Nintendo Switch! The road ahead is long, since most Switch debug tools are 64-bit only, and the Vita is firmly a 32-bit console, so several rewrites and changes are in order to get the project going.</p> <p>yuzu lacks some functionality to offer full 32-bit execution mode support, so the PR was opened to help improve that area, since xerpi is using Switch emulators to assist and ease development. We can’t wait to see how this project grows!</p> <h2 id="vulkan-is-the-future">Vulkan is the future</h2> <p>With the work on <code>Project Y.F.C</code> and other changes scheduled, we’re slowly aiming for enabling Vulkan by default, and keeping OpenGL in long term support. This section will not list changes in yuzu, but settings users can tweak to improve their Vulkan performance in yuzu and other emulators.</p> <p>One of the main issues with performance on Vulkan is the aggressive frequency management current GPUs will do to save power. Since the actual 3D load produced by Nintendo Switch games will be very low for even a modern low-end GPU, clock speeds tend to stay on the power saving side of their spectrum.</p> <p>An easy way to considerably improve performance is to force the GPU to run at higher <em>sustained clock speeds</em>. The highest value the GPU can reach is usually irrelevant here as most GPUs will be faster than a Switch’s Tegra X1, but the sustained clock speed is what will keep framerates high and stuttering to a minimum.</p> <p>NVIDIA users have a simple single setting in the <code>NVIDIA Control Panel</code>, <code>Prefer maximum performance</code>. You can find this toggle in <code>3D Settings &gt; Manage 3D settings &gt; Program Settings tab</code> click on <code>Add</code> and select yuzu from the available options, then scroll down to <code>Power management mode</code> and set it to <code>Prefer maximum performance</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./nvidia.png" title=" Ol&#39; Reliable UI"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/nvidia_hu6b0eed30b9ba250597f7629c8b64362a_24617_558x0_resize_q90_bgffffff_box_3.jpg" alt=" Ol&#39; Reliable UI"></a> <p class="has-text-centered is-italic has-text-grey-light"> Ol&#39; Reliable UI</p> </div> </div> <p>On the AMD side, this requires a bit of manual work, and may only be compatible with RDNA based GPUs. Only relatively recent Radeon drivers added the option to tune both minimum and maximum GPU frequencies on the included <code>Radeon WattMan</code>. This can disable the warranty of your Radeon product.</p> <p>What needs to be done, in a similar way to NVIDIA, is to add yuzu as a profile on the <code>Gaming</code> tab, click on <code>Tune Game Performance</code> and set Tuning Control to <code>Custom</code>. Enable GPU Tuning and you will be able to tweak the <code>Min. Frequency (%)</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./radeon1.png" title=" While this can be set globally on Radeon Software, we recommend to use per-application profiles"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/radeon1_hud8c20c2b4efad20ba2bfe7295c17ad33_13187_589x0_resize_q90_bgffffff_box_3.jpg" alt=" While this can be set globally on Radeon Software, we recommend to use per-application profiles"></a> <p class="has-text-centered is-italic has-text-grey-light"> While this can be set globally on Radeon Software, we recommend to use per-application profiles</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./radeon2.png" title=" Besides the GPU, increasing the memory clock speeds will always help in emulation, especially at high resolutions"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/radeon2_hu6913ef785bab1f828df9d9c127d9f89c_105716_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Besides the GPU, increasing the memory clock speeds will always help in emulation, especially at high resolutions"></a> <p class="has-text-centered is-italic has-text-grey-light"> Besides the GPU, increasing the memory clock speeds will always help in emulation, especially at high resolutions</p> </div> </div> <p>Using a humble (and worse than mediocre) RX 6500 XT as an example, we can see <code>Pokémon Legends: Arceus</code> increase its framerate up to 73% <em>for free</em>, managing to surpass an RX 570 at ease, simply by raising the minimum clock speed from 500MHz to 2875MHz (a 475% increase, as the next graph shows).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./radgraph.png" title=" Too much power-saving can also be a bad thing"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/radgraph_hu353aca7cbf77bdf26fdbb07389ca9d78_16566_600x0_resize_q90_bgffffff_box_3.jpg" alt=" Too much power-saving can also be a bad thing"></a> <p class="has-text-centered is-italic has-text-grey-light"> Too much power-saving can also be a bad thing</p> </div> </div> <p>The performance gains here can be massive, but one can start to see diminishing returns past a certain point.</p> <h2 id="future-projects">Future projects</h2> <p><code>Project Y.F.C.</code> continues to mature as more previously broken games start to become playable. Blinkhawk informs us that he&rsquo;s currently changing focus to performance. We can&rsquo;t wait to tell you more!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./yfc.png" title=" Fire Emblem Warriors"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/yfc_hu6b99ab594d9d152a4798ebba40080821_6869428_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Fire Emblem Warriors"></a> <p class="has-text-centered is-italic has-text-grey-light"> Fire Emblem Warriors</p> </div> </div> <p>Morph has a message regarding the progress of <code>Project Gaia</code>:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gaia.png" title=" Poyo!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/gaia_hu446802e97ee1ad72696fbfe674b36bad_56301_163x0_resize_q90_bgffffff_box_3.jpg" alt=" Poyo!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Poyo!</p> </div> </div> <p>And german77 has been playing with <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7964" data-gh-pr="7964">implementing a Mii editor applet</a> . Current support is pretty barebones, but anyone interested is free to build the pull request and try it.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mii.png" title=" Sweet home Alabama?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2022/mii_huae9adc6e4926b6aff660b843f63dbbb8_931976_882x0_resize_q90_bgffffff_box_3.jpg" alt=" Sweet home Alabama?"></a> <p class="has-text-centered is-italic has-text-grey-light"> Sweet home Alabama?</p> </div> </div> <p>That’s all folks! We thank you for your time, and we hope to see you next month. <a href="https://www.youtube.com/watch?v=DsqfwQwPTH8">Glory to Mankind</a>.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> </p> Progress Report January 2022 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/ Fri, 11 Feb 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/ <p>What a month we&rsquo;ve had, yuz-ers. This time, we offer you a plethora of kernel changes, input fixes and new additions, yet more NVIDIA driver fixes, user interface changes, and more!</p> <p>What a month we&rsquo;ve had, yuz-ers. This time, we offer you a plethora of kernel changes, input fixes and new additions, yet more NVIDIA driver fixes, user interface changes, and more!</p> <h2 id="psa-for-nvidia-users-part-3">PSA for NVIDIA users: Part 3</h2> <p><a href="https://www.youtube.com/watch?v=g02QU-xPV1I">It’s not over yet</a>.</p> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2021/#paint-me-like-one-of-your-french-bits">As you know</a>, regular NVIDIA desktop and laptop GPUs don&rsquo;t support decoding ASTC textures, so yuzu makes use of the compute capabilities of the GPU to parallelize the process. However, the recent release of the 511.XX drivers introduced an issue that affected our compute shader based accelerated ASTC texture decoding.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/astcbug_hudf65613a09f11d2219b4a6c8b47f7a85_2671847_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Crispy (Super Mario Odyssey)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/astcfix_hu5ebb00d6587d2862a15b803306246453_2335349_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Crispy (Super Mario Odyssey)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Crispy (Super Mario Odyssey)</p> <p>After some investigation, <a href="https://github.com/ameerj">epicboy</a> found that the reason for the bug is an over-optimization introduced by the new drivers (an optimization for one scenario results in issues for another). <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7724" data-gh-pr="7724">A small change in behaviour solves the issue</a> . You can find more technical information in the pull request.</p> <p>Users playing <code>Hyrule Warriors: Age of Calamity</code> or <code>Luigi’s Mansion 3</code> should stick to the 47X.XX series of drivers, as any version newer than that will have several rendering issues. Don&rsquo;t fret, we’re investigating the cause!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./aoc.png" title=" Abstract art generator (Hyrule Warriors: Age of Calamity)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/aoc_hu285d905a43d99b7853d806f0371def18_3399220_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Abstract art generator (Hyrule Warriors: Age of Calamity)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Abstract art generator (Hyrule Warriors: Age of Calamity)</p> </div> </div> <p>On the flip side, version 511.65 includes support for the recently released Vulkan 1.3, and improves performance considerably when using said API. Some games show an increase in performance of up to 24%!</p> <h2 id="a-new-legend">A new Legend</h2> <p>Finally, after over two decades, the Pokémon franchise diverges from its tired formula and implements a big change to gameplay in the recently released <code>Pokémon Legends: Arceus</code>.</p> <p>All this at the cost of graphical fidelity. But hey, there are worse looking games&hellip; <a href="https://www.youtube.com/watch?v=-vak7MUaa5E">on the GameCube</a>.</p> <p>Apart from the disappointing graphics, this game&rsquo;s release exposed several issues with yuzu, and has even helped us fix long standing issues that affected many more games.</p> <p><a href="https://github.com/bunnei">bunnei</a> fixed a deadlock found in the code used to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7787" data-gh-pr="7787">migrate threads among the cores</a> , which caused some noteworthy softlocks present in <code>Pokémon Legends: Arceus</code>.</p> <p>The problem can be summarised as follows: One thread (thread <code>A</code>) would be waiting for another one (thread <code>B</code>) to release a lock, and conversely, thread <code>B</code> would be waiting for thread <code>A</code> to release another lock, resulting in a deadlock.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ending.png" title=" Best gameplay change in decades (Pokémon Legends: Arceus)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/ending_hue759304625ed183865854849b108fcb4_8093810_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Best gameplay change in decades (Pokémon Legends: Arceus)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Best gameplay change in decades (Pokémon Legends: Arceus)</p> </div> </div> <p>Moving on from kernel issues, epicboy implemented various GPU changes.</p> <p>He found that <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7788" data-gh-pr="7788">reducing the amount of buffer allocations</a> at the start, rather than only at the end, prevented the game from crashing in certain locations.</p> <p>Some Vulkan drivers, especially Intel Windows ones, can’t process 64-bit atomic operations (operations that can run independently of any other processes). epicboy <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7800" data-gh-pr="7800">adds support in yuzu for unsigned 2x32-bit atomic operations</a> , as that’s the fallback option such drivers use. With this change, the game boots with Intel GPUs running Vulkan.</p> <p>AMD had a longstanding issue with <code>Transform Feedback</code> in both their official Windows and Linux drivers, causing rendering issues in countless games. While this was recently solved in the Linux AMDVLK drivers, AMD Windows drivers still need to be told which <code>Execution Mode</code> will be in use next.</p> <p><a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7799" data-gh-pr="7799">Explicitly stating to use Xfb</a> <code>Execution Mode</code> before starting to use Transform Feedback solves all issues related to it on AMD Windows Vulkan drivers, not only benefiting <code>Pokémon Legends: Arceus</code>, but also games like <code>Xenoblade Chronicles 2</code>, <code>Xenoblade Chronicles Definitive Edition</code>, <code>Hellblade: Senua's Sacrifice</code>, <code>Donkey Kong Country: Tropical Freeze</code>, <code>POKKÉN TOURNAMENT DX</code>, and many many others.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/tfbug1_hue9411cc7536af469208c80598dd07414_2665205_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Legends: Arceus"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/tffix1_hu5ccb1c396bb47f7dfeb4331e193154c5_2658050_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Legends: Arceus"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon Legends: Arceus</p> <p> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/tfbug2_hu8459351e855ab12288bc64f92f8fa0d2_2477937_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Xenoblade Chronicles Definitive Edition"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/tffix2_hu953dd607e7a3f40d06370c7d8bd36d42_2348352_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Xenoblade Chronicles Definitive Edition"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Xenoblade Chronicles Definitive Edition</p> <p> </p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/tfbug3_hudd945f1e85c25d99e224f37b02618517_2520067_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Donkey Kong Country: Tropical Freeze"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/tffix3_huadf4532e3d1e7bac4ebcc8672cc2e74d_2516873_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Donkey Kong Country: Tropical Freeze"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Donkey Kong Country: Tropical Freeze</p> <p><code>Pokémon Legends: Arceus</code> is affected by vertex explosions, exhibiting what looks like textures stretching at random. The bad news is that this is a problem with the <code>Buffer Cache</code>, and fixing it will take considerable time.</p> <p>The good news is that <a href="https://github.com/FernandoS27">Blinkhawk</a>, with some help from epicboy, managed to implement a temporary workaround to avoid this problem while a permanent solution starts taking shape. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7805" data-gh-pr="7805">Flushing the buffer before writing</a> saves us from polygon hell, at a minimal performance cost.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/vebug_hu08cbe94a54aa7bc4ea86b34ea205d334_3250704_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Imagine how it looks from space (Pokémon Legends: Arceus)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/vefix_hubda5e64cad132bfdb67f9294d44f50f9_3604160_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Imagine how it looks from space (Pokémon Legends: Arceus)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Imagine how it looks from space (Pokémon Legends: Arceus)</p> <p>Mark this the day we start to plan yet another Buffer Cache Rewrite.</p> <p>As a start, Arceus showed a considerably higher VRAM use than normal, causing 2GB GPU users to crash during cutscenes. Blinkhawk’s solution is to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7812" data-gh-pr="7812">expand the specific direction the buffer cache is increasing</a> , instead of the previous method of doubling the size. This allows 2GB users to play regularly, and 4GB users to be able to scale to 2x without fear of crashes.</p> <p>Now for some general recommendations:</p> <p>Having a save from previous Switch Pokémon games will unlock special clothing options after the tutorial.</p> <p>We measured a slim performance improvement on the (currently) latest 22.2.1 AMD Windows drivers and, as mentioned, a 24% boost with the 511.65 NVIDIA Windows driver. Chad Vulkan 1.3 lending a hand.</p> <p>Regarding GPU accuracy, while <code>Normal</code> produces the highest performance, <code>High</code> allows for proper particle rendering, so if you want the extra accuracy and have the performance to spare, stick to <code>High</code>.</p> <p>Effects, particles, and certain attacks seem to render incorrectly at resolutions over native 1x. While we’re investigating the reason for this, it seems to also happen on the Switch itself, so it could just be the nature of these shaders (feels reminiscent of the ghosting in the <a href="https://www.reddit.com/r/Citra/comments/ft28sw/is_there_any_way_to_fix_ghosting_on_pokemon_ultra/">3DS Pokémon games</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./particles.png" title=" Thanks Serfrost! (Pokémon Legends: Arceus)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/particles_hu238c6c6141706592182685d1eeada71d_178531_364x0_resize_q90_bgffffff_box_3.jpg" alt=" Thanks Serfrost! (Pokémon Legends: Arceus)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Thanks Serfrost! (Pokémon Legends: Arceus)</p> </div> </div> <p>yuzu’s default setting is to run games in OpenGL using GLASM, commonly known as assembly shaders. These settings will cause weird shadow acne on characters, and the solution is to either use GLSL instead of GLASM, or what we recommend, switch to Vulkan altogether.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/glasmbug_hu5f1c9cf786614a02a448d0b135beb60d_6252815_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Broken shadows? Zero! (Pokémon Legends: Arceus)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/glasmfix_hu2cab055210f523a42c9ed86fd9d34951_6991844_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Broken shadows? Zero! (Pokémon Legends: Arceus)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Broken shadows? Zero! (Pokémon Legends: Arceus)</p> <p>Users of Radeon GPUs older than the 400 series running Windows will experience crashes due to outdated and out of support drivers. Not even modified drivers seem to help, so the only solution is to use Linux with its still supported, and quite faster, Mesa drivers.</p> <p>Finally, excessive mod use or high values of <code>Anisotropic Filtering</code> can cause vertex explosions with some GPU configurations. We’re still investigating the cause for this.</p> <h2 id="other-graphical-fixes">Other graphical fixes</h2> <p>Blinkhawk made some <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7720" data-gh-pr="7720">changes to the Garbage Collector</a> (<code>GC</code>), which encompasses a number of bug fixes, improving the algorithm to make it clean memory in a smarter fashion, and also making it more efficient for iGPUs.</p> <p>The value of the <code>minimal</code>, <code>expected</code>, and <code>critical</code> thresholds were rebalanced, so that it does not act as aggressively on GPUs with more memory, while it still performs the job within an acceptable margin for low-memory graphics cards. Additionally, yuzu now queries the size of the GPU memory instead of estimating it, allowing the <code>GC</code> to make better decisions when cleaning it. These changes seek to benefit both low-end and high-end GPUs the most, without affecting either negatively.</p> <p>Special consideration was put on ASTC textures, which are notoriously heavy on the memory. The <code>GC</code> would clean them too early, causing graphical corruptions on titles that make use of these resources. For this reason, the conditions to determine when to clean ASTC textures were made less strict, which should mitigate the problem in most scenarios.</p> <p>Although these changes were originally part of the <code>YFC</code> project, Blinkhawk decided to implement these changes now, in order to alleviate the problems related to the previous <code>GC</code> implementation. There is still a lot to come from this project, so please stay tuned for more information in future updates.</p> <p>Keep in mind, special case titles like <code>ASTRAL CHAIN</code> will still require 3GB of VRAM or more to properly emulate.</p> <p>On another hand, some titles, such as the <code>Super Mario 64</code> port (homebrew), would experience freezes in some GPU models (especially iGPUs).</p> <p>Blinkhawk investigated the problem, and noticed it lay within our Vulkan Scheduler, a class that abstracts the command buffer so it can perform OpenGL-like operations in a Vulkan environment.</p> <p>As the scheduler manages the order in which it must queue GPU commands before sending them to the device, it is vital that the fencing logic used to determine this is timed correctly.</p> <p>Previously, the scheduler would only queue command chunks whose type offsets were different from zero. The problem arose because there exists a specific valid type of command whose offset is actually zero. Not taking into consideration this case hindered the fencing logic of the scheduler, preventing it from performing its work properly.</p> <p>Thankfully, the solution did not require any difficult change, and Blinkhawk was able to mitigate these freezes by <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7814" data-gh-pr="7814">submitting a simple patch</a> that addresses this specific problem.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mario.png" title=" It&#39;s-a him! (Super Mario 64 homebrew)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/mario_hu186cf830aabf9bca7817f7545aa9f7c6_1339705_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It&#39;s-a him! (Super Mario 64 homebrew)"></a> <p class="has-text-centered is-italic has-text-grey-light"> It&#39;s-a him! (Super Mario 64 homebrew)</p> </div> </div> <h2 id="kernel-changes">Kernel changes</h2> <p>The code for Memory Management — one of the functions of the kernel — was originally written back in early 2020, based on the information available at the time. Since then, there have been numerous updates to the Nintendo Switch&rsquo;s operating system, as well as new documentation obtained through reverse engineering.</p> <p>For this reason, <a href="https://github.com/bunnei">bunnei</a> has been going through each and every part of the code used to manage the memory, focusing on improving both the stability and the accuracy of the kernel.</p> <p>These changes involved brushing up the memory <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7684" data-gh-pr="7684">attribute definitions</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7698" data-gh-pr="7698">permissions</a> , so they match the behaviour of the latest <code>HorizonOS</code> more closely. Most of the code used to map and unmap memory was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7762" data-gh-pr="7762">tidied up</a> , and various functions were renamed to match the official naming. Similarly, the code used to allocate and clear the heap memory was <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7701" data-gh-pr="7701">reviewed</a> in this way.</p> <p>This new implementation should perform better, and also make the code easier to read and navigate.</p> <p>While investigating the long-standing crashes pertaining to <code>Pokémon Sword/Shield</code>, bunnei found they were related to race conditions.</p> <p>The first would happen when opening a new session to a service: that is, yuzu would create a <code>host thread</code> (a non-emulated thread), where service session requests can be dispatched to asynchronously. When this session was closed, the <code>host thread</code> for the closing session was being removed from the tracking list at the same time as a new one was added, which caused the race condition.</p> <p>Services are requested by games when they want to send certain audio to play to the speakers, request certain graphics to be loaded into memory, etc. <code>Pokémon Sword/Shield</code>, in particular, opens and closes LDN service sessions very frequently, which is why it is one of the most affected titles.</p> <p>By <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7711" data-gh-pr="7711">introducing a worker thread to manage the service list</a> , now only one thread will be able to create or destroy service sessions, preventing the crash from happening.</p> <p>Following this lead, bunnei revisited the code used to exit threads, and found that another race condition occurred, where thread references were being destroyed while they were still selectable for scheduling, resulting in a crash.</p> <p>The solution was to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7712" data-gh-pr="7712">reimplement the thread termination code more accurately</a> , so that it matches that of the HorizonOS. yuzu now waits for the thread to be unscheduled from all cores before closing it, so that it is destroyed only when it is no longer running.</p> <p>Another long-standing problem with <code>Pokémon Sword/Shield</code> was related to the code used for the High-Level Emulation (<code>HLE</code>) Service Thread Management.</p> <p>When a game requests certain services, instead of emulating the internal logic of the Nintendo Switch&rsquo;s OS (which would be Low-Level Emulation, <code>LLE</code>), yuzu runs an implementation written by the developers that performs the same job on the user&rsquo;s computer.</p> <p>These <code>HLE</code> services need to be able to interact with the emulated kernel, in order to grab locks and triggers for rescheduling, etc. yuzu achieves this by making use of <code>dummy threads</code>, which are created as an emulated <code>KThread</code> entity.</p> <p>A <code>dummy thread</code> is created for every <code>host thread</code> of a service interface running in the user&rsquo;s computer, so that whenever the kernel needs to interact with a <code>host thread</code>, it can do so through these <code>dummy threads</code>.</p> <p>Previously, these <code>dummy threads</code> were not being released when their main thread was destroyed, and hence, they would accumulate over time. Since the kernel imposes a limit on the amount of threads a process can make, yuzu was eventually unable to create more threads to open service interfaces in long gaming sessions. Furthermore, these dummy threads could inadvertently be scheduled on the emulated cores, which resulted in a crash, as they are not real threads meant to be run.</p> <p>After investigating these problems, bunnei <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7737" data-gh-pr="7737">implemented various fixes and checks</a> to correct this faulty behaviour, and prevent resource leaks and crashes.</p> <p>Next, bunnei <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7765" data-gh-pr="7765">fixed the KThread counter increment/decrement</a> operations, as the old implementation was incorrect, and could occasionally underflow. This is the aforementioned counter used to keep track of all the <code>KThread</code>s in a process, ensuring the limits imposed by the kernel are not breached.</p> <p><a href="https://github.com/ameerj">epicboy</a> also took a look at the kernel, and added a new shut-down method to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7670" data-gh-pr="7670">properly synchronise threads</a> before their destruction. This change fixes a hang that could occur when stopping emulation in yuzu.</p> <h2 id="ui-improvements">UI improvements</h2> <p>In a series of minor changes, a number of contributors decided to improve and correct some elements displayed on our interface, and the way the user can interact with them.</p> <p><a href="https://github.com/german77">german77</a> noticed that some items, such as the <code>Stop</code> and <code>Start</code> buttons, were not being disabled from interaction once the emulation process stopped, and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7662" data-gh-pr="7662">promptly fixed this erroneous behaviour</a> .</p> <p>He also went ahead and implemented the graphical elements needed to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7735" data-gh-pr="7735">report the battery levels</a> of UDP controllers. While this code has been in yuzu&rsquo;s source for some time already, preparing the appropriate front-end graphics and the subsequent implementation into the UI had been pending tasks for a long time.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./battery.png" title=" Pretty useful for Joy-Cons!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/battery_hu19ac21f35d052cb3c35318f0bb445daa_72409_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Pretty useful for Joy-Cons!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Pretty useful for Joy-Cons!</p> </div> </div> <p>While <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7768" data-gh-pr="7768">updating the AMD FidelityFX Super Resolution</a> (<code>FSR</code>) dependency to the latest version, <a href="https://github.com/Moonlacer">Moonlacer</a> changed the text string to replace the brackets around the <code>Vulkan Only</code> message with parenthesis, for consistency with all the other text in our interface.</p> <p>In a similar vein, <a href="https://github.com/gidoly">gidoly</a> corrected a series of spelling mistakes in the strings describing the name of commercial gamepads, namely the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7713" data-gh-pr="7713">PlayStation</a> and <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7715" data-gh-pr="7715">Xbox</a> controllers.</p> <p>Based on a Patreon poll conducted in our <a href="https://discord.gg/u77vRWY">discord server</a>, gidoly also made the necessary changes to make the <code>Dark Colorful</code> theme the <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7719" data-gh-pr="7719">default theme</a> used when running yuzu for the first time on Windows.</p> <p><a href="https://github.com/v1993">v1993</a> also made changes, so that now using the Colourful theme <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7755" data-gh-pr="7755">allows Qt to use the system-wide colours in *NIX systems</a> , instead of forcing dark ones.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./theme.png" title=" Default by popular demand"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/theme_hu455c78d7642c595a8ede7fbd70c1eb0f_119512_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Default by popular demand"></a> <p class="has-text-centered is-italic has-text-grey-light"> Default by popular demand</p> </div> </div> <p>Naturally, users can still change the theme through the configuration settings, if so desired.</p> <h2 id="input-changes">Input changes</h2> <p>german77 has been <em>especially</em> busy this month, so there’s quite a bit to cover in this section.</p> <p>Users reported that the game <code>パワプロクンポケットR</code>, and other games of the Power Pocket saga, crashed when in-game. This is caused by the <code>SetNpadAnalogStickUseCenterClamp</code> service being able to initialize the <code>applet_resource</code> subsystem even if it wasn’t initialized before. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7726" data-gh-pr="7726">Emulating this behaviour solves the issue and makes some game modes playable</a> . However, some game modes still show that yuzu lacks support for some vertex formats, causing crashes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./power.png" title=" パワプロクンポケットR"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/power_hu28a1a280088c1b4955c7f1e94fe7e71f_4506448_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" パワプロクンポケットR"></a> <p class="has-text-centered is-italic has-text-grey-light"> パワプロクンポケットR</p> </div> </div> <p>yuzu will now <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7663" data-gh-pr="7663">only display the currently supported controller types in the applet</a> , depending on what each game reports as compatible.</p> <p><code>Fullkey</code> is the codename used by Nintendo to refer to a generic type of controller that reports itself as a Pro Controller if you connect an “unsupported” gamepad. This can refer to the GameCube, NES, SNES, N64 and Sega Genesis controllers. In case of problems, the console falls back to reporting a Pro Controller for those types of controllers. german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7664" data-gh-pr="7664">added this functionality to yuzu as well</a> .</p> <p>Support was added to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7680" data-gh-pr="7680">allow devices with only an accelerometer present to act as motion devices</a> . While this means broader support, lacking a gyroscope means very poor results in motion, as some axis movements won’t be registered.</p> <p>With the help of v1993, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7682" data-gh-pr="7682">fixed the mapping of UDP controllers</a> (any device connected using the cemuhook protocol). Motion now correctly automaps and manual mapping won’t reset the device in the input list.</p> <p>In a separate PR, by request of v1993, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7807" data-gh-pr="7807">added support for the Home and Touch buttons on UDP connections</a> .</p> <p>Some motion devices can input very precise values, if the threshold is too high, the motion values will be ignored. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7700" data-gh-pr="7700">Reducing the threshold for gyro data</a> fixes this issue.</p> <p>While playing <code>Mario Tennis Aces</code> in swing mode, motion could suddenly stop working. This was because the update rate interval for motion data was set too high. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7707" data-gh-pr="7707">Decreasing the motion update rate to 10ms restores functionality</a> .</p> <p>Also related to motion emulation, the quality and sensitivity of the device can also affect gameplay. As a way to compensate, german77 introduced <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7770" data-gh-pr="7770">an option to configure the gyro threshold</a> , you can find it if you have a motion capable controller (in the example, dual Joy-Cons). Configured in <code>Emulation &gt; Configure… &gt; Controls &gt; right click Motion &gt; Set gyro threshold</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./gyro.png" title=" Right clicking!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/gyro_hu9e2d01b6327797438032cb079ee6990b_86538_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Right clicking!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Right clicking!</p> </div> </div> <p>Accessing 2-player mode in <code>Pokémon: Let’s Go Eevee &amp; Pikachu</code> requires performing a shake motion. The emulated shake on the keyboard was too weak to be registered by the game, so <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7710" data-gh-pr="7710">increasing its “force”</a> shakes things up to allow local multiplayer.</p> <p>One of the features missing with the release of <code>Project Kraken</code>, the input rewrite, was mouse motion support. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7725" data-gh-pr="7725">German77 reintroduced support for it</a> , now using the mouse wheel as input for the Z-axis. Also, mouse buttons get their proper names when being mapped.</p> <p>Another feature that somehow missed the memo <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7760" data-gh-pr="7760">was stick modifiers for keyboard input</a> , holding a mapped key to move an analog stick with a reduced limit. For example, with default keyboard mappings, if you hold shift, the left analog stick will move only up to 50% of its range, allowing keyboard users to walk.</p> <p>We recently introduced controller UI navigation. While comfortable, some users run external programs to translate controller input into keyboard and mouse input. For them, <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7769" data-gh-pr="7769">a toggle to disable controller navigation was added</a> in <code>Emulation &gt; Configure… &gt; Controls &gt; Advanced &gt; Controller Navigation</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./nav.png" title=" Couch gamers will love this"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/nav_hubdef533d76849c9507c07cd6617e9095_43673_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Couch gamers will love this"></a> <p class="has-text-centered is-italic has-text-grey-light"> Couch gamers will love this</p> </div> </div> <p>By default, yuzu assumes that non-Nintendo Switch controllers, for example the Xbox controllers, will use rumble motors. These are cheaper and use an exponential amplitude curve for their rumble, making this kind of method incompatible for emulating HD Rumble. The DS5 on the PlayStation 5, instead, uses more expensive linear actuators (and needs a linear amplitude curve), like the Pro Controller and Joy-Cons. <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7784" data-gh-pr="7784">With this change</a> , german77 extended support to include the official PlayStation 5 controller, the DS5, which is capable of the required precision for HD Rumble.</p> <h2 id="general-changes-and-bugfixes">General changes and bugfixes</h2> <p>TAS scripts can sometimes have errors in them, resulting in yuzu encountering a crash. german77 provides the necessary code to <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7687" data-gh-pr="7687">add error handling to TAS scripts</a> , preventing these crashes.</p> <p>Windows has a nasty, hidden limitation that is the maximum open-file limit a program can use. Some game mods can contain many, <em>many</em> files, going over the previous 4096 limit. Therefore, <a href="https://github.com/Morph1984">Morph</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7690" data-gh-pr="7690">doubled the limit to 8192</a> .</p> <p>v1993 has been working on code cleaning using <a href="https://pvs-studio.com/en/pvs-studio/">PVS-Studio</a>, and the results have been great. So far, errors were found and fixed in <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7727" data-gh-pr="7727">four</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7728" data-gh-pr="7728">separate</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7729" data-gh-pr="7729">input</a> <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7730" data-gh-pr="7730">related areas</a> , <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7731" data-gh-pr="7731">the shader recompiler</a> , and even <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7732" data-gh-pr="7732">kernel emulation</a> !</p> <p>Thanks v1993! Nothing beats cleaner code, especially if it solves out-of-bounds issues.</p> <p>Morph <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7752" data-gh-pr="7752">stubbed the <code>SetCpuOverclockEnabled</code> service</a> (you don’t need to overclock the host CPU on the fly when emulating). This allows <code>Gravity Rider Zero</code> to boot, but nothing is yet displayed on screen due to missing texture format support.</p> <p>And finally, german77 <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7821" data-gh-pr="7821">implemented the 32-bit variant of the supervisor call (SVC) <code>SynchronizePreemptionState</code></a> , making <code>Espgaluda II</code> playable.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./esp.png" title=" Espgaluda II"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/esp_hu807f01420b12b349f31a2d824c4df8e8_7082439_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Espgaluda II"></a> <p class="has-text-centered is-italic has-text-grey-light"> Espgaluda II</p> </div> </div> <p>Meanwhile, <a href="https://github.com/liushuyu">liushuyu</a> updated the dynarmic external submodule, providing <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7679" data-gh-pr="7679">optimizations and also fixing compile errors</a> caused by an update of another external, the <code>fmt</code> library — used to format text in yuzu&rsquo;s log and interface.</p> <p>german77 also added new <a class="gh-hover" href="https://github.com/yuzu-emu/yuzu/pull/7716" data-gh-pr="7716">hotkeys that allow users to manipulate the volume</a> of the application directly with the gamepad, a feature that will surely come in handy to the people who enjoy yuzu from the comfort of their couch.</p> <p>By default, <code>Home + D-Pad Right</code> will mute the application, while <code>Home + D-Pad Down</code> will lower the volume, and <code>Home + D-Pad Up</code> will increase it. Users are free to change these mappings through the configuration menu <code>Emulation &gt; Configure &gt; Hotkeys</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hotkeys.png" title=" The more the merrier!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/hotkeys_hu90a897c1e033556b5bbd5e07875412fe_28289_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The more the merrier!"></a> <p class="has-text-centered is-italic has-text-grey-light"> The more the merrier!</p> </div> </div> <p>While working on this change, german77 noticed the equation used to transform from percentage values to &ldquo;loudness&rdquo; (i.e. output power) was too aggressive below the 70% mark, making the volume extremely soft in this range. Thus, he decided to modify the formula, so that the transformation is smoother throughout the full range of percentage values.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./volume.png" title=" Old is in red and new is in green. Look at those curves!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/volume_hu5c2133228265d08d6961cc1f720f03fa_21366_571x0_resize_q90_bgffffff_box_3.jpg" alt=" Old is in red and new is in green. Look at those curves!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Old is in red and new is in green. Look at those curves!</p> </div> </div> <h2 id="future-changes">Future changes</h2> <p>Progress continues smoothly on our projects in development. For example, german77 is having fun with some heavily requested features. Blinkhawk managed to complete one of the top secret projects <a href="https://github.com/reinuseslisp">Rodrigo</a> left unfinished before <em>turning green</em>, <code>Host Conditional Rendering</code>. Expect to hear more of it in future <code>Project Y.F.C.</code> news.</p> <p>Now for a small leak of some recent internal testing: <code>Marvel Ultimate Alliance 3: The Black Order</code> jumped from 19 to 51 FPS, and your enemy&rsquo;s ink in <code>Splatoon 2</code> works correctly, both changes improving Vulkan.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/1_hu37bdc1eef8bafd8bd832c968be96a89c_1985759_1024x0_resize_q90_bgffffff_box_3.jpg" alt="More than double the performance, for only a few liters of developer tears (Marvel Ultimate Alliance 3: The Black Order)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2022/2_hu3e5381ca2978dfb89c944da3c85c9c1b_2022126_1024x0_resize_q90_bgffffff_box_3.jpg" alt="More than double the performance, for only a few liters of developer tears (Marvel Ultimate Alliance 3: The Black Order)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">More than double the performance, for only a few liters of developer tears (Marvel Ultimate Alliance 3: The Black Order)</p> <p>That’s all folks! It’s always a pleasure to have you here, hope we see you again next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy.min.css" integrity="sha512-HbPh+j4V7pXprvQMt2dtmK/zCEsUeZWYXRln4sOwmoyHPQAPqy/k9lIquKUyKNpNbDGAY06UdiDHcEkBc72yCQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/2.11.2/umd/popper.min.js" integrity="sha512-aDciVjp+txtxTJWsp8aRwttA0vR2sJMk/73ZT7ExuEHv7I5E6iyyobpFOlEFkq59mWW8ToYGuVZFnwhwIUisKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/tippy.js/6.3.7/tippy-bundle.umd.min.js" integrity="sha512-gbruucq/Opx9jlHfqqZeAg2LNK3Y4BbpXHKDhRC88/tARL/izPOE4Zt2w6X9Sn1UeWaGbL38zW7nkL2jdn5JIw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.29.1/moment.min.js" integrity="sha512-qTXRIMyZIFb8iQcfjXWCO8+M5Tbc38Qi5WzdPOYZHIlZpzBHG3L3by84BBBOiRGiEb7KKtAOAs5qYdUiZiQNNQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <div id="gh-template" style="display: none;"> <span> <svg class="gh-hover-icon" viewBox="0 0 16 16" version="1.1" width="16" height="16" aria-hidden="true"><path fill-rule="evenodd" d="M7.177 3.073L9.573.677A.25.25 0 0110 .854v4.792a.25.25 0 01-.427.177L7.177 3.427a.25.25 0 010-.354zM3.75 2.5a.75.75 0 100 1.5.75.75 0 000-1.5zm-2.25.75a2.25 2.25 0 113 2.122v5.256a2.251 2.251 0 11-1.5 0V5.372A2.25 2.25 0 011.5 3.25zM11 2.5h-1V4h1a1 1 0 011 1v5.628a2.251 2.251 0 101.5 0V5A2.5 2.5 0 0011 2.5zm1 10.25a.75.75 0 111.5 0 .75.75 0 01-1.5 0zM3.75 12a.75.75 0 100 1.5.75.75 0 000-1.5z"></path></svg> </span> <span> <a class="gh-hover-title" href=""><strong></strong></a>&nbsp;<span class="gh-hover-number"></span> </span> <p class="gh-hover-date"></p> </div> <style> .gh-hover-icon.open { filter: invert(56%) sepia(47%) saturate(665%) hue-rotate(77deg) brightness(99%) contrast(83%); } .gh-hover-icon.closed { filter: invert(50%) sepia(95%) saturate(3977%) hue-rotate(336deg) brightness(95%) contrast(90%); } .gh-hover-icon.merged { filter: invert(47%) sepia(17%) saturate(4072%) hue-rotate(228deg) brightness(95%) contrast(89%); } .gh-hover { border-bottom: dotted; } </style> <script> tippy('.gh-hover', { content: 'Loading...', onShow(instance) { showHovercard(instance, 'yuzu'); }, allowHTML: true, followCursor: 'horizontal', interactive: true, }); </script> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> </p> Progress Report December 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/ Tue, 11 Jan 2022 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/ <p>Yuz-ers! Welcome to the last progress report of 2021, released in 2022 because we still haven’t figured out how to travel back in time. December brought us improved kernel emulation, fixes for driver issues, improvements to input, rendering, overall stability, and more!</p> <p>Yuz-ers! Welcome to the last progress report of 2021, released in 2022 because we still haven’t figured out how to travel back in time. December brought us improved kernel emulation, fixes for driver issues, improvements to input, rendering, overall stability, and more!</p> <p>We keep trying with the time machine, but we’re running out of bananas to microwave and trash to fuel the Mr. Fusion. Okay, let&rsquo;s get started!</p> <h2 id="psa-for-nvidia-users-part-2">PSA for NVIDIA users: Part 2</h2> <p>As mentioned <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/#psa-for-nvidia-users">two months ago</a>, NVIDIA users have been experiencing issues when using GLSL due to the changes introduced by NVIDIA dropping support for Kepler cards in the 49X series of drivers.</p> <p>We’re happy to announce that we have a <a href="https://github.com/yuzu-emu/yuzu/pull/7629">set of workarounds</a> implemented by <a href="https://github.com/ameerj">epicboy</a> that solve all known issues. These are already available for both Mainline and <a href="https://yuzu-mirror.github.io/help/early-access/">Early Access</a>.</p> <p>The root of the problem in NVIDIA’s drivers seems to be in negation of integer and floating point values, and bitwise conversions of input values.</p> <p>On previous drivers, you could assign a value to a variable named <code>x</code>, then assign <code>-x</code> as the value to a new variable named <code>y</code>. <code>y</code> would be equal to <code>-1 * x</code>. New drivers ignore this negation entirely, resulting in random spontaneous fires, security breaches, too many dogs causing a <a href="https://www.youtube.com/watch?v=Jw0c9z8EllE">Howl</a>, and total chaos.</p> <p>The workaround is to simply subtract the value from 0. In our example, <code>y</code> would get the value of <code>0 - x</code>.</p> <p>The bitwise conversion issue is more complex, but we talked about it in the past. Back in August, <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/#another-terrible-implementation-and-other-graphical-fixes">we mentioned how Intel had issues in Vulkan</a> affecting Mario’s legendary moustache.</p> <p><code>GetAttribute</code> returns a float value, so a conversion is needed when working with integer values.</p> <p>The same issue that affected Intel GPUs now happens here on the “greener” side, but inverted. When using <code>instance_id</code>, old drivers accepted a float to unsigned integer conversion without issue, and you could do this conversion multiple times without losing the correct value. The current drivers, on the other hand, can sometimes return zero.</p> <p>Interpreting the value directly as unsigned integers now solves this issue in both GLSL and <a href="https://github.com/yuzu-emu/yuzu/pull/7630">GLASM</a>. Since this counts as an optimization, we now apply it to all APIs.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/nvidiabug_hud66e200cd80562f5de0acee35839dc17_3609464_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Back to the early days (Fire Emblem: Three Houses)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/nvidiafix_hu0cc7b0cd1a9da1378bcda1d19ba9ff8f_6923169_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Back to the early days (Fire Emblem: Three Houses)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Back to the early days (Fire Emblem: Three Houses)</p> <p>Please report if you find any issues, as there could be more broken games due to yet unknown driver bugs. On a similar note, more fixes should be coming to Vulkan too, if needed. One such issue solved itself, most likely NVIDIA fixed it on the latest drivers.</p> <h2 id="other-graphical-fixes">Other graphical fixes</h2> <p>Whenever a game played multiple videos at the same time, some of them would glitch and flicker. This happened because yuzu was limited to decoding a single video stream at a time. Having multiple videos running at the same time would cause the decoder to receive frames that were sent from different video sources, confusing the interpolation algorithm and causing the aforementioned problems. To prevent this issue from happening, <a href="https://github.com/vonchenplus">vonchenplus</a> implemented a temporary solution that gives each video stream their own video decoder, sending the correct frame data only to the correct decoder.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./mdbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./mdfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It still flickers, but that&#39;s the Chozo&#39;s fault (Metroid Dread)</p> <p><a href="https://github.com/Morph1984">Morph</a> added the missing formats <a href="https://github.com/yuzu-emu/yuzu/pull/7544">R16G16_UINT</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/7549">ASTC_2D_8X5_UNORM</a> to the Vulkan API, fixing the missing graphics on <code>Immortals Fenyx Rising</code> and making <code>LEGO® CITY UNDERCOVER</code> playable, respectively. (Please note that <code>Immortals Fenyx Rising</code> gets in game but has broken graphics at the moment).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lcu.png" title=" I brick you not (LEGO® CITY UNDERCOVER)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/lcu_hu1baa69bdf53d70595418c558d802ecbe_8667839_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" I brick you not (LEGO® CITY UNDERCOVER)"></a> <p class="has-text-centered is-italic has-text-grey-light"> I brick you not (LEGO® CITY UNDERCOVER)</p> </div> </div> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7495">fixed a bug in the texture cache</a> that was conveniently ignored by the AMD driver, but would cause Nvidia GPUs to crash when using the Vulkan API. This crash happened when blitting textures with different format types, something that points to a problem in the texture cache that will be addressed in a future PR.</p> <p>Blinkhawk also updated the Vulkan headers to <a href="https://github.com/yuzu-emu/yuzu/pull/7599">fix an extension and implemented logical operations</a>. Both the extension and these logical operations are used by Vulkan to describe and process data, in order to compose the frames that will later be sent to the screen. This PR fixes the sand and shadow graphical problems in <code>The Legend of Zelda: Skyward Sword</code>, and also the shadow problems as seen in <code>Xenoblade Chronicles 2</code>.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/xc2bug_hudee1ed8ad58b86647f3ada00ad06edad_9649199_1024x0_resize_q90_bgffffff_box_3.jpg" alt="When you invert the polarity of your HDR display (Xenoblade Chronicles 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/xc2fix_hudb5fa66ab71679ad674314889d246aed_8261190_1024x0_resize_q90_bgffffff_box_3.jpg" alt="When you invert the polarity of your HDR display (Xenoblade Chronicles 2)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">When you invert the polarity of your HDR display (Xenoblade Chronicles 2)</p> <p>epicboy took a look at the issues that affected games that made heavy use of sparse GPU memory, and <a href="https://github.com/yuzu-emu/yuzu/pull/7658">made the changes necessary</a> to mitigate the problem.</p> <p>Sparse memory is a technique to store data non-contiguously, which is a fancy way to say that data is broken down into small blocks and only the relevant bits are loaded into memory. There was a bug in the code used to map this data into the memory, as the offsets needed to get the right address weren&rsquo;t being included in the calculations. For the sake of precaution, he also added an extra guard that prevents modifying the memory address 0, as it is used as a placeholder to signal addresses that haven&rsquo;t been loaded in yet.</p> <p>These changes are meant to address (no pun intended) issues related to the GPU memory management, and hopefully alleviate some stability complications related to it. Notably, the crashes on titles developed with the <code>UE4</code> engine <em>(cough, True Goddess Reincarnation V or some such, cough)</em>. The devs are still investigating any other oddities surrounding this game, so stay tuned for more updates.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ue4.png" title=" These changes mitigate memory-related problems but are not guaranteed to “fix” them completely (SHIN MEGAMI TENSEI V)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/ue4_hu276b5f16c7985a6ad6600f19e944a306_5452660_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" These changes mitigate memory-related problems but are not guaranteed to “fix” them completely (SHIN MEGAMI TENSEI V)"></a> <p class="has-text-centered is-italic has-text-grey-light"> These changes mitigate memory-related problems but are not guaranteed to “fix” them completely (SHIN MEGAMI TENSEI V)</p> </div> </div> <p>Users reported crashes when playing <code>Sonic Colors Ultimate</code> on AMD and Intel GPUs on Vulkan after the resolution scaler was introduced. epicboy quickly jumped in to intervene and save the Blue Hedgehog.</p> <p>On the AMD side, Sonic suffers from ImageView issues, causing an invalid pointer dereference when the <code>slot_images</code> container of the texture cache is resized. This can happen even at native resolution. epicboy found that <a href="https://github.com/yuzu-emu/yuzu/pull/7622">keeping a reference of the container</a> resolves the issue.</p> <p>Intel’s turn now. The Intel Vulkan Windows driver strongly follows the specification when dealing with image blits. Khronos defines that <a href="https://en.wikipedia.org/wiki/Multisample_anti-aliasing">MSAA</a> blits are not allowed, and while most drivers let this pass, Intel is being a good boy and crashes when trying to rescale MSAA textures. Leaving aside that using traditional antialiasing on a mobile device like the Switch is a <em>crime against humanity</em> (you don’t waste extremely limited bandwidth on traditional antialiasing), the issue is solved by <a href="https://github.com/yuzu-emu/yuzu/pull/7624">rendering directly into the scaled image</a> when rescaling by using the 3D pipeline. The performance cost is higher (integrated GPUs like most Intel ones also hate traditional antialiasing), but it’s a price to pay to avoid crashing or losing the scaling.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sc.png" title=" Colourful (Sonic Colors: Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/sc_hu7e9294a128774e6216ec410e19c556d1_1784953_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Colourful (Sonic Colors: Ultimate)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Colourful (Sonic Colors: Ultimate)</p> </div> </div> <p>The texture cache has to handle several weird situations when dealing with rendering. One aspect of the process is <code>overlaps</code>, when different textures compete for the same video memory space. A bug in the texture cache&rsquo;s logic was found when an overlap occurs over relatively big distances in GPU memory. An overflow could happen leading to a wrongly massive texture trying to be rendered, causing VRAM to fill up instantly, and leading yuzu to a crash. This issue was common in <code>BRAVELY DEFAULT II</code>. Thanks to epicboy, <a href="https://github.com/yuzu-emu/yuzu/pull/7659">users no longer have to suffer this sudden crash</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bd1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/bd1_hue0fa06c15da68cca0afe4208efb32d9c_8630954_800x0_resize_q90_bgffffff_box_3.jpg" alt="BRAVELY DEFAULT II"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bd2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/bd2_hu837d7b01d4578b78fafc6cc2aea32001_5566436_800x0_resize_q90_bgffffff_box_3.jpg" alt="BRAVELY DEFAULT II"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">BRAVELY DEFAULT II</p> <h2 id="skyline-framework-part-2">Skyline framework: Part 2</h2> <p><a href="https://github.com/itsmeft24">itsmeft24</a> submitted a patch to <a href="https://github.com/yuzu-emu/yuzu/pull/7519">implement the <code>ProcessMemory</code> and <code>CodeMemory</code> kernel SVCs</a> (Supervisor Calls), which are some of the changes needed to support the <a href="https://github.com/skyline-dev/skyline">Skyline</a> framework for modding.</p> <p>Part of the ongoing work includes adding support in yuzu for all tiers of <code>subsdk</code>. Games can use <code>subsdk</code> tiers from 0 to 8, with 9 being free. Skyline uses <code>subsdk9</code> to operate, so <a href="https://github.com/jam1garner">jam1garner</a> included support for the remaining <a href="https://github.com/yuzu-emu/yuzu/pull/7523">two missing tiers in yuzu, 8 and 9</a>.</p> <p>There are still a couple of things that need to be implemented before it&rsquo;s ready, but things are certainly getting closer to being completed.</p> <p>You can check the current progress <a href="https://github.com/yuzu-emu/yuzu/issues/7392">here</a>.</p> <h2 id="input-changes">Input changes</h2> <p><a href="https://github.com/german77">german77</a> has several fixes for us and some important new additions.</p> <p>Let’s kick things off with a great new feature for handheld PC users, couch players, and anyone not wanting to reach all the way to their keyboard while playing: <a href="https://github.com/yuzu-emu/yuzu/pull/7633">support for gamepad hotkeys</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hotkeys.png" title=" You can customize them"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/hotkeys_huf8e076afbba21822963e0b618b915cbb_28313_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" You can customize them"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can customize them</p> </div> </div> <p>With this, users can customize button macros. For example: access or exit fullscreen, unlock the framerate, pause/continue emulation, capture a screenshot (by default conveniently mapped to the capture button of the Nintendo controllers), close yuzu, and more! <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./gamepad1.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./gamepad2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Sorry about the bad quality</p> </p> <p>When certain games start, some internal testing is done to ensure that things are where they should be and respond with an acceptable delay. One of those tests involves rumble. Games prod the controllers with a low frequency rumble test, but sometimes, some games never stop and the controller continues to vibrate, depleting battery and making you doubt what the original intention of the developer was. german77 <a href="https://github.com/yuzu-emu/yuzu/pull/7593">forces the rumble amplitude to zero after the test</a>, stopping unwanted vibrations for these affected games.</p> <p>VR games may use the gyroscope sensor on the Switch itself (not the controllers) to feed motion data. Previously, yuzu would only give partial data to the game, causing erratic movement of the game’s camera. german77 added <a href="https://github.com/yuzu-emu/yuzu/pull/7481">all missing data, including the gyro sensor</a>, to solve this issue.</p> <p>german77 also added support for the <code>SetNpadJoyAssignmentMode</code> series of services, removing some spam from the logs. This change <a href="https://github.com/yuzu-emu/yuzu/pull/7521">also adds support for</a> dual Joy-Con pairs with a single Joy-Con connected, which is something that some games seem to do.</p> <p>After the release of <code>Project Kraken</code>, <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021#projekt-kraken">the input rewrite</a>, analog triggers were accidentally broken. A simple bug slipped by, causing them to only work when the joysticks were moved. <a href="https://github.com/yuzu-emu/yuzu/pull/7583">Two lines of code were changed</a>, and the issue was made no more.</p> <p>german77 has also been working on making <code>Ring Fit Adventure</code> playable. While working on implementing support for the pressure ring accessory that the game requires, german77 also ended up making some global improvements.</p> <p>One change that ended up benefiting all games is <a href="https://github.com/yuzu-emu/yuzu/pull/7503">controller type validation</a>, which ensures that the emulator can only accept controller types that the game supports, while discarding and disconnecting anything else.</p> <p>A bug in the controller type validation code caused <code>Captain Toad: Treasure Tracker</code> to constantly spam the controller applet when trying to launch two-player mode. Well, <a href="https://github.com/yuzu-emu/yuzu/pull/7647">not any more</a>! Again thanks to german77.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./toad.png" title=" Co-op treasure hunting, what else could you ask for? (Captain Toad: Treasure Tracker)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/toad_hu25f04a881e9cd6e0454a26e407be63ee_1042881_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Co-op treasure hunting, what else could you ask for? (Captain Toad: Treasure Tracker)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Co-op treasure hunting, what else could you ask for? (Captain Toad: Treasure Tracker)</p> </div> </div> <h2 id="flatpak-fixes">Flatpak fixes</h2> <p>Following up from our previous mention <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/#graphical-fixes">last month</a>, <a href="https://github.com/liushuyu">liushuyu</a> continues to fight against the weirdness of <a href="https://flatpak.org/">Flatpak</a>.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/7565">NVDEC requirements are now more flexible</a>, the CUDA libraries are no longer mandatory, without actually affecting CUDA decoding support. Also, <a href="https://ffmpeg.org/">FFmpeg</a> requirements have been raised to version 4.3 and higher. This should enable native Vulkan video support later on when there is driver support for it.</p> <p>With this, decoding crashes are solved when running Flatpak builds of yuzu.</p> <p>liushuyu also solved an issue affecting the prevent sleep functionality on Flatpak. <a href="https://github.com/yuzu-emu/yuzu/pull/7614">Implementing XDP’s Inhibit API solves the issue</a>, preventing the display from turning off at the worst moment while playing.</p> <p>Additionally, Flatpak builds are compiled with asserts enabled, meaning that the emulator will be stopped when an assertion fails or an out-of-bound access inside a vector is encountered. <a href="https://appimage.org/">Appimage</a> and regular Mainline/Early Access builds are shipped with asserts disabled.</p> <p>While this usually isn’t an issue, Flatpak users reported crashes in <code>Pokémon Sword &amp; Shield</code> when trying to set their uniform number. As it turns out, the on-screen keyboard (OSK) was performing an out-of-bounds access when calling the number pad. Morph <a href="https://github.com/yuzu-emu/yuzu/pull/7579">pointed the OSK to the proper array</a> and the crashing stopped.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./numpad.png" title=" Thank you RodrigoTR for the pic! (Pokémon Sword)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/numpad_hu5a05f092c5ebe87f0493993927016761_728620_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Thank you RodrigoTR for the pic! (Pokémon Sword)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Thank you RodrigoTR for the pic! (Pokémon Sword)</p> </div> </div> <h2 id="general-changes-and-bugfixes">General changes and bugfixes</h2> <p><a href="https://github.com/bunnei">bunnei</a> continues to work on the kernel rewrite, toiling away to increase the accuracy of our implementation.</p> <p>This time, by simplifying a number of functions and polishing the tracking of resources, he introduced more changes to <a href="https://github.com/yuzu-emu/yuzu/pull/7462">improve the threading and scheduling kernel routines</a>. These changes increase yuzu&rsquo;s parity with recent updates to the Nintendo Switch OS, and also fix a number of race conditions and crashes, such as the ones experienced in <code>Pokémon Sword &amp; Shield</code> and <code>Dead or Alive Xtreme 3 Scarlet</code>.</p> <p>bunnei also implemented <a href="https://github.com/yuzu-emu/yuzu/pull/7621">SetMemoryPermission</a>, and updated the implementation of <a href="https://github.com/yuzu-emu/yuzu/pull/7635">SetHeapSize</a>, which are SVCs used by the kernel to manage the memory resources.</p> <p>Previously, <code>SetHeapSize</code> only supported setting the heap size and expanding it, which was good enough for most games. But since some titles (such as <code>Donkey Kong Tropical Freeze</code>) may shrink this size, the implementation was updated to allow games to change the heap as needed, making it more accurate.</p> <p>Both these changes were validated with hardware tests, ensuring that they behave as expected.</p> <p>While working on these changes, bunnei <a href="https://github.com/yuzu-emu/yuzu/pull/7616">found a bug in the service used to retrieve information of the currently executing process</a>. Correcting this behaviour allowed <code>The Witcher 3: Wild Hunt</code> to boot, although there are still plenty of graphical issues to fix on this title.</p> <p>Blinkhawk also made a number of <a href="https://github.com/yuzu-emu/yuzu/pull/7497">changes to the building process</a> to enforce more link time optimizations, and improve the time needed to generate the <code>PDB</code> (<a href="https://llvm.org/docs/PDB/index.html">Program Database</a>) file, which contains debug information. If this mumbo-jumbo sounds confusing, the gist of it is that the process of building yuzu should produce more efficient code and smaller binaries now. But feel free to skip the following few paragraphs if you&rsquo;re not interested in the specifics.</p> <p>Roughly speaking, compiler optimizations work on a &ldquo;local&rdquo; level per object. This optimization step will <a href="https://en.wikipedia.org/wiki/Inline_expansion">inline</a> some functions, merge loops, put calling and called functions close in memory for better caching, etc. But if a function defined in another file is called within the file, the compiler can&rsquo;t perform these optimizations, as it doesn&rsquo;t know what this external function does, or how to optimize it.</p> <p>Link time optimizations, on the other hand, take into consideration all the functions in the project. The linker, thus, is able to perform the same optimizations as the compiler, but more efficiently, as it is aware of the contents of all the functions defined in the project. This comes at a price, since the process needs more memory and takes more time to finish, but it guarantees that the released binaries perform better.</p> <p>Along with this work, we considered enforcing <a href="https://en.wikipedia.org/wiki/SSE4#SSE4.2">SSE4.2</a> support, improving performance but making yuzu incompatible with 12 year old CPUs like the Core 2 Duo and Phenom II or older. While the performance results were positive, we are still debating whether we should reduce CPU compatibility or not.</p> <p>When you open yuzu, the emulator has to take some time to measure the <a href="https://en.wikipedia.org/wiki/Time_Stamp_Counter">RDTSC frequency</a>, a way to measure the clock speed of the CPU. Due to a bit of bloat in the previous implementation, 3 full seconds were needed to complete the operation. Morph <a href="https://github.com/yuzu-emu/yuzu/pull/7494">rewrote the whole function</a> and now only 0.2 seconds (200 milliseconds) are needed to get results as accurate as before, considerably reducing the boot times of the emulator itself.</p> <p>As previously stated, german77 continues to work towards making <code>Ring Fit Adventure</code> playable. He has <a href="https://github.com/yuzu-emu/yuzu/pull/7524">stubbed the</a> <code>SetNpadCaptureButtonAssignment</code>, <code>ClearNpadCaptureButtonAssignment</code>, <code>ListAlarmSettings</code>, and <code>Initialize</code> services, and <a href="https://github.com/yuzu-emu/yuzu/pull/7525">added support</a> for the <code>notif:a</code> service.</p> <p>With all his changes, the current Early Access build (at the time of writing this article) can boot and play the first stage of the game!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./ringfit.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Ring Fit Adventure</p> </div> </div> <p><a href="https://github.com/Tatsh">Tatsh</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7609">added NSP and XCI file association to Linux</a>. Thanks!</p> <p><a href="https://github.com/Tachi107">Tachi107</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7527">updated cubeb</a> and removed now deprecated functions. Cleaner is always better, thanks!</p> <p><a href="https://github.com/heinermann">heinermann</a> fixed a crash that would occur when the <a href="https://github.com/yuzu-emu/yuzu/pull/7506">emulation was paused and the window was out of focus</a>. Thank you!</p> <p><a href="https://github.com/jbeich">jbeich</a> changed the building configuration so that <a href="https://github.com/yuzu-emu/yuzu/pull/7602">VA-API, one of the video decoding APIs of Linux, is enabled on Unix systems</a>, allowing the users who want to build targeting BSD or other Unix-based systems to use hardware acceleration for video decoding.</p> <p>This is just one of several PRs jbeich wrote to help yuzu work on BSD systems, thank you for your contributions!</p> <h2 id="ui-changes">UI changes</h2> <p>The favourites row in yuzu’s game list was always expanded, even if the user collapsed it. epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/7570">added a persistent setting</a> to remember the user preference between launches.</p> <p>One of the most common issues users face is lack of Vulkan support on their PC. Not lack of hardware support, but instead missing software support caused by outdated GPU drivers or poorly coded/outdated Vulkan injections.</p> <p>Our old error popup didn’t reflect this so <a href="https://github.com/goldenx86">your writer</a>, with his total lack of coding skills, <a href="https://github.com/yuzu-emu/yuzu/pull/7532">decided to improve it</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./vidbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/vidbug_huad2dc04c5688fee435710544c1893140_9377_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> <div class="column is-bottom-paddingless"> <a href="./vidfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/vidfix_huf4508ffade787b447737cacb712cd479_9392_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> </p> <p>This is a complex issue and the main reason Vulkan is not yuzu&rsquo;s default API. Users of old laptops with AMD and Intel integrated GPUs tend to use the driver shipped by either the laptop vendor or Windows Update. In both cases, those drivers are most likely years old (yuzu can run on AMD GPUs from 2012) and either lack Vulkan support at all, or only support a portion of what’s needed to run yuzu. Also, since laptops, by default, connect the display directly to the integrated GPU, that’s the first Vulkan driver that will be seen, so it’s critical to have the latest GPU driver installed <em>even if</em> your laptop has a dedicated NVIDIA GPU running the latest driver.</p> <p>While telling AMD users to <a href="https://www.amd.com/en/support">manually download and install updated drivers</a> is a viable option and works as it should, in its <em>infinite wisdom</em>, Intel decided to block manual installation of its own official drivers if a custom laptop vendor driver is in use (those modified drivers are usually created to cheat on battery life metrics and/or to save money on cooling).</p> <p>The only alternative in those cases is to <a href="https://www.intel.com/content/www/us/en/download/19344/intel-graphics-windows-dch-drivers.html">manually download the ZIP version</a> of the driver &gt; unpack it &gt; Launch the Device Manager &gt; right-click the correct GPU in Display Adapters &gt; select <code>Update Driver Software…</code> &gt; select <code>Browse my computer for driver software</code> &gt; select <code>Let me pick from a list of device drivers on my computer</code> &gt; select <code>Have Disk…</code> &gt; then finally browse to the folder where the driver was unpacked and select the <code>iigd_dch.inf</code> file. What a very intuitive and user-friendly way to update a GPU driver&hellip; great job Intel.</p> <p>Here&rsquo;s a <a href="https://www.youtube.com/watch?v=BZG50Nm5sOM&amp;t=72s">video tutorial</a> for those that prefer visual aid over our rambling. Just make sure to use the <code>iigd_dch.inf</code> file instead of the one shown in the slightly outdated video. Other mentioned optimizations on the video no longer apply.</p> <p>With this <em>easy job</em> done, the Intel GPU gets full Vulkan support, runs at its intended performance, and has access to all the new features, fixes, and performance improvements that the driver developers worked on. The driver is also allowed to auto-update on new official releases.</p> <p>Known software that uses broken Vulkan injectors are outdated screen recorders like Bandicam, Action!, and even OBS. We strongly recommend using an up-to-date OBS, the native encoders from the GPU vendor (Radeon ReLive and Geforce Experience), or the integrated Xbox Game Bar on Windows. Overwolf and GShade are also known to break Vulkan support, so we <strong>strongly</strong> recommend avoiding them.</p> <h2 id="future-projects">Future projects</h2> <p><code>Project Gaia</code> is progressing smoothly. Heads up, SSD users will notice improvements once it is released.</p> <p>Blinkhawk informs us that <code>Project Y.F.C.</code> will be released in smaller chunks in order to push more progressive updates instead of delaying for a big release that would require more testing time. We want to get these updates in your hands as soon as possible! We continue to plan to add several GPU features that have been pending. Here&rsquo;s a screenshot as an example:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./golf.png" title=" Mario Golf: Super Rush"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2021/golf_hu3cfa4b7bc14fa63dd01c119ef743cfa4_2468529_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Mario Golf: Super Rush"></a> <p class="has-text-centered is-italic has-text-grey-light"> Mario Golf: Super Rush</p> </div> </div> <p>That’s all folks! Thank you for your attention, and we hope to see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> </p> Progress Report November 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/ Fri, 10 Dec 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/ <p>Hello yuz-ers! Welcome to November’s progress report. This month, we present to you a full input rewrite, UI navigation with controllers, kernel changes resulting in improved stability, and more.</p> <p>Hello yuz-ers! Welcome to November’s progress report. This month, we present to you a full input rewrite, UI navigation with controllers, kernel changes resulting in improved stability, and more.</p> <h2 id="project-kraken">Project Kraken</h2> <p>Oh boy, what a treat <a href="https://github.com/german77">german77</a> has for us. As we mentioned in the previous progress report, <code>Project Kraken</code>, our latest input rewrite, is now available to all users.</p> <p>But what does it mean? Well, Kraken has multiple goals — first of all is accuracy. Behaving closer to how the Nintendo Switch operates is our goal. Secondly, simplifying and removing old redundant code makes maintenance and scalability a lot easier. And most importantly, making all input event-based instead of polling-based. This means that instead of asking the controller what it did at regular intervals, the controller itself will report its actions the moment the user inputs an action. This applies to buttons, triggers, sticks, motion — the whole deal. The end result is reduced input lag.</p> <p>But those aren&rsquo;t the only improvements, Kraken also includes many bug fixes and new additions. Users can now invert or turn any button into a toggle (press again to release) in any emulated controller. Previously this was only possible on a limited variety of controllers.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./toggle.png" title=" Did someone say they wanted to beat Dark Souls with a driving wheel?"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/toggle_huc90921255a540ddc320a7f3adf4ad51a_5653_286x0_resize_q90_bgffffff_box_3.jpg" alt=" Did someone say they wanted to beat Dark Souls with a driving wheel?"></a> <p class="has-text-centered is-italic has-text-grey-light"> Did someone say they wanted to beat Dark Souls with a driving wheel?</p> </div> </div> <p>Buttons are named instead of numbered on non-SDL input controllers, assisting with identification.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./button.png" title=" SDL input, like native Nintendo controllers or Xbox controllers, will have numbered buttons rather than named"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/button_hu9e24fc9a4b352c5f305fc5685ee3b258_4098_186x0_resize_q90_bgffffff_box_3.jpg" alt=" SDL input, like native Nintendo controllers or Xbox controllers, will have numbered buttons rather than named"></a> <p class="has-text-centered is-italic has-text-grey-light"> SDL input, like native Nintendo controllers or Xbox controllers, will have numbered buttons rather than named</p> </div> </div> <p>While we recommend using controllers without third party drivers, full <a href="https://cemuhook.sshnuke.net/">UDP Cemuhook support</a> is available at <code>Emulation &gt; Configure… &gt; Controls &gt; Advanced &gt; Enabled UDP controllers</code>.</p> <p>Previously, Cemuhook was only used for UDP motion, but now even Android apps can connect to yuzu. Cemuhook provides a guide on how to set up UDP devices <a href="https://cemuhook.sshnuke.net/padudpserver.html">here</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./udp.png" title=" There must be someone trying to play with a phone as a Joy-Con somewhere"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/udp_hu1c22d217213be72d2bd3f2ac69e61c0f_62790_900x0_resize_q90_bgffffff_box_3.jpg" alt=" There must be someone trying to play with a phone as a Joy-Con somewhere"></a> <p class="has-text-centered is-italic has-text-grey-light"> There must be someone trying to play with a phone as a Joy-Con somewhere</p> </div> </div> <p>Keyboard and mouse emulation is improved, allowing games that natively support USB mouse and keyboard inputs to function correctly.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./km.png" title=" Useful in games like Animal Crossing: New Horizons that accept an actual keyboard on the Switch"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/km_hu547cca3f5a07780db74a7e825dd8c0d0_6396_458x0_resize_q90_bgffffff_box_3.jpg" alt=" Useful in games like Animal Crossing: New Horizons that accept an actual keyboard on the Switch"></a> <p class="has-text-centered is-italic has-text-grey-light"> Useful in games like Animal Crossing: New Horizons that accept an actual keyboard on the Switch</p> </div> </div> <p>Additionally, there are hundreds of bugfixes in the backend. To list a few:</p> <ul> <li>Dual Joy-Cons will now correctly reconnect instead of reverting to “any” input after a yuzu reboot.</li> <li>Analog triggers are properly mapped (this includes Gamecube controllers).</li> <li>Configuration parameters are shared on all emulated controller types.</li> <li>Battery level is now informed when available.</li> <li>Pressing a button will automatically reconnect the first player.</li> <li>Rumble on the right side is fixed.</li> </ul> <p>For those interested, the <a href="https://github.com/yuzu-emu/yuzu/pull/7255">pull request</a> description includes all the technical information on how Kraken now operates, including the internal changes to every subsystem.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/7472">Subsequent</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7476">pull requests</a> by <a href="https://github.com/Morph1984">Morph</a> and german77 provided further fixes and cleanups. For example, in the past yuzu would determine automatically if the controller applet needed to pop-up, removing an annoyance in single player games. Kraken shipped with a bug causing the controllers to remain in configure mode, awaiting an applet that never came up. german77 <a href="https://github.com/yuzu-emu/yuzu/pull/7465">corrected this behavior</a> to enable the controllers in such cases.</p> <h2 id="other-input-changes">Other input changes</h2> <p>A highly requested feature is <a href="https://github.com/yuzu-emu/yuzu/pull/7452">controller navigation over UI elements</a>, and that’s exactly what german77 delivered. Currently there is support for the game list and profile selector (if the user created several profiles). The feature is in its baby steps, so expect some rough edges. For example, when in the controller applet or when trying to hold the stick. We are currently working on refining it.</p> <p>Here’s an example on the GPD Win 3:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./ui.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Steam Deck hype train, here we go!</p> </div> </div> <p>When asking for the character’s name in <code>Famicom Detective Club: The Missing Heir</code>, the game generated an error in Chinese and then crashed. The issue is rooted in a bad behaviour in how text is handled with the On-Screen Keyboard (OSK). There’s no need to ask for user confirmation on text that has been already confirmed. The resulting error message was corrupted due to using the wrong character encoding. Morph <a href="https://github.com/yuzu-emu/yuzu/pull/7303">addressed both issues</a>, and the game can be played now.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./detective.png" title=" Elementary, my dear yuzu (Famicom Detective Club: The Missing Heir)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/detective_hu1550ae48722f81a68f9659066103ad28_3985119_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Elementary, my dear yuzu (Famicom Detective Club: The Missing Heir)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Elementary, my dear yuzu (Famicom Detective Club: The Missing Heir)</p> </div> </div> <p>german77 got tired of having to constantly modify the code when testing different types of unsupported controllers, so he added a <a href="https://github.com/yuzu-emu/yuzu/pull/7451">toggle to allow</a> them. We don’t recommend enabling this setting for normal gameplay, but if anyone wants to try it out, the option is in <code>Emulation &gt; Configure… &gt; General &gt; Debug &gt; Enable all Controller Types</code>.</p> <h2 id="graphical-fixes">Graphical fixes</h2> <p>One of the missing video formats was <code>VP8</code>. We didn’t implement it until now because there were very few known games that used it. There are at least 3 known games using <code>VP8</code> at the moment: <code>TY the Tasmanian Tiger HD</code>, <code>Diablo II: Resurrected</code>, and <code>Pokémon Brilliant Diamond/Shining Pearl</code>. Thus, <a href="https://github.com/yuzu-emu/yuzu/pull/7326">epicboy</a> attacked his keyboard and implemented <a href="https://github.com/yuzu-emu/yuzu/pull/7326">VP8 support</a> into yuzu. However, there are known issues with Pokémon <code>VP8</code> decoding that we’re working to address.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./vp8.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Cue the fanfare (Pokémon Shining Pearl)</p> </div> </div> <p>Textures can be divided on colour or depth formats, but everything changed when the <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">TCR</a> attacked.</p> <p>In OpenGL, a conversion method was missing for copying “incompatible” texture formats, like colour &lt;-&gt; depth format copies. epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/7349">worked around this limitation</a> by using the same method implemented in BGR &lt;-&gt; RGB conversions that we&rsquo;ve mentioned in the past.</p> <p>Countless glitches were fixed, two notable examples being the shadows in <code>Luigi’s Mansion 3</code> and the cutscenes in <code>Bayonetta 2</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./bayobug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./bayofix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">You can now focus on... gameplay (Bayonetta 2)</p> <p> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./lm3bug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./lm3fix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more ghost shadows (Luigi&#39;s Mansion 3)</p> <p>With the release of <code>Pokémon Brilliant Diamond/Shining Pearl</code>, a <a href="https://unity.com/">Unity</a> engine game, and <code>SHIN MEGAMI TENSEI V</code>, an <a href="https://www.unrealengine.com/">Unreal Engine 4</a> game, we realized how much work needs to be done to solve stability and rendering issues affecting both engines. Since we don’t have that many GPU developers available (especially in finals months), we can only focus on one thing at a time, so first, Unity.</p> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/#graphical-fixes">Blit detection</a> suffered some regressions with the introduction of the resolution scaler, <a href="https://yuzu-mirror.github.io/entry/yuzu-art/">Project ART</a>. <a href="https://github.com/FernandoS27">Blinkhawk</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7368">fixed them and added texture format</a> <code>D24S8</code> to <code>RGBA8</code> conversions to Vulkan, fixing several crashes affecting both APIs in this new Pokémon remake.</p> <p>Morph later included <a href="https://github.com/yuzu-emu/yuzu/pull/7395">some more fixes</a> for this pull request.</p> <p>Another issue affecting <code>Pokémon Brilliant Diamond/Shining Pearl</code> is an interesting corruption that can happen in battles and in reflections after some time, or with certain attacks that cover the whole screen. By replacing the old “format deduction algorithm” and instead utilizing <a href="https://github.com/yuzu-emu/yuzu/pull/7396">full depth conversions</a>, Blinkhawk fixed this colourful bug.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bdspbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/bdspbug_hu64dfc2fd9b2343f7a6d318f280a498c6_6074641_800x0_resize_q90_bgffffff_box_3.jpg" alt="What a trip, almost like a Disney song (Pokémon Brilliant Diamond)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bdspfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/bdspfix_huc67ba51899a717eb1c9f41ef7702439b_4464556_800x0_resize_q90_bgffffff_box_3.jpg" alt="What a trip, almost like a Disney song (Pokémon Brilliant Diamond)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">What a trip, almost like a Disney song (Pokémon Brilliant Diamond)</p> <p>One of the (many) missing texture formats is <code>S8_UINT</code>, an 8-bit stencil texture. Morph used a homebrew unit test to verify he was making progress. <code>Baldur’s Gate 1 and 2</code> and <code>Citizens of Space</code> make use of <code>S8_UINT</code>, but as both games need other formats that are still missing and other fixes, they weren&rsquo;t very helpful in testing.</p> <p>While <a href="https://github.com/yuzu-emu/yuzu/pull/7357">there is support for S8_UINT in both OpenGL and Vulkan</a> now, NVIDIA is the only vendor to specify support for the format in Vulkan, meaning that any affected game running on an AMD or Intel GPU will need to stick to OpenGL to get proper rendering.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./s8uintbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/s8uintbug_hu8f3eb7ce0e35849d67c7c7cb88e14aa8_164433_800x0_resize_q90_bgffffff_box_3.jpg" alt="Testing homebrew"></a> </div> <div class="column is-bottom-paddingless"> <a href="./s8uintfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/s8uintfix_huacbe66144aabfff542deb1ab0dd39b85_233678_800x0_resize_q90_bgffffff_box_3.jpg" alt="Testing homebrew"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Testing homebrew</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> found a bug where image creation would include width size restrictions that wouldn’t apply to later updates and downloads, causing OpenGL to spam errors. <a href="https://github.com/yuzu-emu/yuzu/pull/7294">Properly handling those cases</a> allows the driver to calm down. Proper and cleaner code can also mean less driver overhead.</p> <p>Continuing with the implementation of unsupported formats, vonchenplus added <code>R5G6B5_UNORM_PACK16</code> <a href="https://github.com/yuzu-emu/yuzu/pull/7291">textures to Vulkan</a> and <code>S8_UINT_D24_UNORM</code> <a href="https://github.com/yuzu-emu/yuzu/pull/7466">globally</a>. Again, just like <code>S8_UINT</code>, AMD and Intel hardware lack Vulkan support for <code>S8_UINT_D24_UNORM</code>.</p> <p>vonchenplus also <a href="https://github.com/yuzu-emu/yuzu/pull/7375">converted all uses of legacy attributes</a> within shaders into generic attributes, since they were not supported by some graphics drivers, improving compatibility.</p> <p>These four changes improve <code>DRAGON QUEST BUILDERS</code>, but more work is required to make the game playable. If you&rsquo;re interested in testing this game, use Vulkan, or disable Asynchronous GPU Emulation when using OpenGL. Beware, crashes may occur.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dqb.png" title=" Missing graphics make the game not an optimal experience for now (DRAGON QUEST BUILDERS)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/dqb_hu56aa2691c8d31eda2ecf845ffe423c18_1224431_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Missing graphics make the game not an optimal experience for now (DRAGON QUEST BUILDERS)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Missing graphics make the game not an optimal experience for now (DRAGON QUEST BUILDERS)</p> </div> </div> <p>Let&rsquo;s go back to the topic of fixing issues introduced by the resolution scaler. Users reported that taking screenshots at the 1x resolution multiplier resulted in saved images with a size higher than the rendering resolution of the game. A mix up resulted in the screenshot being saved at the window size instead of the game’s framebuffer size. epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/7389">fixed the logic</a> and we’re back to proper screenshot resolutions.</p> <p><a href="https://github.com/liushuyu">liushuyu</a>, our fantastic Web Admin, <a href="https://github.com/flathub/org.yuzu_emu.yuzu/issues/200">received reports</a> <a href="https://github.com/flathub/org.yuzu_emu.yuzu/issues/218">of systems with multiple GPUs</a> experiencing crashes while running the Flatpak version of yuzu on Linux. It seems like the bundled version of <a href="https://www.mesa3d.org/">mesa</a> and <a href="https://ffmpeg.org/">ffmpeg</a> will not work on systems with different GPU vendors. This is caused by Flatpak&rsquo;s built-in ffmpeg lacking support for NVDEC and VDPAU on NVIDIA hardware, and having broken codec detection. Just your average GNOME, who manages both Flatpak and FlatHub.</p> <p>liushuyu submitted <a href="https://github.com/yuzu-emu/yuzu/pull/7431">two</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7467">separate</a> pull requests addressing this problem, but more edge cases continue to appear, so the battle isn’t over yet.</p> <p>While we continue to work towards winning this war on Flatpak issues, please stick to using our <a href="https://yuzu-mirror.github.io/downloads/#linux">AppImages</a>, or <a href="https://yuzu-mirror.github.io/wiki/building-for-linux/">manually building yuzu</a>. If you prefer to manually build yuzu, make sure that your ffmpeg library is capable of decoding <code>VP8</code>, <code>VP9</code>, and <code>H.264</code> on hardware. It seems like the only way to solve this problem will be to just ship our own ffmpeg instead of Flatpak’s default version.</p> <h2 id="ui-changes">UI changes</h2> <p><a href="https://github.com/MightyCreak">MightyCreak</a> has been working on changes in behaviour to the default light theme. Previously, yuzu would ignore the system wide theme, sticking to a light palette even if the system switched to a dark one. <a href="https://github.com/yuzu-emu/yuzu/pull/7330">Renaming the Light theme to Default, and allowing it to match the behaviour of the system theme</a>, makes for a more streamlined user experience. At the moment, this behaviour only works correctly on Linux, Windows’ Qt doesn’t yet support system wide themes.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/7342">Yours truly (GoldenX86)</a> decided that the previous missing keys error screen wasn’t clear enough and fixed it right up, short and sweet.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./keysbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/keysbug_hub005b95bd911c6ba69466ecb49be0711_7832_800x0_resize_q90_bgffffff_box_3.jpg" alt="For some reason, people seem to forget what hyperlinks are for"></a> </div> <div class="column is-bottom-paddingless"> <a href="./keysfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/keysfix_hu6e5749f0893dd4b18faf415bc03346a0_7434_800x0_resize_q90_bgffffff_box_3.jpg" alt="For some reason, people seem to forget what hyperlinks are for"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">For some reason, people seem to forget what hyperlinks are for</p> <p>While working on the resolution scaler and its included filters, Blinkhawk named FSR <code>AMD'S FIDELITYFX SR</code> on the bottom status bar. As this was a bit too long, Morph <a href="https://github.com/yuzu-emu/yuzu/pull/7369">renamed it</a> to simply <code>FSR</code>. Small change, but more pleasing to the eyes.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./fsrbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/fsrbug_hu4824e490d033b1e9e95c932c7efd2a22_1623_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better, don&#39;t you agree?"></a> </div> <div class="column is-bottom-paddingless"> <a href="./fsrfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/fsrfix_hu011497e26baca6110672f979d71c8403_1295_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better, don&#39;t you agree?"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Better, don&#39;t you agree?</p> <p><a href="https://github.com/Kewlan">Kewlan</a> implemented a very nice addition for high refresh rate users. With the introduction of the FPS unlimiter that players can toggle by pressing <code>Ctrl + U</code> while in-game, a cap was introduced in the configuration to allow setting a multiplier of the native framerate as the upper limit.</p> <p>For example, if a game runs at 30FPS, and the user wants to limit it to 120FPS to better match the maximum refresh rate of their display, a 4x multiplier would be needed. A 2x multiplier if the game runs at 60FPS natively.</p> <p>The problem with this approach is that as shown in the example, different games will run at different framerates natively, so a global value isn&rsquo;t ideal. Kewlan <a href="https://github.com/yuzu-emu/yuzu/pull/7404">added support for framerate caps in the custom configuration</a> and users can access it by right clicking a game in yuzu’s list and selecting properties. This way, the user can set their preferred cap on a per-game basis.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./cap1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/cap1_huf6a94776f23c8ba3ff3e03baa9cc9eec_8034_800x0_resize_q90_bgffffff_box_3.jpg" alt="If you buy a new display, remember to manually increase the refresh rate!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./cap2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/cap2_hu9556e9b41f5102647f4661eaaa76d700_6736_800x0_resize_q90_bgffffff_box_3.jpg" alt="If you buy a new display, remember to manually increase the refresh rate!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">If you buy a new display, remember to manually increase the refresh rate!</p> <p>If the user wants a value that isn’t a multiple of the native framerate of the game, they can use software like <a href="https://www.guru3d.com/files-details/msi-afterburner-beta-download.html">MSI Afterburner</a> to specify a custom limit.</p> <p>There has been some extensive work to improve hotkeys.</p> <p><a href="https://github.com/v1993">v1993</a> received a report that yuzu’s window will flicker if the user holds the <code>Esc</code> key when trying to exit fullscreen. <a href="https://github.com/yuzu-emu/yuzu/pull/7353">That won’t happen any more</a>.</p> <p>german77 discovered that holding a hotkey would constantly spam the input. This was unintended, so he ensured <a href="https://github.com/yuzu-emu/yuzu/pull/7355">this behaviour was no more</a>.</p> <p><a href="https://github.com/heinermann">heinermann</a> modified <a href="https://github.com/yuzu-emu/yuzu/pull/7419">the Menu bar as follows:</a></p> <p>In <code>Emulation</code>, the <code>Start</code> button has been removed and <code>Continue</code> will now say <code>Pause</code> when applicable and vice versa. <code>Restart</code> will no longer cause a crash. In <code>File</code>, the <code>Load Amiibo...</code> hotkey was fixed. We still have issues with several games when using this function, so consider it in a beta state. <code>TAS</code> <a href="https://github.com/yuzu-emu/yuzu/pull/7406">received its own submenu</a> in <code>Tools &gt; TAS</code>. And in exciting news, Exiting the emulator will now work while in fullscreen!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./tasbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/tasbug_hu9d0ec7df002e646b9cc5c52554cbb94c_20453_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> <div class="column is-bottom-paddingless"> <a href="./tasfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2021/tasfix_hu506132873de2e7dc761b2cd92468cce9_13786_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> </p> <h2 id="kernel-fixes">Kernel fixes</h2> <p>Morph fixed <a href="https://github.com/yuzu-emu/yuzu/pull/7278">a compilation warning</a> in the kernel <code>SVC::WaitSynchronization</code>, where the parameter <code>num_handles</code> was wrongly declared as an unsigned integer when it was actually a signed integer.</p> <p>heinermann discovered a bug in the kernel that crashed yuzu upon exiting.</p> <p>This happened because dummy threads in the kernel weren&rsquo;t getting destroyed properly. When yuzu was exited during emulation or after stopping emulation, these threads stayed alive even though the kernel got destroyed, thus causing yuzu to crash.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/7359">By making the kernel own these threads</a>, we ensure they get destroyed when the kernel gets destroyed, mitigating the crash.</p> <p><a href="https://github.com/OatmealDome">OatmealDome</a> fixed a bug that caused some homebrew to not boot. The fix was to <a href="https://github.com/yuzu-emu/yuzu/pull/7320">pass default threadinfo when the kernel creates a thread</a>, allowing homebrew to boot.</p> <h2 id="skyline-framework-part-1">Skyline framework, Part 1</h2> <p><a href="https://github.com/itsmeft24">itsmeft24</a>, <a href="https://github.com/jam1garner">jam1garner</a>, and Morph started working on adding support for the <a href="https://github.com/skyline-dev/skyline">Skyline</a> modding framework. This will allow for more intricate code mods, such as using <a href="https://github.com/Raytwo/ARCropolis">ARCropolis</a>, a mod loader for Smash Ultimate made by <a href="https://github.com/Raytwo">Raytwo</a> and <a href="https://github.com/blu-dev">blujay</a>.</p> <p>All these PRs <a href="https://github.com/yuzu-emu/yuzu/pull/7393">[1]</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/7394">[2]</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/7407">[3]</a> are part of the on-going effort to implement support for the modding framework in yuzu.</p> <p>There are more juicy additions, but they didn&rsquo;t make it in time to be mentioned in this article, we will continue to expand on Skyline&rsquo;s progress in December&rsquo;s report. See the current progress <a href="https://github.com/yuzu-emu/yuzu/issues/7392">here</a>.</p> <h2 id="general-changes-and-bugfixes">General changes and bugfixes</h2> <p>Not much to talk about in this section this time, mostly just service stubs and implementations.</p> <p><code>Animal Crossing: New Horizons</code> takes the spotlight <a href="https://github.com/yuzu-emu/yuzu/pull/7283">with</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7285">4</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7287">stubs</a> to make the new 2.0.0 update playable. Thank you, german77 and Morph.</p> <p>german77 also provides <code>Just Dance 2022</code> <a href="https://github.com/yuzu-emu/yuzu/pull/7293">with its own stub</a> for the <code>EndFreeCommunication</code> service.</p> <p>And finally, Morph <a href="https://github.com/yuzu-emu/yuzu/pull/7482">implements the</a> <code>GetCompletionEvent</code> service for <code>Super Bomberman R Online</code>. However, as the game requires online services, it won’t be playable for now.</p> <h2 id="future-projects">Future projects</h2> <p><code>Project Gaia</code> continues to progress and is receiving optimizations as we speak. We&rsquo;re not that far away from starting internal testing on it.</p> <p>That’s all folks! As always, thank you so much for your attention, and we’ll see you next time!</p> <p>Special thanks to RodrigoTR and PacoA for their provided media.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report October 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/ Sat, 13 Nov 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/ <p>Hey there, yuz-ers! We&rsquo;ve had quite an exciting month. Our most anticipated and highly requested feature, Resolution Scaling, is finally out! But we didn&rsquo;t rest on our laurels, a host of other fixes were pushed this month and we can&rsquo;t wait to tell you all about them!</p> <p>Hey there, yuz-ers! We&rsquo;ve had quite an exciting month. Our most anticipated and highly requested feature, Resolution Scaling, is finally out! But we didn&rsquo;t rest on our laurels, a host of other fixes were pushed this month and we can&rsquo;t wait to tell you all about them!</p> <h2 id="psa-for-nvidia-users">PSA for NVIDIA users</h2> <p>Before delving further, we want to remind NVIDIA users that there are issues with the latest graphics drivers, specifically the 49X releases.</p> <p>Past the last 472.XX drivers, NVIDIA removed support for Windows versions prior to 10 and the Kepler series of GPUs (mostly 600 and 700 series cards). Additionally, OpenGL GLSL and Vulkan rendering were affected, with GLSL becoming virtually unusable and Vulkan exhibiting minor glitches.</p> <p>While NVIDIA works to resolve the issues, and we work on alternatives to mitigate the problems, we&rsquo;ve configured <a href="https://github.com/yuzu-emu/yuzu/pull/7243">NVIDIA GPUs on affected drivers to only use GLASM when OpenGL is selected</a>. This seems to workaround most of the GLSL errors we&rsquo;ve been seeing on these latest drives. Thanks to <a href="https://github.com/lat9nq">toastUnlimited</a> for the quick update.</p> <p>GLSL will still be available for version 472.XX and older drivers. If someone wishes to use GLSL on recent 49X series drivers, turn on <code>Enable Graphics Debugging</code> in <code>Emulation &gt; Configure… &gt; General &gt; Debug</code>. Keep in mind this will reduce performance, as it is only intended for debugging.</p> <p>With the PSA out of the way, let&rsquo;s get into the good stuff!</p> <h2 id="project-art">Project A.R.T.</h2> <p><code>Advanced Rendering Techniques</code> or was it <code>Aristotle’s Rescaling Technology</code>? I think there&rsquo;s another name I’m forgetting. Maybe <a href="https://github.com/yuzu-emu/yuzu/pull/7219">the Pull Request</a> will have more information for those curious.</p> <p>Anyway, <code>Project A.R.T.</code> is out in the wild! <a href="https://github.com/FernandoS27">Blinkhawk</a>, <a href="https://github.com/breadfish64">BreadFish</a>, <a href="https://github.com/ameerj">epicboy</a>, and <a href="https://github.com/reinuseslisp">Rodrigo</a> are to thank for this incredible release.</p> <p>As explained in its dedicated article <a href="https://yuzu-mirror.github.io/entry/yuzu-art/">here</a>, this is a complete rewrite of our old resolution scaling implementation from 2019. Before we jump into the end-user benefits, let&rsquo;s first cover some terminology. The correct terms for the scaling process are <code>Upsampling</code> and <code>Supersampling</code>, which can also be more commonly called <code>Downsampling</code>. In layman&rsquo;s terms, downsampling means taking a big frame and reducing its size to fit a smaller display. Downsampling is rendering the game at a higher resolution than your display’s native one.</p> <p>In contrast, <code>upsampling</code> means taking a smaller frame and stretching it to fit a bigger display. It results in a lower quality image, but users with low-end GPUs, particularly users of integrated graphics, may prefer to have better framerates over image quality.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./art.png" title="A work of art (read left to right)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/art_hueb3062cf06dcf4b492f3133692bbe1d6_20679_638x0_resize_q90_bgffffff_box_3.jpg" alt="A work of art (read left to right)"></a> <p class="has-text-centered is-italic has-text-grey-light">A work of art (read left to right)</p> </div> </div> <p>There seems to be a lot of confusion about this. Remember, improving the visual quality of the game is downsampling, not upsampling. Games look their best when they have a 1:1 ratio between rendering and display resolution, or when downsampling.</p> <p>With that out of the way, let’s get started. All new options can be found in <code>Emulation &gt; Configure… &gt; Graphics</code></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./options.png" title="yuzu Graphics configuration window "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/options_hub6d5c511f5ac338e7fd38dff1f912762_23502_1019x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu Graphics configuration window "></a> <p class="has-text-centered is-italic has-text-grey-light">yuzu Graphics configuration window </p> </div> </div> <p>Starting with <code>Resolution</code>, this option is the Scaling Multiplier being used. It will double the width and height of whatever resolution the game is rendering at. At the moment, we offer two upsampling multipliers: <code>0.5X</code> and <code>0.75X</code>, and five downsampling multipliers: <code>2X</code>, <code>3X</code>, <code>4X</code>, <code>5X</code>, and <code>6X</code>.</p> <p>Here&rsquo;s an example, <code>Super Mario Odyssey</code> displays a 1920x1080 frame in docked mode but actually renders at 1600x900, and at 1280x720 in undocked mode. Applying a 2X resolution to Super Mario Odyssey gives us a rendering resolution of 3200x1800 in docked mode and 2560x1440 in undocked mode. 3X would give us 4800x2700 and 3840x2160 respectively, 0.5X would be 800x450 and 640x360, and so on. Keep in mind that games can reduce graphical details in undocked mode, not only their resolution.</p> <p>With high resolutions comes increased texture sizes. This has a significant impact on both video memory (VRAM) and other available graphical resources, like memory bandwidth. The user must consider the available VRAM and the performance of the GPU they are using when deciding which resolution multiplier to use. For integrated GPU users, RAM overclocking becomes critical, as faster RAM means faster “VRAM” for your iGPU.</p> <p>If the GPU runs out of VRAM faster than the emulator or graphics driver can manage resources, yuzu will close, so follow our recommended values in the picture below.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vram.png" title="We recommend 2GB and lower users to use 1X on graphic intensive games"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/vram_hu0f7f47f68d20f95d5554461536b87a08_15821_813x0_resize_q90_bgffffff_box_3.jpg" alt="We recommend 2GB and lower users to use 1X on graphic intensive games"></a> <p class="has-text-centered is-italic has-text-grey-light">We recommend 2GB and lower users to use 1X on graphic intensive games</p> </div> </div> <p>Small, low-end GPUs (like our recommended GT 1030, RX 550, or any integrated GPU) will see considerable performance benefits when upsampling as the reduction in 3D load and the lower VRAM utilization will provide higher framerates.</p> <p>People with current mid to high-end GPUs can benefit from the surplus of computational capabilities and available VRAM. Actual performance will be determined by each specific game, but it’s safe to assume that good hardware can use a 2X or 3X multiplier with little issue most of the time. We personally don’t recommend going higher than 3X as not even the best consumer hardware available at this moment can provide a perfect experience when rendering at very high resolutions, but the options are there to experiment with.</p> <p>Light or very well optimized games like <code>Super Smash Bros. Ultimate</code> and <code>Metroid Dread</code> can make for great experiences on 4K or 8K displays. On the other hand, particular games like <code>Astral Chain</code> should not be downsampled, as they already use 3840x2160 textures. Trying high resolution multipliers with games like this will result in your GPU&rsquo;s VRAM not being very happy.</p> <p>We strongly recommend using Vulkan for downsampling as VRAM use will be considerably lower as compared to OpenGL.</p> <p>Let’s move on to the second option, <code>Window Adapting Filter</code>.</p> <p>When using a display with a different native resolution than your rendering resolution, you need some way of deciding which pixels will be shown in the final image. Filters are used for that!</p> <p>Currently, yuzu offers 6 filtering options, each recommended for different scenarios, and with different performance costs. We plan to expand this section in the future, adding sliders to let users customize the filters to their own tastes. And yes, on GPU limited scenarios, the filter in use can affect framerate.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./filters.png" title="Tested on Mario Kart 8 Deluxe, filtering ain&#39;t free!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/filters_huf9c323c0cf5eb15346b55786288d2947_15704_602x0_resize_q90_bgffffff_box_3.jpg" alt="Tested on Mario Kart 8 Deluxe, filtering ain&#39;t free!"></a> <p class="has-text-centered is-italic has-text-grey-light">Tested on Mario Kart 8 Deluxe, filtering ain&#39;t free!</p> </div> </div> <p>While an integrated GPU will suffer the performance cost, even a low-end dedicated card will handle the increased computational load with ease.</p> <p>Here are some recommendations and comparisons of all current options against the default bilinear filter.</p> <p><code>Nearest Neighbor</code> is ideal for pixel art style games like <code>UNDERTALE</code> or <code>OCTOPATH TRAVELER</code>, it can also provide the best results when the game’s rendering resolution matches the window or display’s resolution. It and <code>Bilinear</code> have the lowest performance cost of all the options.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/otbilinear_hucd9d11b2b2fe7cd284b1ce20b994dd42_1539618_1024x0_resize_q90_bgffffff_box_3.jpg" alt="OCTOPATH TRAVELER (Bilinear Vs. Nearest Neighbour)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/otnearest_hu94544779c866e2119187fbd8aee4c885_1614091_1024x0_resize_q90_bgffffff_box_3.jpg" alt="OCTOPATH TRAVELER (Bilinear Vs. Nearest Neighbour)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">OCTOPATH TRAVELER (Bilinear Vs. Nearest Neighbour)</p> <p><code>Bilinear</code> is our combat tested default option. It&rsquo;s very good for downsampling and like <code>Nearest Neighbor</code>, it has almost no performance cost. It’s a great all-rounder. If you have a 1080p display, we recommend <code>Bilinear</code> with a 2X resolution multiplier.</p> <p><code>Bicubic</code> can produce better downsampling results than <code>Bilinear</code>, but at a slightly higher performance cost. We recommend it for 2X or 3X multipliers on 1080p displays.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/botwbilinear_huad67af673bfe25941e438dd0e7ef5933_1382345_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild (Bilinear Vs. Bicubic)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/botwbicubic_hu53573981f313c71bcfd36673143eb881_1239711_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild (Bilinear Vs. Bicubic)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild (Bilinear Vs. Bicubic)</p> <p><code>Gaussian</code> is intended for extreme cases, like when the user wants to test a very high multiplier. It also has a high performance cost. When very high values are used, the image can, ironically, start to become pixelated again. The gaussian blur produced by this filter will help provide a more pleasant image. Recommended for 4X to 6X multipliers on 1080p displays.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/dreadbilinear_hu84b71936d0cc0e909a566a8e5d9525ff_917436_720x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (Bilinear Vs. Gaussian)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/dreadgaussian_huafae6c885c8ec8de4fa5e2547565563b_829533_720x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (Bilinear Vs. Gaussian)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Metroid Dread (Bilinear Vs. Gaussian)</p> <p><code>Scaleforce</code> was invented by BreadFish. It is a great downsampling filter for 3D games and a fine upsampling filter for 2D games, while also only requiring a moderate performance cost. A true jack of all trades.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/otbilinear_hucd9d11b2b2fe7cd284b1ce20b994dd42_1539618_1024x0_resize_q90_bgffffff_box_3.jpg" alt="OCTOPATH TRAVELER (Bilinear Vs. Scaleforce)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/otscaleforce_hu7357fe75a9a451639ceb9e68201c3181_1559024_1024x0_resize_q90_bgffffff_box_3.jpg" alt="OCTOPATH TRAVELER (Bilinear Vs. Scaleforce)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">OCTOPATH TRAVELER (Bilinear Vs. Scaleforce)</p> <p><code>AMD Fidelity FX™ Super Resolution</code>, or FSR for short, is <a href="https://github.com/GPUOpen-Effects/FidelityFX-FSR">in AMD’s own words</a> “&hellip;an open source, high-quality solution for producing high resolution frames from lower resolution inputs.”</p> <p>This means that it is particularly useful for low-end users trying to restore some of the missing details lost when upsampling a game to gain performance. It is NOT recommended for downsampling, as the output resolution is used as part of the process. A perfect pick for people forced to run 0.5X or 0.75X multipliers for performance reasons.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/smo1xbilinear_hu7ec165b64df65c7ccd99ffde914f6eca_3540520_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (1X Bilinear Vs. 0.75X FSR)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/smo075xfsr_hu21a730d6822a81e5ef7aa54a1e355131_3658527_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (1X Bilinear Vs. 0.75X FSR)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (1X Bilinear Vs. 0.75X FSR)</p> <p>If the user tries FSR while downsampling, they <em><strong>will be reducing image quality</strong></em> and will end up only seeing the sharpening aspect of the filter, negating any advantage of increasing the rendering resolution while incurring the full performance cost of it.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/zlabilinearbad_hu662f8740bad7c8488dec4c46cca87f54_2045562_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening (2X Bilinear Vs. 2X FSR on a 1080p display)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/zlafsrbad_hu5b2718a9fb856aec59ac8f43941c790a_752358_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening (2X Bilinear Vs. 2X FSR on a 1080p display)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Link&#39;s Awakening (2X Bilinear Vs. 2X FSR on a 1080p display)</p> <p>So, in short, if the rendering resolution is <em>higher</em> than the display’s resolution, FSR should be avoided. If the rendering resolution is <em>equal or lower</em> than the display’s resolution, FSR is an excellent shader-based filtering option, but with the highest performance cost on the list.</p> <p>As a way to cheat around this limitation, AMD and NVIDIA Windows users can fake higher display resolutions with the use of <a href="https://www.amd.com/en/support/kb/faq/dh2-010">Virtual Super Resolution</a> and <a href="https://www.nvidia.com/en-us/geforce/technologies/dsr/technology/">Dynamic Super Resolution</a> respectively. This way, for example, a 1080p display can fake a 2160p (4K) maximum resolution, giving FSR a lot more information to play with.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/zlabilineargood_hub2b74858f536bbc2b3a962e9ba8182d7_2047005_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening (2X Bilinear Vs. 2X FSR on a 4K display)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/zlafsrgood_hu641e1924be04b784e5db81d80bcfd41f_2151116_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening (2X Bilinear Vs. 2X FSR on a 4K display)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Link&#39;s Awakening (2X Bilinear Vs. 2X FSR on a 4K display)</p> <p>Finally our current last option, <code>Anti-Aliasing Method</code>. Pixels are almost squares and squares aren&rsquo;t great for displaying curves. Anti-aliasing methods are used to smooth out this undesired effect. At the moment we only offer <a href="https://en.wikipedia.org/wiki/Fast_approximate_anti-aliasing">FXAA</a>, which can help reduce the excessive sharpening shown when using FSR. In the near future, we plan to add more options like <a href="https://en.wikipedia.org/wiki/Morphological_antialiasing">MLAA/SMAA</a></p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/lm3fsr_hu5b5cd213d00e9435b55eba944b77109a_3852406_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi&#39;s Mansion 3 (FSR Vs. FSR &#43; FXAA, both on a 4K display)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/lm3fxaa_hu3751a06a230238c6665965c89b97fdf8_3845415_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Luigi&#39;s Mansion 3 (FSR Vs. FSR &#43; FXAA, both on a 4K display)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Luigi&#39;s Mansion 3 (FSR Vs. FSR &#43; FXAA, both on a 4K display)</p> <p>Both the filters and anti-aliasing options can be changed while in-game using the buttons on the bottom left of yuzu’s window. Changing the resolution multiplier in-game is not possible at the moment.</p> <p>As an additional note, <code>A.R.T.</code> also reimplements our <code>Anisotropic Filtering</code>! This option can be accessed from the Advanced tab in the graphics settings. In the past we recommended skipping this option as not all games are particularly fond of forcing values higher than they specified, but this new implementation is smarter, avoiding previous drawbacks.</p> <p>At a low performance cost, it will increase the quality of textures at oblique angles, particularly ground textures, most noticeable in first and third person view games. It should now be safe to set at 16x and forget about it.</p> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/pksw1x_hu2859533cfba6cbef6f8d7dc87a7baeed_385531_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Sword (default Vs. 16X Anisotropic Filtering)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/pksw16x_huaa283a2fe7c2191c207a0c0dc5b4ae08_444160_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Sword (default Vs. 16X Anisotropic Filtering)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon Sword (default Vs. 16X Anisotropic Filtering)</p> <p>One last note, AMD users should ensure that <a href="https://www.youtube.com/watch?v=wTh_O9BZlGc">Radeon Image Sharpening</a> is disabled before using the scaler, as it can affect the quality of some filters, especially FSR which includes its own sharpening already.</p> <p>At the time of writing this article, <code>Resolution Scaling</code> remains in <a href="https://yuzu-mirror.github.io/help/early-access/">Early Access</a> for testing and regression finding, but be sure that it won’t take long to be merged into <a href="https://yuzu-mirror.github.io/downloads/">Mainline</a>. Check the progress in the pull request previously listed, code review is usually the main reason for delays on merging.</p> <h2 id="graphical-and-general-bugfixes">Graphical and general bugfixes</h2> <p><code>Metroid Dread</code> has been a very important release both for the series and for the console, giving us the first main entry for the series in years.</p> <p>This game is heavily optimized and well polished all around, part of that is thanks to using very clever tricks to render. Dread doesn’t shy away from using pre-rendered videos for backgrounds, displays, manuals, and the intro menu. Such videos were using an <a href="https://github.com/yuzu-emu/yuzu/pull/7138">unsupported frame format, <code>RGBX8</code></a>, which epicboy implemented.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="dreadbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/dreadbug_hu41932d7cf9e06156bc410a0f1e01b345_24431_800x0_resize_q90_bgffffff_box_3.jpg" alt="There&#39;s no need to introduce more dread into this game (Metroid Dread)"></a> </div> <div class="column is-bottom-paddingless"> <a href="dreadfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/dreadfix_huecf99986d5ce3a98467a2b7522ee0a0e_740275_800x0_resize_q90_bgffffff_box_3.jpg" alt="There&#39;s no need to introduce more dread into this game (Metroid Dread)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">There&#39;s no need to introduce more dread into this game (Metroid Dread)</p> <p>While this solves the rendering of a single video on screen, some areas of the game can play multiple streams simultaneously, causing glitches on screen. yuzu’s decoding needs to be improved to handle those cases, something we’re still working on.</p> <p>While Blinkhawk was working on <code>Project A.R.T</code>, he also <a href="https://github.com/yuzu-emu/yuzu/pull/7127">doubled the counter of cached pages in the rasterizer</a>.</p> <p>yuzu uses these counters to keep track of the number of GPU objects stored in a cache within a CPU page. Previously, this counter would account for pages whose addresses were up to a size of 38 bits. Some games, however, can use memory addresses of up to 39 bits.</p> <p>By doubling the counter, the rasterizer can effectively keep track of these addresses now, allowing certain games that did not work with the old counter to boot, such as <code>Final Fantasy X</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ffx.png" title="Listen to my story, the story of the worst laugh ever recorded (FINAL FANTASY X/X-2 HD Remaster)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/ffx_huc2dfe4202400edcc6b9719c08ac72dd1_3956005_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Listen to my story, the story of the worst laugh ever recorded (FINAL FANTASY X/X-2 HD Remaster)"></a> <p class="has-text-centered is-italic has-text-grey-light">Listen to my story, the story of the worst laugh ever recorded (FINAL FANTASY X/X-2 HD Remaster)</p> </div> </div> <p>epicboy investigated the graphical issues present in <code>Mario Party Superstars</code>. Following the lead from this initial research, Blinkhawk found the problem and submitted a patch that <a href="https://github.com/yuzu-emu/yuzu/pull/7262">improves the performance of the backtracking algorithm</a> used by the shader cache to find the handlers of a bindless texture.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="mpsbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/mpsbug_hu41932d7cf9e06156bc410a0f1e01b345_71127_800x0_resize_q90_bgffffff_box_3.jpg" alt="Old school minigames are the best (Mario Party Superstars)"></a> </div> <div class="column is-bottom-paddingless"> <a href="mpsfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/mpsfix_hu979ec8f77601462edb52d27bc9c94b36_1527421_800x0_resize_q90_bgffffff_box_3.jpg" alt="Old school minigames are the best (Mario Party Superstars)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Old school minigames are the best (Mario Party Superstars)</p> <p>yuzu’s window can be freely resized, but users may want some presets to return things to accurate 16:9 proportions. In the past we offered 720p and 1080p options, but now epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/7158">adds a 900p option</a>, useful for both people with 1080p displays wanting some free space on their screen, and for getting a 1:1 ratio on 3D games that render natively at 1600x900.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./size.png" title="A simple way to make good use of nearest neighbour"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/size_hu7f5dfde15abcae25d09f5db6bb75ae4a_8297_451x0_resize_q90_bgffffff_box_3.jpg" alt="A simple way to make good use of nearest neighbour"></a> <p class="has-text-centered is-italic has-text-grey-light">A simple way to make good use of nearest neighbour</p> </div> </div> <p>Blinkhawk has been investigating an issue affecting <code>Catherine: Full Body</code>, <code>Hyrule Warriors: Definitive Edition</code>, and an unknown number of other games.</p> <p>NVN, the graphics API most Nintendo Switch games use, will skip <a href="https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkFence.html">fences</a> (ways to synchronize rendering) if a certain amount of time has passed. This is a sensical design choice on native hardware, where a long wait could mean a <a href="https://en.wikipedia.org/wiki/Timeout_Detection_and_Recovery">TDR</a> from a malfunctioning game or faulty hardware. In the emulator, on the other hand, long wait times can be caused by shaders being built, textures being downloaded or uploaded, background processes hogging the system, etc.</p> <p>If those delays are not taken into consideration, games can experience graphical glitches and bad frame pacing. The solution is <a href="https://github.com/yuzu-emu/yuzu/pull/7187">forcing the GPU to wait</a> until the system responds with all tasks finished.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="catbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/catbug_hu8c8e3e87e97014237239944bb96feed8_2552044_800x0_resize_q90_bgffffff_box_3.jpg" alt="Almost a Nice Boat protagonist (Catherine: Full Body)"></a> </div> <div class="column is-bottom-paddingless"> <a href="catfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/catfix_hu8bad7bf72712b31cb909f3c6080f5a8e_3363730_800x0_resize_q90_bgffffff_box_3.jpg" alt="Almost a Nice Boat protagonist (Catherine: Full Body)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Almost a Nice Boat protagonist (Catherine: Full Body)</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> is back with more fixes! This time a couple of stubs helping in-game stability or rendering.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/7184">Stubbing <code>IHOSBinderDriver::TransactParcel</code> and <code>GetBufferHistory</code></a> help to boot <code>Luigi’s Mansion 3</code>, which is notorious for refusing to load at random. While this helps mitigate the issues, they are not fully solved. It seems the small delay introduced by shader building can affect the stability of this game too. We need to investigate this issue further.</p> <p>It’s time to add some love to <code>yuzu-cmd</code> again, our command line alternative to the default Qt-based yuzu. toastUnlimited added the option to <a href="https://github.com/yuzu-emu/yuzu/pull/7148">select the network interface to use</a>, providing LAN support to terminal-loving users.</p> <p>Some videos in <code>Touhou Genso Wanderer -Lotus Labyrinth R-</code> and <code>Tsukihime -A piece of blue glass moon-</code> would render completely black. <a href="https://github.com/v1993">v1993</a> figured out the cause of the problem, which happened because the height of the video frame that needed to be decoded was smaller than the surface where it was supposed to be drawn upon. In order to avoid writing outside of bounds, there is a check that ensures these two dimensions are equal, or it will not draw the frame. v1993 changed this check to <a href="https://github.com/yuzu-emu/yuzu/pull/7152">allow the surface to be higher than frame</a>, so that videos with this issue can render their frames.</p> <p>But this was a transient solution, as epicboy later addressed the problem by <a href="https://github.com/yuzu-emu/yuzu/pull/7157">implementing a general solution</a> that uses the minimum between these two sizes when writing the decoded image into the GPU, while keeping the aforementioned check in place to ensure no out-of-bounds memory is compromised.</p> <p>These changes affect all titles with size disparities, allowing them to render their videos even if the height of the frame and the surface differ by a couple of pixels.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="thbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="thfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That piano really hits with nostalgia (Tsukihime -A piece of blue glass moon-)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="gwbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/gwbug_hu34264a64c7d74cce405a83173c53b749_93596_800x0_resize_q90_bgffffff_box_3.jpg" alt="Speaking of good music (Touhou Genso Wanderer -Lotus Labyrinth R-)"></a> </div> <div class="column is-bottom-paddingless"> <a href="gwfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/gwfix_hu2882a5f6989347a3746cee6ef8ba80e5_1359537_800x0_resize_q90_bgffffff_box_3.jpg" alt="Speaking of good music (Touhou Genso Wanderer -Lotus Labyrinth R-)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Speaking of good music (Touhou Genso Wanderer -Lotus Labyrinth R-)</p> <p>epicboy also made changes to the SPIR-V emitter, so that <a href="https://github.com/yuzu-emu/yuzu/pull/7201">implicit LOD sampling behaves the same way as the hardware on all GPU drivers</a> during non-fragment stages of the pipeline.</p> <p>It is possible to specify how detailed things can appear on the screen based on the <code>LOD</code> (Level of Detail). So, for example, objects further away from the camera will use lower-quality textures, saving computation power and also preventing other problems, such as <a href="https://en.wikipedia.org/wiki/Moir%C3%A9_pattern">Moiré patterns</a>. The programmer is able to specify in the shader whether they sample from the original texture (level 0), or from these lower-quality textures (level 1, 2, 3&hellip;, etc.). In case the <code>LOD</code> isn&rsquo;t specified in non-fragment stages of the pipeline (i.e. implicit LOD sampling), the LOD level is considered zero in the Nintendo Switch. Since other GPU drivers don&rsquo;t necessarily behave this way, epicboy simply ensured that this always happens.</p> <p>While this change doesn&rsquo;t necessarily translate as a performance or graphic improvement, it guarantees the code ran among different GPU vendors matches the behaviour of the console.</p> <p>Morph updated the <a href="https://github.com/yuzu-emu/yuzu/pull/7120">dynarmic external dependency</a> to use the CPU cache invalidation fixes submitted by Blinkhawk to <a href="https://github.com/yuzu-emu/yuzu/pull/7173">perform ranged invalidations when unmapping code memory</a>.</p> <p>Memory usually gets invalidated when unloading from memory <code>NROs</code> (Nintendo Relocatable Object), which are dynamic libraries utilized by a variety of titles. These changes should alleviate (but not completely solve) the crashes that occur when titles swap NROs in-and-out of memory, such as the case of <code>Super Smash Bros. Ultimate</code>.</p> <p>Some games would crash if the user had a profile picture set in yuzu. <a href="https://github.com/german77">german77</a> discovered that this happened when the image&rsquo;s dimensions were greater than <code>256x256</code>. To avoid the crash, he made it so that <a href="https://github.com/yuzu-emu/yuzu/pull/7246">yuzu now resizes big profile pictures</a> to fit the allowed dimensions instead.</p> <p>On Linux, opening the Configuration Window and pressing the <code>OK</code> button would lead consistently to a crash. <a href="https://github.com/MightyCreak">MightyCreak</a> found the cause of this problem and submitted a patch to <a href="https://github.com/yuzu-emu/yuzu/pull/7186">solve it</a>.</p> <p>Another linux-only crash would happen when inputting text on <code>The Legend of Zelda: Breath of the Wild</code>. Morph investigated the problem and found it was caused by an out-of-bounds access in the string buffer, so <a href="https://github.com/yuzu-emu/yuzu/pull/7172">he added the necessary checks</a> to prevent it.</p> <h2 id="ui-changes">UI changes</h2> <p>On the way to achieve better high DPI support, <a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7122">updated the version of Qt</a> used by yuzu. This will allow in the near future to finally have legible UI elements on high DPI settings.</p> <p>MightyCreak has arrived with several internal changes, most helping with the build process of yuzu. One of them is <a href="https://github.com/yuzu-emu/yuzu/pull/7174">enabling mouse cursor auto-hide by default</a>, a very welcome quality of life change, especially now that more users will be playing their games in fullscreen. Thanks!</p> <p>Linux gamepad users will no longer have to periodically tap their mouse to avoid the screensaver from taking over their screens! toastUnlimited <a href="https://github.com/yuzu-emu/yuzu/pull/6702">properly disabled the screensaver while running yuzu</a>.</p> <p><a href="https://github.com/Moonlacer">Moonlacer</a> continues polishing the text strings in the UI, this time helping new users <a href="https://github.com/yuzu-emu/yuzu/pull/7165">understand what our <code>NVDEC</code> (video decoding) options do</a>.</p> <p>Some users tend to think that NVDEC means that video decoding will only work on NVIDIA GPUs, this is not the case. NVDEC is the name of the module in the Nintendo Switch, which uses the Tegra X1, an NVIDIA SoC (System on a Chip). This SoC uses the NVDEC module to decode videos, and the work yuzu has to do is emulate it to work on any compatible system, including systems without NVIDIA GPUs on them. We have a full explanation <a href="https://yuzu-mirror.github.io/entry/yuzu-nvdec-emulation/">here</a>.</p> <p>So, for the sake of clarity, the options were renamed to better convey the intended result:</p> <ul> <li><code>No Video Output</code> will result in a black screen every time a video wants to render, nothing is displayed, no fun.</li> <li><code>CPU Video Decoding</code> means processing videos using the CPU. This can be useful for AMD Windows users, since the AMD driver is notorious for having bad VP9 video decoding performance on Vega and newer GPU series, and using the CPU to render could be both faster and more accurate.</li> <li><code>GPU Video Decoding</code> means actually using the GPU&rsquo;s decoding capabilities to process videos. This is considerably faster than CPU decoding and is the default option. If a video format is not compatible with the user’s GPU, yuzu’s NVDEC emulation will automatically fallback to CPU decoding.</li> </ul> <p>For some time, we were wondering why the Switch had an open spot in its language selection. Turns out, with the release of <code>Mario Party Superstars</code>, Nintendo added support for Brazilian Portuguese! Morph <a href="https://github.com/yuzu-emu/yuzu/pull/7244">rushed to add support for it in yuzu</a>. Our game language selection menu can be found at <code>Emulation &gt; Configure… &gt; System &gt; System &gt; Language</code>. Jogo bonito on your gameplay sessions!</p> <p>The text on the TAS configuration window looked cramped, so <a href="https://github.com/behunin">Behunin</a> edited the <a href="https://github.com/yuzu-emu/yuzu/pull/7147">UI file and reformatted the text</a> to make it easier to read. Later, <a href="https://github.com/Moonlacer">Moonlacer</a> added to these changes by <a href="https://github.com/yuzu-emu/yuzu/pull/7197">fixing some grammar nits and adding a hyperlink</a> that links to the guide on our site.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="tasbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/tasbug_hub55b1a986939a53b04162f772c0e2059_15400_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> <div class="column is-bottom-paddingless"> <a href="tasfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/tasfix_hua0c0d9fed859bce3b6911b635aaf4e92_16295_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> </p> <p>Moonlacer also <a href="https://github.com/yuzu-emu/yuzu/pull/7223">fixed a problem with the per-game configuration window</a>, where scaling the monitor over 100% would squash the window.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="csbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/csbug_hu82b28f53f9ff904d543b036769fc42b1_252197_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> <div class="column is-bottom-paddingless"> <a href="csfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/csfix_hu200a7e1631d5bad3ad4cd8212f74b669_280918_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> </p> <h2 id="input-changes">Input changes</h2> <p>When <a href="https://github.com/yuzu-emu/yuzu/pull/7142">german77</a> added <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/#input-changes">auto-centering support all the way back in July</a>, the range of the new center wasn’t considered, making the analog sticks overpass 100% in a direction while failing to reach it in the opposite way. <a href="https://github.com/yuzu-emu/yuzu/pull/7142">Scaling the value of the range depending on the offset applied when centering</a> solves this issue.</p> <h2 id="future-projects">Future projects</h2> <p>With the resolution scaler finished, our GPU devs have space to breathe, and they can focus back on work that was reserved for later. <code>Project Y.F.C</code> is an example. In Blinkhawk’s words, “there&rsquo;ll be Chicken Nuggets for everyone soon, a.k.a. it will cover many different things.”</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wol.png" title="Lifelight intensifies (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2021/wol_hu6b6943eb6044d07a2009211dc32b200f_2945024_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Lifelight intensifies (Super Smash Bros. Ultimate)"></a> <p class="has-text-centered is-italic has-text-grey-light">Lifelight intensifies (Super Smash Bros. Ultimate)</p> </div> </div> <p><code>Project Gaia</code> is advancing very well, and <code>Project Kraken</code> (our Input Rewrite) <a href="https://github.com/yuzu-emu/yuzu/pull/7255">is out</a> but didn’t make it in time for this progress report. Don&rsquo;t worry, we will discuss it next time!</p> <p>That’s all folks! Thank you so much for your attention and see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> </p> New Feature Release - Resolution Scaler https://yuzu-mirror.github.io/entry/yuzu-art/ Sun, 24 Oct 2021 07:12:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-art/ <p>Hey there, yuz-ers! For those of you eager to go beyond the limits of Switch hardware and experience the full potential of Switch games, the wait has finally ended. Our most requested and anticipated feature — the <strong>Resolution Scaler</strong> — is finally here!</p> <p>Hey there, yuz-ers! For those of you eager to go beyond the limits of Switch hardware and experience the full potential of Switch games, the wait has finally ended. Our most requested and anticipated feature — the <strong>Resolution Scaler</strong> — is finally here!</p> <p> </p> <p>This new and massively improved <strong>Resolution Scaler</strong> is now available in the latest yuzu Early Access builds.<br> We will be working diligently towards bringing this exciting new feature to our Mainline builds as soon as it&rsquo;s ready for a full release.</p> <article class="message is-danger"> <div class="message-body" style="color:#f14668"><b>Latest Nvidia drivers are causing rendering issues with OpenGL. Please make sure to use the last known good driver: 472.12</b></div> </article> <article class="message is-warning"> <div class="message-body" style="color:#ffc107"><b>All following images have large file sizes when expanded. Please consider if on a Metered Connection.</b></div> </article> <h2 id="what-is-resolution-scaler">What is Resolution Scaler?</h2> <p>Resolution Scaler is a new yuzu feature, which scales the dimensions of textures that Switch games render to, and then renders the games at the scaled resolution. This allows games that were designed to render at lower resolutions (720p/900p/1080p), to go far beyond what was intended and be played at much higher resolutions (2K/4K/8K) in the same window!</p> <p>The massive undertaking to reimplement this complex feature was only possible thanks to the combined efforts of our talented developers <a href="https://github.com/FernandoS27"><strong>Blinkhawk</strong></a>, <a href="https://github.com/breadfish64"><strong>BreadFish</strong></a>, <a href="https://github.com/ameerj"><strong>epicboy</strong></a>, and <a href="https://github.com/reinuseslisp"><strong>Rodrigo</strong></a>.</p> <p>  <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./metroid_dread.png" title="Metroid Dread (4x)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/metroid_dread_hua7fe460ad658f0f0eb308ef48e0bc77f_13446256_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (4x)"></a> <p class="has-text-centered is-italic has-text-grey-light">Metroid Dread (4x)</p> </div> </div> </p> <h2 id="old-scaler">Old Scaler</h2> <p>Blinkhawk implemented the original Resolution Scaler back in July of 2019. However, the approach he took to achieve that was a bit different. It was inspired by <a href="https://cemu.info/"><strong>Cemu&rsquo;s</strong></a> graphic packs, but rather than having a manual graphics pack developed for each title, it would automatically generate scaling profiles as the user played.</p> <p>The generation algorithm used a database that recorded texture types and whether they were scalable or not. The database was initially empty and, as the game ran, the algorithm would keep learning which textures to scale and which not to. This approach was necessary, because of how yuzu was initially designed.</p> <p>Originally, yuzu&rsquo;s memory reads were <code>reactive</code> — meaning textures were downloaded only when games tried to read them and hence it wasn&rsquo;t possible to know which textures were going to be downloaded.</p> <p>Although these memory reads were fixed a few months later, the Scaler still needed changes to be made to the management of uniform buffers, so that it would be supported on drivers other than Nvidia. However, the planned rewrites of the <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/"><strong>Texture Cache</strong></a>, <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/"><strong>Buffer Cache</strong></a>, and the massive GPU emulation overhaul with <a href="https://yuzu-mirror.github.io/entry/yuzu-hades/"><strong>Project Hades</strong></a> further delayed developers from working on the Scaler, resulting in it never getting merged.</p> <p>  <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="aoc1x.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/aoc1x_hu6750194acdd6dec7e398869f2880ad5c_4294494_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors: Age of Calamity (1x Vs. 3x)"></a> </div> <div class="column is-bottom-paddingless"> <a href="aoc3x.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/aoc3x_hu60b94c369c8c9720b7946a0454bfc58a_19400042_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors: Age of Calamity (1x Vs. 3x)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hyrule Warriors: Age of Calamity (1x Vs. 3x)</p> </p> <h2 id="enter-project-art">Enter Project ART</h2> <p>Once all of the heavy lifting subsided, Blinkhawk quickly went back to working on the Resolution Scaler and instead of continuing work on the original scaler, he decided to rewrite it from the ground up.</p> <p>Learning from the experiences of the original, Blinkhawk designed and created the new scaling system, which took a significant amount of time and effort. He initially researched and experimented with a lot of different design approaches and learned their challenges, before finally landing on this new scaling system.</p> <br> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/botwbilinearzoom_hu3bfde729f9128864194207c65b2a68fc_3750078_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild (Bilinear Vs. FSR @ 2x)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/botwfsrzoom_hu807e78a74f12de1ec8aa37506447de5e_2673945_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild (Bilinear Vs. FSR @ 2x)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild (Bilinear Vs. FSR @ 2x)</p> <p>Unlike the original scaler, which was inspired by Cemu&rsquo;s profile-based scaling, Project ART uses a rating system. The meticulously designed rating system works by having a set of rules dictating which <code>render targets</code> can be scaled and having a rating for each texture. We couldn&rsquo;t simply use a binary &ldquo;YES/NO&rdquo; system because, unbeknownst to us, some games may render textures only once. Scaling these is pointless and has the potential to break them.</p> <p>For the uninitiated, <a href="https://en.wikipedia.org/wiki/Render_Target"><strong>render targets</strong></a> are just textures that the game renders to. Textures can only earn <code>1</code> credit per frame. And to earn that <code>1</code> credit, the texture itself as well as any other textures in that renderpass, all need to satisfy our set of rules. After accruing <code>2</code> or more credits, the texture will be scaled and now all rendering will be done in the scaled resolution for that texture.</p> <p>The textures keep earning more credits as frames pass. But if in any frame, even a single texture within a renderpass fails to satisfy the set of rules, all texture scores will be reset to <code>0</code>. If a texture interacts with other textures, its new rating will either be based on the current rating of those textures or will be increased to the maximum possible rating, if one of those textures is already scaled.</p> <br> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/dread_bilinear_zoom_hu6542f3e19365a57537f2968133a91146_1920015_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (Bilinear Vs. FSR @ 2x)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/dread_fsr_zoom_hu8ddbb4c990c46b5fb012ec121d00b3de_1409273_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Metroid Dread (Bilinear Vs. FSR @ 2x)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Metroid Dread (Bilinear Vs. FSR @ 2x)</p> <h2 id="the-rest-of-the-puzzle-pieces">The Rest of the Puzzle Pieces</h2> <p>After the scaling system was ready, Rodrigo helped implement the shader patching required for scaling. This was needed to ensure shaders behaved properly when textures were scaled.</p> <p>While Blinkhawk was working on improving scaling in Vulkan and the texture cache, epicboy was working in parallel to add scaling support on the OpenGL side. But little did they know, their bug squashing crusade was just about to begin.</p> <p>As scaling is intrusive, bugs can occur in a myriad of ways. Scaling occurs when games load in textures, which is usually during loading screens, but the visual bugs tend to happen later during gameplay. This makes it quite hard to figure out where the bug originally manifested.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smp1x.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/smp1x_hu40be40745cbf293254d6e68fe0f31b74_3356223_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Party (1x Vs. 3x)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smp3x.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/smp3x_hu3fce8cf3650005ff277118a9fdf1bb4c_16515346_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Party (1x Vs. 3x)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Party (1x Vs. 3x)</p> <p>Fast-forward a few weeks, and thanks to continuous iterative internal testing, our developers were finally able to fix most of the bugs they came across.</p> <p>With much of the scaler work nearly being done, Blinkhawk ported some texture filters from Citra and adapted those to be scaling filters for yuzu. BreadFish later tuned them and also added a little something extra, AMD&rsquo;s <a href="https://www.amd.com/en/technologies/radeon-software-fidelityfx-super-resolution"><strong>FidelityFX™ Super Resolution</strong></a> (FSR)!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo1x.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/smo1x_hu74d3629948bea5d3c3af3712f3ad56b9_3905692_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (1x Vs. 3x)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo3x.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/smo3x_hubdc8eca32926903c779ce0d8e6896dad_17824972_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (1x Vs. 3x)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (1x Vs. 3x)</p> <h2 id="benefits-of-project-art">Benefits of Project ART</h2> <p>The feature-set of Project ART includes the following:</p> <ul> <li>Native Resolution Scaling: <ul> <li><strong>Upscaling</strong> (2x, 3x, 4x, 5x, 6x) and <strong>Downscaling</strong> (0.5x, 0.75x).</li> </ul> </li> <li>FXAA Pre-filtering Pass</li> <li>Fixed various bugs introduced from the Texture Cache Rewrite (TCR).</li> <li>Window Adaptation Filters</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./filters.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/filters_hud6d478e00299c7d27a92ea7602413b16_109661_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <br> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/mk8bilinearzoom_hu885ac1f655081c796a5581c29af71f09_3968667_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe (Bilinear Vs. FSR @ 2x)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/mk8fsrzoom_hu888d10fd8882f28b9ff91ac018873fe2_2263151_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe (Bilinear Vs. FSR @ 2x)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mario Kart 8 Deluxe (Bilinear Vs. FSR @ 2x)</p> <h2 id="what-to-expect-from-project-art">What to expect from Project ART</h2> <p>The Resolution Scaler requires much more VRAM as compared to games running at their native resolutions. Here are some minimum and recommended values based on our testing:</p> <center><img src="./scaling.png" width="500"></img></center> &nbsp; <p>Upscaling works with most games! We currently know of two games that don&rsquo;t upscale - <code>Paper Mario: The Origami King</code> and <code>Crash Bandicoot 4: It's About Time</code>. These games are incompatible because they use a compute shader to render an image, which is challenging to work around. However, thanks to mods, <code>Paper Mario: The Origami King</code> can be upscaled with a workaround discussed below.</p> <p>Downscaling, surprisingly, turned out to be more stable than we thought. With this, you can gain 20% or more performance at the cost of reduced quality. It works for most of the games we tested, but our testing has been limited. We currently know of one game that doesn&rsquo;t downscale (but upscales) — <code>Sonic Colors: Ultimate</code>.</p> <br> <div class="columns is-bottom-marginless"> <div class="column is-bottom-paddingless juxtapose"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/acnh%201x%2030fps_huad5cd4788bb90a84b8039365431c9cec_2750594_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Animal Crossing (1x 30FPS vs. 0.5x 36FPS)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-art/acnh%2005x%2036fps_hu53dac30b4996a9eff21a9786f4af4fdc_808040_960x0_resize_q90_bgffffff_box_3.jpg" alt="Animal Crossing (1x 30FPS vs. 0.5x 36FPS)"> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Animal Crossing (1x 30FPS vs. 0.5x 36FPS)</p> <p>Some games that have their own FXAA need a mod to disable their built-in FXAA. This is because the games use hard coded texture dimensions in their FXAA filters, which leads to poor anti-aliasing quality or artifacts. <code>Pokémon Sword/Shield</code> needs the <a href="https://github.com/yuzu-emu/yuzu/wiki/Switch-Mods#pokemon-swordshield-romfs"><strong>No Outlines</strong></a> mod for optimal picture quality, as the outlines don&rsquo;t scale correctly.</p> <p><code>Kirby Star Allies</code> is known to have an additional performance cost when upscaled. This is caused by the need to downscale textures before upscaling in order to bypass some crashes and issues in the game.</p> <p>Special thanks to our community member and modder <a href="https://github.com/theboy181">theboy181</a>, who created new mods that help with upscaling some of the games listed earlier.</p> <ul> <li><a href="https://cdn.discordapp.com/attachments/799182828038258698/901595782501781534/Paper_Mario_Origami_King_-_4K.rar">Paper Mario: The Origami King 4K</a></li> <li><a href="https://cdn.discordapp.com/attachments/799182828038258698/901595757117866045/XenoBlade_Chronicles_2_-_SuperSampling_x2.rar">Xenoblade Chronicles 2 - Super Sampling x2</a></li> </ul> <h2 id="conclusion">Conclusion</h2> <p>As we couldn&rsquo;t fully test the Resolution Scaling with the entire Switch game library, we look forward to all the user feedback we will receive. Your reports will be important in fixing bugs and polishing the Scaler to be the best experience possible.</p> <p>If you encounter any issues, bugs, or crashes, please reach out to us via our <a href="https://discord.gg/u77vRWY"><strong>Discord</strong></a> Patreon channels. We hope you love this new feature and will be back with more exciting news in the future! Happy emulating!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> <script src="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/js/juxtapose.min.js"></script> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/juxtaposejs@1.1.6/build/css/juxtapose.css"> </p> Progress Report September 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/ Mon, 11 Oct 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/ <p>Hi yuz-ers! Welcome to the latest entry of our monthly progress reports. We have even more GPU rendering fixes, TAS support, 8 player mayhem, input and UI changes, some preliminary work for future big changes, and more!</p> <p>Hi yuz-ers! Welcome to the latest entry of our monthly progress reports. We have even more GPU rendering fixes, TAS support, 8 player mayhem, input and UI changes, some preliminary work for future big changes, and more!</p> <h2 id="yet-more-amd-specific-changes-and-other-graphical-fixes">Yet more AMD specific changes and other graphical fixes</h2> <p>Certain AMD and Intel GPUs were unable to utilize yuzu&rsquo;s unlock FPS feature with the Vulkan API, due to the lack of driver support for the <code>VK_PRESENT_MODE_MAILBOX_KHR</code> presentation mode. They, however, support <code>VK_PRESENT_MODE_IMMEDIATE_KHR</code>, another mode that allows Vulkan to present at a higher framerate than the screen refresh rate, so <a href="https://github.com/ameerj">epicboy</a> made the <a href="https://github.com/yuzu-emu/yuzu/pull/7003">necessary changes</a> in order to unlock the FPS on these GPUs. Due to the nature of this presentation mode, this may cause visible tearing on the screen, so bear that in mind if you try this out.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./framerate.png" title=" And this is with just an RX 550 (Metroid Dread)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/framerate_hufbca9929c0aee4c563e79d8b7b133cfc_1511357_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" And this is with just an RX 550 (Metroid Dread)"></a> <p class="has-text-centered is-italic has-text-grey-light"> And this is with just an RX 550 (Metroid Dread)</p> </div> </div> <p>Booting a title in Linux with the Vulkan API using the Intel Mesa driver resulted in a crash due to a device loss error. The problem was in the synchronization between the rendering and subsequent presentation of frames.</p> <p>Previously, yuzu would issue the Vulkan <code>Present</code> command, then wait for the frame to be rendered before continuing with the process. While this was fine for other drivers and vendors, ANV (Intel’s Vulkan driver) expected to have the frame already rendered before this command, causing this error.</p> <p>epicboy fixed the synchronization behaviour so that <a href="https://github.com/yuzu-emu/yuzu/pull/6953">yuzu now waits until the frame is fully rendered and ready before presenting it</a>.</p> <p>With the release of AMD’s Windows driver version 21.9.1, and its equivalent AMDVLK and AMDGPU-PRO Vulkan Linux counterparts, users started noticing crashes in most games right at boot. We rushed once again to blame AMD for breaking another extension, as it wouldn’t be the first time. We even singled out <code>Int8Float16</code> as the culprit, providing an <a href="https://github.com/yuzu-emu/yuzu/pull/7006">alternative path that reduced performance on all AMD GPUs running non-RADV drivers.</a></p> <p>We were wrong.</p> <p>Turns out, it was our fault. epicboy found out that during the process of initializing Vulkan, the emulator <a href="https://github.com/yuzu-emu/yuzu/pull/7027">assigned Int8Float16’s values after its memory was freed.</a> Surprisingly, this only started affecting official AMD drivers recently, after their periodical Vulkan version update. So we had to lay down the pitchforks, <em>this time.</em> Performance returned to normal after the introduction of this PR.</p> <p>AMD Windows users are also familiar with certain stages in <code>Super Smash Bros. Ultimate</code> turning completely white or ghosting, akin to when applications <a href="https://i.stack.imgur.com/4Jh7t.jpg">would freeze</a> back in the Windows XP era. Those were the good days.</p> <p>Ahem, anyway, AMD Radeon GPUs lack support for fixed point 24-bit depth textures, or D24 for short, a relatively common texture format. To bypass this hardware limitation, yuzu uses D32 textures instead, which can cause precision issues during the conversion process. <a href="https://github.com/yuzu-emu/yuzu/pull/7070">By adjusting the Depth Bias and Polygon Offset of yuzu’s D24 emulation,</a> <a href="https://github.com/FernandoS27">Blinkhawk</a> solves the issue for good.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smashbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/smashbug_hu3cad3d3496a1b9e9ecfe5512ca9aa21d_2087765_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fair play, please (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smashfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/smashfix_hu73706acd92810e3237a0754e629ff3db_2444679_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fair play, please (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fair play, please (Super Smash Bros. Ultimate)</p> <p>Yet another AMD Radeon specific issue is visible when playing <code>The Legend of Zelda: Breath of the Wild</code>. Terrain textures were colourful and corrupted, like when a PC gamer dials up the RGB to 11.</p> <p>This issue affected our regular suspects, GCN4 devices (Polaris, RX 400/500 series) and older, running on the Windows and Linux proprietary Vulkan drivers. GCN5 (Vega), RDNA1, and RDNA2 devices were unaffected. The problem resided in how we guessed the textures were being handled by the game.</p> <p>Some information first: there are several ways to handle textures, and in this particular example we need to focus on two, <code>Cube Maps</code> and <code>Texture Arrays</code>.</p> <p>Cube maps are a cube with its six faces filled with different textures. The coordinate used to fetch the data, unlike the regular X and Y values, is a single <a href="https://en.wikipedia.org/wiki/Versor">versor</a> originating from the center and pointing to the surface of the cube.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./array.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/array_hu920f27f94bbf0db0eb0183e1a214ebcc_5896_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>Texture arrays on the other hand are just as the name implies, an ordered array of textures one after the other, with X and Y used for positioning information inside the texture, and a Z axis used to determine which texture of the array is in use.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cube.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/cube_huca32371eac8086dcb2f34036394b343a_9781_559x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>TL;DR, one is a sphere and the other is a list.</p> <p>Vulkan allows for textures to be marked for conversion into cube maps if later needed, but the sampling (reading) is determined by the texture type specified by the game’s shader instructions. This type is then passed to the graphics API. We do just this and the game decides to keep its textures as arrays, which is its own decision. However, the AMD driver decides that the textures should be sampled as cube maps, ignoring what the texture view determined just before.</p> <p>While this should not be a problem on its own, as coordinates can still be pulled out from the wrong texture type, the driver can end up reading the wrong texel. This can result in happy rainbow ground in <code>The Legend of Zelda: Breath of the Wild</code>, or as dark and evil terrain in <code>Hyrule Warriors: Age of Calamity</code>.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/7076">By disabling Cube Compatibility on GCN4 and older devices running the official AMD proprietary drivers,</a> epicboy returned proper sense to the devastated land of Hyrule.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./botwbug.png" title=" I prefer no RGB, thanks (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/botwbug_huf13585f4071f04c8891a3ac1ce6ee677_4878469_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" I prefer no RGB, thanks (The Legend of Zelda: Breath of the Wild)"></a> <p class="has-text-centered is-italic has-text-grey-light"> I prefer no RGB, thanks (The Legend of Zelda: Breath of the Wild)</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./botwfix.png" title=" But not THAT dark! (Hyrule Warriors: Age of Calamity)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/botwfix_huc0e07545264cae07449539ef5239ff9a_4521895_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" But not THAT dark! (Hyrule Warriors: Age of Calamity)"></a> <p class="has-text-centered is-italic has-text-grey-light"> But not THAT dark! (Hyrule Warriors: Age of Calamity)</p> </div> </div> <p>Speaking of RGB, <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2021/#paint-me-like-one-of-your-french-bits">as discussed back in February</a>, yuzu has to use compute shaders to convert most BGR texture formats in OpenGL to avoid mismatched colours. While this can work fine on most current GPUs, there’s a performance cost that can affect older and slower products.</p> <p>Users of Kepler series Nvidia GPUs (usually GTX 600/700 series, with several renamed 800 and 900 series too) could experience those performance penalties while also producing rendering corruptions. Instead of using compute shaders to swizzle textures, epicboy figured we could just use <code>Pixel Buffer Objects</code> <a href="https://www.khronos.org/opengl/wiki/Pixel_Buffer_Object">(or PBO for short)</a> for <a href="https://github.com/yuzu-emu/yuzu/pull/7036">all affected texture formats instead.</a> This has many benefits: it solves Kepler BGR issues, improves performance on weak devices from any GPU vendor, and is also a required change for <code>A.R.T.</code> (the resolution scaler in development).</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./keplerbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/keplerbug_hu0c8365c67d108db9df353d5144d10d8a_1321068_800x0_resize_q90_bgffffff_box_3.jpg" alt="A Hat in Time"></a> </div> <div class="column is-bottom-paddingless"> <a href="./keplerfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/keplerfix_hub87386c446c22fb30cf3bec7f22278e8_783110_800x0_resize_q90_bgffffff_box_3.jpg" alt="A Hat in Time"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">A Hat in Time</p> <p>On the subject of changes needed for the resolution scaler, Blinkhawk implemented <a href="https://github.com/yuzu-emu/yuzu/pull/7077">fixes to queries and indexed samplers.</a> The result is fewer crashes while playing <code>Luigi’s Mansion 3</code> on Intel and AMD GPUs, be it on Windows or Linux. This PR helps improve stability for <code>A.R.T.</code> as well.</p> <p>Another issue affecting <code>Luigi’s Mansion 3</code> is related to its use of <a href="https://en.wikipedia.org/wiki/Tessellation_(computer_graphics)">Tessellation Shaders</a> on Vulkan. The Vulkan specification requires the input-assembler topology to be <code>PATCH_LIST</code> in the tessellation stages. Not all games follow this, so <a href="https://github.com/yuzu-emu/yuzu/pull/7101">manually forcing it</a> solves crashes experienced in some drivers, more specifically, as you may have guessed it, AMD’s proprietary ones. All thanks to our fishy epicboy.</p> <p>epicboy has also <a href="https://github.com/yuzu-emu/yuzu/pull/7001">fixed some minor bugs with the <code>StencilOp</code></a>, a type of data buffer intended to help limit the size of the rendering area. Thanks to this, <code>WarioWare: Get It Together!</code> properly renders its models.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./waabug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/waabug_hua1ed077d95b345f6cbb6fdbe12e39cf4_571875_800x0_resize_q90_bgffffff_box_3.jpg" alt="Waa! (WarioWare: Get It Together!)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./waafix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/waafix_hu08765337d064faa05cba533ba112b1bc_584924_800x0_resize_q90_bgffffff_box_3.jpg" alt="Waa! (WarioWare: Get It Together!)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Waa! (WarioWare: Get It Together!)</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> added support for the legacy GLSL <code>gl_Color</code> and <code>gl_TexCoord</code> attributes into our Vulkan backend, so that any game that uses them can render properly when using this API.</p> <p>Both these attributes are part of a set of attributes with specific definitions and uses. But they were deprecated in newer versions of OpenGL in favour of &ldquo;generic&rdquo; attributes that the programmer can freely define as they want, based on their needs.</p> <p>While OpenGL is still able to run shaders that use this legacy feature for the sake of backwards compatibility, they were already considered obsolete by the time Vulkan was created, which means that this API lacks a fallback.</p> <p>What vonchenplus did is use generic attributes in Vulkan to emulate these features, so that they behave exactly as the legacy GLSL attributes.</p> <p>After that, vonchenplus corrected the definition of <a href="https://github.com/yuzu-emu/yuzu/pull/6980">the values in an enum</a> used for blending textures.</p> <p>Both these changes affect <code>DRAGON QUEST III: The Seeds of Salvation</code>, fixing the graphical bugs present in this game.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./dqbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/dqbug_hu3c34e31a1e3dedcba56977db14e1d472_1080021_800x0_resize_q90_bgffffff_box_3.jpg" alt="DRAGON QUEST III: The Seeds of Salvation"></a> </div> <div class="column is-bottom-paddingless"> <a href="./dqfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/dqfix_hu7a76ba4e3f0a987c7e0f578a6b6249d0_991289_800x0_resize_q90_bgffffff_box_3.jpg" alt="DRAGON QUEST III: The Seeds of Salvation"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">DRAGON QUEST III: The Seeds of Salvation</p> <h2 id="tool-assisted-speedrun">Tool-assisted speedrun</h2> <p><a href="https://github.com/MonsterDruide1">MonsterDruide1</a> has added <a href="https://github.com/yuzu-emu/yuzu/pull/6485">TAS support</a> to yuzu! This means precise input commands can be recorded and replayed in-game. The format used to store them is the one <a href="https://github.com/hamhub7/TAS-nx/tree/master/scripts">TAS-nx</a> implemented, and we have a guide on <a href="https://yuzu-mirror.github.io/help/feature/tas/">how to enable and use this feature here.</a></p> <p>You can access TAS configuration by going to <code>Tools &gt; Configure TAS…</code></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tas.png" title=" TAS Configuration window"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/tas_hu1290e8e13f946ea1cbbbbb244570b5cc_15125_414x0_resize_q90_bgffffff_box_3.jpg" alt=" TAS Configuration window"></a> <p class="has-text-centered is-italic has-text-grey-light"> TAS Configuration window</p> </div> </div> <h2 id="other-input-changes">Other input changes</h2> <p>Let’s start with a nice addition by <a href="https://github.com/german77">german77</a> that will make <code>Super Smash Bros. Ultimate</code> players happy, and Parsec users especially so. There’s now an option to enable <a href="https://github.com/yuzu-emu/yuzu/pull/6950">8 player support</a> for XInput devices, at the cost of disabling the Web Applet. A small price to pay for epic fights with your friends.</p> <p>You can find the option in <code>Emulation &gt; Configure… &gt; Controls &gt; Advanced &gt; Enable XInput 8 player support (disables web applet)</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./8.png" title=" yuzu Controls configuration window"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/8_huf54355b8df7c4df96bf002e7e00d5046_30961_1019x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Controls configuration window"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Controls configuration window</p> </div> </div> <p><a href="https://github.com/v1993">v1993</a> later <a href="https://github.com/yuzu-emu/yuzu/pull/7042">hid the option for non-Windows OSes</a>, as this limitation doesn’t apply outside the Windows SDL builds.</p> <p>Linux kernel drivers for Joy-Cons use a different naming convention than the ones we use on Windows. <a href="https://github.com/yuzu-emu/yuzu/pull/6979">Properly following this convention makes the Dual Joy-Con input show up in the device list.</a> german77 thinks of the penguins.</p> <h2 id="ui-changes">UI changes</h2> <p>With the release of <a href="https://yuzu-mirror.github.io/entry/yuzu-hades/">Project Hades</a>, yuzu started using a full <code>Pipeline cache</code> instead of single stages of the graphics pipeline, both in Vulkan and OpenGL. This means parts of our UI were outdated, so <a href="https://github.com/goldenx86">your degenerate writer</a> decided to simply <a href="https://github.com/yuzu-emu/yuzu/pull/6976">update the context menu entries</a> from Shader cache to Pipeline cache.</p> <p>Following suit, <a href="https://github.com/Moonlacer">Moonlacer</a> helped <a href="https://github.com/yuzu-emu/yuzu/pull/6977">replace <code>Use disk shader cache</code> with <code>Use disk pipeline cache</code></a>. ¡Gracias!</p> <p>Later on, Moonlacer <a href="https://github.com/yuzu-emu/yuzu/pull/7020">removed the toggle</a> for <code>Enable audio stretching</code> from the audio settings, as it no longer had any purpose. As a general rule, the fewer options available, the better.</p> <p>Morph decided to <a href="https://github.com/yuzu-emu/yuzu/pull/7102">eliminate a 2 year old feature,</a> <a href="https://yuzu-mirror.github.io/entry/yuzu-boxcat/">boxcat</a>.</p> <p>BCAT is a network service used by the Nintendo Switch to add content to its games without needing constant updates. Our old BCAT implementation only added some “gifts” our developers placed into games that were playable at the time. It was unable to support real use cases, like the game updates <code>Animal Crossing: New Horizons</code> regularly pushes.</p> <p>While the plan is to add support for this in the future, major changes to the file system emulation need to come first.</p> <p><a href="https://github.com/behunin">behunin</a> implemented much needed <a href="https://github.com/yuzu-emu/yuzu/pull/7068">clean ups to our debug configuration window.</a> View the results below:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./debugbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/debugbug_hu54e4e3ca60dab6c5cd8cf31499506332_107568_800x0_resize_q90_bgffffff_box_3.jpg" alt="Before and After, Debug configuration settings"></a> </div> <div class="column is-bottom-paddingless"> <a href="./debugfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/debugfix_hu2f474a9ac5c964b236cc5f9d62943584_99196_800x0_resize_q90_bgffffff_box_3.jpg" alt="Before and After, Debug configuration settings"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Before and After, Debug configuration settings</p> <h2 id="general-bugfixes">General bugfixes</h2> <p>epicboy noticed a memory leak that would grow progressively after stopping and restarting the emulation, which was caused by yuzu’s <code>main_process</code> not being cleaned up. <a href="https://github.com/yuzu-emu/yuzu/pull/7009">By destroying this process when stopping emulation</a>, the resources are properly freed now, fixing the leak.</p> <p>Additionally, epicboy also mitigated the crashes that happened when emulation was stopped by <a href="https://github.com/yuzu-emu/yuzu/pull/7019">using std::jthread for worker threads</a>.</p> <p><code>std::jthread</code> is a <a href="https://en.cppreference.com/w/cpp/thread/jthread">new implementation of the thread class that was recently introduced in C++20</a>, which alleviates their management and usage, since they simplify some of the synchronization challenges inherent to multithreading.</p> <p>With this change, the number of crashes caused by race conditions between working threads upon shutdown was supposed to decrease, but it also introduced a new bug that would cause yuzu to hang when the emulation was stopped.</p> <p>This problem was caused by the order in which objects were being destroyed, which epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/7078">fixed in a follow-up PR</a>.</p> <p><a href="https://github.com/bunnei">bunnei</a> also <a href="https://github.com/yuzu-emu/yuzu/pull/6965">introduced std::jthreads into the cpu_manager</a>, in favour of using this more efficient implementation of the class for yuzu&rsquo;s host threads.</p> <p>He also made changes so that the KEvents used in the nvflinger <a href="https://github.com/yuzu-emu/yuzu/pull/6968">service</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/6971">queue</a> are owned by these services, instead of being owned by the process for the emulated game, which makes the implementation more accurate.</p> <p>We’ve been trying to focus on improving our homebrew support, as this isn’t just a powerful tool that only developers use. For example, modders have very powerful homebrew apps that the Switch community enjoys. One important example is <a href="https://github.com/ultimate-research/UltimateModManager">UltimateModManager</a>, or UMM for short, which refuses to work on yuzu for now.</p> <p>To counter this, <a href="https://github.com/ogniK5377">ogniK</a> allowed homebrew running in yuzu to <a href="https://github.com/yuzu-emu/yuzu/pull/6974">also create subdirectories instead of just the parent directory</a>, resulting in UMM managing to at least start. This is a temporary solution until our much needed filesystem rewrite is finished. Additionally, <a href="https://github.com/Morph1984">Morph</a> pushed a <a href="https://github.com/yuzu-emu/yuzu/pull/7010">partial implementation of the <code>GetFileTimeStampRaw</code> function,</a> removing several warnings.</p> <p>This isn’t enough to allow full UMM compatibility, but we’re getting there.</p> <p>Moving on to a quality-of-life change, some games pop-up a confirmation window when trying to stop emulation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./exit.png" title=" Like this, End emulation confirmation window"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/exit_hudbd14da1147c6ed437dd1c24692a8c7e_7560_415x0_resize_q90_bgffffff_box_3.jpg" alt=" Like this, End emulation confirmation window"></a> <p class="has-text-centered is-italic has-text-grey-light"> Like this, End emulation confirmation window</p> </div> </div> <p>This kind of redundant question is generated by the game itself and while we always had a toggle to skip it, it wasn’t working properly. epicboy comes to the rescue, <a href="https://github.com/yuzu-emu/yuzu/pull/6997">fixing the toggle</a> for good and saving us precious seconds in quitting our games.</p> <p>If you wish to change this behaviour, the option is in <code>Emulation &gt; Configure… &gt; General &gt; Confirm exit while emulation is running</code>.</p> <p>v1993 <a href="https://github.com/yuzu-emu/yuzu/pull/7075">moved all QtWebEngine data to a more organized centralized folder,</a> improving consistency and reducing clutter from the user’s storage. Instead of a separate folder in <code>%localappdata%</code>, information is now saved in yuzu’s directory, <code>%appdata%\yuzu\qtwebengine</code> by default.</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> <a href="https://github.com/yuzu-emu/yuzu/pull/7018">performed his first stubbing surgery with the audio input services <code>Start</code>, <code>RegisterBufferEvent</code>, and <code>AppendAudioInBufferAuto</code></a>. This way, <code>Splatoon 2</code> can now be played via <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/#lan-party-time">LAN</a> without requiring the use of auto-stub. Happy splatting!</p> <p>german77 <a href="https://github.com/yuzu-emu/yuzu/pull/6992">stubbed <code>SetTouchScreenConfiguration</code> and implemented <code>GetNotificationStorageChannelEvent</code></a> to make <code>Dr Kawashima's Brain Training for Nintendo Switch</code> playable.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./brain.png" title=" Dr Kawashima&#39;s Brain Training for Nintendo Switch"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/brain_hu5f76972ce26d6461518f81c37dfb0841_1193144_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Dr Kawashima&#39;s Brain Training for Nintendo Switch"></a> <p class="has-text-centered is-italic has-text-grey-light"> Dr Kawashima&#39;s Brain Training for Nintendo Switch</p> </div> </div> <p>He has also <a href="https://github.com/yuzu-emu/yuzu/pull/7015">stubbed <code>Match</code></a> to make <code>Cruis'n Blast</code> playable. This game experiences some crashes, so there’s more work to do.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./blast.png" title=" Cruis&#39;n Blast"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/blast_hu4d70e92df426d5a49ec273cc89aeb49a_2961115_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Cruis&#39;n Blast"></a> <p class="has-text-centered is-italic has-text-grey-light"> Cruis&#39;n Blast</p> </div> </div> <p>ogniK <a href="https://github.com/yuzu-emu/yuzu/pull/6975">implemented the <code>EnsureTokenIdCacheAsync</code> function,</a> making <code>Death Coming</code> go in-game, albeit with some graphical bugs that we have to sort out in the future.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./death.png" title=" Death Coming"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/death_hu120ee96626b8ff607add2cc8748dafd1_2816897_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Death Coming"></a> <p class="has-text-centered is-italic has-text-grey-light"> Death Coming</p> </div> </div> <p>Morph has been working on implementing what is needed to get <code>Diablo II: Resurrected</code> working. Initially, the <a href="https://github.com/yuzu-emu/yuzu/pull/7082"><code>Read</code> socket service was implemented</a>, but this mandates also implementing more complex services like <code>Select</code> and <code>EventFD</code>. <code>EventFD</code> is particularly tricky as there is no native support for it on Windows, so a considerable amount of work is needed to properly emulate it in the most popular OS.</p> <p>As a temporary alternative, <a href="https://github.com/yuzu-emu/yuzu/pull/7085">Read was just stubbed</a>, allowing the game to boot.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./diablo.png" title=" Diablo II: Resurrected"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/diablo_huaea0704d7ed08fc84eec4c59d7c4a88d_2166201_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Diablo II: Resurrected"></a> <p class="has-text-centered is-italic has-text-grey-light"> Diablo II: Resurrected</p> </div> </div> <h2 id="future-projects">Future projects</h2> <p>For anyone wondering about <code>Project A.R.T.</code>, the following image speaks for itself.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./art.png" title=" Xenoblade Chronicles Definitive Edition"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2021/art_huca2967bee837b21824c48b3c2699c593_16950267_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Xenoblade Chronicles Definitive Edition"></a> <p class="has-text-centered is-italic has-text-grey-light"> Xenoblade Chronicles Definitive Edition</p> </div> </div> <p>Regarding works in progress, there are more rendering fixes underway, and we’re already starting plans on what to focus on after <code>A.R.T.</code> is finished.</p> <p>That’s all folks! Thank you for your attention and see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report August 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/ Sun, 12 Sep 2021 12:00:00 -0300 Honghoa https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/ <p>Welcome, yuz-ers, to our monthly report of developer perseverance and other happenings! In this recap, we&rsquo;ll discuss Radeon fixes, Reaper v3, LAN support, smooth video rendering, and more!</p> <p>Welcome, yuz-ers, to our monthly report of developer perseverance and other happenings! In this recap, we&rsquo;ll discuss Radeon fixes, Reaper v3, LAN support, smooth video rendering, and more!</p> <h2 id="another-terrible-implementation-and-other-graphical-fixes"><strong>A</strong>nother <strong>T</strong>errible <strong>I</strong>mplementation, and other graphical fixes</h2> <p>This month was certainly a happy one for AMD users, as our developers managed to fix a number of graphical bugs present for those with AMD graphics cards.</p> <p><a href="https://github.com/ameerj">epicboy</a> pushed a <a href="https://github.com/yuzu-emu/yuzu/pull/6900">fix for the wireframe issue</a> affecting various 3D models when playing <code>Pokémon Sword and Shield</code> while using an AMD GPU on Windows. Unfortunately, some games, like <code>Super Mario 3D World + Bowser's Fury</code>, have similar bugs which were not improved by this fix. Also, do note that, in some rare cases and conditions, the issue can still occur.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./wirebug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/wirebug_huc62f823e3ccb3460b2e957ab52cdcf87_1741628_800x0_resize_q90_bgffffff_box_3.jpg" alt="Best character (Pokémon Sword)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./wirefix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/wirefix_hu5168c55792f5659c59520cf4533b9637_1670799_800x0_resize_q90_bgffffff_box_3.jpg" alt="Best character (Pokémon Sword)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Best character (Pokémon Sword)</p> <p>The cause of the problem boils down to the drivers of <em>a certain vendor</em> (AMD) not properly reading shader attributes near a <code>demote</code> or <code>discard</code> instruction.</p> <p>Among the many programs that run on the GPU to render graphics, fragment shaders are in charge of calculating the colour of every pixel written into the frame-buffer that will be sent to your screen. In some cases, these shaders are used to perform subordinate calculations instead, such as derivatives.</p> <p>This is a problem, however, as fragments shaders are <em>always</em> expected to write into the frame-buffer. When used like this, the colour data of these shader instances remains uninitialized, which is undefined behaviour that will most likely result in rainbow-puke graphics being sent to your screen.</p> <p>This is where the <code>demote</code> and <code>discard</code> instructions come in to the rescue. They are used to mark these fragment shaders, so that the colour of every shader instance that is demoted is ignored, keeping the thread alive to perform calculations while the frame-buffer remains untouched.</p> <p>Whenever the driver tried to read attributes (i.e. data such as positions, normals, etc.) in the proximity of these instructions, it would misread them, causing the infamous graphical glitch.</p> <p>Thankfully, this was fixed by simply delaying the demotion of these fragments to the end of the shader program, which has a slight impact on their performance, albeit not one big enough to be concerned.</p> <p>Next on epicboy&rsquo;s list, we have a <a href="https://github.com/yuzu-emu/yuzu/pull/6941">fix that solves the brightness of sRGB graphics</a> when rendering from a secondary GPU, since they looked much darker than they should.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./presentationbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/presentationbug_hu714a47d94fab05174b2a8361efa7d313_1052116_800x0_resize_q90_bgffffff_box_3.jpg" alt="Free HDR! (Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./presentationfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/presentationfix_hufbae919a9ee47aa2dc1f5489a014d38a_1155535_800x0_resize_q90_bgffffff_box_3.jpg" alt="Free HDR! (Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Free HDR! (Super Mario Odyssey)</p> <p>This occurred when the rendering was performed by an AMD GPU, but the presentation of images from the <a href="https://en.wikipedia.org/wiki/Swap_chain">swap chain</a> (the virtual buffers used by the GPU to prevent tearing and stuttering when updating your screen) was done by an Intel or Nvidia GPU. The swap chains that were being rendered on the AMD GPU, which contained images in <code>sRGB</code> format, were being read as <code>Linear</code> on the secondary GPU, causing them to be presented with erroneous intensity levels. This is because the scales used in these formats are incompatible, and their values do not automatically map to an equivalent value on their counterpart space, resulting in a quality degradation of the image when using the wrong format.</p> <p>As a solution, the <code>Linear</code> colour space format is now preferred when presenting frames from the swap chain. This alleviates the wrong interpretation of the frame&rsquo;s format, allowing all frames to display properly in the linear colour space.</p> <p>Another annoying Windows-only AMD GPU bug gone for good thanks to epicboy is <a href="https://github.com/yuzu-emu/yuzu/pull/6948">the horrible bright squares</a> that would appear in the shading of a number of titles: most notably, <code>Fire Emblem: Three Houses</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./fethbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./fethfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Not so psychedelic any more (Fire Emblem: Three Houses)</p> <p>The cause of this problem lies at the hardware-level differences between the GPU of the Nintendo Switch, and that of AMD cards.</p> <p>In graphics programming, it&rsquo;s extremely common to perform the same operation over a considerable number of elements — such as vertices, pixels, etc. GPUs were, thus, designed to operate over large amounts of data at the same time (i.e. in parallel), using instructions that exploit this principle, known as <code>SIMD</code> (<a href="https://en.wikipedia.org/wiki/SIMD">Single Instruction, Multiple Data</a>). This method of parallel computing, combined with multi-threading, is known as <code>SIMT</code> (<a href="https://en.wikipedia.org/wiki/Single_instruction,_multiple_threads">Single Instruction, Multiple Threads</a>).</p> <p>In the case of the Tegra X1 (the GPU of the Nintendo Switch), these instructions operate on bundles of 32 threads (called <code>workgroups</code>), all of which run the same code — although they do not necessarily operate on the same data. The <code>SIMT</code> instructions in AMD cards post the <a href="https://en.wikipedia.org/wiki/Graphics_Core_Next"><code>GCN</code> architecture</a>, however, only work with workgroups of 64 threads. This presented a challenge, as yuzu had to divide these workgroups of 64 threads and make them behave as two workgroups of 32 threads in order to properly emulate the guest GPU on these devices.</p> <p>epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/6948">addressed this problem</a> and fixed these instructions, so that by using the thread&rsquo;s invocation ID, it&rsquo;s possible to tell whether any thread is part of the &ldquo;lower&rdquo; or &ldquo;upper&rdquo; 32-thread group, effectively allowing AMD cards to emulate the behaviour of the Nintendo Switch GPU.</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> has also contributed a number of fixes for bugs affecting AMD, starting with <a href="https://github.com/yuzu-emu/yuzu/pull/6943">disabling a vulkan extension</a> (<code>VK_EXT_SAMPLER_FILTER_MINMAX</code>) in their GPUs prior to <code>GCN4</code> (Polaris), which do not have the necessary hardware to support the extension. Notably, this fixed the psychedelic graphics in <code>The Legend of Zelda: Skyward Sword HD</code>, one that many of us will miss, for sure.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./sshdbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/sshdbug_hu557fcad7a3ea8809418c4d1806a05946_1963876_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was originally a video, but it could have triggered epilepsy (The Legend of Zelda: Skyward Sword)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sshdfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/sshdfix_hu162189b5e306e9683a6bc9bb6b65114d_1965027_800x0_resize_q90_bgffffff_box_3.jpg" alt="This was originally a video, but it could have triggered epilepsy (The Legend of Zelda: Skyward Sword)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This was originally a video, but it could have triggered epilepsy (The Legend of Zelda: Skyward Sword)</p> <p>On a similar vein, <a href="https://github.com/yuzu-emu/yuzu/pull/6944">he increased the number of sets per pool on AMD</a> (a feature used in Vulkan to manage the memory of resources), fixing the random crashes that occurred when booting <code>Xenoblade Chronicles 2</code>.</p> <p><a href="https://github.com/K0bin">K0bin</a> is back again, fixing another major issue. This time, yuzu was not following the official Vulkan specification correctly, leading to overlapping information for textures and buffers on Nvidia graphics cards.</p> <p><code>bufferImageGranularity</code> specifies the size in bytes at which textures and buffers can be aligned. AMD and Intel GPUs allow for pretty precise values of 1 or 64 bytes depending on the hardware, but Nvidia on the other hand is hard limited to a 1024 byte block.</p> <p>yuzu didn’t take this alignment into consideration, leading to data corruption primarily shown by <code>Super Mario Odyssey</code> with and without the GPU cache garbage collector enabled. But the same issue could affect any game that handles small textures at any time, as any buffer could corrupt any texture, and any texture could corrupt any buffer.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6834">Properly respecting this hardware set value</a> fixes unheard instabilities when running games in Vulkan with an Nvidia GPU, and allows Reaper, the GPU cache garbage collector, to work on all games.</p> <p>There was a bug that made Mario&rsquo;s moustache appear to be light-brown (instead of the classic dark shade we are used to seeing) when using an Intel GPU with the Vulkan API. The problem was a simple one: yuzu was returning the wrong data type when querying the <code>gl_FrontFacing</code> attribute — an unsigned integer, instead of a 32-bit floating-point value. The solution was equally simple: epicboy changed the code so that the <a href="https://github.com/yuzu-emu/yuzu/pull/6928">queried attribute returned with the correct data type</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./intelbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/intelbug_hu90970aa980e48050f411f2651d6bb52b_776235_800x0_resize_q90_bgffffff_box_3.jpg" alt="Finally, that hair dye was on discount (Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./intelfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/intelfix_hub07e98721129b028d4d34fcceaa5446a_738127_800x0_resize_q90_bgffffff_box_3.jpg" alt="Finally, that hair dye was on discount (Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Finally, that hair dye was on discount (Super Mario Odyssey)</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6887">v1993</a> has been using <a href="https://pvs-studio.com/en/">PVS-Studio</a> to catch logic errors in the code with good success so far. For example, <a href="https://github.com/yuzu-emu/yuzu/pull/6887">a small clean up in SPIR-V was possible thanks to this</a>.</p> <h2 id="lan-party-time">LAN party time!</h2> <p>Work on <code>Local Wireless</code> continues, but in the meantime, yuzu is proud to announce that <code>LAN</code> <a href="https://github.com/yuzu-emu/yuzu/pull/6863">(Local Area Network)</a> support has been added for all users! This is all thanks to work done by <a href="https://github.com/spholz">spholz</a>.</p> <p>This means that a small selection of games can now be played with a Switch or any other computer running yuzu while connected to the same network (be it wired ethernet, or via WiFi). With a service like <a href="https://www.zerotier.com/">ZeroTier</a> (hamachi has not worked so far) or by manually configuring a VPN <a href="https://en.wikipedia.org/wiki/Virtual_private_network">(Virtual Private Network)</a>, this can be extended to global gameplay!</p> <p><strong>Games with LAN support so far are:</strong></p> <ul> <li><code>ARMS</code></li> <li><code>Bayonetta 2</code></li> <li><code>Duke Nukem 3D: 20th Anniversary World Tour</code></li> <li><code>Mario &amp; Sonic at the Olympic Games Tokyo 2020</code></li> <li><code>Mario Golf: Super Rush</code></li> <li><code>Mario Kart 8 Deluxe</code></li> <li><code>Mario Tennis Aces</code></li> <li><code>Pokkén Tournament DX</code></li> <li><code>Pokémon Sword &amp; Shield</code> (limited game functions by design)</li> <li><code>Saints Row IV®: Re-Elected™</code></li> <li><code>SAINTS ROW®: THE THIRD™ - THE FULL PACKAGE</code></li> <li><code>Splatoon 2</code> (works with auto-stub enabled)</li> <li><code>Titan Quest</code></li> </ul> <p>At the moment, not all of the listed games work due to missing services or not having the best compatibility with yuzu, but gameplay proved stable in all working cases.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lan.png" title=" It just works! (Mario Kart 8 Deluxe)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/lan_hud5147d941255afc455b5ee8cbdd44ecb_3098574_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" It just works! (Mario Kart 8 Deluxe)"></a> <p class="has-text-centered is-italic has-text-grey-light"> It just works! (Mario Kart 8 Deluxe)</p> </div> </div> <p>Keep in mind that some games require certain button combinations to switch between LAN and Local Wireless modes. For example, <code>Mario Kart 8 Deluxe</code> requires the user to simultaneously hold L + R and depress the left analog stick (L3) in the main menu to be able to create or join a LAN room.</p> <p><a href="https://github.com/Morph1984">Morph</a> later followed with <a href="https://github.com/yuzu-emu/yuzu/pull/6905">network interface cleanups</a>.</p> <h2 id="smooth-and-glitchless-videos-for-the-win">Smooth and glitchless videos for the win</h2> <p>Thanks to the <a href="https://github.com/yuzu-emu/yuzu/pull/6713">introduction of VA-API</a> by <a href="https://github.com/yzct12345">yzct12345</a> back in July, epicboy made it possible to <a href="https://github.com/yuzu-emu/yuzu/pull/6846">use hardware video acceleration</a> to decode videos with <a href="https://en.wikipedia.org/wiki/FFmpeg">FFmpeg</a> for all other compatible GPU and driver combinations. Furthermore, yuzu will gracefully fall back to software decoding in case none of the combinations are supported.</p> <p>This considerably speeds up the decoding process, improving the performance of the emulator when playing videos.</p> <p>Currently, the following GPU decoders are implemented:</p> <table> <thead> <tr> <th style="text-align:center">GPU</th> <th style="text-align:center">WINDOWS</th> <th style="text-align:center">LINUX</th> </tr> </thead> <tbody> <tr> <td style="text-align:center">NVIDIA</td> <td style="text-align:center">NVDEC/D3D11VA</td> <td style="text-align:center">NVDEC/VDPAU</td> </tr> <tr> <td style="text-align:center">AMD</td> <td style="text-align:center">D3D11VA</td> <td style="text-align:center">VA-API/VDPAU</td> </tr> <tr> <td style="text-align:center">INTEL</td> <td style="text-align:center">D3D11VA</td> <td style="text-align:center">VA-API</td> </tr> </tbody> </table> <p>Please note that, since the GPU used to decode videos isn&rsquo;t necessarily the same as the one used for rendering, NVDEC is preferred on Windows over D3D11VA, as the performance experienced with the latter when it defaults to using the iGPU for decoding was lower.</p> <p>Next on the list, we have had reports of noisy artifacts appearing in the videos of some games. Notably, those that were encoded with the <a href="https://en.wikipedia.org/wiki/VP9">VP9 format</a>. epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/6799">investigated the problem and solved it by stubbing <code>UnmapBuffer</code></a>, a driver command that is, as you could guess, used to free GPU memory held by a buffer. But what was exactly the problem behind this? I&rsquo;m afraid that this will get a tad bit technical, so bear with me for a while. I promise it will not hurt&hellip; much.</p> <p>The VP9 codec defines, among other things, a number of frames in the video to be used as references, which are in turn employed to reconstruct the frames in-between these <code>key-frames</code>. That means that, to properly interpolate these &ldquo;in-between&rdquo; frames, one must rely on the information from both the <code>key-frames</code>, and previous <code>inter-frames</code>. <code>key-frames</code>, on the other hand, are decoded completely on their own, without relying on any reference. Decoding a frame like this is a slower process, but it guarantees that the frame will be as clean of errors as possible, which is why they can be used as references.</p> <p>As was previously mentioned, FFmpeg is used to decode videos. In the case of the VP9 format, yuzu needs to send FFmpeg the raw bytes that will be decoded (i.e. the actual images that you see in the video), along with a header that contains metadata, such as the dimensions of the frame, whether it is a <code>key-frame</code>, or, if it isn&rsquo;t, what frames are used as references when processing it, etc.</p> <p>The information that constitutes this header is mapped to a buffer in memory. And now, here&rsquo;s where things turn a bit funny. For some reason, the information in this buffer — namely, that part of the header that specified what <code>key-frames</code> should be used as reference, would change inconsistently among <code>inter-frames</code>. This led to a degradation of the quality of the video, as every interpolated frame would reference a different <code>key-frame</code>, leading to the creation of these infamous garbled noise artifacts.</p> <p>By stubbing the <code>UnmapBuffer</code> command, the addresses of these reference frames now remain constant for as long as they are needed, allowing yuzu to pass to <code>FFmpeg</code> the correct information and decode the videos without any problems.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./vp9bug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./vp9fix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Both glitch free and smoother (The Legend of Zelda: Link&#39;s Awakening)</p> <p>On a related note, epicboy fixed another VP9 problem: the first frame of the bitstream was missing its frame data, so he changed the logic to <a href="https://github.com/yuzu-emu/yuzu/pull/6844">ensure the first frame is complete</a>, silencing a runtime error thrown by FFmpeg.</p> <p>As previously mentioned, yuzu reads the header information directly from the NVDEC registers contained in a buffer. Unfortunately, one key flag that needs to be passed to FFmpeg, <code>is_hidden_frame</code>, was not actually held in this buffer.</p> <p>To circumvent this problem, our implementation also buffers the next frame, and then, based on another flag that holds the same information (<code>is_previous_frame_hidden</code>), informs FFmpeg whether the previous frame should be displayed or not. This means that yuzu would always decode one frame late, and since that was already the case, yuzu wasn&rsquo;t sending the header information for the very first frame, as it needs to know the value of <code>is_hidden_frame</code> beforehand.</p> <p>What epicboy did was simply copy the first frame in the bitstream, so that essentially the first and second frame are the same, and thus, exploiting this fact, the header information can be passed to FFmpeg so it stops complaining.</p> <p>Alas, the joys of software development are fleeting in this world.</p> <h2 id="general-bugfixes">General bugfixes</h2> <p>You can’t predict how a bug will show up, sometimes they pop out like daisies. With the addition of Brazilian Portuguese as a language for the user interface, <code>Paper Mario: The Origami King</code> started to run only in Japanese, ignoring any user setting.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6793">Fixing the copy amount of <code>GetAvailableLanguageCodes</code></a> was enough to solve this issue. Thanks Morph!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./papermario.png" title=" True native gameplay (Paper Mario: The Origami King)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/papermario_hub71c60c4d32be149b6a18e2bb3c24a28_2814805_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" True native gameplay (Paper Mario: The Origami King)"></a> <p class="has-text-centered is-italic has-text-grey-light"> True native gameplay (Paper Mario: The Origami King)</p> </div> </div> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6795">sankasan</a> gave <code>yuzu-cmd</code>, our command-line SDL2 alternative to the regular Qt yuzu, some additional love. By correctly implementing <code>SDL_ShowCursor</code>, yuzu-cmd can now <a href="https://github.com/yuzu-emu/yuzu/pull/6795">properly hide the mouse cursor while in fullscreen</a>. Thank you!</p> <p>Also relating to <code>yuzu-cmd</code>, in the past, while button mapping and other settings were working correctly, the toggle to enable the controller was being completely ignored. <a href="https://github.com/yuzu-emu/yuzu/pull/6816">Reading the <code>connected</code> value as a boolean</a> was all it took to get past this misstep, thanks <a href="https://github.com/lat9nq">toastUnlimited</a>!</p> <p>toast also found an issue in the logic of how per-game profiles were handled: only the default user profile was ever selected. <a href="https://github.com/yuzu-emu/yuzu/pull/6805">Some code changes, and now the currently selected user profile will be used</a>.</p> <p><a href="https://github.com/gidoly">gidoly</a> opened his first ever pull request, fixing a small but arguably very important description.</p> <p><code>Use Fast GPU time</code>, one of the options in the Advanced Graphics tab, is a hack intended to improve compatibility with games that use dynamic resolution as a way to keep steady performance on the Switch.</p> <p>By lying and informing the game/application that performance is always good, the emulator avoids unnecessary destruction and reconstruction of textures, saving both performance and VRAM. As an added benefit, some games use this <em>totally-not-adulterated</em> information to constantly render at their highest supported resolution.</p> <p>For both these reasons we recommend users to keep this option always enabled, as no regressions have been found when using it, and the stability benefits on some particular titles like <code>Luigi’s Mansion 3</code> are more than worth it.</p> <p>So, by calling a spade a spade, gidoly now informs us that <code>Use Fast GPU time</code> <a href="https://github.com/yuzu-emu/yuzu/pull/6817">is indeed a hack</a>. Al pan, pan, y al vino, vino.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6927">Stubbing the <code>NGCT:U</code> service</a> allows <code>Boyfriend Dungeon</code> to boot. Good catch by <a href="https://github.com/german77">german77</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./boyfriend.png" title=" Boyfriend Dungeon"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/boyfriend_hu641e84f64543168739c538e300464d58_1164604_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Boyfriend Dungeon"></a> <p class="has-text-centered is-italic has-text-grey-light"> Boyfriend Dungeon</p> </div> </div> <p>epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/6839">flipped the positions of <code>Limit Speed Percent</code> and <code>Framerate Cap</code></a> in the configuration window. Tidying the user interface never hurts.</p> <p>Are there any developers tired of having to wait over 3 minutes to compile each change done to the texture cache section of the code? Well, <a href="https://github.com/yzct12345">yzct12345</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6820">split out the definitions</a>, reducing the build time to only 30 seconds.</p> <p>yzct12345 also found a <a href="https://en.wikipedia.org/wiki/Deadlock">deadlock</a> in our <code>Single-Producer, Single Consumer queue</code>, <a href="https://github.com/yuzu-emu/yuzu/pull/6868">and submitted a fix</a> to address this problem. The work to rewrite this queue and make it <code>Multi-Producer, Multi-Consumer</code> has also been started, so hopefully we might see a follow-up next month. If you’re confused about these &ldquo;<a href="https://en.wikipedia.org/wiki/Producer%E2%80%93consumer_problem">Producer-Consumer</a>&rdquo; terms, just know that they basically describe how to tackle the access to a resource in a multi-core system, so that the processes that write into (produce), and those that read from (consume), a shared resource, are properly synchronized — in this case, the queue.</p> <p>This adventurous developer also <a href="https://github.com/yuzu-emu/yuzu/pull/6861">optimized the UnswizzleTexture function</a>, yielding a sweet speed gain. Swizzling refers to a technique used to optimize how textures are stored in memory to minimize cache misses. The opposite operation, thus, would be to take a swizzled texture and reorganize it so it makes sense to humans.</p> <p>Some time ago, toast detected a potential out-of-bounds access, which is a bug that occurs when the program accesses memory that is outside the range where it should be operating at that given moment. The code in question is also part of the function used to unswizzle textures. epicboy noticed that the root of the problem laid in the calculation of the frame buffer size, used to limit where the code should operate, <a href="https://github.com/yuzu-emu/yuzu/pull/6879">and fixed it in this PR</a>, effectively eliminating the bug.</p> <p>While inspecting yuzu manually and with the help of analysis tools, v1993 also found a number of small bugs in different parts of our codebase, such as a <a href="https://github.com/yuzu-emu/yuzu/pull/6884">misplaced break statement</a> in the kernel function <code>GetThreadContext()</code> — a human error that changed the logic of the algorithm, preventing it from behaving as intended. In a similar vein, he also corrected a <a href="https://github.com/yuzu-emu/yuzu/pull/6889">copy-paste error</a> affecting the code of the software keyboard.</p> <p>v1993 also found another bug in the <code>GetSubmappedRange()</code> function, used to obtain the CPU memory segments from a GPU memory address. Blinkhawk <a href="https://github.com/yuzu-emu/yuzu/pull/6894">went ahead and fixed it</a>.</p> <p>Another noteworthy change by Blinkhawk is that he <a href="https://github.com/yuzu-emu/yuzu/pull/6897">changed the logic of the Garbage Collector</a> (Reaper), so that it uses a Least-Recently Used (<code>LRU</code>) cache instead.</p> <p>Previously, the cache of the GC (Garbage Collector) would iterate over <code>n</code> textures every frame, checking whether they should be cleaned from memory or not. It also used certain heuristics that would make the cleaning more aggressive towards certain kinds of textures, cleaning them without synchronizing with the host memory.</p> <p>The <code>LRU</code> scheme, however, orders the textures based on how recently they were used. Once the memory is full, the GC starts iterating over the elements of the <code>LRU</code> cache, eliminating the textures that haven&rsquo;t been used in the longest time. Additionally, the GC now prioritizes eliminating textures that do not need to synchronize with the host memory, and only considers other textures once these have been emptied from the cache. These changes make the new Garbage Collector more stable, so we can safely enable it by default for all users.</p> <p>Meanwhile, <a href="https://github.com/BreadFish64">BreadFish64</a> found that yuzu spent considerable CPU time running <code>GetHostThreadID()</code> — a function of the kernel used to manage threads — while profiling <code>Fire Emblem: Three Houses</code>, and <a href="https://github.com/yuzu-emu/yuzu/pull/6878">submitted a patch that optimized the generated code</a>, providing a small performance boost.</p> <h1 id="input-improvements">Input improvements</h1> <p>german77 implemented a few input changes this month.</p> <p>First of all, when mapping and moving an analog stick, the previous implementation used to only show a blue dot representing the relative position of the analog stick. <a href="https://github.com/yuzu-emu/yuzu/pull/6815">A new green dot is now present</a>, representing the emulated position of the stick, considering range and dead zones values. It&rsquo;s useful to know if the stick actually reaches the whole input range.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./stick.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Remember to test and set both Range and Deadzone</p> </div> </div> <p>Next, the usual <a href="https://github.com/yuzu-emu/yuzu/pull/6855">update to SDL</a>, which always brings some goodies. In this case:</p> <ul> <li>The ability to send effects to DualSense triggers (not implemented at the moment).</li> <li>Better sensor data rate for Switch and PlayStation controllers.</li> <li>Added support for the Amazon Luna controller.</li> <li>Added rumble support for the Google Stadia controller.</li> <li>Improved rumble for the Pro Controller.</li> </ul> <p>And finally, the Web Applet can cause the SDL process to die, <a href="https://github.com/yuzu-emu/yuzu/pull/6862">disabling an unnecessary feature</a> solves the issue.</p> <h2 id="future-projects">Future projects</h2> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./art.png" title=" 4K beach episode (Xenoblade Chronicles Definitive Edition)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2021/art_hu87073d82fc7ddf57e5e37443d347018e_12861480_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" 4K beach episode (Xenoblade Chronicles Definitive Edition)"></a> <p class="has-text-centered is-italic has-text-grey-light"> 4K beach episode (Xenoblade Chronicles Definitive Edition)</p> </div> </div> <p>Progress on <code>Project A.R.T.</code> is going well, most major problems have been addressed. Morph had several eureka moments with <code>Project Gaia</code>. And now other secret recipes are in the oven, waiting their turn.</p> <p>That’s all folks! Thank you for your attention — happy playing, and see you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report July 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/ Thu, 12 Aug 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/ <p>Bienvenidos, yuz-ers, to our latest monthly progress report! We have a <em>lot</em> to talk about this month, so buckle up, ‘cause this will be one good ride!</p> <p>Bienvenidos, yuz-ers, to our latest monthly progress report! We have a <em>lot</em> to talk about this month, so buckle up, ‘cause this will be one good ride!</p> <h1 id="project-hades">Project Hades</h1> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hades.png" title=" Why Hades? Well here&#39;s why!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/hades_hu208308d6efaa0adddc38249d8eaf6df2_1621_135x0_resize_q90_bgffffff_box_3.jpg" alt=" Why Hades? Well here&#39;s why!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Why Hades? Well here&#39;s why!</p> </div> </div> <p><a href="https://www.youtube.com/watch?v=4Zq3OCrzn84">Kept you waiting, huh?</a> After being in development for six months, and spanning almost 50,000 lines of new code, <code>Project Hades</code> has finally been released. This massive <a href="https://github.com/yuzu-emu/yuzu/pull/6585">rewrite of the shader decompiler</a> is brought to you by <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, <a href="https://github.com/FernandoS27">Blinkhawk</a>, and <a href="https://github.com/ameerj">epicboy</a>.</p> <p>Fixing an innumerable amount of rendering bugs, reducing shader build times, improving compatibility, and increasing performance by over 30% for all GPU vendors, Hades is easily one of the biggest changes made to yuzu to date.</p> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-hades/">We have a dedicated article explaining the process in technical detail</a>, so we will be focusing only on the end user changes and some recommendations to help you get the best experience out of this new feature that both Early Access and Mainline users can enjoy.</p> <p>While we keep OpenGL as the default graphics API for compatibility reasons (outdated drivers won’t affect it as much, and it lets Nvidia Fermi GPU users run yuzu out of the box), we strongly recommend testing your games with the Vulkan API first. Vulkan performance and compatibility have improved significantly (especially if paired with the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/#project-texture-reaper">Texture Reaper</a>, the GPU Cache Garbage Collector), additionally, rendering and shader build performance almost always beat OpenGL. This applies not only for AMD and Intel GPU users, but also Nvidia users.</p> <p>There is an exception, however. The Intel Linux Vulkan driver is not stable at the moment, but we’re investigating the cause of the issue. For now, Intel Linux users should stick to OpenGL.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./perf_ea_vs_hades_ea.png" title=" Integrated GPU users benefit the most from Hades"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/perf_ea_vs_hades_ea_hu025fb8c84f747518bd081df5c2115493_14445_630x0_resize_q90_bgffffff_box_3.jpg" alt=" Integrated GPU users benefit the most from Hades"></a> <p class="has-text-centered is-italic has-text-grey-light"> Integrated GPU users benefit the most from Hades</p> </div> </div> <p>Hades implements a <code>Pipeline Cache</code> for both Vulkan and OpenGL, meaning that regardless of which API you are using, all shaders are now stored and reused the next time the game is started. This functions similarly to how the old OpenGL Shader Cache behaved. Needless to say, this means that all previous Shader Caches are no longer valid, and will be discarded if someone tries to use them.</p> <p>The difference in terminology lies in the fact that the whole <a href="https://en.wikipedia.org/wiki/Graphics_pipeline">Graphics Pipeline</a> is now stored, not just a specific set of Shader stages. An important detail, the OpenGL pipeline cache is not interchangeable with the Vulkan pipeline cache and vice versa. Two separate sets of shaders are generated if you use both APIs.</p> <p>Vulkan now also benefits from <code>parallel shader building</code>, meaning all CPU threads will be able to handle all upcoming shaders in a parallel fashion, instead of asynchronously, avoiding graphical issues and building faster. The end result is the shortest build times of all API and shader backends (more on this later). Thus, on a fresh game with no previously built cache, more CPU threads will provide a smoother experience, with no imposed limit. Someone should test running <code>Super Smash Bros. Ultimate</code> on a big server CPU!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./vulkan.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> First time gameplay has never been smoother!</p> </div> </div> <p>All CPU threads, save for one, are used to build shaders. The remaining free thread either handles shader saving to the pipeline cache, or continues the rendering process, depending on if all shaders have been dealt with at the moment. This decision was made not only to improve performance, but also to improve overall system response times while building several shaders simultaneously, and to avoid certain “gaming” laptops from overheating the CPU while keeping all threads busy.</p> <p>Note that this is a hardware design flaw by the laptop vendors, not an issue with the emulator. The product should provide enough cooling performance to keep its components cool enough even at full demand, not just for reaching advertised turbo clock speeds in short bursts. (Writer note: basically, if you want good gaming performance and longevity, buy <strong>thicc</strong> laptops.)</p> <p>Now, not all games will perform or render the best in Vulkan, some will still show better results with OpenGL instead. For the old API, we have some changes too.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./backend.png" title=" When selecting OpenGL, new options show up!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/backend_hufa3e1f2275438a38cd748d28d8a5373d_22268_1019x0_resize_q90_bgffffff_box_3.jpg" alt=" When selecting OpenGL, new options show up!"></a> <p class="has-text-centered is-italic has-text-grey-light"> When selecting OpenGL, new options show up!</p> </div> </div> <p>We have introduced a new drop list option in the Graphics settings. Replacing the device selection of Vulkan when using OpenGL, <code>Shader backend</code> shows up, giving three different options to choose from.</p> <p>Out of the box, yuzu uses <a href="https://en.wikipedia.org/wiki/OpenGL_Shading_Language">GLSL</a>, the default backend for OpenGL. On good performing OpenGL GPU drivers (only Nvidia and the Linux Mesa drivers as of now), it has the best performance, but also takes the longest time to build shaders, resulting in noticeable stuttering when accessing new areas or performing new attacks. This is the recommended option for Nvidia users with a previously built cache searching for the highest performance. While it has its uses in some edge cases, we recommend Windows AMD and Intel users to run Vulkan instead. Linux Mesa users don’t have this limitation and can enjoy GLSL without issues, thanks to far more mature drivers.</p> <p>Next up is <a href="https://en.wikipedia.org/wiki/ARB_assembly_language">GLASM</a>, what in the past was called Assembly Shaders. This is an Nvidia only feature, it provides lower performance than GLSL or Vulkan, but the second fastest shader build times, only behind Vulkan’s parallel shaders. We recommend Nvidia users interested in using OpenGL to first run games in GLASM in order to build their pipeline cache, and once done, move to GLSL to get the best performance without suffering the shader stuttering associated with GLSL. Any other GPU vendor will skip GLASM and default to GLSL.</p> <p>Finally, <a href="https://en.wikipedia.org/wiki/Standard_Portable_Intermediate_Representation">SPIR-V</a>, the default backend of Vulkan, which is a valid option in OpenGL since the release of version 4.6. Originally, we wanted OpenGL to use this backend, discontinuing support for GLSL.</p> <p>Reality always hits back like the laws of thermodynamics, delaying the release of Hades for several months. Driver support for SPIR-V in Windows is very bad (especially for Nvidia), with only the Linux Mesa drivers having a correct and fast implementation. So we decided to keep the option as an experimental feature, focusing on the old GLSL and GLASM backend first. We plan to improve SPIR-V rendering and performance later. Ideally, SPIR-V in OpenGL should be a jack-of-all-trades, a mix of the performance of GLSL and the shader build times of GLASM.</p> <p>So to ease our user’s decision on what to choose, here’s a chart of all possible options for the most common GPU vendors.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./best.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/best_hu2a592afc15a1d2ec7cd1d25d815217cf_477092_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>Another important change is in how GPU accuracy operates. In the past, certain games like <code>Pokémon Sword &amp; Shield</code> required using High GPU accuracy to get the best performance. This is no longer the case. Now, Normal consistently produces the best performance, at a low cost in accuracy, while High produces better particle effects and lighting, at a low performance cost.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6575">We removed values</a> that should be enabled by default from the bottom left action buttons of the user interface, like Asynchronous GPU shaders and Multicore. In their place, users can now <em>switch</em> between Normal and High GPU accuracy while playing. A fast and easy way to test what’s better for each game, GPU vendor, and API.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./statusbar.png" title=" Old (top) vs new (bottom)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/statusbar_hu0de8e6b0d628be9d1cc5358354a18163_3649_500x0_resize_q90_bgffffff_box_3.jpg" alt=" Old (top) vs new (bottom)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Old (top) vs new (bottom)</p> </div> </div> <h2 id="thank-you-captain-obv--er-i-mean-captain-vortex">Thank you, Captain Obv — er, I mean, Captain Vortex</h2> <p>Communication is vital for any project, and it is essential that we make our configuration options <em>even more explanatory</em> than they already are.</p> <p>We want to thank our fellow developer, <a href="https://github.com/CaptV0rt3x">Vortex</a>, for the marvelous change of <a href="https://github.com/yuzu-emu/yuzu/pull/6736">rewording the explanation of GLASM</a>. This change was made in order to elaborate that it is, effectively, a shorthand for <code>OpenGL Assembly Shaders</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vortex.png" title=" This is critical"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/vortex_huc936706a8265a389b0bf1716e0c37940_14353_1019x0_resize_q90_bgffffff_box_3.jpg" alt=" This is critical"></a> <p class="has-text-centered is-italic has-text-grey-light"> This is critical</p> </div> </div> <p>Fear not, my fellow yuz-ers, for we always have the most serious and capable people doing only the best work for your benefit. Rest assured that if a similar situation were to arise again in the future, Vortex will have your back. I salute you, my dear friend, and pray that you may ennoble yuzu even further with your future contributions.</p> <h2 id="graphical-fixes">Graphical fixes</h2> <p>epicboy was very busy during the development of Hades, and continues to be busy after it was finished.</p> <p>World 1-5 of <code>Super Mario 3D World + Bowser's Fury</code> used to crash when loading on AMD and Intel GPU equipped systems running Vulkan. A depth image was being cleared as a regular colour image and, while OpenGL is totally fine with this, Vulkan is more strict which lead to a crash. <a href="https://github.com/yuzu-emu/yuzu/pull/6635">By only clearing valid colour images</a>, epicboy resolved the issue.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sm3dw.png" title=" Affected world in Super Mario 3D World &#43; Bowser&#39;s Fury"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/sm3dw_hu8896f1afccd74ef7c8189eded75dda6f_3118017_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Affected world in Super Mario 3D World &#43; Bowser&#39;s Fury"></a> <p class="has-text-centered is-italic has-text-grey-light"> Affected world in Super Mario 3D World &#43; Bowser&#39;s Fury</p> </div> </div> <p>As a way to limit the maximum framerate a dynamic FPS game can run at, epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/6697">implemented a multiplier based cap</a>. So, for example, if a game natively runs at 30 FPS, but can be run without issues at 240 FPS, setting an FPS cap of 8x will limit the FPS unlimiter to that value. Ideal for high refresh displays!</p> <p>To avoid confusion with the FPS unlimiter, the old Frame limit was <a href="https://github.com/yuzu-emu/yuzu/pull/6696">renamed to Speed limit.</a></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fpscap.png" title=" You can find the new options here"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/fpscap_huc3e33aecf9591297985d7126f0e2331d_24604_1021x0_resize_q90_bgffffff_box_3.jpg" alt=" You can find the new options here"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can find the new options here</p> </div> </div> <p>From before the <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">release of the texture cache rewrite</a>, a regression has existed that caused users&rsquo; screenshots to save in the wrong directory. Turns out <a href="https://github.com/yuzu-emu/yuzu/pull/6709">a single directory separator was missing in the code</a>. Now, screenshots will work correctly by either pressing the <code>Ctrl + P</code> hotkey, or via selecting the <code>Tools &gt; Capture Screenshot…</code> menu option, and save in the selected folder.</p> <p>epicboy also <a href="https://github.com/yuzu-emu/yuzu/pull/6720">added support for taking screenshots in the Vulkan API</a>, solving an old issue from way back when <a href="https://yuzu-mirror.github.io/entry/yuzu-vulkan/">Vulkan was first implemented</a> two years ago. How time flies&hellip;</p> <p>Finally, before being dragged against his will to work on Hades, epicboy was working on improving the performance of our compute shader accelerated ASTC decoder. By reducing the size of the workgroup, making some code simplifications, moving some look up tables, and other changes, <a href="https://github.com/yuzu-emu/yuzu/pull/6791">performance increased by 15% on average.</a> <code>Astral Chain</code> and similar titles that madly love ASTC should see more consistent frametimes with this change.</p> <p>Blinkhawk has also been working constantly lately, not only on Hades and several other improvements, but also in some top secret projects we will mention later.</p> <p>Koei Tecmo games are usually quite special, they never fail to give our developers headaches thanks to… unique decisions the studio makes. It’s not an exaggeration to say that Project Hades’ main motivation was improving how these games run in yuzu.</p> <p>One of the remaining issues with <code>Hyrule Warriors: Age of Calamity</code>, <code>Fire Emblem: Three Houses</code>, and similar Koei games was instability caused by running them in High GPU accuracy when loading specific levels. In Blink’s own words, <a href="https://github.com/yuzu-emu/yuzu/pull/6627">a simple fix</a>, and the problem was solved.</p> <p>Another old regression introduced by the <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/">Buffer Cache Rewrite</a> affected particles in games like <code>The Legend of Zelda: Breath of the Wild</code>, the rendering of the BowWow in <code>The Legend of Zelda: Link’s Awakening</code> and caused vertex explosions in Unreal Engine 4 games like <code>Yoshi’s Crafted World</code>, <code>BRAVELY DEFAULT 2</code> and similar. <a href="https://github.com/yuzu-emu/yuzu/pull/6557">Tuning how to handle high downloads and not fully waiting for command buffers to finish</a> solved these issues. To make the best out of this change, High GPU accuracy needs to be enabled.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./particlebug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./particlefix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">High GPU Accuracy is recommended (The Legend of Zelda: Breath of the Wild)</p> <p>When Blinkhawk introduced the new fence manager while working on improvements for <code>Asynchronous GPU Emulation</code> two years ago, some frame delays came with it, causing stuttering in gameplay even if the framerate counter showed a solid 30 or 60 FPS value. To counter this, Blink starts <a href="https://github.com/yuzu-emu/yuzu/pull/6787">pre-queueing frames</a>, providing a smooth gameplay experience, especially noticeable if the user&rsquo;s hardware can’t sustain perfect performance constantly.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./vsyncbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./vsyncfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Smooth as butter (Xenoblade Chronicles Definitive Edition)</p> <p>Rodrigo has also been hitting those keycaps without rest.</p> <p><code>Hyrule Warriors: Age of Calamity</code> suffered from very dark environments due to unprepared images that were used as render targets. When their dirty flags were not properly set, a desynchronization happened on the texture cache, causing the issue shown below. <a href="https://github.com/yuzu-emu/yuzu/pull/6670">By correctly preparing such images</a>, the game renders correctly.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./aocbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/aocbug_hubb66d40baf6ff720a7056d3148f6bc4c_1425159_800x0_resize_q90_bgffffff_box_3.jpg" alt="That looks like the Dark World to me (Hyrule Warriors: Age of Calamity)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./aocfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/aocfix_hua67f22e77cdc276e5853fe4aad55bcad_1982883_800x0_resize_q90_bgffffff_box_3.jpg" alt="That looks like the Dark World to me (Hyrule Warriors: Age of Calamity)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That looks like the Dark World to me (Hyrule Warriors: Age of Calamity)</p> <p>By optimizing shaders doing <a href="https://en.wikipedia.org/wiki/Multiply%E2%80%93accumulate_operation#Fused_multiply%E2%80%93add">FMA</a> operations, yuzu <a href="https://github.com/yuzu-emu/yuzu/pull/6722">gains an extra 4% of performance</a> overall.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/6765">flipping the viewport</a> in <code>Y_NEGATE</code>, Rodrigo matches in Vulkan the correct behaviour OpenGL has, resolving the &ldquo;flipping&rdquo; issues for the following games: <code>Katana ZERO</code>, <code>UNDERTALE</code>, <code>DELTARUNE</code>, <code>Shantae</code>, <code>Fire Emblem: Shadow Dragon and the Blade of Light</code>, and others.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./flipbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/flipbug_hu51987ead620a08c2dd3a9b1386fe9449_126923_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Shadow Dragon and the Blade of Light"></a> </div> <div class="column is-bottom-paddingless"> <a href="./flipfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/flipfix_hu0e867690cb7408d1e2f4b277ef9b6771_127261_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Shadow Dragon and the Blade of Light"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fire Emblem: Shadow Dragon and the Blade of Light</p> <p><code>Xenoblade Chronicles 2</code> experienced crashes with the Vulkan Mesa drivers due to them lacking null buffers in its transform feedback bindings. Rodrigo had to <a href="https://github.com/yuzu-emu/yuzu/pull/6580">emulate the lack of this function</a> in order to solve the crashing.</p> <p>AMD Radeon Linux users may have noticed that <code>The Legend of Zelda: Skyward Sword</code> would run at very slow framerates in stable versions of the OpenGL Mesa drivers. This is caused by a driver level bottleneck resulting in very slow <a href="https://www.khronos.org/opengl/wiki/Pixel_Buffer_Object">PBO</a> (Pixel Buffer Object) downloads. While the current mesa-git has this bottleneck solved, a solution is needed until those fixes reach the stable release versions. <a href="https://github.com/yuzu-emu/yuzu/pull/6685">By specifying the <code>GL_CLIENT_STORAGE_BIT</code> flag</a>, an alternative faster path can be used, increasing performance from around 8 FPS to a solid 60 FPS. Mesa drivers are the best drivers.</p> <p><a href="https://github.com/Morph1984">Morph</a> also contributed with some graphical fixes.</p> <p><code>New Super Mario Bros. U Deluxe</code> provides video tutorials accessed via the web applet. Prior to his fix, trying to access that list would only result in the game returning to the previous menu. <a href="https://github.com/yuzu-emu/yuzu/pull/6641">By implementing how to handle Nintendo CDN URLs in the web applet</a>, this section of the game can now be accessed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./nsmbuvid.png" title=" Video playback is still a work in progress (New Super Mario Bros. U Deluxe)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/nsmbuvid_hu56a44c7a1221bff3aea727efbcff69f7_1026870_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Video playback is still a work in progress (New Super Mario Bros. U Deluxe)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Video playback is still a work in progress (New Super Mario Bros. U Deluxe)</p> </div> </div> <p>Morph also solved a quite specific render issue affecting users with multiple displays. If two or more monitors were in use and the user started a game from any display besides the primary, black borders would appear in the rendering window. To solve this, <a href="https://github.com/yuzu-emu/yuzu/pull/6658">Morph needed to tell Qt to create a dummy render widget.</a></p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bordersbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/bordersbug_hu4f9517beedf23569f2952d55582b6eab_524497_800x0_resize_q90_bgffffff_box_3.jpg" alt="Sonic Mania, in proper pixelated format"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bordersfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/bordersfix_hud01172dba0769c83b2b09f4cd6b6184f_743600_800x0_resize_q90_bgffffff_box_3.jpg" alt="Sonic Mania, in proper pixelated format"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Sonic Mania, in proper pixelated format</p> <p>Newcomer <a href="https://github.com/yzct12345">yzct12345</a> arrived like a sonic boom, implementing critical improvements at impressive speeds!</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/6679">ignoring an invalid texture operation</a>, an early crash affecting <code>Pokémon: Let’s go, Eevee! &amp; Pikachu!</code> in Vulkan was solved. No more crashes when catching your first Pokémon. Gotta catch ’em all!</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6790">yzct12345’s work on optimizing UnswizzleTexture</a> resulted in up to double the performance for video decoding, and it also improved general gameplay! This results in far smoother video playback and a considerable reduction of the CPU performance needed to get a pleasant gaming experience. Thanks!</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> is our specialist in Linux testing and bug reporting. He noticed that the rune teleporting animation in <code>The Legend of Zelda: Breath of the Wild</code> wasn’t working correctly on the Iris and RadeonSI Mesa drivers, the default OpenGL drivers for recent Intel and AMD GPUs, respectively.</p> <p><a href="https://gitlab.freedesktop.org/mesa/mesa/-/issues/3820#note_753371">Thanks to instructions the Mesa driver team gave us</a> in how to properly use BindImageTexture, toastUnlimited was able to <a href="https://github.com/yuzu-emu/yuzu/pull/6570">implement the needed changes in yuzu</a>, making the animation render correctly.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botwbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/botwbug_hu0352cfee7ea9f221c11735dd97c82e80_4938744_800x0_resize_q90_bgffffff_box_3.jpg" alt="Well excuse me, Princess (The Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botwfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/botwfix_huc8fedd9ee23db00a1ac798317363c686_4929130_800x0_resize_q90_bgffffff_box_3.jpg" alt="Well excuse me, Princess (The Legend of Zelda: Breath of the Wild)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Well excuse me, Princess (The Legend of Zelda: Breath of the Wild)</p> <p><a href="https://github.com/K0bin">K0bin</a> arrived to give us a hand, fixing an important screw up we made.</p> <p>Prior to the introduction of full support on Resizable BAR in modern GPUs and systems, the PCI-Express standard is limited to a buffer of 256MB in video memory to communicate to the CPU at a time. yuzu uses this small portion of VRAM for allocating its staging buffer, but if the user has GPU intensive background applications, there may not be enough space to allow the allocation to happen, and yuzu would refuse to create a Vulkan instance, failing to boot any game. OpenGL is, as usual, excluded from this issue thanks to letting the GPU driver handle those allocations on its own.</p> <p>K0bin fixes this issue by <a href="https://github.com/yuzu-emu/yuzu/pull/6740">performing the allocation in system RAM</a> if there isn’t enough free space. Many thanks!</p> <h2 id="stop-this-sound">Stop This Sound!</h2> <p><a href="https://github.com/Kelebek1">Maide</a> has been dedicated to improving the audio side of yuzu this month. By <a href="https://github.com/yuzu-emu/yuzu/pull/6564">introducing some missing PCM formats</a>, the missing audio present in <code>Ys IX: Monstrum Nox</code> was finally fixed.</p> <p><code>PCM</code> stands for <a href="https://en.wikipedia.org/wiki/Pulse-code_modulation">Pulse-Code Modulation</a>, an encoding technique used to represent analogue audio signals digitally. These signals have two basic properties: The <a href="https://en.wikipedia.org/wiki/Sampling_(signal_processing)#Sampling_rate">sample rate</a> (how many samples of the signal are taken per second), and the <a href="https://en.wikipedia.org/wiki/Audio_bit_depth">bit-depth</a> (how many bits are used to represent the &ldquo;loudness&rdquo; of the signal&rsquo;s samples at any given point in time).</p> <p>In this PR, Maide introduced a number of methods to process formats that were missing in the current implementation — namely, the ability to decode PCM files encoded with a bit-depth of 8-bit, 32-bit, and also floating-point values. Since previously none of these formats were being decoded by yuzu, any audio file that made use of them was not being reproduced, causing this behaviour.</p> <p><code>Tales of Vesperia</code> was another title with sound problems, in which audio would be played monaurally through the left channel — far from a pleasant experience, as you can hear here:</p> <audio preload="auto" controls> <source src="./vesperiabug.mp3" type="audio/mpeg"> <a href="./vesperiabug.mp3">Download the audio instead</a> </audio> <p>This game in particular would request the available number of active channels and cap its output based on this information — in other words, the game would not output audio to more channels than what yuzu reported. Since yuzu was always returning a value of <code>1</code>, the game ended up outputting all the audio into the left channel. Thus, this problem was fixed by <a href="https://github.com/yuzu-emu/yuzu/pull/6567">reporting two channels as active instead of one</a>, which is now mixed properly:</p> <audio preload="auto" controls> <source src="./vesperiafix.mp3" type="audio/mpeg"> <a href="./vesperiafix.mp3">Download the audio instead</a> </audio> <p>Not satisfied with just this, Maide also went on and <a href="https://github.com/yuzu-emu/yuzu/pull/6569">changed the downmixing logic</a>, which improved the audio in titles such as <code>The Legend of Zelda: Link's Awakening</code>, <code>New Super Mario Bros. U</code>, <code>Disgaea 6: Defiance of Destiny</code>, and <code>Super Kirby Clash</code>.</p> <p>Simply put, downmixing refers to the process of combining multiple audio channels so it is possible to reproduce them in a system with a lower number of available audio channels. There is some mathematics involved here and there, but the general idea behind it is to balance the volume of these individual channels so that the resulting signal sounds centred.</p> <p>In the case of the Nintendo Switch, many games report six audio channels as available to the system, even though they end up providing data for only two channels (stereo sound). Consequently, yuzu would think the games used all these channels and then &ldquo;downmix&rdquo; them to stereo, affecting the volumes of the left and right channel in the process, which would end up being much quieter than needed. While the math used by yuzu is valid when used to downmix six channels to two, it certainly was not a desirable effect in this case. Therefore, Maide changed the code to preserve the volume of these channels if the audio in a game is already stereo, which now reproduces with the correct levels.</p> <p>On the same page of volume problems, there was also a bug with the volume in certain areas of <code>Xenoblade Chronicles 2</code>, where it would occasionally spike out of proportion. Maide tracked down the cause of this behaviour, and discovered that the gain of the samples sent by this game to yuzu had their values set as <code>NaN</code>.</p> <p>A <a href="https://en.wikipedia.org/wiki/NaN">NaN</a> is a type of placeholder used by computers to represent numeric values that can&rsquo;t be defined otherwise — hence, the acronym <code>N</code>ot <code>a</code> <code>N</code>umber. Particularly, the problem at hand lies in the fact that, in order to operate over the samples of the audio signal, these gain values must be converted into integers. But in this process, the <code>NaN</code> values, in turn, become obscenely large positive and negative integer values.</p> <p>As these samples were further processed by yuzu before sending them to your sound system, these gains would distort and cap the volume of the audio samples to their maximum or minimum value, causing this bug. To prevent this problem, Maide added a check that <a href="https://github.com/yuzu-emu/yuzu/pull/6571">changes the gain value from NaN to zero in such cases</a>, so that no error is propagated along the mixing.</p> <p>This is mostly a workaround, as it still remains under investigation why the game is yielding these <code>NaN</code> values, but at the very least, it should help prevent a number of bleeding ears here and there.</p> <h2 id="input-changes">Input changes</h2> <p>Along with some miscellaneous quality of life changes, <a href="https://github.com/german77">german77</a> also changed the behaviour of recently enabled controllers in yuzu. In order to provide the most precise experience, now <a href="https://github.com/yuzu-emu/yuzu/pull/6698">sticks will be auto-centred</a> the moment the device is detected by yuzu. Surprisingly, this happens with almost every game controller, sticks are always slightly off-centre, and if the dead zone value is small enough, users would experience slight drifting during gameplay. No drift in this emulator!</p> <p>Thanks to internal changes on how settings are stored, the default values of mouse panning were affected. german77 <a href="https://github.com/yuzu-emu/yuzu/pull/6659">restored the previous values</a> and additionally solved an issue where the emulated stick would always look down if the user had multiple screens. No drift, not even with the mouse!</p> <h1 id="ui-changes">UI changes</h1> <p>A silent change that has the potential to improve performance considerably for users of old or low-end CPUs has been made by toastUnlimited. In the past, we recommended our users to manually select the <code>Unsafe</code> CPU accuracy option if their CPU lacked the FMA instruction set. This is not only confusing for users, as it required them to know if their specific CPU model was compatible with FMA, but also relied on communication channels and guides properly explaining this to as many people as possible. This, of course, resulted in several users not even knowing why games performed so poorly.</p> <p>Additionally, it was later discovered that using the whole Unsafe preset can cause precision issues affecting things like the shape of the character hitboxes in <code>Super Smash Bros. Ultimate</code>. A better solution was needed.</p> <p>In response, toastUnlimited implemented <a href="https://github.com/yuzu-emu/yuzu/pull/6573">the all new <code>Auto</code> CPU accuracy setting!</a> Enabled by default for all users, this setting determines the need to use the <code>Unfuse FMA</code> value automatically by reading if the FMA instruction set is supported by the CPU in use. It also sets other values, for example <code>Faster ASIMD instructions</code>, to boost the performance of 32-bit games. Auto CPU accuracy has the potential to more than triple the performance of users running old or very low end CPUs!</p> <p>Thanks to work done by Morph, <a href="https://github.com/yuzu-emu/yuzu/pull/6556">now all default six Miis are available to the user</a> in games that request them.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mii.png" title=" We&#39;re still far away from offering full Mii customization, but at least more options are available now (Mario Kart 8 Deluxe)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/mii_hufdf4963a08bcb80c2c5a6a29837199fb_1101654_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We&#39;re still far away from offering full Mii customization, but at least more options are available now (Mario Kart 8 Deluxe)"></a> <p class="has-text-centered is-italic has-text-grey-light"> We&#39;re still far away from offering full Mii customization, but at least more options are available now (Mario Kart 8 Deluxe)</p> </div> </div> <p><a href="https://github.com/lioncash">lioncash</a>, our silent optimizer and code cleaner, found an issue with the new strings that report if a game is 32 or 64-bit. Languages that read from right to left had issues with the initial implementation, and translating this string was disabled. <a href="https://github.com/yuzu-emu/yuzu/pull/6574">Now both issues are resolved!</a></p> <p>After gathering more information on the behaviour of the FPS unlimiter, epicboy discovered that some games will crash when attempting to boot them unlimited. <a href="https://github.com/yuzu-emu/yuzu/pull/6576">Simply force-enabling the limiter at each game boot is enough to solve the issue.</a> Remember to unlock the framerate manually after you start a game!</p> <p><a href="https://github.com/vonchenplus">vonchenplus</a> is back with another nice addition! Certain game dumps contain several games inside them, and yuzu would default to only launching the first one in the list. <a href="https://github.com/yuzu-emu/yuzu/pull/6582">This change makes the necessary modifications so all games are properly listed.</a></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./games.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/games_hu2ce51e6f0d087fa0dae9c2238c5d5ad9_116016_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <h2 id="command-line-shenanigans">Command-Line Shenanigans</h2> <p>toastUnlimited performed a general <a href="https://github.com/yuzu-emu/yuzu/pull/6651">update to the settings of the command-line version of yuzu</a>, <code>yuzu-cmd</code>.</p> <p>The previous implementation had many options that were originally carried over from Citra and later deprecated, as well as others that were not read properly from the <code>ini</code> file, or were read but not written into the <code>ini</code> file, etc. In other words, there were a lot of things wrong with it, and some updating was in order to properly synchronize everything back with the settings present in the main executable of yuzu.</p> <p>Since toastUnlimited was already working on <code>yuzu-cmd</code>, he also went on and <a href="https://github.com/yuzu-emu/yuzu/pull/6652">fixed some problems related to Vulkan on Linux</a>. When this executable was launched, it wasn&rsquo;t able to detect the window manager, and would proceed to exit instead of booting a game.</p> <p>The cause behind this problem lies in the fact that we recently updated how the SDL external library is being fetched for our Linux binaries, which came with a dummy configuration file with invalid settings. toastUnlimited made it so that we manually include the correct generated configuration file for building SDL instead of this dummy, while also adding some new logging information to report when support for a window manager was not compiled.</p> <p>In a follow-up PR, toastUnlimited also added <a href="https://github.com/yuzu-emu/yuzu/pull/6693">support for the full-screen mode settings</a> to <code>yuzu-cmd</code>. Concurrently, he also fixed a bug that caused yuzu to render with the wrong resolution when in full-screen.</p> <p>Some time ago, we made it possible for yuzu to run in different full-screen modes, but these options were never added to the command-line version of our executable, which is addressed in this PR.</p> <h2 id="technical-changes">Technical Changes</h2> <p>Meanwhile, <a href="https://github.com/bunnei">bunnei</a> was busy <a href="https://github.com/yuzu-emu/yuzu/pull/6551">improving the management of kernel objects</a>, drastically reducing the amount of objects that kept dangling in memory after closing the emulation session.</p> <p>A dangling object refers to a stale object in memory that still has references, even though the object is no longer in use.</p> <p>In yuzu, kernel objects are implemented so that they keep track of themselves through a <a href="https://en.wikipedia.org/wiki/Reference_counting">reference counter</a>, which keeps the object alive for as long as they&rsquo;re needed. In other words, whenever a process needs an object, the reference counter is increased, and conversely, the reference is decreased when the object isn&rsquo;t needed any more.</p> <p>Once this value reaches zero, the object is automatically deleted. Previously, yuzu wasn&rsquo;t doing a great job at maintaining this reference counter, as these kernel objects can be called by more more than just one process — i.e. the &ldquo;owners&rdquo;, who are responsible for freeing the resource once they&rsquo;re done with it. In some cases, some of these owners weren&rsquo;t properly freeing the object at all, which meant that the reference counter never reached zero, leaving this object &ldquo;dangling&rdquo; in memory, even though the information became basically useless at this point.</p> <p>One of the many jobs of the kernel in the OS is to keep track of all the resources available in the system. For this reason, these dangling objects were a problem, as the kernel calculates the number of resources that can be spawned based partly on the number of active objects in memory. With dozens of different kernel objects being created thousands of times between emulation sessions, this easily saturated the amount of objects that could be spawned due to yuzu hitting the resource limits much earlier than expected. What&rsquo;s more, since these objects stick around even after the emulation session is closed, this is a memory leak that would gradually increase for as long as the emulator is running a game — in other words, it would persist even if you stopped the emulation and started it again.</p> <p>bunnei took a long look at the problem and improved the situation, but there&rsquo;s still ongoing work to make our implementation more robust and accurate.</p> <p>Blinkhawk also had his share of bug-fixing work, as he revisited the texture cache code related to <a href="https://github.com/yuzu-emu/yuzu/pull/6553">1D-to-2D texture overlaps</a>, which fixes problems in <code>Monster Hunter Rise</code> and both the the trial and final versions of <code>Monster Hunter Stories 2: Wings of Ruin</code>.</p> <p>Similarly to how two-dimensional textures are mapped to three dimensions, one-dimensional textures are a simple type of texture that is mapped as two-dimensional when rendered on the screen. The problem here lies in the fact that the GPU is unable to tell the difference between a one-dimensional texture and a two-dimensional texture with a height of one.</p> <p>As such, it was necessary to add support for them, so that they can be processed correctly by our texture cache. With the changes in this PR, Blink made it so that they can be copied seamlessly, fixing this faulty behaviour.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./1d2dbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/1d2dbug_hu5f2f0b014db14a9edd270fcea91f4f7f_694602_800x0_resize_q90_bgffffff_box_3.jpg" alt="From Zero to Hero (MONSTER HUNTER STORIES 2: WINGS OF RUIN Trial Version)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./1d2dfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/1d2dfix_huf98d39d6d8c6c64338be4a3fdb0e6146_2791860_800x0_resize_q90_bgffffff_box_3.jpg" alt="From Zero to Hero (MONSTER HUNTER STORIES 2: WINGS OF RUIN Trial Version)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From Zero to Hero (MONSTER HUNTER STORIES 2: WINGS OF RUIN Trial Version)</p> <p>If you&rsquo;re interested in a more technical explanation about textures and their types, we recommend reading <a href="https://docs.microsoft.com/en-us/windows/win32/direct3d11/overviews-direct3d-11-resources-textures-intro">the D3D11 documentation provided by Microsoft</a>.</p> <h2 id="future-projects">Future projects</h2> <p><code>Project A.R.T.</code>, the designated name for our revival of the resolution scaler, has started, and early results look very promising!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./art.png" title=" Getting blue-shelled at 4K doesn&#39;t really help with anger management (Mario Kart 8 Deluxe)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2021/art_hude6a1ca24805b5f9f3db1624799073f1_10612972_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Getting blue-shelled at 4K doesn&#39;t really help with anger management (Mario Kart 8 Deluxe)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Getting blue-shelled at 4K doesn&#39;t really help with anger management (Mario Kart 8 Deluxe)</p> </div> </div> <p>There are many bugs to fix, optimizations to make, and tons of testing to do before we can confidently release this feature. So for now, know that the scaler is returning!</p> <p>toastUnlimited <a href="https://github.com/yuzu-emu/yuzu/pull/6667">started the preliminary work to get an operational Linux installer</a> to accompany our current Windows one. This also means offering precompiled builds for both Mainline and Early Access. Once it is finished, Linux users will no longer need to be forced to build from the source (if they so prefer)!</p> <p>That’s all folks! As a certain AI singer would say, thank you for your kind attention. See you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report June 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/ Fri, 16 Jul 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/ <p>Heya yuz-ers! Welcome to June’s progress report. This past month, we&rsquo;ve had impressive CPU performance gains, the release of Project Reaper v1, critical audio fixes, an &ldquo;unlimited&rdquo; FPS toggle, tons of kernel changes, UI improvements, and more!</p> <p>Heya yuz-ers! Welcome to June’s progress report. This past month, we&rsquo;ve had impressive CPU performance gains, the release of Project Reaper v1, critical audio fixes, an &ldquo;unlimited&rdquo; FPS toggle, tons of kernel changes, UI improvements, and more!</p> <h2 id="project-texture-reaper">Project Texture Reaper</h2> <p>An old debt we owed since the release of the <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">Texture Cache Rewrite</a> was <code>Project Texture Reaper</code>, a <code>GPU Cache Garbage Collector</code>, originally started by <a href="https://github.com/ReinUsesLisp">Rodrigo</a> and finished by <a href="https://github.com/FernandoS27">Blinkhawk</a> with new and very important optimizations.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6465">This garbage collector</a> has the task of freeing VRAM space by removing the least used resources (textures and buffers), targeting a range of 2 to 4GB of total used VRAM. This range has been decided by Blinkhawk after extensive testing.</p> <p>It’s worth mentioning that GPUs with 2GB of VRAM or less will be handled by either the driver (in OpenGL) or yuzu (in Vulkan), diverting resources to shared VRAM (a portion of system RAM) as needed. For performance reasons, we strongly recommend a GPU with 4GB of VRAM or more.</p> <p>While this is a critical feature for our Windows AMD Radeon and Intel GPU users that suffer from bad OpenGL performance and rendering, all GPU vendors benefit from it. This makes it a safe option to use in most games going forward, with the exception of a few outliers: most notably <code>Super Mario Odyssey</code> running in OpenGL.</p> <p>The end results speak for themselves. Games like <code>Xenoblade Chronicles 2</code> can now be played perfectly fine in either OpenGL or Vulkan. In the following graphs, you can see the effects of Reaper in action. Our test system is running an Nvidia GeForce GTX 1650 SUPER with 4GB of VRAM, and the API in use is Vulkan (in order to avoid any possible driver-level garbage collector).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./reaper1.png" title=" Before"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/reaper1_huc2c40ecb21c83753983584953b9a7170_2764_683x0_resize_q90_bgffffff_box_3.jpg" alt=" Before"></a> <p class="has-text-centered is-italic has-text-grey-light"> Before</p> </div> </div> <p>The above (Before) result has Reaper disabled just after starting the game. VRAM utilization quickly rises to the maximum 4GB available on the testing graphics card. Once the available VRAM is consumed, the GPU driver will start to use system RAM as a fallback, continuing to pile up resources until the application crashes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./reaper2.png" title=" After"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/reaper2_hu717b35fe3f1b4d1c88500d2706d271f9_1898_683x0_resize_q90_bgffffff_box_3.jpg" alt=" After"></a> <p class="has-text-centered is-italic has-text-grey-light"> After</p> </div> </div> <p>The above (After) result has Reaper enabled. You can see how the GPU keeps a steady 2.5-2.6GB of VRAM utilization after several minutes of gameplay, until a sudden spike in use happens. Reaper intervenes and VRAM utilization quickly returns to the average idle of 2.5GB.</p> <p>Reaper is available to all users in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced &gt; Enable GPU Cache Garbage Collector</code>. Due to some issues found in <code>Super Mario Odyssey</code>, the option is disabled by default. We plan to introduce a more robust version in the future. It is expected to be enabled by default then.</p> <p>While previous <code>Disable Dynamic Resolution</code> mods can now be disabled, we recommend keeping them, not only for picture quality purposes, but also to reduce unnecessary resource use by avoiding creating new textures after each resolution change.</p> <h2 id="one-does-not-simply-fastmem-into-windows">One does not simply fastmem into Windows</h2> <p>This was a very exciting month as we were able to <a href="https://github.com/yuzu-emu/yuzu/pull/6422">implement <code>fastmem</code></a>, a technique that provides a considerable performance boost by reducing the CPU load when accessing memory within yuzu. Instead of emulating the Nintendo Switch&rsquo;s Memory Management Unit (<code>MMU</code>) through software, yuzu is now able to use the host PC <code>MMU</code> to decode memory addresses. This reduces the latency and size of the code of this operation, allowing for a more efficient use of the instruction cache (used to store instructions within the CPU and speed up the fetching stage).</p> <p>Originally, implementing <code>fastmem</code> in yuzu wasn&rsquo;t considered an option as there was a technical limitation in the Windows OS, but thanks to some changes in the API introduced in Windows 10 version 1803, it finally became viable. However, due to a lack of documentation of this feature (thanks Microsoft), our devs didn&rsquo;t know they could use it. We&rsquo;d like to thank <a href="https://github.com/BreadFish64/">BreadFish64</a> for informing our devs about this change, and <a href="https://github.com/bylaws">bylaws</a> for <a href="https://github.com/MicrosoftDocs/sdk-api/pull/799">updating Microsoft&rsquo;s documentation regarding this behaviour</a>. As previously mentioned, this feature is incompatible with Windows versions older than 1803. Using an older Windows version will cause yuzu to fallback to the old <code>MMU</code> implementation — although this requirement could change in the future. If you are interested in a more detailed explanation of how it works and the limitations that prevented its implementation, feel free to read the <a href="https://yuzu-mirror.github.io/entry/yuzu-fastmem/">dedicated article for fastmem</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./fastmem1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/fastmem1_hu49f9560544469445580c5ab129245522_90593_800x0_resize_q90_bgffffff_box_3.jpg" alt="Some of the measured performance gains, in FPS"></a> </div> <div class="column is-bottom-paddingless"> <a href="./fastmem2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/fastmem2_huf21840f7b36a43b8c316bf0189f61422_101568_800x0_resize_q90_bgffffff_box_3.jpg" alt="Some of the measured performance gains, in FPS"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Some of the measured performance gains, in FPS</p> <p>Shortly afterwards, <a href="https://github.com/lat9nq">toastunlimited</a> noticed there was a bug in our MinGW builds, resulting in <code>fastmem</code> not working. This was because the defined constant <code>MEM_RESERVE_PLACEHOLDER</code>, a mask value used for reserving virtual memory as a placeholder, was manually imported for these builds, but incorrectly declared. Thankfully, the fix was as simple as redeclaring it with the correct value, which Toast <a href="https://github.com/yuzu-emu/yuzu/pull/6494">did in this PR</a>.</p> <h2 id="core-changes">Core changes</h2> <p>Meanwhile, <a href="https://github.com/MerryMage">Merry</a> tweaked dynarmic to add a <a href="https://github.com/yuzu-emu/yuzu/pull/6499">new unsafe CPU option</a>. This new option optimizes performance for the 32-bit <a href="https://en.wikipedia.org/wiki/ARM_architecture#Advanced_SIMD_(Neon)"><code>ASIMD</code> instructions</a>, improving the performance in titles such as <code>Mario Kart 8 Deluxe</code> and <code>Megadimension Neptunia VII</code>.</p> <p><a href="https://en.wikipedia.org/wiki/Floating-point_arithmetic">Floating-point numbers</a> are represented as an exponent in base 2, and a fixed number of significant bits. But there&rsquo;s a limit to how small a number can be represented as a float, which depends on these significant bits, and the numbers that fall below this threshold are called <a href="https://en.wikipedia.org/wiki/Denormal_number">Denormal Numbers</a>. Depending on the CPU architecture or the instruction performed, these numbers may be ignored and considered zero (called <code>FZ</code> mode, &ldquo;flush to zero&rdquo;), while others are capable of operating with these denormal values. This is the case with these <code>ASIMD</code> instructions, whose logic for floating-point operations is different from other instructions in the <code>ARM</code> architecture. To properly emulate the behaviour of these <code>ASIMD</code> operations, which ignore the <code>FZ</code> flag, it is necessary to modify the <code>MXCSR</code> register — which is a very expensive operation — not only once, but twice (to set and unset this flag before and after every instruction). With this change, it’s now possible to toggle this option on and lose some precision in favour of performance.</p> <p>A few days later, Merry followed up with the affirmation that yes, <a href="https://github.com/yuzu-emu/yuzu/pull/6532">Apple is indeed a POSIX system.</a></p> <p><a href="https://github.com/bunnei">bunnei</a> continues to work on our kernel, and the highlights this month are related to fixes for a number of bugs in some Pokémon games.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6414">By allocating <code>ServiceThreads</code> per service handler instead of per session</a>, a race condition that resulted in crashes and softlocks in <code>Pokken Tournament DX</code> was fixed.</p> <p>In the same vein, a crash affecting <code>Pokémon Sword/Shield</code> — also caused by a race condition — was fixed by <a href="https://github.com/yuzu-emu/yuzu/pull/6428">removing the service thread manager and refactoring the code to use weak pointers</a>. But this wasn&rsquo;t the only kernel change solving a problem with this game. bunnei investigated our session code and fixed another crash caused by <a href="https://github.com/yuzu-emu/yuzu/pull/6441">disconnected sessions trying to overwrite a cloned session&rsquo;s handler</a>. The sessions were also being reserved more times than needed, causing yuzu to run out of available sessions. For this reason, <a href="https://github.com/yuzu-emu/yuzu/pull/6444">he made sure to remove these redundant reservations</a> to solve the problem.</p> <p>bunnei also noticed that the error check for <code>CancelSynchronization</code> — used to manage threads — was missing and <a href="https://github.com/yuzu-emu/yuzu/pull/6440">added it on this PR</a>. This change allows yuzu to avoid a potential crash now, while also making the implementation more accurate.</p> <p>On top of these kernel changes, bunnei has also been implementing more of the changes introduced by version 12.X.X of the Switch’s firmware, allowing <code>DOOM Eternal</code> to boot with its update 1.5 installed — although the game still requires more work in order to start rendering correctly.</p> <h2 id="audio-changes">Audio changes</h2> <p><a href="https://github.com/Kelebek1">Maide</a> investigated the cause of the crackling and popping in the audio of some titles, and came to the conclusion that not enough audio samples were being fed into the sink in order to be played out in your headset or speakers.</p> <p>All games call the <code>RequestUpdateImpl()</code> to send samples into the sink and also to pass other information, such as the <code>sampling rate</code> of the audio signal and the <code>sample count</code> (number of samples to be processed). Some titles — particularly those running at fixed frame rate of 30 FPS — would call this function less frequently than their 60 FPS counterparts, which resulted in not enough audio samples being processed in time and sent into the sink, causing the aforementioned annoying popping.</p> <p>This is how <code>Hellblade: Senua's Sacrifice</code> sounded with the old implementation:</p> <audio preload="auto" controls> <source src="./audiobug.mp3" type="audio/mpeg"> <a href="./audiobug.mp3">Download the audio instead</a> </audio> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/6498">decoupling the processing and sending of audio samples from the update function</a>, the games now will be able to call the update function every time they need it (a process that yuzu can&rsquo;t control), while a separate audio thread will process the sample data and send it to the sink. With this new implementation, yuzu is now capable of scheduling the rate at which it will be sending this audio information based on the <code>sample rate</code> and the <code>sample count</code>. For example: if a game is using a 48 kHz <code>sample rate</code> with a <code>sample count</code> of 240, yuzu will now send the audio data to the sink at a rate of least 200 times per second — enough to keep the buffers full and prevent these problems with the audio.</p> <p>And this is <code>Hellblade: Senua's Sacrifice</code> again, now with the current implementation merged:</p> <audio preload="auto" controls> <source src="./audiofix.mp3" type="audio/mpeg"> <a href="./audiofix.mp3">Download the audio instead</a> </audio> <p>This change fixed the slow audio in titles such as <code>ARK</code>, <code>Bulletstorm</code>, and <code>Megademension Neptunia VII</code>, while also — on top of improving the quality — solving the audio softlocks in <code>Donkey Kong Country: Tropical Freeze</code> and <code>Xenoblade Chronicles 2</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/xc2_hu942eafff102b48ff01c23dfb6ae46666_3342111_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better audio and stable gameplay! (Xenoblade Chronicles 2 &amp; Donkey Kong Country: Tropical Freeze)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./dktf.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/dktf_hu19a82fa91ab3a793cc8c02421fdbaf41_2843884_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better audio and stable gameplay! (Xenoblade Chronicles 2 &amp; Donkey Kong Country: Tropical Freeze)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Better audio and stable gameplay! (Xenoblade Chronicles 2 &amp; Donkey Kong Country: Tropical Freeze)</p> <h2 id="graphical-improvements">Graphical improvements</h2> <p>Let’s start with something nice, <code>Unlimited FPS</code>! <a href="https://github.com/ameerj">Epicboy</a> implemented a toggle that <a href="https://github.com/yuzu-emu/yuzu/pull/6475">allows the rendering service, nvflinger, to disable the buffer swap interval limit,</a> allowing the GPU to process frames as soon as they are available, resulting in no FPS limit on games that allow this behaviour.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./unlimitedfps.png" title=" Beat my framerate!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/unlimitedfps_hu61f8e510487c71b80f206d1958dc5c35_1264031_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Beat my framerate!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Beat my framerate!</p> </div> </div> <p>A default hotkey for toggling the FPS limit was also added, say hello to <code>Ctrl + U</code>! For the best results, <code>Vertical Synchronization</code> (or vSync) should be disabled in the GPU driver control panel, otherwise games will be constrained by the refresh rate of the monitor. Keep in mind, not all games like the setting, some will ignore it, some will not behave well (running faster for example), and some will outright break. Case-by-case user testing applies.</p> <p>Some examples of games that have full dynamic FPS support are:</p> <ul> <li><code>Hollow Knight</code></li> <li><code>DRAGON QUEST BUILDERS 2</code></li> <li><code>Dragon Quest XI S: Echoes of an Elusive Age - Definitive Edition</code></li> <li><code>WORLD OF FINAL FANTASY MAXIMA</code></li> <li><code>FINAL FANTASY XV POCKET EDITION HD</code></li> <li><code>Hungry Shark® World</code></li> <li><code>MONSTER HUNTER STORIES 2: WINGS OF RUIN</code></li> <li><code>NEO: The World Ends with You</code> demo</li> <li><code>MISTOVER</code></li> <li><code>Crash™ Team Racing Nitro-Fueled</code></li> <li><code>Crash Bandicoot™ N. Sane Trilogy</code></li> <li>&hellip;and many more</li> </ul> <p>ASTC texture decoding is a complex topic when it comes to emulation, as no desktop graphics card has the required hardware support needed to process these heavily compressed textures. The only exception is Intel with their integrated HD Graphics and UHD Graphics series.</p> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2021/">In the past,</a> epicboy implemented a way to accelerate ASTC texture decoding via the use of <code>Compute Shaders</code>, improving decoding performance considerably thanks to taking advantage of the great computing power of modern GPUs.</p> <p>The issue is that in some games, <code>Astral Chain</code> for example, a synchronization issue caused yuzu to try to access a texture before its decoding was finished, resulting in driver panics and application crashes. <a href="https://github.com/yuzu-emu/yuzu/pull/6496">Implementing various optimizations and enhancements to the GPU accelerated decoder</a> solved those crashes, even on a simple GT 730, a card 41.5x times weaker than an RTX 2080 SUPER in compute performance.</p> <p>Now that <a href="https://yuzu-mirror.github.io/entry/yuzu-hades/">Project Hades</a> is finished, there are plans to implement performance optimizations on the ASTC GPU accelerated decoder.</p> <p>Prior to this work, <a href="https://github.com/yuzu-emu/yuzu/pull/6464">a toggle to disable the GPU accelerated decoder</a> was added for debugging purposes. It’s no longer needed, but if anyone is curious about how much of a difference decoding with the CPU makes, the option is in <code>Emulation &gt; Configure… &gt; Graphics &gt; Accelerate ASTC texture decoding</code>.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/6469">avoiding creating image views for blits for different bytes per block, </a> Rodrigo solved crashes experienced with Unreal Engine 4 games on Vulkan.</p> <p>Speaking of blits, <a href="https://github.com/vonchenplus">vonchenplus</a> found that our previous way of handling out of bounds texture blits wasn’t accurate enough, causing rendering glitches in games like <code>DRAGON QUEST III The Seeds of Salvation</code>. <a href="https://github.com/yuzu-emu/yuzu/pull/6531">Adding an offset to the source texture address</a> puts this bug to rest.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./blitbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/blitbug_hu39c0570f86f645c5644ff17dcb14865d_919831_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more acne! (DRAGON QUEST III: The Seeds of Salvation)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./blitfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/blitfix_hub483d658f20cc32f4ef37558b813d7a0_908856_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more acne! (DRAGON QUEST III: The Seeds of Salvation)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more acne! (DRAGON QUEST III: The Seeds of Salvation)</p> <p>Some games running in Vulkan, like <code>Super Smash Bros. Ultimate</code> or <code>A Hat in Time</code>, can cause loops decoding textures, resulting in <code>Out of Bounds</code> access on an array, potentially leading to a crash, and breaking our Flatpak support. <a href="https://github.com/yuzu-emu/yuzu/pull/6410">As preemptive work</a>, <a href="https://github.com/lat9nq">toastUnlimited</a> added a <code>break</code> safeguard, and now Flatpaks work as intended. Having less crashes is always better, right?</p> <h2 id="general-changes-and-bugfixes">General changes and bugfixes</h2> <p><code>discord-rpc</code>, the submodule in charge of handling Discord’s <code>Rich Presence</code> “Now Playing” feature, <a href="https://github.com/yuzu-emu/yuzu/pull/6484">was updated</a> by <a href="https://github.com/CaptV0rt3x">Vortex</a> to the last version before it was deprecated in favour of a closed-source alternative named <code>GameSDK</code> which, of course, we can’t use. Since <code>discord-rpc</code> still is compatible with <code>Rich Presence</code>, this update should provide more stable reporting in your Discord Status.</p> <p>Vortex also <a href="https://github.com/yuzu-emu/yuzu/pull/6486">updated <code>httplib</code></a>, removing the need for previous fixes, solving issues with token verification and Compatibility Report uploading.</p> <p>We previously mentioned Flatpak support. <a href="https://github.com/liushuyu">liushuyu</a> requested that <a href="https://flathub.org/home">Flathub</a> add yuzu to their repositories, officially providing <a href="https://flathub.org/apps/details/org.yuzu_emu.yuzu">another installation option</a> for our Linux users.</p> <p>Maide implemented the <code>GetAudioOutPlayedSampleCount</code> service, making <code>Ninja Gaiden</code> series games playable!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ninja1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/ninja1_hu962e34b4960823c11060fd1253c12f5d_1773010_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ninja Gaiden series"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ninja2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/ninja2_hu7cafcfc5f52f308f61d317471e3e3cf0_1939922_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ninja Gaiden series"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ninja3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/ninja3_hu41af33556bbd080be7c63937c6bc289e_1636631_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ninja Gaiden series"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Ninja Gaiden series</p> <p><a href="https://github.com/german77">german77</a> has been having fun rewriting how analog input is handled by yuzu. The old method handled each analog joystick in a separate thread, periodically updating the angle held by the user. This is not only imprecise, but also slower and was found to cause data races, eventually leading to random crashes.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6389">By removing the need for separate threads, and using timestamps the game can consult at its own request</a>, the data race is avoided. This eliminates the crashes, results in considerably smoother movement, and lowers resource utilization, helping performance. A victory in all scenarios!</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6450">Thanks to changes made upstream</a>, <a href="https://github.com/lat9nq">toastUnlimited</a> was able to update the <code>SDL</code> version in use, resolving crashes experienced by Linux users right when opening yuzu.</p> <p><a href="https://github.com/clementgallet">kilaye</a> has been giving us a hand in an often forgotten area of yuzu, the <code>yuzu-cmd</code> binary, which is intended as an SDL2 alternative to the most commonly used <code>yuzu</code> Qt interface binary. <a href="https://github.com/yuzu-emu/yuzu/pull/6412">OpenGL wasn’t rendering</a> due to recent changes applied, and a bad initialization of <a href="https://github.com/yuzu-emu/yuzu/pull/6411">touch_from_button</a> was causing crashes. All were fixed thanks to kilaye’s work.</p> <p>While on an SDL2 rush, kilaye also <a href="https://github.com/yuzu-emu/yuzu/pull/6418">implemented an SDL2 audio backend</a> as an alternative to our default cubeb backend. More work is needed to refine its performance and end-results, but having an easy-to-maintain, multi-platform backend is never a bad idea.</p> <h2 id="filesystem-changes">Filesystem changes</h2> <p>toastUnlimited has been working along with <a href="https://github.com/Morph1984">morph</a> to improve the experience of using the <a href="https://github.com/ultimate-research/UltimateModManager">Ultimate Mod Manager</a> application with yuzu — a tool that allows one to mod <code>Super Smash Bros. Ultimate</code>. First, toast added an option in the context menu of a game to support <a href="https://github.com/yuzu-emu/yuzu/pull/6471">dumping the RomFS to the SDMC subdirectory</a>, while morph <a href="https://github.com/yuzu-emu/yuzu/pull/6472">made the necessary changes</a> for this setup to work.</p> <p>New users intending to use UMM only need to right click the game in yuzu’s game list and select <code>Dump RomFS &gt; Dump RomFS to SDMC</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./umm.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/umm_hu1335599702a043b764226efdec618dd6_21817_526x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>While <a href="https://github.com/yuzu-emu/yuzu/pull/6460">working on new debug options for the filesystem emulation</a>, Morph also fixed certain DLCs that used to make <code>Xenoblade Chronicles 2</code> fail to load at boot with the previous implementation. You can now run the game without major issues, even when fully updated.</p> <p>When dumping RomFS to disk, there has to be enough free space. Morph <a href="https://github.com/yuzu-emu/yuzu/pull/6451">added a check to avoid users trying to dump without enough room.</a></p> <p>Due to a bug in the Microsoft Visual C++ (or just MSVC) compiler, a crash could happen when trying to access folders recursively in order to load game dumps in yuzu’s game list. Morph fixed it by replacing the <code>recursive_directory_iterator</code> class <a href="https://github.com/yuzu-emu/yuzu/pull/6448">with the <code>directory_iterator</code> class</a>.</p> <h2 id="ui-changes">UI changes</h2> <p>Some changes have been done to the title bar by epicboy. To begin with, games will now <a href="https://github.com/yuzu-emu/yuzu/pull/6535">display if they are built for the 32-bit or 64-bit instruction set.</a> This will help determine when <code>Unsafe CPU</code> should be used to get the previously mentioned performance optimization.</p> <p>Additionally, <a href="https://github.com/yuzu-emu/yuzu/pull/6502">the GPU vendor will now be displayed too.</a> This is not only for debugging purposes or providing better support to users, it also clarifies which driver is in use on systems running multiple GPUs. One would think there are only 3 vendors per API, but that’s far from reality. <a href="https://github.com/yuzu-emu/yuzu/pull/6502/files">By checking the list</a>, you can see there are many different reported vendors for different needs, including CPU software rendering drivers.</p> <p>For their first Pull Request with yuzu, <a href="https://github.com/OZtistic">OZ</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6514">corrected the size of the Per-Game configuration window and removed the useless “help” button</a> in the top right corner.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./oz.png" title=" Thanks OZ!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/oz_hu706f4dd0f39c6115fa56376b6e7b3f7c_223083_843x0_resize_q90_bgffffff_box_3.jpg" alt=" Thanks OZ!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Thanks OZ!</p> </div> </div> <p>toastUnlimited added a new option to the right click context menu on any game in yuzu’s game list. You can now <a href="https://github.com/yuzu-emu/yuzu/pull/6426">right click a game and launch it</a> with any custom per-game configuration you may have, or with the current global settings.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./start.png" title=" Quick way to test two different sets of settings"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/start_hu6d057bc1f9155f0d2ee8b2b19fbf3e1a_17998_292x0_resize_q90_bgffffff_box_3.jpg" alt=" Quick way to test two different sets of settings"></a> <p class="has-text-centered is-italic has-text-grey-light"> Quick way to test two different sets of settings</p> </div> </div> <p>Column sizes in the game list used to constantly resize during updates or DLC installation to NAND, resulting in an extreme width that made the game list uncomfortable to use. Maide <a href="https://github.com/yuzu-emu/yuzu/pull/6402">put a stop to this</a>, improving the quality of life of our UI.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/6413">Kewlan</a> is back at it, this time <a href="https://github.com/yuzu-emu/yuzu/pull/6413">preventing users from inputting invalid characters in text windows,</a> for example when creating a new Input Profile.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./text.png" title=" No more 1337 talk"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2021/text_hudc6d6b8a97aecc9c9bed3cadf0048f6c_5608_285x0_resize_q90_bgffffff_box_3.jpg" alt=" No more 1337 talk"></a> <p class="has-text-centered is-italic has-text-grey-light"> No more 1337 talk</p> </div> </div> <h2 id="future-projects">Future projects</h2> <p>With Project Hades <a href="https://yuzu-mirror.github.io/entry/yuzu-hades/">(our new shader decompiler)</a>, Rodrigo continues with his crazy experiments, bunnei has yet more kernel changes in the oven, and german77 and Morph continue to work on their top secret projects.</p> <p>More GPU related optimizations are underway, and users should keep a keen eye on the horizon.</p> <p>That’s all folks! As always, we hope you keep enjoying yuzu. See you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - Shader Decompiler Rewrite https://yuzu-mirror.github.io/entry/yuzu-hades/ Sat, 10 Jul 2021 03:40:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-hades/ <p>Greetings, yuz-ers! The long awaited day is finally here. We are very excited to present to you, <strong>Project Hades</strong>, our shader decompiler rewrite! This massive update includes huge performance improvements, countless bug fixes, and more. Let&rsquo;s get started!</p> <p>Greetings, yuz-ers! The long awaited day is finally here. We are very excited to present to you, <strong>Project Hades</strong>, our shader decompiler rewrite! This massive update includes huge performance improvements, countless bug fixes, and more. Let&rsquo;s get started!</p> <p> </p> <p>Project Hades is now available in the latest <a href="https://yuzu-mirror.github.io/help/early-access/">yuzu Early Access build</a>. As always, we ask that you test various games with these builds and if you encounter any issues, bugs, or crashes, please reach out to us via the <a href="https://discord.gg/u77vRWY">Discord</a> Patreon channels.</p> <article class="message is-warning"><div class="message-header"><p>Notice</p></div><div class="message-body"><p style="color:white">The entire shader generation process has been redesigned from the ground up, thus existing shader caches have been invalidated. Users will need to build their shader caches again, from scratch, with Project Hades.</p></div></article> <h1 id="what-is-project-hades-">What is Project Hades ?</h1> <blockquote> <p><strong>Project Hades</strong> is the codename for our shader decompiler code rewrite, although at this point it&rsquo;s become much more than that.</p> </blockquote> <p>For those who don&rsquo;t know what a shader decompiler is, you&rsquo;ll need to understand the process of how games render (show/display) anything. <a href="https://en.wikipedia.org/wiki/Shader">Shaders</a> are special programs that are coded to perform various tasks on GPUs, typically relating to rendering graphics on display. Shaders are usually written in high-level shader languages compatible with the graphics API in use - e.g. <a href="https://en.wikipedia.org/wiki/OpenGL_Shading_Language">OpenGL Shading Language (GLSL)</a>, <a href="https://en.wikipedia.org/wiki/Standard_Portable_Intermediate_Representation">Standard Portable Intermediate Representation - V (SPIR-V)</a>, and <a href="https://en.wikipedia.org/wiki/ARB_assembly_language">OpenGL ARB Assembly language (GLASM)</a>. Games often use hundreds or thousands of these shaders to tell the GPU what to render and how to do it.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./yuzu_gpu.png" title=" yuzu Shader Generation"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/yuzu_gpu_hu92801aac6d0367ff5db200297e11d194_1208513_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Shader Generation"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Shader Generation</p> </div> </div> <p>In the case of Switch games, they also use shaders to render graphics on the Switch itself. However, since these shaders are precompiled for the Switch&rsquo;s GPU, yuzu cannot use them directly to render graphics using the host GPU (User&rsquo;s GPU). Therefore, yuzu first decompiles these shaders into something called <a href="https://en.wikipedia.org/wiki/Intermediate_representation">IR, or Intermediate Representation</a>, which is then used to generate the high-level <strong>GLSL/SPIR-V/GLASM</strong> shaders used by the graphics APIs and drivers to render games on the host GPU.</p> <p>Shader decompilation is the process of translating the guest (in this case, the Nintendo Switch) GPU machine code to a representation that can be compiled on the host (User&rsquo;s PC) GPU. Shader compilation is the process of taking that representation and sending it to the host GPU driver to get compiled and then executed on the user&rsquo;s GPU.</p> <h2 id="goals">Goals</h2> <p>The main goal of Project Hades was to redesign the decompiler and shader generation code with a focus on simplicity and accuracy. It aimed to make both decompilation and compilation faster overall, thus improving the performance. Rewriting the decompiler would allow us to audit it through <a href="https://en.wikipedia.org/wiki/Unit_testing">unit testing</a>, following a design similar to <a href="https://github.com/MerryMage/dynarmic">dynarmic</a>, allowing proper program analysis and optimizations over fast-to-emit intermediate representation.</p> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Dark%20Souls.png" title=" Dark Souls"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Dark%20Souls_hu4bb822bd111f7f599597b05c187afbd8_6871744_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Dark Souls"></a> <p class="has-text-centered is-italic has-text-grey-light"> Dark Souls</p> </div> <div class="column has-text-centered"> <a href="./Dragon%20Quest%20XI.png" title=" Dragon Quest XI"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Dragon%20Quest%20XI_hub7a69653e5b2cd6e5045fc37a6856eda_9613705_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Dragon Quest XI"></a> <p class="has-text-centered is-italic has-text-grey-light"> Dragon Quest XI</p> </div> </div> <p>Taking a leaf from dynarmic&rsquo;s book, the developers opted to use an <a href="https://en.wikipedia.org/wiki/Static_single_assignment_form">SSA representation</a>, as it would work very nicely with the <code>SPIR-V</code> IR used for shaders, thanks to its native support for SSA. As for the unit testing, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> wrote <a href="https://github.com/ReinUsesLisp/nxgpucatch">homebrew tests for the hardware</a> which helped the developers accurately emulate hardware behaviour.</p> <p>But this was just the beginning. Over the course of a few months, the developers would go on to face and overcome many hurdles with the code rewrite and the Project&rsquo;s goals would expand to accommodate much more.</p> <h1 id="overview-of-changes">Overview of changes</h1> <p>Project Hades was a collaborative effort from developers <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, <a href="https://github.com/FernandoS27">Blinkhawk</a>, and <a href="https://github.com/ameerj">epicboy</a>. They distributed the required work among themselves and spent countless hours in coding, unit testing, game testing, and performance validation.</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> mainly worked on implementing miscellaneous instructions, including texture sampling instructions required for decompilation. He added support for Nvidia&rsquo;s <code>VertexA shader stage</code>, a non-standard shader stage available on Nvidia hardware that is executed before the regular <code>VertexB shader stage</code>.</p> <p>This allowed games such as <code>Catherine: Full Body</code>, <code>Bravely Default 2</code>, and <code>A Hat in Time</code> to render graphics for the first time. <a href="https://github.com/FernandoS27">Blinkhawk</a> also fixed an issue in yuzu&rsquo;s texture cache relating to the texture streaming used in Unreal Engine 4 (UE4) games, resolving many of their rendering issues.</p> <p><strong>Note:</strong> Due to a race condition in our GPU Emulation, to render Catherine Full Body correctly, you may need to disable Asynchronous GPU Emulation.</p> <p> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Catherine.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Catherine_hu4b3214fd3ec49dbdfb814eca3113b3f0_3119614_800x0_resize_q90_bgffffff_box_3.jpg" alt="Catherine: Full Body"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Catherine_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Catherine_2_hu9896ecf641cbf42daab0bc11f20973bb_5294932_800x0_resize_q90_bgffffff_box_3.jpg" alt="Catherine: Full Body"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Catherine: Full Body</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Hat%20in%20Time.png" title=" A Hat in Time"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Hat%20in%20Time_hua599f4cf11a03ed570fb38ae3ffc065d_4904946_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" A Hat in Time"></a> <p class="has-text-centered is-italic has-text-grey-light"> A Hat in Time</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Bravely_Default_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Bravely_Default_2_hu96f0056f921c1fc040e8b513badda00c_4860834_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bravely Default II"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Bravely_Default_2_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Bravely_Default_2_2_hueced9db7a9f39a8767d147b99f8d7e10_4479365_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bravely Default II"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Bravely Default II</p> <p><a href="https://github.com/ameerj">epicboy</a> implemented almost all of the arithmetic, logical, and floating-point instructions, as well as developing the entire GLSL backend. <strong>GLSL</strong> is the default backend, when the OpenGL API is selected in the yuzu configuration settings.</p> <p>The <strong>GLSL</strong> backend rewrite was not part of the initial plan for Project Hades, as the developers only intended to work on <strong>GLASM</strong> and <strong>SPIR-V</strong>, but it was later included due to how buggy and slow some OpenGL <strong>SPIR-V</strong> compilers are. That said, some OpenGL drivers benefit greatly from the use of <strong>SPIR-V</strong> shaders, so the choice of using <strong>SPIR-V</strong> on OpenGL is left as an experimental setting.</p> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Mario%20and%20rabbids.png" title=" Mario and Rabbids"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Mario%20and%20rabbids_huec273303423fde9f672c2636430d328a_7003814_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Mario and Rabbids"></a> <p class="has-text-centered is-italic has-text-grey-light"> Mario and Rabbids</p> </div> <div class="column has-text-centered"> <a href="./monchrome_hades.png" title=" Monochrome"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/monchrome_hades_huece621bca4f925b0ed80429fead088d8_1647911_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Monochrome"></a> <p class="has-text-centered is-italic has-text-grey-light"> Monochrome</p> </div> </div> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> designed the overall structure to support these changes, and developed multiple optimization passes to improve performance wherever possible. In addition to that, he rewrote the entire <strong>GLASM</strong> (GL Assembly) backend, and integrated the existing frontend rasterizers with the new backends.</p> <p>The <strong>GLASM</strong> backend is a special path where the decompiled shaders (<a href="https://en.wikipedia.org/wiki/Assembly_language">assembly language</a>) skip the shader compilation steps on the host GPU, thus improving the performance. Unfortunately, <strong>GLASM</strong> is only supported by Nvidia GPUs, limiting the scope of this performance boost.</p> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="Crash%20Bandicoot%204.png" title=" Crash Bandicoot 4"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Crash%20Bandicoot%204_hu5e6d6507231ee50224f88d4e3c9fe34f_4705630_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Crash Bandicoot 4"></a> <p class="has-text-centered is-italic has-text-grey-light"> Crash Bandicoot 4</p> </div> <div class="column has-text-centered"> <a href="world-of-ff-hades.jpg" title=" World of Final Fantasy"><img src="world-of-ff-hades.jpg" alt=" World of Final Fantasy"></a> <p class="has-text-centered is-italic has-text-grey-light"> World of Final Fantasy</p> </div> </div> <p>While these were the major changes, there were also many other minor improvements. Changing how the shaders are generated also meant changing the way shader information is presented to the renderers. This was overhauled for simplicity, which led to some new features, and ease of caching.</p> <h2 id="vulkan-pipeline-caching">Vulkan Pipeline Caching</h2> <p>All the information required to generate pipelines from scratch now gets cached to disk, thereby removing shader stutter almost completely on Vulkan. In contrast, OpenGL can still encounter shader stutters due to unpredictable or undocumented state changes. Vulkan still can have minor stutters when new shaders are detected, but it hasn&rsquo;t been noticeable during our testing.</p> <h2 id="asynchronous-pipeline-creation">Asynchronous Pipeline Creation</h2> <p>yuzu already supported <code>Asynchronous Shaders</code>, where draw calls are skipped (rendering is paused) until the shader, or in Vulkan&rsquo;s case, the pipeline, is compiled. This is nice in some cases because it allows for more consistent play sessions, minimizing stutter from shader compilations. But this also has a big drawback: it introduces graphical glitches, which are sometimes persistent throughout the play session. While this is not an issue after restarting emulation and having the shaders cached, it&rsquo;s not optimal.</p> <p>A better way to implement this for Vulkan was to build pipelines in parallel without skipping draw calls. In other words, continue processing GPU commands while the pipelines are being built. This allows building one pipeline per CPU thread (minus one) in parallel while the game is executing. This results in reduced stutter that is, in a way, similar to skipping draw calls.</p> <article class="message"><div class="message-header">How does this work?</div><div class="message-body"> To understand why this is possible, it's necessary to explain how yuzu's Vulkan command recording works. Commands are recorded and deferred to a separate thread for processing (sometimes called the "Command Submission (CS) thread").<br> <br> This thread runs in parallel to the main GPU thread. This means the CS thread can build the pipelines sequentially while the main GPU thread continues its execution, periodically pushing new commands to the CS thread.<br> <br> Sadly, this is not possible at the moment on OpenGL, because drivers wait more often for their CS thread than yuzu on its own CS thread. It may be possible if we optimize the whole OpenGL backend to avoid "glGen*" and "glGetSynciv" calls within a draw call. </div></article> <h2 id="even-more">Even more!!</h2> <p>On top of these big improvements, we also have many minor optimizations. Some notable ones are listed below:</p> <ul> <li>Project Hades keeps track of the number of bytes used in constant buffers and passes this information to the buffer cache. This reduces the number of uploaded bytes on some titles, thus improving performance.</li> <li>Vulkan command submission to the GPU now happens on the separate CS thread, increasing performance by 1 to 2 FPS in <code>Super Mario Odyssey</code>, although presentation to screen is still being synchronized.</li> <li>Synchronization for <a href="https://www.khronos.org/opengl/wiki/Buffer_Texture">texture buffers</a> between the texture cache and the buffer cache, fixing some crashes on Koei Tecmo games.</li> <li>Generate specialized Vulkan descriptor pools, sharing pools within similar pipelines. This reduces memory consumption and boot time on most drivers, saving ~700 MiB of VRAM on AMD compared to the previous approach.</li> <li>Usage of <a href="https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VK_KHR_push_descriptor.html">VK_KHR_push_descriptor</a> when available. Reduces the overhead of updating descriptor sets on Nvidia by 57% and by 10% on Intel (measured on <code>Super Smash Bros. Ultimate</code> 1v1 on Final Destination). It also reduces memory consumption but this hasn&rsquo;t been measured.</li> <li>Usage of <a href="https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VK_EXT_conservative_rasterization.html">VK_EXT_conservative_rasterization</a> and <a href="https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VK_EXT_provoking_vertex.html">VK_EXT_provoking_vertex</a> when available.</li> <li>Use specialized &ldquo;pre-draw&rdquo; functions per pipeline to reduce unnecessary work.</li> <li><code>Texture Reaper</code>, which cleans the least used resources in your VRAM to reduce VRAM usage. We will cover this and others, in detail, in our next progress report.</li> </ul> <h1 id="graphical-fixes">Graphical fixes</h1> <p>Thanks to the redesign and reimplementation of our entire shader generation code, the developers were able to investigate and identify the causes for graphical glitches in many games. In fact, some games like <code>Yoshi's Crafted World</code>, <code>Trials of Mana</code>, <code>Minecraft Dungeons</code>, and many others, now render almost perfectly. <code>The Legend of Zelda: Breath of the Wild</code> is now fully playable on Vulkan.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./BOTW_Vulkan.png" title=" Breath of the Wild (fixed runes in Vulkan)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/BOTW_Vulkan_hu41cc6fb4552daa198aad01711681b8b8_5282307_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Breath of the Wild (fixed runes in Vulkan)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Breath of the Wild (fixed runes in Vulkan)</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw-ea.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/botw-ea_hu3d00fdf11e56b3c643c6c4052e5fe98b_2179212_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw-hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/botw-hades_hucad959a175ecaec1f8864972593763e6_2418285_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild (EA Vs. HADES)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Yoshi%27s%20Crafted%20World.png" title=" Yoshi&#39;s Crafted World"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Yoshi%27s%20Crafted%20World_hu1dee2d59b199ca1e1353d7909bba9f99_5373685_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Yoshi&#39;s Crafted World"></a> <p class="has-text-centered is-italic has-text-grey-light"> Yoshi&#39;s Crafted World</p> </div> <div class="column has-text-centered"> <a href="./bd2.png" title=" Bravely Default II"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/bd2_hufa2eee2f863e015dcb4b8354a8f38746_3106185_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Bravely Default II"></a> <p class="has-text-centered is-italic has-text-grey-light"> Bravely Default II</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./minecraft_dungeons.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/minecraft_dungeons_huae9e9fb51969176748db0d5de4e62076_2959134_800x0_resize_q90_bgffffff_box_3.jpg" alt="Minecraft Dungeons"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Minecraft_Dungeons_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Minecraft_Dungeons_2_hucb574f453fe9b21308f266bdbd9ec57e_4776520_800x0_resize_q90_bgffffff_box_3.jpg" alt="Minecraft Dungeons"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Minecraft Dungeons</p> <p>The broken bloom, causing sand and fog in <code>Super Mario Odyssey</code> to render incorrectly, is now fixed!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo_sand_ea.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/smo_sand_ea_hu5eb1f3af53cb9e0d79864366b14d46fa_3155555_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo_sand_hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/smo_sand_hades_hu687e40c3f6796522dab56f4bb70579b0_2855700_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo_fog_ea.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/smo_fog_ea_hu927726ef8b6d14845d96e30b56fbe5a1_4521519_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo_fog_hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/smo_fog_hades_hu804cbb5b15c50c0ab02a7773d0d1eac5_4292521_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (EA Vs. HADES)</p> <p>Thanks to the implementation of tessellation shaders, the sand in <code>Luigi's Mansion 3</code> is no longer broken! <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Luigis%20Mansion%203.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Luigis%20Mansion%203_hudf7fb30f9a91fd0d8d5068b8ed345dd1_3153371_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> </p> <p>Various graphical glitches, crashes and general stability issues in <code>Fire Emblem: Three houses</code>, <code>Hyrule Warriors: Age of Calamity</code>, <code>Marvel Ultimate Alliance 3</code>, <code>Persona 5 Strikers</code>, and <code>Xenoblade Chronicles</code> were also fixed.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Fire%20emblem%20Three%20houses.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Fire%20emblem%20Three%20houses_hu8f39cdf45ad3d981dad8d7e3b9dd0455_7364437_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Three Houses"></a> </div> <div class="column is-bottom-paddingless"> <a href="./feth1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/feth1_hu126c279a2868b535fffa25f7aca636e9_2720351_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Three Houses"></a> </div> <div class="column is-bottom-paddingless"> <a href="./feth2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/feth2_hu496ef06f876dee824fcd43a6d0b8e4ee_3401237_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Three Houses"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fire Emblem: Three Houses</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./AOC_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/AOC_2_hu276b87c01d91dade1af7f256f81b3e3d_4338315_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors: Age of Calamity"></a> </div> <div class="column is-bottom-paddingless"> <a href="./AOC_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/AOC_3_hu7fddf97b4f7f419220255e9f20ea6772_4702082_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors: Age of Calamity"></a> </div> <div class="column is-bottom-paddingless"> <a href="./AOC_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/AOC_4_huceeb667b0ea2aed1cee1984f194e5f72_4208369_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors: Age of Calamity"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hyrule Warriors: Age of Calamity</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Marvel%20Ultimate%20Alliance%203.png" title=" Marvel Ultimate Alliance 3"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Marvel%20Ultimate%20Alliance%203_hu8fd1d5c891f2dcac7f2e3a37e8ae8900_3974015_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Marvel Ultimate Alliance 3"></a> <p class="has-text-centered is-italic has-text-grey-light"> Marvel Ultimate Alliance 3</p> </div> <div class="column has-text-centered"> <a href="./Hyrule_Warriors_DE.png" title=" Hyrule Warriors Definitive Edition"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Hyrule_Warriors_DE_hu6e760e9977e7e60b4621329474643070_4022138_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Hyrule Warriors Definitive Edition"></a> <p class="has-text-centered is-italic has-text-grey-light"> Hyrule Warriors Definitive Edition</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./P5S.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/P5S_hu9df0358370a47e98b357c8039aaff192_634220_800x0_resize_q90_bgffffff_box_3.jpg" alt="Persona 5 Strikers"></a> </div> <div class="column is-bottom-paddingless"> <a href="./P5S_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/P5S_2_huf9c00d1863e8d739edae0f750392b60e_2881807_800x0_resize_q90_bgffffff_box_3.jpg" alt="Persona 5 Strikers"></a> </div> <div class="column is-bottom-paddingless"> <a href="./P5S_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/P5S_3_huc3f3f9502a985a296975c084dc837b7f_2916964_800x0_resize_q90_bgffffff_box_3.jpg" alt="Persona 5 Strikers"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Persona 5 Strikers</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc-ea.jpg" title=""><img src="./xc-ea.jpg" alt="Xenoblade Chronicles (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc-hades.jpg" title=""><img src="./xc-hades.jpg" alt="Xenoblade Chronicles (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Xenoblade Chronicles (EA Vs. HADES)</p> <p><code>Hollow Knight's</code> issue with transparent textures has been fixed. <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hollow_knight_ea.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/hollow_knight_ea_hu73a02a4a60254979235c628c88139f60_1976672_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hollow Knight (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hollow_knight_hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/hollow_knight_hades_hubfd635b9ed39bb9fa543891bd36ffc93_2029908_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hollow Knight (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hollow Knight (EA Vs. HADES)</p> </p> <p><code>Kirby Star Allies</code>, <code>Mario Kart 8 deluxe</code>, <code>Tony Hawk Pro Skater</code>, <code>Story of Seasons</code>, and <code>Clubhouse</code> games, were among many other titles that saw graphical glitches fixed. <code>Rune Factory 4</code> renders perfectly now and <code>Rune Factory 5</code> has improved rendering.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kirby-ea.jpg" title=""><img src="./kirby-ea.jpg" alt="Kirby Star Allies (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kirby-hades.jpg" title=""><img src="./kirby-hades.jpg" alt="Kirby Star Allies (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Kirby Star Allies (EA Vs. HADES)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./MK8_EA.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/MK8_EA_hu2eb988e5012a87e87f8560a835f07f97_3359581_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./MK8_Hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/MK8_Hades_hu6af1bae841fb8159e8d2bdcfa1568150_3452946_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mario Kart 8 Deluxe (EA Vs. HADES)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./tonyhawk-ea.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/tonyhawk-ea_hub823b10f3fbf400511efe6b23224d5fa_1322348_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tony Hawk Pro Skater (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./tonyhawk-hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/tonyhawk-hades_hucada89fd6bc6fd329b7a586e680a8f00_2958317_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tony Hawk Pro Skater (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Tony Hawk Pro Skater (EA Vs. HADES)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./story-of-seasons_ea.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/story-of-seasons_ea_huc2ebb6ee57b130e9f1082d71e771e12b_2624380_800x0_resize_q90_bgffffff_box_3.jpg" alt="Story of Seasons (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./story-of-seasons_hades.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/story-of-seasons_hades_hu64a1232677bea6322cf4fa18a4fa7223_3350112_800x0_resize_q90_bgffffff_box_3.jpg" alt="Story of Seasons (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Story of Seasons (EA Vs. HADES)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./runefactory-ea.jpg" title=""><img src="./runefactory-ea.jpg" alt="Rune Factory 4 (EA Vs. HADES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./runefactory-hades.jpg" title=""><img src="./runefactory-hades.jpg" alt="Rune Factory 4 (EA Vs. HADES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Rune Factory 4 (EA Vs. HADES)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Rune_Factory_5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Rune_Factory_5_huc78fe89e2df3de5fca7cf4b5e65fff3e_4569873_800x0_resize_q90_bgffffff_box_3.jpg" alt="Rune Factory 5"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Rune_Factory_5_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Rune_Factory_5_2_hu044e5045c5ae5987e06a13eb8272b252_5408641_800x0_resize_q90_bgffffff_box_3.jpg" alt="Rune Factory 5"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Rune Factory 5</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Trials%20of%20mana.png" title=" Trials of Mana"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Trials%20of%20mana_hu7495918c6d02b54bf688df179d70927b_5929794_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Trials of Mana"></a> <p class="has-text-centered is-italic has-text-grey-light"> Trials of Mana</p> </div> <div class="column has-text-centered"> <a href="./clubhouse.png" title=" Clubhouse"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/clubhouse_hu0d5abf495636586e8c77dae671be8f94_1773136_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Clubhouse"></a> <p class="has-text-centered is-italic has-text-grey-light"> Clubhouse</p> </div> <div class="column has-text-centered"> <a href="./farm_sim_20.png" title=" Farming Simulator 20"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/farm_sim_20_hu96df3ce91c0e7951e0f9b0dd34f94905_3638083_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Farming Simulator 20"></a> <p class="has-text-centered is-italic has-text-grey-light"> Farming Simulator 20</p> </div> </div> <h3 id="and-many-more">And many more!!</h3> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Densha_de_Go.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Densha_de_Go_hu65e378351049ff0c7c3e1e3a5f564488_2340572_800x0_resize_q90_bgffffff_box_3.jpg" alt="Densha de Go"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Densha_de_Go_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Densha_de_Go_2_hu7785ad342f1278d73cb5da6fa57e58d9_3245778_800x0_resize_q90_bgffffff_box_3.jpg" alt="Densha de Go"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Densha de Go</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./FF_XII.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/FF_XII_hubfe436b85b10d79c7fd71063b732faa0_1152532_800x0_resize_q90_bgffffff_box_3.jpg" alt="Final Fantasy XII"></a> </div> <div class="column is-bottom-paddingless"> <a href="./FF_XII_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/FF_XII_2_hu71a1b6e8376e15b6d1714471e99099f6_1744003_800x0_resize_q90_bgffffff_box_3.jpg" alt="Final Fantasy XII"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Final Fantasy XII</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hellblade.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/hellblade_hu46f9cc1e115ed0dcf3ba894a76717a60_2243631_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hellblade: Senua&#39;s Sacrifice"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hellblade_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/hellblade_2_hu717702cf97d784101d0d9e90c54120b0_2025895_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hellblade: Senua&#39;s Sacrifice"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hellblade: Senua&#39;s Sacrifice</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Spyro_Reignited.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Spyro_Reignited_hub563145b6bdbf5f62e206d4e946511c9_1594716_800x0_resize_q90_bgffffff_box_3.jpg" alt="Spyro Reignited Trilogy"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Spyro_Reignited_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/Spyro_Reignited_2_huaad40072b770e26fb0e02119c8e727ae_1974313_800x0_resize_q90_bgffffff_box_3.jpg" alt="Spyro Reignited Trilogy"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Spyro Reignited Trilogy</p> <h1 id="alright-lets-talk-numbers-now">Alright! Let&rsquo;s talk numbers now!</h1> <p>Project Hades rewrote a vast majority of the GPU code and made tons of improvements and optimizations to boost the performance. Since the changes touched on many areas of the GPU emulation, we observed performance improvements in many titles.</p> <p>Below are some performance comparison charts between yuzu Early Access (1860) and Project Hades on our recommended specifications using Vulkan API. Please note that at the time of comparison, EA 1860 was almost equivalent to yuzu Mainline, with no changes that would significantly affect performance.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./perf-1.png" title=" Recommended Specs (* is OpenGL)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/perf-1_hu473a6e90981a7ad473f304347797404c_26621_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Recommended Specs (* is OpenGL)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Recommended Specs (* is OpenGL)</p> </div> </div> <p>That&rsquo;s not all. The improvements made to the Vulkan backend in Project Hades have greatly improved performance for AMD GPU users on Linux (RADV).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./perf-2.png" title=" Linux AMD (RADV)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-hades/perf-2_huc2e74ba1b28fdf2605402809760b2731_82713_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Linux AMD (RADV)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Linux AMD (RADV)</p> </div> </div> <p>These are just a small testament to the performance improvements that Hades brings. We will be sharing more performance charts with our next progress report.</p> <h1 id="fin">Fin</h1> <p>Our development efforts were massively accelerated by our testers, who tested dozens of titles for bugs, fixes, and performance regressions. Since our testing couldn&rsquo;t realistically cover all titles, we request that you test and play your favourite games in yuzu and experience the improvements yourselves. While testing, if you come across any regressions, glitches, bugs, or crashes, please reach out to us via our Discord Patreon Channels. This will assist us in identifying and fixing any potential issues Project Hades might present.</p> <h3 id="thats-all-we-have-for-now-until-next-time-happy-emulating">That&rsquo;s all we have for now, until next time! Happy emulating!</h3> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report May 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/ Thu, 10 Jun 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/ <p>Hola yuz-ers! It&rsquo;s time yet again for another progress report! We have dozens of changes to discuss: Kernel fixes, input and UI improvements, graphical updates, the saga of the legendary dot, and even a method to procure extra VRAM!</p> <p>Hola yuz-ers! It&rsquo;s time yet again for another progress report! We have dozens of changes to discuss: Kernel fixes, input and UI improvements, graphical updates, the saga of the legendary dot, and even a method to procure extra VRAM!</p> <h2 id="pokémon-snap-but-its-new">Pokémon Snap, but it’s New</h2> <p><code>New Pokémon Snap</code>’s release resulted in tons of work needed to make the game playable. For starters, Snap experienced crashes during gameplay, an issue <a href="https://github.com/ameerj">epicboy</a> was not happy about. The <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/">buffer cache rewrite</a> introduced an optimized fast path for <code>uniform bindings</code>, but the conditions to take advantage of it are that buffers must be both small and <em>non-null</em>. Turns out, null buffers were not being explicitly checked for, causing instabilities along the way. <a href="https://github.com/yuzu-emu/yuzu/pull/6322">Properly checking for those zero sized buffers</a> fixed the stability issues the new Snap was facing.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/1_hue8994bfb41fe47113d39d0ee8ee9067f_4733050_800x0_resize_q90_bgffffff_box_3.jpg" alt="New Pokémon Snap"></a> </div> <div class="column is-bottom-paddingless"> <a href="./2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/2_huac17e32688fdb6c177cecb39eaa3625d_5288088_800x0_resize_q90_bgffffff_box_3.jpg" alt="New Pokémon Snap"></a> </div> <div class="column is-bottom-paddingless"> <a href="./3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/3_hube9e18280c58039b95a27d1718bcccef_4483400_800x0_resize_q90_bgffffff_box_3.jpg" alt="New Pokémon Snap"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">New Pokémon Snap</p> <p><a href="https://github.com/Morph1984">Morph</a> has been working hard on implementing much needed fixes in yuzu&rsquo;s file system emulation. In this particular case, <a href="https://github.com/yuzu-emu/yuzu/pull/6265">improving the accuracy of CreateFile</a> fixes the saving and loading issues Snap was experiencing. Unexpectedly, the error codes of conditions like “parent directory doesn’t exist” or “path already exists” were incorrect, causing havoc in the file system emulation.</p> <p>Snap also revealed flaws in our touch screen gesture emulation. Thanks to work done by <a href="https://github.com/yuzu-emu/yuzu/pull/6275">german77</a>, yuzu <a href="https://github.com/yuzu-emu/yuzu/pull/6267">now properly supports multiple fingers</a>.</p> <p>GPU emulation related issues stop this game from being perfectly playable. In its current status, photos are not recognized when they are evaluated at the end of a stage. <a href="https://bugs.dolphin-emu.org/issues/4460">Like mother, like daughter</a>. This can be partially solved by using High GPU accuracy in OpenGL with Assembly Shaders enabled, or for non-Nvidia users, using Extreme GPU accuracy on Vulkan.</p> <h2 id="graphical-fixes">Graphical fixes</h2> <p>Texture blits (bit block transfers, a combination of bitmaps) can sometimes work out of bounds by interleaving copy regions, by design. yuzu has to be able to <a href="https://github.com/yuzu-emu/yuzu/pull/6289">properly emulate this behaviour</a> and return the correct portion, something epicboy had no problem properly implementing for us.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./blits.png" title=" Here’s a beautifully detailed example of the old out-of-bounds incorrect behaviour in red, and the correct result in blue, with the affected area moving to the next row, as it should"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/blits_hub987128d074f901733e30b7431f6c8fc_8248_550x0_resize_q90_bgffffff_box_3.jpg" alt=" Here’s a beautifully detailed example of the old out-of-bounds incorrect behaviour in red, and the correct result in blue, with the affected area moving to the next row, as it should"></a> <p class="has-text-centered is-italic has-text-grey-light"> Here’s a beautifully detailed example of the old out-of-bounds incorrect behaviour in red, and the correct result in blue, with the affected area moving to the next row, as it should</p> </div> </div> <p>The result is quite noticeable in games that use this blit technique, such as <code>Shantae</code> and <code>Pixel Game Maker Series Werewolf Princess Kaguya</code>, which we mentioned in the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/">previous progress report</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./shantae-bug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/shantae-bug_hu10017b9eb08ad162879e7c6c6f46e2d5_1457400_800x0_resize_q90_bgffffff_box_3.jpg" alt="Textures and text rendering correctly, notice the stairstepping on the right side of the left image"></a> </div> <div class="column is-bottom-paddingless"> <a href="./shantae-fix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/shantae-fix_hu08fff6eda3ca9caf07cb46e36893981c_1425921_800x0_resize_q90_bgffffff_box_3.jpg" alt="Textures and text rendering correctly, notice the stairstepping on the right side of the left image"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Textures and text rendering correctly, notice the stairstepping on the right side of the left image</p> <p>Thanks to user reports, it was brought to our attention that our FPS counter in the lower right corner of yuzu’s window was not accurate. The readings were previously accurate when the GPU thread was synchronous with the other services. Now that asynchronous GPU emulation is implemented, this is no longer the case.</p> <p>The solution epicboy came up with is, instead of letting the nvflinger service handle the counter, <a href="https://github.com/yuzu-emu/yuzu/pull/6317">let the graphics API inform the counter after it finishes drawing the frame</a>. This way, the value is far more accurate and stable on performance oscillations. Additionally, the update frequency of the counter was changed from 2000 ms to 500 ms to allow for more frequent and up-to-date information to be displayed.</p> <p>And now for a big update for Vulkan users waiting for <code>Project Reaper</code> to leave the development board. The previous Vulkan <code>memory allocator</code> used local memory as top priority (that’s the physical VRAM on your dedicated GPU), and only used host memory in certain applicable cases. These cases varied depending on how the GPU driver informed the different memory heaps available to yuzu, primarily in keeping critical required information closer to the CPU.</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> implemented a new method (solving some issues with the old one) that <a href="https://github.com/yuzu-emu/yuzu/pull/6367">allows yuzu to access all the available host memory</a>. Up to 50% of the total system RAM is available to the GPU as host memory, or as Windows calls it in the Task Manager, GPU shared memory. This change means that the GPU effectively has more RAM available to use with Vulkan, helping delay our sadly infamous out-of-memory issues with this API.</p> <p>For those that can’t wait, want to test an in-development partial solution, and have experience with git, <a href="https://github.com/Kelebek1">Maide</a> has been working on what can be called a <a href="https://github.com/yuzu-emu/yuzu/pull/6378">“light Reaper”</a>. This is a simpler version of what Rodrigo plans to release in the future, working as a garbage collector on a configurable fixed timer. For anyone interested and with the time to spare in building yuzu manually, the PR is open to be tested. We don’t plan to merge it for now as it needs as much refinement as the regular Reaper to provide a pleasant user experience.</p> <p><a href="https://github.com/bunnei">bunnei</a> removed <a href="https://github.com/yuzu-emu/yuzu/pull/6372">the risk of an overflow in the rasterizer cache</a> by doubling the size of the responsible array.</p> <p>The Nintendo Switch shares its RAM with both the CPU and GPU, so games are free to assume any information in VRAM will be the same in RAM (since it physically is). As PCs don’t allow this (even on integrated GPU systems), yuzu has to keep track of any memory pages in use by the GPU to ensure that all information is also reflected in system RAM. The previous limit of 255 references was observed to be surpassed in some rare instances during testing, resulting in utter chaos, so this PR increases it to a maximum of 65535.</p> <p>All of this costs the user 2<em>MB</em> of RAM instead of the previous 1<em>MB</em>. Such a heavy price to pay for the additional peace of mind, Google Chrome would be proud of us.</p> <h2 id="core-changes-and-improvements">Core changes and improvements</h2> <p><a href="https://github.com/bunnei">bunnei</a> migrated our old implementation of kernel objects to <a href="https://github.com/yuzu-emu/yuzu/pull/6266">KAutoObjects</a>, which is part of the newly written implementations that have been added in the past months to match more closely to that of how the kernel of the Nintendo Switch works.</p> <p>Previously, our kernel objects, such as condition variables, events, threads, processes, etc., used the C++ <code>std::shared_ptr</code> (a type of smart pointer) in their implementation. Whenever a new instance of a shared pointer reference is made using one of these pointers, a counter is automatically increased to keep track of them. Similarly, whenever one of the references isn&rsquo;t needed anymore, the counter decreases its value and the reference is discarded. However, the implementation doesn&rsquo;t necessarily reflect the way the Nintendo Switch&rsquo;s kernel deals these objects and their reference counters. Thus, the advantage of implementing these <code>KAutoObjects</code> is that it allows yuzu to manage when these objects are created and destroyed, accurately.</p> <p>This was a big change that involved refactoring the codebase for consistency and fleshing out the implementation of various existing kernel objects and their definitions to match the new behaviour correctly.</p> <p>Part of the work also involved improving some system calls (the so-called <code>SVCs</code>) by implementing missing calls such as <code>UnmapSharedMemory</code>, and making the implementation of other calls more robust (e.g. better error checking, etc.). These <code>SVCs</code> are functions used by games to communicate with the rest of their system, in order to create events, manage them, or send information to other services such as audio and graphics. They are essential for the communication between processes and the OS, so their correct functioning is imperative, as they are the programs that run whenever a game needs the kernel to perform operations that require elevated permissions.</p> <p>With the introduction of the firmware version <code>12.0.0</code>, the protocol of <a href="https://en.wikipedia.org/wiki/Inter-process_communication">Inter-Process Communication</a> (<code>IPC</code>) has also been updated. bunnei worked on <a href="https://github.com/yuzu-emu/yuzu/pull/6299">various improvements to the IPC and session management</a> with the aim to support <code>TIPC</code> — the new protocol.</p> <p><code>IPC</code> is a mechanism provided by the OS and used by processes to communicate between themselves, usually to manage or cooperate in the processing of some shared resource — such as a memory region, a file, etc. A <code>session</code> in this context refers to an object that is created to manage the information exchange between a client (i.e. games) and a server (services that the game uses to render graphics, play audio, get user input, etc.). With these changes, the code in charge of <code>session management</code> has been updated to support the new <code>IPC</code> protocol, additionally fixing a number of inaccuracies in some of the error-checking functions. bunnei has also greatly simplified the original <code>IPC</code> code, which should improve the memory usage and performance of these operations.</p> <p>As a consequence of the changes introduced in the previous <code>KAutoObject</code> PR, the maximum values for many of the kernel objects have started to be enforced. This resulted in crashes in games that open and close sessions often, such as <code>Nintendo Labo</code>, <code>Pokémon Sword</code>, and <code>Pokémon Shield</code>, due to yuzu not managing sessions correctly. The root problem was also the cause of small memory leaks that hadn&rsquo;t been noticed until now, since the sessions weren&rsquo;t being properly closed and remained in memory. For this reason, bunnei implemented mechanisms for moving and closing objects in a <a href="https://github.com/yuzu-emu/yuzu/pull/6347">follow-up PR</a>, which corrected the way the session counter and its opening and closing operations worked.</p> <p>There are still many other kernel objects to migrate and, for this reason, bunnei introduced a PR to make the <a href="https://github.com/yuzu-emu/yuzu/pull/6373">KSlabHeap use both guest and host allocations</a>, as this will facilitate the process while missing functions and other structures are being implemented.</p> <p>Simply put, the <a href="https://en.wikipedia.org/wiki/Slab_allocation">slab heap</a> is a structure used to store kernel elements more efficiently in memory in a <a href="https://en.wikipedia.org/wiki/Linked_list">linked list</a>, based on their size. All the slots in a slab of memory have the same size, and there can be lists of different sizes to store different objects too. Instead of allocating and deallocating memory, the kernel marks the nodes on the list as &ldquo;used&rdquo; or &ldquo;free,&rdquo; so when it needs to store a new object, it looks for a free slot and overwrites the data there. On the other hand, if an object is not needed anymore, the node where it&rsquo;s stored is marked as &ldquo;free&rdquo; so that it can be used to store a new object. This way, the kernel will find frequently-requested memory sizes available more quickly, providing a small optimization to the whole process.</p> <p>As of yet, yuzu doesn&rsquo;t emulate the complete memory structure of the Nintendo Switch. The emulated memory space only provides enough functionality to run a single process (i.e. a game), while every other service, such as the kernel, is allocated outside of the virtual memory. This implementation works because the games aren&rsquo;t allowed to access kernel memory, and so, when yuzu switches from executing a game to running some kernel procedure, it just handles this internally through the High Level Emulation (<code>HLE</code>) implementations, with the games completely oblivious to where any of said procedures are stored. However, there are certain elements that the games actually need to access, and so, they must be inside the emulated memory. One such case is the <a href="https://en.wikipedia.org/wiki/Thread-local_storage">Thread Local Storage</a> (<code>TLS</code>), a memory region used by the emulated threads to store variables that only they see, but none of their peers have access to — because a thread can access only its own <code>TLS</code> region. Since these entities can be allocated in the <code>KSlabHeap</code>, along with other entities that don&rsquo;t need to be inside the emulated memory accessible for the games, bunnei introduced this hybrid method so yuzu is able to manage the slab list for all kernel objects, regardless of whether they need to be <code>HLE</code>&rsquo;d, or stored in the virtual memory.</p> <p>Of course, there are still many other things to flesh out and implement. The kernel is an essential part of the system that makes it possible for everything else to work. Any improvements and additions to this component make the emulation experience more robust and solidify the accuracy of how the emulator works.</p> <p>Morph has also been paying attention to the kernel, refactoring part of the IPC code and adding a function to <a href="https://github.com/yuzu-emu/yuzu/pull/6320">pop the ID of a process</a>, fixing a small bug where a <a href="https://github.com/yuzu-emu/yuzu/pull/6337">wrong value was being returned</a>, and stubbing a <a href="https://github.com/yuzu-emu/yuzu/pull/6358">function for the memory manager</a>.</p> <p>However, the real poyo-pearl of this month has been his <a href="https://github.com/yuzu-emu/yuzu/pull/6270">rework of yuzu&rsquo;s Common File System Interface</a> to make use of the <code>std::filesystem</code> library introduced in C++17, as a continuation of the work done by the maintainer <a href="https://github.com/lioncash">lioncash</a>.</p> <p>The file system interface is the code that controls how yuzu accesses files (e.g. the creation of save files, or how yuzu loads DLC and update files for a game, etc.). Since yuzu originally started as a fork of <a href="https://citra-emu.org/">Citra</a>, there were many functions inherited from that project that weren&rsquo;t as new as the ones included in this newly added library, or weren&rsquo;t compatible with the new Virtual File System that yuzu uses, or simply weren&rsquo;t used at all.</p> <p>With this huge PR, after Morph reversed-engineered the file system in order to bring yuzu&rsquo;s behaviour closer to how it works on the Nintendo Switch, he removed the clutter in favour of simpler code and rewrote the whole implementation, fixing some problems that the old code had in Windows builds in the process. As a bonus, he also documented all of yuzu&rsquo;s file system functions.</p> <p>While these changes don&rsquo;t necessarily result in a performance increase for end-users, they have certainly tackled some long-standing problems with how yuzu handled files, besides simplifying the codebase notably, making it much easier to read and maintain for our developers.</p> <h2 id="on-screen-keyboard-changes">On-Screen Keyboard changes</h2> <p>Morph has been working hard on fixes for the software keyboard.</p> <p>Games received the text string of the inline keyboard instead of the regular one, resulting in empty fields being sent which could cause games to panic, as it would mean an invalid entry was sent. Fixing this only required <a href="https://github.com/yuzu-emu/yuzu/pull/6333">sending the correct information from the right keyboard type.</a></p> <p>Users reported crashes when pressing Enter after naming a ruleset or controller layout in <code>Super Smash Bros. Ultimate</code>. As it turns out, the <code>QLineEdit::returnPressed</code> signal generated a <a href="https://en.wikipedia.org/wiki/Race_condition">race condition</a>, resulting in the crashes. <a href="https://github.com/yuzu-emu/yuzu/pull/6339">Switching to <code>Qt::QueuedConnection</code></a> solved the issue.</p> <p>Additionally, testing confirmed that games can leave regions of memory uninitialized if a text check is performed and doesn’t result in either <code>Failure</code> or <code>Confirm</code>, causing, once again, crashes. This is fixed by <a href="https://github.com/yuzu-emu/yuzu/pull/6374">reading only the text check message.</a>. Thanks to gidoly and OZ for all the help in finding this!</p> <p>Lastly, there was an issue where the mouse input is captured by the software keyboard until the user moves to the next event. german77 fixed this <a href="https://github.com/yuzu-emu/yuzu/pull/6275">by releasing the mouse input when yuzu is out of focus.</a></p> <h2 id="general-bugfixes">General bugfixes</h2> <p>Let’s begin this section with an obituary. Keen-eyed users may have noticed that old builds used to have a single . <em>dot</em> at the end of the title bar. A suspicious <em>dot</em> whose purpose was unknown.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dot.png" title=" The Legend"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/dot_hu0290b5ecf97c46349ce69dda7aa179c3_2040_227x0_resize_q90_bgffffff_box_3.jpg" alt=" The Legend"></a> <p class="has-text-centered is-italic has-text-grey-light"> The Legend</p> </div> </div> <p>When resuming an old quest that was previously left unfinished, epicboy, <a href="https://github.com/yuzu-emu/yuzu/pull/6316">while working on displaying the game version on the title bar</a>, found the code related to the existence of the <em>dot</em>, and decided to slay it.</p> <p>Of course, the <em>dot</em> wouldn’t be gone without a fight, and removing it caused the yuzu version info to disappear from logs and even the “about us” window! Morph was the next hero of light selected by the king to slay the monster, <a href="https://github.com/yuzu-emu/yuzu/pull/6326">and so he did</a>.</p> <p>And thus, the saga of the mysterious <em>dot</em> ends, for now.</p> <p>Speaking of sagas, <a href="https://github.com/ogniK5377">ogniK</a> works in ways beyond our comprehension. An open PR about <a href="https://github.com/yuzu-emu/yuzu/pull/6354">allowing yuzu to set a nickname for the emulated switch</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/6355">implementing the <code>DisableAutoSaveDataCreation</code> service</a> are some of the surprises The Shark left us. By the way, that last service? It’s used by <code>Mii Edit</code>.</p> <p>Morph <a href="https://github.com/yuzu-emu/yuzu/pull/6301">stubbed the ´ImportClientPki´ and ´ImportServerPki´ services</a>, making <code>JUMP FORCE Deluxe Edition</code> boot. <code>Project Hades</code> will help make this game playable.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./jfmenu.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/jfmenu_hu3698d5ff4d7b8bc1471ea43b6f364657_2687999_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks, Ghost, for the pics! (JUMP FORCE Deluxe Edition)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./jfingame.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/jfingame_hu09b33837015da968a9ac8e9b03373535_128366_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thanks, Ghost, for the pics! (JUMP FORCE Deluxe Edition)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Thanks, Ghost, for the pics! (JUMP FORCE Deluxe Edition)</p> <p>bunnei <a href="https://github.com/yuzu-emu/yuzu/pull/6386">fixed a hang on shutdown in the NVFlinger thread</a> (used for compositing), fixing hangs when stopping emulation while playing <code>Super Mario Odyssey</code>. You not only have to let’s-a go, Mario, but also let’s-a stop sometimes.</p> <p>While yuzu allows users to install anything to NAND, be it updates, DLC, or even the base game, we recommend that only updates and DLC be installed, leaving yuzu to find the base game with the user provided locations of the game dumps. Morph <a href="https://github.com/yuzu-emu/yuzu/pull/6319">properly blocked this,</a> and added a warning that accompanies it.</p> <p>Besides what was mentioned earlier in the article, <code>Shantae</code> took a bit of extra work to become playable. Another case of an emulator inside an emulator. epicboy <a href="https://github.com/yuzu-emu/yuzu/pull/6284">solved a softlock at boot</a> by creating layers when queried but not found in the compositting service NVFlinger and ogniK <a href="https://github.com/yuzu-emu/yuzu/pull/6279">fixed the crashes</a> by stubbing the emulation of <code>nvhost-prof-gpu</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./shantae.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Atta girl! Thank you OZ for the gameplay! (Shantae)</p> </div> </div> <p>Linux deserves some love too, and <a href="https://github.com/lat9nq">toastUnlimited</a> shall give it. <a href="https://github.com/linuxdeploy/linuxdeploy">linuxdeploy</a> introduced a regression that caused any file open dialog to crash yuzu if you ran one of our official AppImages. toast solved it <a href="https://github.com/yuzu-emu/yuzu/pull/6324">by downloading our own version hosted as one of our externals</a>, allowing us to have better control on changes to linuxdeploy, as well as fixing the crashes. Users can enjoy the ease of use of AppImage releases again.</p> <p>An old limitation we faced with Linux Distributions that decide to “stay on their old and trusted packages” is outdated versions of the Qt binaries. <a href="https://github.com/yuzu-emu/yuzu/pull/6366">By setting up version 5.12 as the minimum requirement and adding 5.15 to our externals,</a> we can ensure that no problems are faced when building yuzu with any of the valid compilers, be it MSVC, GCC, Clang, or even MinGW.</p> <h2 id="ui-and-other-quality-of-life-improvements">UI and other Quality of Life improvements</h2> <p>Users have the option to customize the game list via <code>Emulation &gt; Configure… &gt; General &gt; UI</code>, and the Add-Ons column can be disabled there. Previously, if the user disabled it, the game list was not being refreshed, forcing the user to find inventive ways to manually do it. Thanks to <a href="https://github.com/Kewlan">Kewlan</a>’s work, <a href="https://github.com/yuzu-emu/yuzu/pull/6298">the game list now properly refreshes itself with no need for manual intervention!</a></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./add-ons.png" title=" Add-Ons shows which update, DLCs and mods are installed and enabled"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/add-ons_hub680e63d023b0306b58e32fcfabb0065_1325_102x0_resize_q90_bgffffff_box_3.jpg" alt=" Add-Ons shows which update, DLCs and mods are installed and enabled"></a> <p class="has-text-centered is-italic has-text-grey-light"> Add-Ons shows which update, DLCs and mods are installed and enabled</p> </div> </div> <p>toastUnlimited reluctantly <a href="https://github.com/yuzu-emu/yuzu/pull/6321">added the CPU tab to per-game settings.</a> At the same time, Custom RTC (Real-Time-Clock) was removed to force it as a global value.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cpu.png" title=" Totally not a hint of anything"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/cpu_hu22c0472363fc17a01bb2b764036d8088_134384_802x0_resize_q90_bgffffff_box_3.jpg" alt=" Totally not a hint of anything"></a> <p class="has-text-centered is-italic has-text-grey-light"> Totally not a hint of anything</p> </div> </div> <p>While we’re on this subject, some things need to be clarified about the CPU settings tab. Unsafe was originally only intended for CPUs that lacked the FMA instruction set, which causes games to run at very low framerates. Later on, a fix was discovered that could boost the performance of <code>Luigi’s Mansion 3</code> by reducing precision. This was described in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/">January’s progress report.</a></p> <p>As a result, we recommend users of CPUs that do have FMA to stick to <code>Accurate</code> and only force <code>Unsafe</code> for <code>Luigi’s Mansion 3</code>. Using <code>Unsafe</code> is known to cause precision issues, for example, exaggerating the hitboxes of characters in <code>Super Smash Bros. Ultimate</code>. Users with old or low-end Intel CPUs that lack FMA, feel free to keep <code>Unsafe</code> enabled all the time.</p> <p>We provide some examples in the following gorgeous and totally perfect table:</p> <table> <thead> <tr> <th style="text-align:center">CPU series</th> <th style="text-align:center">FMA support</th> <th>Recommended setting</th> </tr> </thead> <tbody> <tr> <td style="text-align:center">Intel Core 4000 to 11000 series</td> <td style="text-align:center">Yes</td> <td>Use Accurate, Unsafe for LM3</td> </tr> <tr> <td style="text-align:center">Intel Core 500 to 3000 series and older</td> <td style="text-align:center">No</td> <td>Use Unsafe</td> </tr> <tr> <td style="text-align:center">Intel Atom, Celeron and Pentium series</td> <td style="text-align:center">No</td> <td>Use Unsafe</td> </tr> <tr> <td style="text-align:center">AMD Ryzen series</td> <td style="text-align:center">Yes</td> <td>Use Accurate, Unsafe for LM3</td> </tr> <tr> <td style="text-align:center">AMD FX and A 4000 to 9000 APU series</td> <td style="text-align:center">Yes</td> <td>Use Accurate, Unsafe for LM3</td> </tr> <tr> <td style="text-align:center">AMD Phenom, A 3000 APU series and older</td> <td style="text-align:center">No</td> <td>Use Unsafe</td> </tr> </tbody> </table> <p>*LM3 = Luigi’s Mansion 3</p> <p>toastUnlimited also gave us the option to <a href="https://github.com/yuzu-emu/yuzu/pull/6346">apply settings while games are running</a>. This can allow users to more efficiently test settings while playing. Keep in mind that settings that require a reboot to take effect won&rsquo;t be affected by the apply button.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./apply.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/apply_hu6b0436de7678dfc9c3516a541e5aedc7_197295_802x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>Continuing with the per-game setting improvements, toast also added an exception for homebrew. Since most homebrew use a game-ID of 0000000000000000, using the ID to save the per-game settings would have been useless, so instead, <a href="https://github.com/yuzu-emu/yuzu/pull/6361">yuzu will use the name of the homebrew file.</a></p> <p>And finally, toast, continuing work from german77 and <a href="https://github.com/FearlessTobi">Tobi</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6362">added a button to reset yuzu settings to default</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./reset.png" title=" Simple as that"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/reset_hu2b365c9312301b302fea2f2ae00d6528_21315_1021x0_resize_q90_bgffffff_box_3.jpg" alt=" Simple as that"></a> <p class="has-text-centered is-italic has-text-grey-light"> Simple as that</p> </div> </div> <p>This is sometimes needed in very rare cases, for example, when being unable to boot <code>Super Smash Bros. Ultimate</code>.</p> <h2 id="shake-it-babyhttpsyoutubeiac0t6dnuzm"><a href="https://youtu.be/Iac0T6dnuzM">Shake it, baby</a></h2> <p>german77 has been working on <a href="https://github.com/yuzu-emu/yuzu/pull/6244">implementing SDL motion</a>, with the purpose of removing our dependency on third party programs to get motion input from valid controllers like Dual Sense, Joy-Cons, or Pro Controllers. With this PR, users can simply pair their controllers via Bluetooth and yuzu will pick them up as a valid input device, auto-mapping and enabling motion support, effectively removing the need to use betterjoy, ds4windows, or other third party software in yuzu.</p> <p>A separate PR adds <a href="https://github.com/yuzu-emu/yuzu/pull/6318">detection of two separate Joy-Cons as a single input device</a>.</p> <p>And to provide motion support on the Linux side, <a href="https://github.com/v1993">v1993</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6293">enables the use of HIDAPI within SDL2</a>.</p> <p>Work continues to fine tune how the sensor data is interpreted, specially from non-Nintendo devices. For example, PS3 controllers operate motion on a single Z axis, but report the remaining 2 axes to the operating system with useless NaN values, making any motion calculations useless. <a href="https://github.com/yuzu-emu/yuzu/pull/6310">By replacing the X and Y axis values with zeros</a>, german77 solved the issue.</p> <p>Games don’t always check for obvious physical limitations. For example, in the past, it was possible to use handheld controller emulation while the game was in a docked status. Doing this can break games like <code>Xenoblade Chronicles 2</code>, as the game expects the console to disable input when the Joy-Cons are connected to a docked Switch’s rails. german77 solves this by <a href="https://github.com/yuzu-emu/yuzu/pull/6353">forcing an emulated Pro Controller instead</a>. No more weird Frankenstein input monstrosities, please.</p> <p>Finally, it could sometimes be difficult to map analog sticks in yuzu due to a bug in how the event was handled. While fixing this, german77 also <a href="https://github.com/yuzu-emu/yuzu/pull/6312">fixed a crash caused by controllers not listed in the controller list disconnecting</a>.</p> <h2 id="future-projects">Future projects</h2> <p>Now, I know we keep teasing <code>Project Hades</code>, but we have good news! SPIR-V is finalized, GLASM is in its final testing, and GLSL is not far behind. Few regressions remain to be squashed. Once the shading languages are done, previous features like the old asynchronous shaders are reimplemented, and the fine tuning is finished, it will finally be released. We&rsquo;re trying to release it alongside Reaper, but time will tell.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hades1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/hades1_hu3f7c499c24b5817705fbd68fca5956be_1445382_800x0_resize_q90_bgffffff_box_3.jpg" alt="MARVEL ULTIMATE ALLIANCE 3: The Black Order, WORLD OF FINAL FANTASY MAXIMA, Yoshi&#39;s Crafted World"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hades2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/hades2_hu044534dd602dbed5fdb632bd9288b9a6_1867644_800x0_resize_q90_bgffffff_box_3.jpg" alt="MARVEL ULTIMATE ALLIANCE 3: The Black Order, WORLD OF FINAL FANTASY MAXIMA, Yoshi&#39;s Crafted World"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hades3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2021/hades3_hu015136e6565f279a41d9c5befaed0c12_1727791_800x0_resize_q90_bgffffff_box_3.jpg" alt="MARVEL ULTIMATE ALLIANCE 3: The Black Order, WORLD OF FINAL FANTASY MAXIMA, Yoshi&#39;s Crafted World"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">MARVEL ULTIMATE ALLIANCE 3: The Black Order, WORLD OF FINAL FANTASY MAXIMA, Yoshi&#39;s Crafted World</p> <p>That’s all folks! Thank you so much for staying with us until the end of this month’s progress report. See you in the next one!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> <p><em><strong>.</strong></em></p> New Feature Release - Fastmem Support https://yuzu-mirror.github.io/entry/yuzu-fastmem/ Tue, 08 Jun 2021 04:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-fastmem/ <p>Hey there, yuz-ers! While all of you wait eagerly for the release of Project Hades, our shader decompiler rewrite, we thought we&rsquo;d bring you a nice little surprise to keep you occupied. We present to you, the newest addition to yuzu&rsquo;s ever-improving features list - Fastmem (Fast Memory Access)!</p> <p>Hey there, yuz-ers! While all of you wait eagerly for the release of Project Hades, our shader decompiler rewrite, we thought we&rsquo;d bring you a nice little surprise to keep you occupied. We present to you, the newest addition to yuzu&rsquo;s ever-improving features list - Fastmem (Fast Memory Access)!</p> <p> </p> <p>This is now available in the latest yuzu Early Access build (1759 or newer) and we intend to make this available in Mainline builds very soon. As always, we ask that you test various games with these builds and if you encounter any issues, bugs, or crashes, please reach out to us via the <a href="https://discord.gg/u77vRWY">Discord</a> Patreon channels.</p> <p><strong>Note: This feature is enabled by default.</strong></p> <h2 id="what-is-fastmem">What is Fastmem?</h2> <p>Fastmem or Fast Memory Access, is a well-known feature among emulator developers and emulation enthusiasts. Emulators like <a href="https://dolphin-emu.org/">Dolphin</a> and <a href="https://citra-emu.org/">Citra Android</a> have implemented this in the past.</p> <p>All modern Operating Systems have this concept of &ldquo;virtual memory,&rdquo; where addressable memory (from the running process) is a space of memory addresses that are only &ldquo;known&rdquo; to that process, e.g. Discord on your PC, or Super Mario Odyssey on your Switch — and the addresses are translated by the Switch&rsquo;s MMU (Memory Management Unit) to the physical location in the Switch’s physical RAM as the game runs.</p> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./MMU.png" title="Illustration of an MMU (By Mdjango, Andrew S. Tanenbaum)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-fastmem/MMU_hu8193ff6017aea71cb7f5920cb65b79d7_41187_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Illustration of an MMU (By Mdjango, Andrew S. Tanenbaum)"></a> <p class="has-text-centered is-italic has-text-grey-light">Illustration of an MMU (By Mdjango, Andrew S. Tanenbaum)</p> </div> </div> <p>In yuzu, we emulate the Switch&rsquo;s virtual address space for the running process. But, that means for each time the game tries to read/write memory, which happens millions of times per frame, we need to basically &ldquo;decode&rdquo; where that Switch virtual address maps to our &ldquo;emulated&rdquo; Switch memory (RAM allocated for yuzu). This adds a lot of overhead when you consider how much the game reads/writes to memory.</p> <p>The idea behind Fastmem here is to map the emulated Switch game&rsquo;s addressable memory on the host (Windows / Linux), at offset addresses. The offset is a constant.</p> <h2 id="the-technical---how">The Technical - HOW?</h2> <p>On the Switch, we have 4GB of memory. The hardware supports a virtual memory size of 48bits (just like x64); however, the Switch kernel limits this to only 39bit to save some memory for storing page tables. This results in a 512GB virtual address space (2^39) for use. (A page table is the data structure used to store the mapping between virtual addresses and physical addresses.)</p> <p>To emulate this, we allocated a HUGE page table, which had an offset for each memory page addressable in the virtual memory region of the Switch. This table alone was 1GB in size! And whenever a game wanted to access the memory, we looked up this table, which resulted in roughly ~10 x64 CPU instructions and twice the memory latency. That latency being: first read the table&rsquo;s value, then read the correct memory.</p> <p>Fastmem, however, uses the host MMU to rebuild the same 39bit virtual memory arena. Here, we&rsquo;re lucky that Nintendo limits the memory to 39bit. We cannot allocate 48bit because that&rsquo;s the entire virtual address space on the host.</p> <p>This cuts the effort to access the memory down to 3+1 x64 CPU instructions with a single memory latency. 3 instructions to check if the pointer is smaller than 39 bit, and one memory load instruction. We need this size check to ensure out-of-bounds memory access won&rsquo;t return any physical address.</p> <h2 id="the-challenges">The Challenges</h2> <p>Implementing Fastmem required two major things in <a href="https://github.com/MerryMage/dynarmic/">Dynarmic</a>, our JIT recompiler.</p> <p><strong>First:</strong> A64 Fastmem support on Dynarmic.</p> <p>Dynarmic has had support for A32 Fastmem (see Citra Android) for a while now. A64 Fastmem support was <a href="https://github.com/MerryMage/dynarmic/pull/528">originally worked on a year ago by MerryMage and vdwjeremy</a> but it never got merged to the master branch.</p> <p><a href="https://github.com/degasus/">degasus</a> worked with <a href="https://github.com/MerryMage/">MerryMage</a> to clean up and get <a href="https://github.com/MerryMage/dynarmic/pull/613">these changes merged</a> to the master branch so that yuzu could benefit from this.</p> <p><strong>Second:</strong> To generate the 512GB virtual address space with the same mappings as on the Switch.</p> <p>degasus proved last year that this was easy to implement on Linux as the POSIX mmap call provided very similar features to the Horizon OS. But it was a huge challenge for Windows, as the Windows Virtual Memory API is larger with a few missing features. Moreover, while Windows page tables were 4K aligned, Windows memory management was 64K aligned for <a href="https://devblogs.microsoft.com/oldnewthing/20031008-00/?p=42223">outdated reasons</a>.</p> <h2 id="the-solutions">The Solutions</h2> <p>Turns out, Microsoft had realized this too and frequently patched their Virtual Memory API. With the release of Windows 10 v1803, their new API supported new &ldquo;placeholder&rdquo; memory which didn&rsquo;t suffer from the previous limitations.</p> <p>Thanks to <a href="https://github.com/BreadFish64/">Breadfish64</a>, who used this new API in their Gameboy emulator and showed us that it was now indeed possible to support Fastmem on Windows. Unfortunately, this makes the feature usable only on Windows versions 1803 and higher.</p> <p>Since we already met the base requirements for our new Fastmem implementation long ago, our devs were able to quickly address the missing pieces. <a href="https://github.com/bunnei/">bunnei</a> implemented the much-needed kernel rework changes in yuzu, degasus cleaned up their original proof-of-concept code for Linux, and <a href="https://github.com/ReinUsesLisp/">Rodrigo</a> implemented the Windows Fastmem support. <a href="https://github.com/FernandoS27">Blinkhawk</a> provided valuable advice and coordinated these efforts to get the feature release-ready.</p> <h2 id="the-results">The Results</h2> <p>As an added bonus, game booting/loading times have been improved thanks to these changes. Thanks to developer Rodrigo, Normal GPU accuracy no longer triggers a myriad of exceptions on the Smash character selection screen, improving its performance from 10-20 FPS to a full 60.</p> <p>  <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./SSBU.png" title="Super Smash Bros. Ultimate"> <img src="https://yuzu-mirror.github.io/entry/yuzu-fastmem/SSBU_hu59186921872e87ac8045b58428fbe211_2417530_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Smash Bros. Ultimate</p> </div> </div> </p> <p>For all game benchmarks, we utilized a PC built to our own recommended hardware spec. In this testing we observed performance improvements ranging from 15-60% in some of the most demanding areas of gameplay. Please note the marked titles that were tested with the processor limited to 2.4Ghz, to synthetically make it slower than usual and highlight the improvements.</p> <p>  <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./BENCH_01.png" title="The * indicates titles tested at 2.4Ghz"> <img src="https://yuzu-mirror.github.io/entry/yuzu-fastmem/BENCH_01_hu49f9560544469445580c5ab129245522_90593_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The * indicates titles tested at 2.4Ghz"></a> <p class="has-text-centered is-italic has-text-grey-light">The * indicates titles tested at 2.4Ghz</p> </div> </div> </p> <p>  <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./BENCH_02.png" title="The * indicates titles tested at 2.4Ghz"> <img src="https://yuzu-mirror.github.io/entry/yuzu-fastmem/BENCH_02_huf21840f7b36a43b8c316bf0189f61422_101568_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The * indicates titles tested at 2.4Ghz"></a> <p class="has-text-centered is-italic has-text-grey-light">The * indicates titles tested at 2.4Ghz</p> </div> </div> </p> <h5 id="thats-all-we-have-for-now-see-you-soon-with-exciting-news-about-project-hades-and-more-happy-emulating">That&rsquo;s all we have for now, see you soon with exciting news about Project Hades and more! Happy emulating!</h5> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report April 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/ Sun, 09 May 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/ <p>Howdy yuz-ers! Another month gone, another progress report written. From new firmware versions to Vulkan fixes, we have quite a bit to talk about, so let’s get right into it!</p> <p>Howdy yuz-ers! Another month gone, another progress report written. From new firmware versions to Vulkan fixes, we have quite a bit to talk about, so let’s get right into it!</p> <h2 id="project-eleuthia">Project Eleuthia</h2> <p>As described in <a href="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/">its own dedicated article</a>, <a href="https://github.com/Morph1984">Morph</a> and <a href="https://github.com/Its-Rei">Rei</a> have been very busy <a href="https://github.com/yuzu-emu/yuzu/pull/6133"><em>rei</em>mplementing the applets</a> yuzu uses.</p> <p>This first step implements the <code>On-Screen Keyboard</code> (or OSK) that games use, and the <code>Error Display</code> yuzu uses to alert the user to bugs, missing data, or crashes.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./osk1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/osk1_hu570db074cf62d4f9859fc182e850552e_597810_800x0_resize_q90_bgffffff_box_3.jpg" alt="Examples of the different kinds of keyboards games request"></a> </div> <div class="column is-bottom-paddingless"> <a href="./osk2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/osk2_hu790d73f10f126ef0c4712e58cbf5a128_86692_800x0_resize_q90_bgffffff_box_3.jpg" alt="Examples of the different kinds of keyboards games request"></a> </div> <div class="column is-bottom-paddingless"> <a href="./osk3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/osk3_hu710b6c0150e0c275201c73ef535b2701_249683_800x0_resize_q90_bgffffff_box_3.jpg" alt="Examples of the different kinds of keyboards games request"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Examples of the different kinds of keyboards games request</p> <p>Another major advantage is adding gamepad support! No need to get off the couch to grab a keyboard anymore.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./error1.png" title=" An error example"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/error1_hu60695a5bfb724efeb7fda18e719f6e79_54846_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" An error example"></a> <p class="has-text-centered is-italic has-text-grey-light"> An error example</p> </div> </div> <p>Part of the effort included working around Qt’s quirks, so as a by-product users now have the option to select either the old <code>Exclusive Fullscreen</code> (recommended and used as default on Linux), or the <a href="https://github.com/yuzu-emu/yuzu/pull/6135">new</a> <code>Borderless Fullscreen</code> (recommended for most cases and to have OSK properly working).</p> <p>Borderless not only gives us better input support for gamepads, but also reduces screen tearing and improves clock management related performance issues on some AMD GPUs.</p> <h2 id="input-improvements">Input improvements</h2> <p>A feature lacking from our <code>Stereo Vision</code> implementation was support for the Switch’s motion detection, and by this we don&rsquo;t mean Joy-Cons, but rather the actual console. This is commonly used for moving the camera with your head when the Switch is in the Labo goggles.</p> <p><a href="https://github.com/german77">german77</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6226">implemented SevenSixAxis and ConsoleSixAxisSensor</a>, continuing from <a href="https://github.com/yuzu-emu/yuzu/pull/6224">previous work</a> done by <a href="https://github.com/Morph1984">Morph,</a> allowing your configured motion device to freely let you look around in compatible games.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vr.png" title=" Please don&#39;t use it like this..."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/vr_hu83682f27ceb9ddfde613d1cd19ad58d4_22601_372x0_resize_q90_bgffffff_box_3.jpg" alt=" Please don&#39;t use it like this..."></a> <p class="has-text-centered is-italic has-text-grey-light"> Please don&#39;t use it like this...</p> </div> </div> <p>Both the left and right Joy-Cons map their buttons to different memory locations, as <a href="https://github.com/german77">german77</a> found out. He discovered that we had the wrong <a href="https://github.com/yuzu-emu/yuzu/pull/6131">location for the SL and SR buttons.</a> One fix later, and everything is as it should be.</p> <p>A long standing bug when trying to play <code>Mario Kart 8 Deluxe</code> in local split screen multiplayer was a freeze that occurred when confirming all connected players. <a href="https://github.com/yuzu-emu/yuzu/pull/6205">Morph</a> fixed this crash by <a href="https://github.com/yuzu-emu/yuzu/pull/6205">sending the focus state change message</a> on applet state changes.</p> <p>Thank you EmulationFanatic and riperiperi for the help!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./mk8input.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Better to crash other players than crash the game!</p> </div> </div> <p>Taking inspiration from <a href="https://rpcs3.net/">RPCS3</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6205">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6241">sets the default keyboard input</a> to something more suitable for PC users. You just can’t beat WASD movement, especially when combined with mouse aiming.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./keys.png" title=" Rip and tear, press and click until it is done"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/keys_hu2773565411ba624b4ad48db890d304fc_73287_872x0_resize_q90_bgffffff_box_3.jpg" alt=" Rip and tear, press and click until it is done"></a> <p class="has-text-centered is-italic has-text-grey-light"> Rip and tear, press and click until it is done</p> </div> </div> <p>Gamecube controllers connected to an adapter sometimes reported the joystick off-center due to invalid data being sent during the connection. <a href="https://github.com/german77">german77</a> solved this <a href="https://github.com/yuzu-emu/yuzu/pull/6243">by taking 4 measurements during initialization</a>, ensuring that the controller finds its center, like any warrior should.</p> <h2 id="user-interface-changes">User interface changes</h2> <p><a href="https://github.com/Kewlan">Kewlan</a> is back with more UI improvements!</p> <p>To start off, they&rsquo;ve <a href="https://github.com/yuzu-emu/yuzu/pull/6198">added a favourite option in the context menu,</a> so you can force some of your games to the top of the list.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fav.png" title=" Just right click them!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/fav_huff3a3f0a0eaa0ba7c1cdd8235e9d227b_56553_442x0_resize_q90_bgffffff_box_3.jpg" alt=" Just right click them!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Just right click them!</p> </div> </div> <p>Additionally, they <a href="https://github.com/yuzu-emu/yuzu/pull/6261">updated the results from a filtered search</a> after you remove a directory. This fixes incorrect behaviour if the user decides to modify the game folders while doing a filtered search.</p> <p>And lastly, they fixed a <a href="https://github.com/yuzu-emu/yuzu/pull/6263">random bug that caused folders to expand or collapse when moving them in the game list.</a></p> <p>Several users reported that <code>Super Smash Bros. Ultimate</code> may get stuck when loading our web applet, making the whole game softlock. Turns out the URL used by the applet was getting deleted before being used. <a href="https://github.com/Morph1984">Morph</a> got around this bug <a href="https://github.com/yuzu-emu/yuzu/pull/6257">by extending the lifetime of the URL.</a></p> <h2 id="its-12-oclock-and-its-time-for-a-new-firmware">It’s 12 o’clock and it’s time for a new firmware!</h2> <p>A big challenge made its entrance last month: the Nintendo Switch&rsquo;s firmware version was finally updated to Version 12.X, which has kept our developers quite busy figuring out what has changed and what needs to be implemented.</p> <p>Thanks to joint efforts of <a href="https://github.com/german77">german77</a>, <a href="https://github.com/ameerj">epicboy</a>, <a href="https://github.com/lioncash">lioncash</a>, and <a href="https://github.com/Morph1984">Morph</a>, yuzu was able to update many system call ID tables (<a href="https://github.com/yuzu-emu/yuzu/pull/6153">PR #6153</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6154">PR #6154</a>), services and function tables (<a href="https://github.com/yuzu-emu/yuzu/pull/6157">PR #6157</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6158">PR #6158</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6159">PR #6159</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6160">PR #6160</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6161">PR #6161</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6164">PR #6164</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6171">PR #6171</a>), as well as some system values (<a href="https://github.com/yuzu-emu/yuzu/pull/6155">PR #6155</a>).</p> <p>Firmware updates generally aim to improve the stability of the hardware and patch exploits, but they might also add support for new features under the hood, which usually requires changes to services, their structures, and other monsters lurking within the OS. Since future games could make use of any of these things, it’s imperative to integrate and support these changes as soon as possible.</p> <h2 id="general-bugfixes">General bugfixes</h2> <p>Recently, <a href="https://github.com/lat9nq">toastUnlimited</a> caught some bugs using <a href="https://github.com/google/sanitizers/wiki">Sanitizers</a>: a number of tools present in some compilers, which are used to analyse the source code and alert the programmer about memory-related problems (leaks, overflows), undefined behaviour (code that works in one environment but might fail in another), data races (a synchronization problem that appears when dealing with multiple threads accessing the same data), etc. This led to a series of PRs implementing fixes in yuzu&rsquo;s code, such as: <a href="https://github.com/yuzu-emu/yuzu/pull/6141">Prevent stack-use-after-scope</a>, which ensures that data that used to be accessed indirectly through pointers cannot be accessed again once the reference is lost (possibly corrupting the data that was being pointed to), <a href="https://github.com/yuzu-emu/yuzu/pull/6142">Avoid reference binding to misaligned address</a>, as well as a number of undefined behaviour bugs that occurred when copying memory from one address to another (<a href="https://github.com/yuzu-emu/yuzu/pull/6143">PR #6143</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/6145">PR #6145</a>, and <a href="https://github.com/yuzu-emu/yuzu/pull/6146">PR #6146</a>).</p> <p>toastUnlimited also reported an overflow that occurred when he tried playing <code>Pokémon Sword</code> and <code>Pokémon Let's Go Pikachu</code>’s demo, which was related to some of the operations realized by the clock. This helped <a href="https://github.com/Morph1984">Morph</a> notice a problem in the implementation of the <code>CalculateStandardUserSystemClockDifferenceByUser</code> function, and <a href="https://github.com/yuzu-emu/yuzu/pull/6167">promptly submit a fix</a>.</p> <p>Different processes communicate through mechanisms known as <code>IPC</code> (Inter-Process Communication), and they can send data by using <code>data buffers</code>, typically used for large data transfers, or <code>raw arguments</code>, which are usually composed of smaller data sets. In the case of the clock service of this function, this information has to be sent through the aforementioned <code>data buffers</code>, but it was being extracted as <code>raw arguments</code> instead. This caused the function to operate using uninitialized data (in other words, junk), since it retrieved the wrong values. What should have been generally reported as a couple of milliseconds was instead being reported as a time span of trillions of years — approximately, 320 000 times the calculated age of the universe! Thankfully, the fix only required a small change, so now the values are retired from the proper buffers, and yuzu won&rsquo;t try to dilate time any more (relatively speaking, if you catch my drift).</p> <p><a href="https://github.com/ameerj">epicboy</a> made a follow-up of previous work that aimed to improve the accuracy of how the values for <code>resource limits</code> are <a href="https://github.com/yuzu-emu/yuzu/pull/6185">used in the kernel</a>.</p> <p>By nature, all resources in any piece of hardware are limited. The amount of memory, the number of I/O devices, and even the number of processors, just to name a few examples, have a fixed value that cannot be changed at whim, without changing the hardware first. One of the many functions of the kernel in an operating system is to manage and distribute these resources to the processes that request them — and for this, it must know the availability and limits of these resources. Whenever a process is created or deleted, the hardware calculates the amount of memory that is free to use and being used by checking and updating the variables that keep track of these resources.</p> <p>Previously, yuzu created processes in such a way that each instance of a process had their own value for <code>resource limits</code>. This was a work-around to ensure that, whenever a process queried the kernel for the amount of memory available, a correct value was always returned. This, however, is not how the hardware works. Memory is a resource that is shared system-wide among all the processes, and the task of the kernel to coordinate how these resources are shared among the processes in the system.</p> <p>With this PR, processes don&rsquo;t &ldquo;own&rdquo; their own instance of <code>resource limits</code>, and they now use the global kernel instance instead.</p> <p><a href="https://github.com/MerryMage/dynarmic">Dynarmic</a> — yuzu&rsquo;s JIT, used to translate the Switch’s ARM CPU instructions — was recently updated again in order to <a href="https://github.com/yuzu-emu/yuzu/pull/6132">increase the size of the code cache</a> (where yuzu stores the translated code), and add support for some unimplemented instructions from the <code>thumb32</code> set, expanding the amount of code that can be translated.</p> <p><a href="https://github.com/degasus">degasus</a> found that the code cache size was too small when testing <code>The Legend of Zelda: Breath of the Wild</code>, and alerted <a href="https://github.com/MerryMage">merry</a>, the chief maintainer, about the problem.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smash.png" title=" No items, The Best only, Final Destination"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/smash_huab2d8b3d86d2c120eabadd193b8a6a99_3577392_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" No items, The Best only, Final Destination"></a> <p class="has-text-centered is-italic has-text-grey-light"> No items, The Best only, Final Destination</p> </div> </div> <p>Surprisingly, this simple change fixed a very obnoxious problem in a completely different game: the strange slowdowns in <code>Super Smash Bros. Ultimate</code>. It turned out that these slowdowns were unrelated to the power of the computer running yuzu, nor were they neither related to building the shader cache. Dynarmic was just translating code again, simply because the cache where the translated code was stored was too small. But now, with the new size value in place, Dynarmic has no need for any recompilation, and the emulation can proceed smoothly.</p> <p>Continuing with previous <code>Super Smash Bros. Ultimate</code> Spirit Board’s fixes, <a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6170">synchronized the network clock to the local clock</a>, solving the game timers getting reset.</p> <p><a href="https://github.com/Morph1984">Morph</a> also fixed <code>GetClockSnapshotFromSystemClockContext</code>. <a href="https://github.com/yuzu-emu/yuzu/pull/6214">This PR</a> allowing <code>Super Kirby Clash</code> and <code>Yo-Kai Watch 4</code> to boot.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./kirby.png" title=" Poyo!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/kirby_hu6c8d95f6728eb2366b73b7add2812006_2931019_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Poyo!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Poyo!</p> </div> </div> <p><a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6234">stubbing <code>SetRequestExitToLibraryAppletAtExecuteNextProgramEnabled</code></a> and <a href="https://github.com/german77">german77</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6235">adding the <code>ectx:aw</code> service</a> made <code>Pixel Game Maker Series Werewolf Princess Kaguya</code> boot!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kaguya.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/kaguya_hu8efd136892d8794cbd2c43d30d0e4c68_362752_800x0_resize_q90_bgffffff_box_3.jpg" alt="Right picture is from a more recent PR that will be mentioned in the next progress report (Pixel Game Maker Series Werewolf Princess Kaguya)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kaguya2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/kaguya2_huf172acf33f244f5a2a658f67cd06bccc_252578_800x0_resize_q90_bgffffff_box_3.jpg" alt="Right picture is from a more recent PR that will be mentioned in the next progress report (Pixel Game Maker Series Werewolf Princess Kaguya)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Right picture is from a more recent PR that will be mentioned in the next progress report (Pixel Game Maker Series Werewolf Princess Kaguya)</p> <p>The game currently has rendering bugs especially affecting Nvidia hardware. AMD users will have a better experience in this particular game for now.</p> <h2 id="graphics-improvements">Graphics improvements</h2> <p>For our <del>thermonuclear</del> laptop users and heavy multitaskers, the legendary <a href="https://github.com/degasus">degasus</a> has a treat for you. By <a href="https://github.com/yuzu-emu/yuzu/pull/6162">avoiding spin loops</a> in the video core, more idle time is achieved with no performance loss. This means the GPU can enter <code>sleep</code> state more often, resulting in lower temperatures/power consumption, better battery life, and allows the scheduler to take on other tasks waiting in the background, improving system responsiveness. No more burned thighs while on the pause menu, laptop users!</p> <p><a href="https://github.com/Joshua-Ashton">Joshua-Ashton</a>, the Frog Master from <a href="https://github.com/doitsujin/dxvk">DXVK</a>, brought us a few Vulkan fixes and improvements.</p> <p>First on the list is avoiding a device loss (GPU locks up and the driver restarts it) by <a href="https://github.com/yuzu-emu/yuzu/pull/6180">checking the return value of vkAcquireNextImageKHR.</a></p> <p>Joshua also <a href="https://github.com/yuzu-emu/yuzu/pull/6181">enabled the individual features</a> from <code>VK_EXT_robustness2</code>, instead of just enabling the extension.</p> <p>And finally, <a href="https://github.com/yuzu-emu/yuzu/pull/6182">fixing a wrong offset for null vertex buffers</a> to properly follow the Vulkan specification. You never know when a driver will behave in erratic ways. Fixes like this allow developers to report bugs to the vendors&rsquo; driver development teams, thanks to confirming everything is within specs. Any resulting error falls under responsibility of the driver teams.</p> <p>OpenGL wasn&rsquo;t the only API to have BGR issues, it turns out Vulkan can also suffer from &ldquo;blue madness&rdquo; when a game uses the <code>A1B5G5R5_UNORM</code> texture format.</p> <p><a href="https://github.com/ameerj">epicboy</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6238">swapped the Red and Blue channels</a> of this format, fixing colours in games like <code>Pokémon Let’s Go Eevee/Pikachu</code>, <code>Shantae: Risky’s Revenge</code>, and many others! You can see the result in the following pictures, before (left) and after (right).</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./pokebug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/pokebug_hu863223a432dd4bc55841f46140c761f7_1227246_800x0_resize_q90_bgffffff_box_3.jpg" alt="I didn’t want Pokémon Blue! (Pokémon Let&#39;s Go, Eevee!)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pokefix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/pokefix_hu1591ffdf51d53f7b932f06839e43a3ea_1129846_800x0_resize_q90_bgffffff_box_3.jpg" alt="I didn’t want Pokémon Blue! (Pokémon Let&#39;s Go, Eevee!)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">I didn’t want Pokémon Blue! (Pokémon Let&#39;s Go, Eevee!)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./shanbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/shanbug_hu7d964a72ff5fd61efd93e64944faf03f_951050_800x0_resize_q90_bgffffff_box_3.jpg" alt="That’s definitely not Vivi (Shantae: Risky’s Revenge)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./shanfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2021/shanfix_hubae4324284a41f0a1aac33a149688ddb_1004284_800x0_resize_q90_bgffffff_box_3.jpg" alt="That’s definitely not Vivi (Shantae: Risky’s Revenge)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That’s definitely not Vivi (Shantae: Risky’s Revenge)</p> <h2 id="linux-build-system">Linux Build System</h2> <p><a href="https://github.com/lat9nq">toastUnlimited</a> has been periodically improving yuzu’s build system for our Linux user base. Not all our users want or are able to use the official AppImage, so not only did our build instructions need to be improved, but it was also equally important to refine the environment necessary to get yuzu running — namely, the dependencies, build process, etc.</p> <p>The first step was to <a href="https://github.com/yuzu-emu/yuzu/pull/6204">make SDL2</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6207">an external dependency.</a> This would allow us to ship the latest version without having to face Linux distributions&rsquo; incompatibilities due to different build flags (different characteristics being enabled), or outright outdated versions that aren’t able to support all of the required features that our input asks for.</p> <p>The changes to SDL2 introduced an incompatibility with the Conan-provided Boost version. <a href="https://github.com/yuzu-emu/yuzu/pull/6222">Downloading it as an external dependency</a> ensures compatibility, as most of the time the local packages provided by the distribution won’t be enough. This change also makes our external download script cross-platform with Windows and other distributions that used to require special workarounds.</p> <p>As a special bonus, due to all of these changes, Red Hat Enterprise Linux 8 and its derivatives can build yuzu in a much more user-friendly way.</p> <p>For anyone interested, we keep updated build instructions <a href="https://github.com/yuzu-emu/yuzu/wiki/Building-For-Linux">on this page.</a></p> <h2 id="future-projects">Future projects</h2> <p>This section has lately turned into Project Hades teasing, but we won’t apologize for that! Here’s more info/teasing:</p> <p>While working on implementing SPIR-V for OpenGL, we discovered that Nvidia decided to take the lazy way out and just convert SPIR-V back to GLSL, which is then compiled again to GLASM. This not only destroys any benefit we expected to gain when switching to SPIR-V by default, it also causes huge delays and rendering problems. We are forced to also implement GLSL in Project Hades, introducing a considerable amount of extra work that wasn’t expected.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./hades.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> The best use of Tessellation Shaders ever</p> </div> </div> <p>This will provide better compatibility for Nvidia hardware, saving Fermi once again from the gutter.</p> <p>Regarding other project news, Morph’s Project Gaia is growing. german77 is working hard on Project Kraken. bunnei has more kernel changes in the oven.</p> <p>That’s all folks! Thank you for sticking with us and see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report March 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/ Sat, 10 Apr 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/ <p>Hi yuz-ers, we&rsquo;re here with the March progress report to offer you our latest news! We continue to update the Kernel, some considerations have been made for specific hardware, we have several changes and fixes to discuss, and we have a sneak peek at the progress on Project Hades.</p> <p>Hi yuz-ers, we&rsquo;re here with the March progress report to offer you our latest news! We continue to update the Kernel, some considerations have been made for specific hardware, we have several changes and fixes to discuss, and we have a sneak peek at the progress on Project Hades.</p> <h2 id="general-bug-fixes-and-improvements">General bug fixes and improvements</h2> <p><a href="https://github.com/Morph1984">Morph</a> to the rescue! <a href="https://github.com/yuzu-emu/yuzu/pull/6053">Fixing CalculateSpanBetween</a> allows <code>Super Smash Bros. Ultimate’s</code> Spirit Board to work! A separate PR <a href="https://github.com/yuzu-emu/yuzu/pull/6054">improving ClockSnapshot</a> fixes the timers.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./spirit.png" title=" More work is needed to make World of Light playable, we continue to fight for it! (Super Smash Bros. Ultimate)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/spirit_huf76c90c1ab70c5bbbda791294d1ae883_1177156_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" More work is needed to make World of Light playable, we continue to fight for it! (Super Smash Bros. Ultimate)"></a> <p class="has-text-centered is-italic has-text-grey-light"> More work is needed to make World of Light playable, we continue to fight for it! (Super Smash Bros. Ultimate)</p> </div> </div> <p>Those who have paid attention to our previous progress reports will notice that we sometimes write about when a service is <code>stubbed</code> (ignored, basically) to allow a game to progress further. This process requires manual intervention each and every time a game update or new game uses a new unimplemented service. To mitigate user frustration, <a href="https://github.com/ameerj">epicboy</a> implemented <a href="https://github.com/yuzu-emu/yuzu/pull/6062">Auto-Stubbing</a>, continuing <a href="https://github.com/yuzu-emu/yuzu/pull/4237">previous work</a> from <a href="https://github.com/ogniK5377">ogniK.</a></p> <p>With this toggle, games will just ignore any unimplemented services and continue running, allowing developers to focus on the services that need urgent, proper implementations. This is not a new invention by any means. Several emulators in the past have used this feature to great benefit, reducing the load on developers and providing a better experience for the end user.</p> <p>Keep in mind that auto-stub will be always disabled by default on each boot, so it has to be manually enabled for each session by going to <code>Emulation &gt; Configure &gt; General &gt; Debug &gt; Enable Auto-Stub</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./stub.png" title=" You can find it here, at the bottom of the picture in the Advanced section"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/stub_hud7f37b35d37ce77085b17be9411f1d11_23455_1021x0_resize_q90_bgffffff_box_3.jpg" alt=" You can find it here, at the bottom of the picture in the Advanced section"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can find it here, at the bottom of the picture in the Advanced section</p> </div> </div> <p><a href="https://github.com/Morph1984">Morph</a> took it upon himself to <a href="https://github.com/yuzu-emu/yuzu/pull/6070">update the emulated Switch firmware version to 11.0.1</a>, and <a href="https://github.com/yuzu-emu/yuzu/pull/6069">the NgWord version,</a> improving compatibility with recent games, and solving some odd bugs. For example, <code>Disgaea</code> games no longer require a firmware dump to be playable.</p> <p>We now have some new additions to our command line arguments thanks to <a href="https://github.com/german77">german77</a>. Users can <a href="https://github.com/yuzu-emu/yuzu/pull/6116">select which user profile to load</a> by adding the <code>-u #</code> argument to their command, with <code>#</code> being the profile number. For example, by using <code>yuzu.exe -u 1 -g &quot;path_to_game&quot;</code>, the second profile will be selected.</p> <p>In an attempt to reduce file size when downloading yuzu and also reduce the download size when building it from source, <a href="https://github.com/lat9nq">toastUnlimited</a> reworked <a href="https://github.com/yuzu-emu/yuzu/pull/5880">how FFmpeg is linked</a>. This way, only what is needed for yuzu is built, reducing the size and build time required for this module, and as an added bonus Linux users will avoid problems with possible outdated versions included in their distributions. Data capped users rejoice!</p> <p><a href="https://github.com/ivan-boikov">ivan-boikov</a> fixed an <a href="https://github.com/yuzu-emu/yuzu/pull/6092">issue where pressing Cancel would result in the wrong destination folder</a> in the file system configuration. Nothing beats quality of life fixes!</p> <p><code>Microsoft Visual Studio</code>, by default, will compile applications with the character set corresponding to the region of the local developer’s PC. This limitation can cause issues for certain regions like Asia when trying to build our source. Morph bypassed this limitation <a href="https://github.com/yuzu-emu/yuzu/pull/6029">by forcing the UTF-8 character set.</a> As an added benefit, some UI elements like up and down arrows started rendering. Free bonus.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./utf8.png" title=" There&#39;s nothing like a good arrow icon."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/utf8_hu2050023f4d130682a5821e9002527337_4157_193x0_resize_q90_bgffffff_box_3.jpg" alt=" There&#39;s nothing like a good arrow icon."></a> <p class="has-text-centered is-italic has-text-grey-light"> There&#39;s nothing like a good arrow icon.</p> </div> </div> <p>While a ton of work is needed to make <code>MONSTER HUNTER RISE</code> run, including finishing the shader decompiler rewrite and implementing the asynchronous software keyboard, that doesn’t mean <a href="https://github.com/ogniK5377">ogniK</a> can’t start some preliminary work. In this particular case, the focus is to improve <a href="https://github.com/yuzu-emu/yuzu/pull/6112"><code>Parental Control</code> emulation,</a> bringing it closer to the Switch’s native hardware implementation.</p> <h2 id="graphic-improvements">Graphic improvements</h2> <p>Since the introduction of <code>Asynchronous shaders</code>, we noticed that not all drivers like the feature. In particular, Intel Windows OpenGL, and the proprietary AMD drivers (for both Windows with Adrenalin, and Linux with AMDGPU-PRO) despise the setting, with Intel ignoring it at a driver level, and AMD outright skipping frames, resulting in massive stuttering.</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6095">added a blacklist</a> for our red and blue GPU users, ensuring no performance or graphical regressions occur while attempting to use a feature that their drivers can’t support in OpenGL anyway. It’s worth mentioning that Asynchronous shaders work as intended in Vulkan and all free Linux OpenGL drivers, be it for AMD or Intel. Nvidia works as expected on any combination of API or OS with their proprietary drivers. Thanks to <a href="https://github.com/theboy181">theboy181</a> for the suggestion!</p> <p><a href="https://github.com/bunnei">bunnei</a> implemented an optimization that affects all graphic caches (texture, buffer, shader). By <a href="https://github.com/yuzu-emu/yuzu/pull/6028">using a flat array</a>, cache performance is improved slightly, with the bonus of some memory bandwidth saved due to better resource allocation. A small but measurable 5% performance bump can be experienced, for example, in <code>Super Mario Odyssey</code>.</p> <h2 id="technical-fixes-continued">Technical fixes, continued</h2> <p>The <a href="https://github.com/MerryMage/dynarmic">dynarmic</a> submodule has been recently <a href="https://github.com/yuzu-emu/yuzu/pull/6047">updated in this PR</a>, merging the latest changes with yuzu. Thanks to the efforts of <a href="https://github.com/MerryMage/">merry</a> and <a href="https://github.com/lioncash">lioncash</a>, many <code>thumb32</code> instructions (a subset of ARM instructions) were implemented, increasing the amount of instructions supported for 32-bit games on yuzu.</p> <p>Additionally, all floating-point instructions received minor optimizations, and a couple of bugs in the implementation of <a href="https://github.com/yuzu-emu/yuzu/pull/6118">AVX-512 extensions</a> were fixed too. There was also a problem with <code>AMD</code> CPUs, where previously dynarmic disabled the use of the <code>BMI</code> instruction set (used for bit manipulation), due to being extremely slow in those processors. However, on Zen 3 and newer, the performance of these instructions has increased considerably, so now dynarmic allows these <code>AMD</code> processors to use <code>BMI</code> instructions if the detected CPU is fast enough to perform them.</p> <p>All of these changes were possible thanks to the contribution of <a href="https://github.com/Wunkolo">Wunkolo</a> to dynarmic (which eventually made it to yuzu), so shoutouts for the great work!</p> <p>Going back to kernel updates, <a href="https://github.com/bunnei/">bunnei</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6099">reworked and cleaned the kernel memory management code</a>. As the name implies, this is the part of the OS that allocates memory resources for games when they request them. With this change, the implementation matches more closely that of the Nintendo Switch. As always, these changes make it easier to support any future hardware revisions, along with all other kernel changes that are currently ongoing.</p> <p>Bunnei also fixed <a href="https://github.com/yuzu-emu/yuzu/pull/6036">a memory leak</a> caused by <code>dummy threads</code>. These dummies are used by yuzu to interact with our emulated kernel. Every &ldquo;real&rdquo; emulated thread has a dummy associated with it. As explained in the <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2021/">previous progress report</a>, yuzu utilizes fibers in order to emulate threads. However, these dummy threads don&rsquo;t actually use fibers. With this change, bunnei removed some unnecessary memory overhead by removing the creation of fibers (which would only be needed for &ldquo;real&rdquo; emulated threads), thus reducing the memory usage by a bit.</p> <p>Another bug that was also fixed by bunnei was related to how <a href="https://github.com/yuzu-emu/yuzu/pull/6100">JIT states are saved between page table changes</a>. A <a href="https://en.wikipedia.org/wiki/Page_table">page table</a> is a scheme used to map physical memory into virtual memory, used to give processes the impression they&rsquo;re working with a unique, contiguous section of memory, regardless of where and how this memory is actually stored. Due to the way dynarmic is coded, whenever yuzu changes the page table that is currently in use, it needs to recreate the CPU JIT. But, until now, yuzu wasn&rsquo;t saving and restoring the state of this JIT properly when this happened. However, with this change, all the context needed by the JIT is now stored and retrieved correctly.</p> <h2 id="input-improvements">Input improvements</h2> <p>Not all devices can do <code>N-key rollover</code>, meaning pressing many keys/buttons at the same time without some inputs being missed. For this, <a href="https://github.com/german77">german77</a> implemented a <a href="https://github.com/yuzu-emu/yuzu/pull/6040">toggle to hold a button for you.</a> This way you can ask yuzu to keep pressing a button, freeing your hand and devices from it, while you move to something else! To access this feature, right click the Modifier button in control settings, and select <code>Toggle button</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./toggle.png" title=" Right click any button or modifier"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/toggle_hua7e71105a8314bd44a01ad8e7ed31634_66982_1021x0_resize_q90_bgffffff_box_3.jpg" alt=" Right click any button or modifier"></a> <p class="has-text-centered is-italic has-text-grey-light"> Right click any button or modifier</p> </div> </div> <p>For those using <a href="https://cemuhook.sshnuke.net/">Cemuhook</a> to provide motion via an Android device, <a href="https://github.com/german77">german77</a> has a nice stability improvement for you! <a href="https://github.com/yuzu-emu/yuzu/pull/6004">Each individual socket connection now needs its unique client ID.</a></p> <p>In a separate PR, german77 <a href="https://github.com/yuzu-emu/yuzu/pull/6127">tests using a single UDP connection per server</a> instead of per controller, reducing the error rate thanks to simplified communications. The end result of this work is more stable connections for motion devices.</p> <p>Xbox 360 and Xbox One controllers were incorrectly displayed as just <code>Xinput Controller</code> in our device list, causing confusion to our users. Additionally, the default Pro Controller mapping had its face buttons swapped by mistake. <a href="https://github.com/german77">german77</a> <a href="https://github.com/yuzu-emu/yuzu/pull/6119">fixed both issues.</a> Bad defaults are bad.</p> <h2 id="future-projects">Future projects</h2> <p>Project Hades, our rewrite of the shader decompiler, is taking shape. On the games that can be booted now, we can already measure performance increases and countless bugs fixed.</p> <p>Here’s a sneak peak, fresh from the source.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wip.png" title=" You can say it&#39;s one hell of a rewrite!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/wip_hu3d34bb77dc55edd65b3f16256a0f841d_1618135_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" You can say it&#39;s one hell of a rewrite!"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can say it&#39;s one hell of a rewrite!</p> </div> </div> <p>While our graphics devs continue to rewrite all shader instructions, we can inform everyone that the new pipeline cache for Vulkan is fully working, storing and loading just as well as OpenGL’s shader cache, while even being faster!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./wip1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/wip1_hue4ceccf5ff2f341bc538ce6b993c5e52_2375665_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more hard crashes (Fire Emblem: Three Houses)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./wip2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/wip2_hu97a4ea07de5423f466ceaf5ed928bbb6_5334084_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more hard crashes (Fire Emblem: Three Houses)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./wip3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/wip3_hue86e53e19c7edd4d46601c1f1c5aee78_2376897_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more hard crashes (Fire Emblem: Three Houses)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more hard crashes (Fire Emblem: Three Houses)</p> <p>On top of that, Rodrigo also implemented a new kind of asynchronous shader “secret technique” that scales better with the number of threads available, and produces zero graphical glitches!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wip4.png" title=" The Bokoblin Slayer (Hyrule Warriors: Age of Calamity)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2021/wip4_hue13b15e9a0d29453e5f5a8d51a6cd98c_4003779_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The Bokoblin Slayer (Hyrule Warriors: Age of Calamity)"></a> <p class="has-text-centered is-italic has-text-grey-light"> The Bokoblin Slayer (Hyrule Warriors: Age of Calamity)</p> </div> </div> <p>We will expand this information once Hades is out and has its own dedicated article.</p> <p>That’s all folks! Thank you so much for allowing us to take some of your time, and see you next month!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - Applet Overlays https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/ Sat, 03 Apr 2021 01:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/ <p>Hey there, yuz-ers! Have you ever thought of enjoying yuzu on your TV, relaxing on your couch, but found our user interface cumbersome? Thanks to the efforts of our developers <a href="https://github.com/Morph1984">Morph</a> and <a href="https://github.com/Its-Rei">Rei</a>, yuzu has taken a massive step forward in making couch gaming comfy. Let&rsquo;s dig in!</p> <p>Hey there, yuz-ers! Have you ever thought of enjoying yuzu on your TV, relaxing on your couch, but found our user interface cumbersome? Thanks to the efforts of our developers <a href="https://github.com/Morph1984">Morph</a> and <a href="https://github.com/Its-Rei">Rei</a>, yuzu has taken a massive step forward in making couch gaming comfy. Let&rsquo;s dig in!</p> <h1 id="what-is-this-about">What is this about?</h1> <p>For a while now, users have complained that yuzu&rsquo;s couch setup (full-screen, TV, controller) experience isn&rsquo;t as comfortable as it could be. One pain point was that pop-ups of any kind can&rsquo;t be addressed with a controller. On top of that, these pop-up windows were separate background processes that wouldn&rsquo;t appear until you exited full-screen mode. As you can guess, you always had to have a keyboard and mouse handy.</p> <p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./error_old.png" title=" Old error applet"> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/error_old_hucf490d9216edddf799ccbf12100e1b08_1893328_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Old error applet"></a> <p class="has-text-centered is-italic has-text-grey-light"> Old error applet</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./error_new.png" title=" New controller friendly error applet"> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/error_new_hucc6c7b86b81f2ff65c1d0c0dfe7e03e7_559004_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" New controller friendly error applet"></a> <p class="has-text-centered is-italic has-text-grey-light"> New controller friendly error applet</p> </div> </div> </p> <p>To fix this once and for all, Rei started work on eliminating all pop-up windows and to make it possible to control all system messages with a controller. It was during this time that Morph began working on rewriting our software keyboard applet. And since the software keyboard applet wasn&rsquo;t controller friendly either, they both collaborated and redesigned it from the ground up.</p> <p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./swkbd_old.png" title=" Old software keyboard applet"> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/swkbd_old_huc6e881e5d57201c17c9050b3ef45d73b_10851_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Old software keyboard applet"></a> <p class="has-text-centered is-italic has-text-grey-light"> Old software keyboard applet</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./swkbd_new.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> New controller friendly software keyboard applet</p> </div> </div> </p> <h1 id="the-software-keyboard">The Software Keyboard</h1> <p>As many of you might know, the Switch has a software keyboard that allows players to input text into games. What you might not know is that there are multiple variants of keyboards implemented within the Switch&rsquo;s Horizon OS. For example, there is the full-screen keyboard, which pauses games and allows input, and there is the inline keyboard, which allows input while the game is running.</p> <p>Our old software keyboard implementation was just the bare minimum required by the full-screen variant and, due to its design, was difficult to add support for the other variants. It also quickly became outdated due to the newer revisions of the applet that shipped with later Switch firmware updates. Equipped with the knowledge and expertise from previously rewriting two other applets - namely, the browser applet &amp; the controller applet - Morph set out to rewrite the entire software keyboard applet from scratch.</p> <p>Rei had meticulously designed the new overlays for the keyboard applet and they turned out to be absolutely stunning. Now, all that was left was to implement the keyboard applet backend and connect it to the frontend — but then came the challenges.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./osk_ssbu_line_white.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/osk_ssbu_line_white_hu10a4a9fda2d0b0b90fc2401684a1d2d3_73062_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new software keyboard layouts for each yuzu theme"></a> </div> <div class="column is-bottom-paddingless"> <a href="./osk_ssbu_line_midnight.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/osk_ssbu_line_midnight_hu96ff7a183ca05854fd0696415b19c464_78369_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new software keyboard layouts for each yuzu theme"></a> </div> <div class="column is-bottom-paddingless"> <a href="./osk_ssbu_line_dark.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/osk_ssbu_line_dark_hu077abc1d4082e197cb507cc585c64164_77745_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new software keyboard layouts for each yuzu theme"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The new software keyboard layouts for each yuzu theme</p> <h1 id="challenges">Challenges</h1> <p>As mentioned earlier, our old implementation was not designed with multi-variant support in mind. With the rewrite, our foundational goal was to ensure all keyboard variants were supported. A major challenge was figuring out how the inline keyboard variant worked. In contrast to the full-screen variant, this one worked asynchronously.</p> <p>Applets run as separate processes on the Switch, but games have a habit of pausing their processes, invoking the keyboard applet, and making it seem synchronous. There are several more applets that work asynchronously in addition to the inline keyboard variant. As such, Morph spent a lot of time and effort on testing how the applet worked on original hardware — figuring out how all the pieces fall into place, making optimizations, and thus slowly perfected the backend implementation.</p> <p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./mhgu_line_swkbd.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Monster Hunter Generations Ultimate - Inline Keyboard in action</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./swsh_num_swkbd.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Pokémon Sword/Shield - Numeric Keyboard in action</p> </div> </div> </p> <p>With the backend in place, a new set of challenges arose due to yuzu&rsquo;s frontend library, <a href="https://www.qt.io/">Qt</a>. Qt has a <strong>lot</strong> of annoying quirks, such as window positioning, transparency, and more. These took several days of testing to track down and resolve. For the frontend, Morph and Rei also had to plan and account for various other things like game specific keyboard scaling, high DPI displays, and higher resolutions.</p> <p>The final and most important challenge was figuring out how to make the applet controller friendly. Thanks to the efforts spent in planning and testing at various stages of development, our devs were able to overcome these challenges.</p> <h1 id="extra">Extra</h1> <p>Although the overlay dialogs were initially designed with the keyboard applet in mind, the devs soon discovered its potential as a replacement for pop-up windows. Thanks to this, the error applet has now joined the list of controller friendly applets, with more to come soon. The error applet is used by games to crash and report back error codes to the user in various scenarios, which was previously done via a pop-up window.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./error_white.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/error_white_hud3bb1ba5ce2bcad704158530826d5151_734789_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new error applet overlays for each yuzu theme"></a> </div> <div class="column is-bottom-paddingless"> <a href="./error_midnight.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/error_midnight_hud595fd048a1e9a938b4f2dce7be224c0_659969_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new error applet overlays for each yuzu theme"></a> </div> <div class="column is-bottom-paddingless"> <a href="./error_dark.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-applet-overlays/error_dark_hu3985d37d183b137d70646b0b6860235a_566637_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new error applet overlays for each yuzu theme"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The new error applet overlays for each yuzu theme</p> <h1 id="fin">Fin</h1> <p>Both the new keyboard applet and the controller friendly error applet are now available in the <a href="https://yuzu-mirror.github.io/help/early-access/">latest Early Access build</a>. Since these are currently still under development, we would like to hear more about your experiences and any bugs/issues you might encounter. Please don&rsquo;t hesitate to reach out to us on our Discord server&rsquo;s Patreon support channels to report any findings. That&rsquo;s all we have for today but, we&rsquo;re sure to be back with more exciting news soon!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report February 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2021/ Wed, 10 Mar 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-feb-2021/ <p>Welcome back yuz-ers, welcome to <del>City 17</del> February’s progress report! This time we will talk about Vulkan performance improvements, audio changes, how to make good use of compute shaders, new input additions, and more kernel rewrites.</p> <p>Welcome back yuz-ers, welcome to <del>City 17</del> February’s progress report! This time we will talk about Vulkan performance improvements, audio changes, how to make good use of compute shaders, new input additions, and more kernel rewrites.</p> <h2 id="new-minimum-requirements">New minimum requirements</h2> <p>Thanks to progress in Linux’s mesa drivers, we&rsquo;ve recently modified our minimum graphics requirements.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/5888">yuzu now requires OpenGL 4.6</a>. However, any previously compatible hardware reaches this requirement with its latest GPU drivers installed, even old Fermi or GCN 1.0 series products. Laptop users, like desktop users, should visit the GPU manufacturer&rsquo;s site (<a href="https://www.amd.com/en/support">AMD</a>, <a href="https://downloadcenter.intel.com/product/80939/Graphics">Intel</a>, and <a href="https://www.nvidia.com/en-us/geforce/drivers/">Nvidia</a>) instead of the laptop vendor’s site (HP, Lenovo, Asus, etc.), as it will provide compatible and up-to-date drivers. Thanks <a href="https://github.com/Morph1984">Morph</a> for the change!</p> <p>On the flip side, while the requirement of Vulkan 1.1 hasn&rsquo;t changed, as stated in previous articles, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> made <code>VK_EXT_robustness2</code> <a href="https://github.com/yuzu-emu/yuzu/pull/5917">a hard requirement.</a> This means that updated drivers are critical now, as lacking this extension will stop yuzu from booting games while on Vulkan. AMD users still require to install the latest <code>Optional</code> driver version to get support for <code>VK_EXT_robustness2</code>. At the time of writing, the latest version is <code>21.2.3</code>, but yuzu will work with drivers as old as <code>20.12.1</code>.</p> <p>Multi-GPU systems must have all their drivers updated, even for integrated graphics that are functional but not in use.</p> <h2 id="technical-bugfixes">Technical bugfixes</h2> <p><a href="https://github.com/MerryMage">Merry</a> recently caught a bug in the implementation of yuzu&rsquo;s <code>SPSC</code> ring buffer and fixed it by <a href="https://github.com/yuzu-emu/yuzu/pull/5885">removing the granularity template argument</a>. What does this mean exactly? Let&rsquo;s explain!</p> <p>A buffer is a data structure that reserves space in memory as slots to store information temporarily: for example, an audio buffer. In particular, a <a href="https://en.wikipedia.org/wiki/Circular_buffer">ring buffer</a> is a special type of buffer where the slot next to the final one is the first slot in the buffer (so the start and the end are connected). Once it&rsquo;s full, no new data is added until some information has been extracted from the buffer and processed.</p> <p><code>SPSC</code> stands for &ldquo;Single-Producer/Single-Consumer,&rdquo; and is a model that comes from the <a href="https://en.wikipedia.org/wiki/Producer%E2%80%93consumer_problem">Producer-Consumer problem</a> proposed by computer scientists to deal with the problem of proper synchronization when various simultaneous processes write and read from the same buffer. In this case, only one thread at a time can insert data into the buffer (the Single-Producer), and only one thread at a time can remove elements from the buffer (the Single-Consumer).</p> <p>It&rsquo;s possible to choose a minimal size for each &ldquo;slot&rdquo; of the buffer in order to exploit regularities of the information stored. The entities inside these slots are then considered a single &ldquo;unit&rdquo; of information, an <em>information granule</em>, from which the term &ldquo;granularity&rdquo; stems from. The ring buffer implementation in yuzu was meant to be as general as possible, which is why granularity was a parameter that the programmer could modify to fit their needs. Merry noticed there was a small bug when pushing data into the buffer with a granularity different from <code>1</code>, but since there is no use case for a granularity different from <code>1</code> in yuzu, Merry decided to remove the parameter altogether, in favor of simplifying the codebase.</p> <p><a href="https://github.com/bunnei">bunnei</a> has been taking a look at the timing code and <a href="https://github.com/yuzu-emu/yuzu/pull/5964">fixed an integer overflow in the wall-clock</a> - a tool used to measure the passage of time in the emulator. Previously, these calculations would use 128-bit math for high precision, which can be quite expensive on the processor, so a few optimizations were done to perform 64-bit math instead. However, there was a bug introduced with these optimizations, and the timing math would result in an integer overflow. This PR fixed the bug by preventing the wall-clock from overflowing, and now things are back to working as intended.</p> <p>bunnei also continues on his campaign to rewrite the kernel and its codebase. This time, he has been tidying up the <a href="https://github.com/yuzu-emu/yuzu/pull/5953">memory management code</a> and refactoring the implementation to be closer to the latest Switch firmware in order to make it easier to import code from newer firmware.</p> <p>Additionally, he changed the implementation of <a href="https://en.wikipedia.org/wiki/Fiber_(computer_science)">fibers</a> to <a href="https://github.com/yuzu-emu/yuzu/pull/6006">use unique_ptr instead of shared_ptr</a>, but later <a href="https://github.com/yuzu-emu/yuzu/pull/6041">changed it again to use weak_ptr</a> as it&rsquo;s more appropriate in this use case.</p> <p>Fibers are similar to threads, except they can&rsquo;t be executed in parallel. Instead, they <em>yield</em> control to other fibers in a process. In yuzu, they&rsquo;re used to have better control over thread scheduling, working as tools for the kernel to quickly pause and resume emulated guest threads from within the application, without having to rely on the OS scheduler.</p> <p>Previously, fibers were managed through a special object called a <code>shared pointer</code>, a kind of variable that stores the memory addresses of other objects - it “references” them. In particular, this variable keeps track of how many <code>shared_ptr</code> references to an object exist in the program, and the memory won&rsquo;t be freed until the total amount of references is zero (i.e. when the object isn&rsquo;t being used anymore). If these references aren&rsquo;t managed with proper care, some pointers may retain memory and never free it, resulting in memory leaks. For this reason, bunnei changed the implementation to use a different kind of object, a <code>weak pointer</code>, which is similar to the <code>shared pointer</code> but it doesn&rsquo;t increase the reference counter, nor is it capable of deleting the original referenced object. Thus, the referenced memory will be free only when the original pointer is deleted, regardless of how many other <code>weak_ptr</code> references to the same memory exist, eliminating the memory leaks caused by the old implementation.</p> <p>One of the many tasks of the kernel is to assign resources to processes whenever they ask for them. For this reason, <a href="https://github.com/ameerj">epicboy</a> started the work necessary to <a href="https://github.com/yuzu-emu/yuzu/pull/5877">utilize a more accurate resource_limit implementation</a>, in order to match the hardware behavior more closely.</p> <p>Be it memory, threads, or ports, the kernel checks for their availability and keeps track of them through a variable called <code>resource limit</code>. By comparing the current amount of resources being used against the resource limit, the kernel can determine whether to deny a request or not. This stems from the fact that resources are finite, especially in weaker hardware such as that in the Nintendo Switch. A PC, on the other hand, isn&rsquo;t as restricted as a Nintendo Switch. Until now, whenever a process requested resources, yuzu would create its own instance of <code>resource limit</code> instead of using a system-wide variable to keep track of it. This PR is just the initial step in preparation to reverse engineer the correct behavior and implement it in the emulator.</p> <h2 id="paint-me-like-one-of-your-french-bits">Paint me like one of your french bits</h2> <p><a href="https://github.com/ameerj">epicboy</a> has also been busy this month implementing two features through <a href="https://en.wikipedia.org/wiki/Compute_kernel">compute kernels</a>, a special kind of program that is written to run in the GPU instead of the CPU. Originally, these subroutines were used to calculate light levels, darkness, colors, and other properties to render 3D images on the screen. Thus, these programs were promptly named as <a href="https://en.wikipedia.org/wiki/Shader">shaders</a>.</p> <p>Modern GPUs are designed to break down their workload into smaller sized problems, which in turn are processed simultaneously in the many compute units of the card (entities akin to cores in a CPU). The reason for this design choice is simply because parallelisation is a very efficient scheme to process computer graphics. A single instruction is capable of operating over many components of data at the same time, such as the vertices and textures of a 3D scene, and produce separate results for each parallel thread of execution, which is generally a pixel. This increases the throughput of information, especially when compared against the performance of running the same operations on a CPU. Their potential isn&rsquo;t limited to just these functions though. It is possible to write programs that won&rsquo;t necessarily operate over graphics, but can still take advantage of the high levels of parallelisation provided by GPUs. This is known as <code>GPGPU</code> - <a href="https://en.wikipedia.org/wiki/General-purpose_computing_on_graphics_processing_units">General-purpose computing on graphics processing units</a> - and it&rsquo;s intended to be used when there is a problem that can be separated into a number of parallel tasks in order to be processed more efficiently. These problems are commonly called <code>embarrassingly parallel problems</code>.</p> <p>One of these cases was the <a href="https://github.com/yuzu-emu/yuzu/pull/5927">use of compute shaders to decode ASTC textures</a>. <code>ASTC</code> stands for &ldquo;Adaptable Scalable Texture Compression,&rdquo; and it&rsquo;s a fairly new image compression format developed by ARM and AMD mainly aimed at mobile devices. The Nintendo Switch is capable of decoding these textures natively in hardware, but it&rsquo;s a feature that most PC GPU vendors lack in their products (with the exception of Intel Graphics, being the only vendor that offers native support). The decoding of these textures is therefore a non-trivial task that can have a huge impact on performance. Two notable examples are <code>Astral Chain</code> and <code>Luigi's Mansion 3</code>, since both games make extensive use of this format, but it can also be observed to varying degrees in other titles, where these textures are generally used in menu icons, minimaps, etc.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./astral_chain_atsc.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Comparison between the old and the new implementation of the ASTC decoder</p> </div> </div> <p>This led to the implementation of an <code>ASTC</code> decoder through the CPU, which was faster than what GPUs could do with their lack of native support. The CPU decoder was still far from being a satisfactory solution, since it consumed precious CPU resources and, consequently, slowed down to a halt when running games that made extensive use of this format. The solution, thus, was to implement the decoding through compute shaders. Since this is an embarrassingly parallel process, seeing as how every block of pixels can be decoded independently, it&rsquo;s more fit to be performed on the GPU by manipulating the data through <code>GPGPU</code>. This way, the load on the CPU will be shifted to the GPU, allowing emulation to run in parallel with the texture decoding. As a side benefit, now textures remain in the GPU memory all the time, since they don&rsquo;t need to be transferred between CPU and GPU for decoding. This means that there won&rsquo;t be time spent downloading the texture to the CPU and then uploading it back to the GPU after the decoding is done, like in the old implementation.</p> <p>This feature works as intended on all GPU vendors on Windows, although there are a few problems on Linux (more specifically, the <code>AMDGPU-PRO</code> driver) that still need to be ironed out. Our devs are working hard to solve these bugs, so we ask our tux-friends to be patient and stay tuned!</p> <p>Since compute programs were originally meant to manipulate image data, they also worked out nicely to fix a problem with one of the rendering APIs used in yuzu: by <a href="https://github.com/yuzu-emu/yuzu/pull/5891">using compute shaders to swizzle BGR textures on copy</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./octopath1.jpg" title=""><img src="./octopath1.jpg" alt="Color-swapped and properly swizzled versions of Octopath Traveler&#39;s title screen"></a> </div> <div class="column is-bottom-paddingless"> <a href="./octopath2.jpg" title=""><img src="./octopath2.jpg" alt="Color-swapped and properly swizzled versions of Octopath Traveler&#39;s title screen"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Color-swapped and properly swizzled versions of Octopath Traveler&#39;s title screen</p> <p>In OpenGL, colors are stored in channels, and the way they are laid out varies depending on the format used. For example, the <code>RGB</code> format stores the color channels in the order &ldquo;Red, Green, and Blue,&rdquo; while the <code>BGR</code> format stores the channels in the order &ldquo;Blue, Green, and Red.&rdquo; Unfortunately, this latter format isn&rsquo;t supported internally by OpenGL, which caused problems with a number of games that made use of <code>BGR</code> textures: their Red and Blue channels were swapped and the final images looked blue-ish.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./sg1.jpg" title=""><img src="./sg1.jpg" alt="Blue Christina looks nice, but the red hue definitely suits the Nixie Tubes much better in Steins;Gate: My Darling&#39;s Embrace"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sg2.jpg" title=""><img src="./sg2.jpg" alt="Blue Christina looks nice, but the red hue definitely suits the Nixie Tubes much better in Steins;Gate: My Darling&#39;s Embrace"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Blue Christina looks nice, but the red hue definitely suits the Nixie Tubes much better in Steins;Gate: My Darling&#39;s Embrace</p> <p>The solution to this problem then was to reorder the Blue and Red channels of <code>BGR</code> textures in the copy uploaded to the GPU. Reordering the graphical information of an image to process it in the graphics card is called swizzling, so what this PR does is copy the values of the Red channel into the Blue channel and vice-versa, a process that can be exploited through parallel computation. This way, the limitation with OpenGL is directly bypassed on the GPU, and these textures are rendered as intended on screen.</p> <h2 id="general-bug-fixes-and-improvements">General bug fixes and improvements</h2> <p><code>Pokémon Sword and Shield</code> players can enjoy one less frequent crash. Boss <a href="https://github.com/bunnei">bunnei</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5920">fixed a problem on LDN initialization</a>, eliminating the crash that occurred if the player pressed <code>Y</code> during gameplay (activating online services that yuzu lacks). An error window will still pop up, but emulation will continue.</p> <p>Yet another <code>Animal Crossing: New Horizons</code> update, yet another service to stub or implement to regain playability. This time, <a href="https://github.com/yuzu-emu/yuzu/pull/5892">stubbing GetSaveDataBackupSetting</a> made <code>1.7.0</code> and later versions playable again. Thanks <a href="https://github.com/german77">german77</a>!</p> <p>Under certain conditions, the <code>WebApplet</code> would crash yuzu when opening, for example, the Action Guide in <code>Super Mario Odyssey</code>. <a href="https://github.com/aleasto">aleasto</a> managed to solve this by <a href="https://github.com/yuzu-emu/yuzu/pull/5878">fixing an out of bounds read.</a></p> <p>A common annoyance that affected new users was a prompt asking for the derivation keys to be placed in the correct <code>keys</code> folder, a folder which had to be manually created until now. Thanks to <a href="https://github.com/Morph1984">Morph</a>, now there is an empty <code>keys</code> folder created by default as part of the installation process of yuzu, ready to be populated by the user’s own Switch keys.</p> <h2 id="graphics-improvements">Graphics improvements</h2> <p><a href="https://github.com/Kelebek1">Maide</a> has been working on improving the recently released <code>Disgaea 6: Defiance of Destiny</code>.</p> <p>First, Vulkan needed some <a href="https://github.com/yuzu-emu/yuzu/pull/5936">corrected offsets</a> for <code>TexelFetch</code> and <code>TextureGather</code>, types of texture instructions.</p> <p>A similar change <a href="https://github.com/yuzu-emu/yuzu/pull/5980">was needed for OpenGL.</a> This code also includes better handling of <code>signed atomics</code>, improving precision. Thanks to <a href="https://github.com/Ryujinx/Ryujinx">Ryujinx</a> for helping here.</p> <p>Finally, <a href="https://github.com/yuzu-emu/yuzu/pull/5997">implementing glDepthRangeIndexedNV</a> solves out of range issues in the depth buffer.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./d6bug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./d6fix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The result of Maide&#39;s work (Disgaea 6: Defiance of Destiny)</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5919">fixed a bug in Vulkan’s stream buffer</a>, improving performance and reducing VRAM use, while also making better use of the dedicated VRAM, instead of falling back to shared VRAM, which is better known as just system RAM.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/5923">using dirty flags</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> also managed another slim, but measurable, Vulkan performance bump. Reducing draw calls always helps!</p> <p>After a lot of time spent experimenting, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5989">reduced the size of Vulkan’s command pool</a>, from 4096 to just 4. This makes the driver assign less memory for command buffers, saving a considerable amount of system RAM.</p> <p>For example, in <code>Pokémon Sword and Shield</code>, Vulkan’s use of system RAM goes from 707MB, to just 2MB.</p> <p>To end the day, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed a regression introduced by the <code>Buffer Cache Rewrite</code>. Some games benefit from skipping the cache, but others lose performance. <code>Animal Crossing: New Horizons</code> was an example severely affected in Vulkan. By <a href="https://github.com/yuzu-emu/yuzu/pull/6021">implementing a way to heuristically decide when to skip the cache</a>, performance was not only restored, but also increased.</p> <h2 id="input-improvements">Input improvements</h2> <p>First and foremost, <a href="https://github.com/german77">german77</a> finished implementing <a href="https://github.com/yuzu-emu/yuzu/pull/4940">native Gamecube controller support!</a> With this change, games will now actually register GC controllers instead of registering them as, for example, emulated Pro Controllers. Right now Gamecube triggers are mapped as buttons, but they will be correctly handled as analog triggers in coming changes.</p> <p><a href="https://github.com/Morph1984">Morph</a> later added <a href="https://github.com/yuzu-emu/yuzu/pull/5944">vibration support for the GC controller.</a></p> <p>Another new feature <a href="https://github.com/german77">german77</a> added is stick <a href="https://github.com/yuzu-emu/yuzu/pull/5869">mouse panning.</a> This allows users to set the mouse as an analog stick, enabling very comfortable gameplay on titles that use the right analog stick as camera control. By default, pressing Ctrl + F9 toggles this feature.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./panning.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Keyboard warriors rejoice! (The Legend of Zelda: Breath of the Wild)</p> </div> </div> <p>A <a href="https://github.com/yuzu-emu/yuzu/pull/5929">separate PR</a> improves panning functionality even more, giving it a more natural control.</p> <p><a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5908">implemented the Finalize request</a> on the inline keyboard implementation, allowing it to exit in a stable and graceful way instead of looping indefinitely. This solves issues experienced in <code>Super Mario 3D World + Bowser’s Fury</code>.</p> <p><a href="https://github.com/Jatoxo">Jatoxo</a> gives us a feature we didn’t know we wanted. <a href="https://github.com/yuzu-emu/yuzu/pull/5894">They&rsquo;ve added depth to the analog sticks</a> of the Pro Controller in the controls preview. See the result for yourself!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./stickold.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./sticknew.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Nothing beats quality of life changes like this</p> <h2 id="audio-achievements">Audio achievements</h2> <p>One of our most requested fixes is finally here. <code>Fire Emblem: Three Houses</code> no longer echoes voices! <a href="https://github.com/ogniK5377">ogniK</a> is responsible for this fix, which properly <a href="https://github.com/yuzu-emu/yuzu/pull/5909">implemented I3dl2Reverb.</a></p> <p>If you paused emulation and resumed it some time later, you would experience severe stuttering until the audio caught up to the rendering. <a href="https://github.com/german77">german77</a> resolved this unpleasant experience by <a href="https://github.com/yuzu-emu/yuzu/pull/5868">preventing overscheduling audio events</a>, allowing for a seamless experience after resuming emulation.</p> <h2 id="future-projects">Future projects</h2> <p>Project Kraken is underway. Project Gaia started. Project Hades, the shader decompiler rewrite, is progressing steadily. If it continues like this, it will be released before Memory Reaper. As you’ve seen in this article, bunnei continues to suffer through implementing Kernel changes.</p> <p>That’s all folks! As always, thank you for reading until the end, and see you next time!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report January 2021 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/ Wed, 10 Feb 2021 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/ <p>Welcome yuz-ers, to the first progress report of 2021! We have quite a bit in store for you: from kernel and CPU emulation improvements to another major graphical rewrite. Here are the most important changes of January.</p> <p>Welcome yuz-ers, to the first progress report of 2021! We have quite a bit in store for you: from kernel and CPU emulation improvements to another major graphical rewrite. Here are the most important changes of January.</p> <h2 id="the-buffer-cache-rewrite">The Buffer Cache Rewrite</h2> <p>While we have a <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/">dedicated article detailing the improvements from the Buffer Cache Rewrite</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5741">(BCR)</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> didn&rsquo;t sit idle and continued to improve the buffer cache. These new changes and improvements deserve some time in the spotlight. For the full context, we advise reading the dedicated article before continuing.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xcdebug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xcdefix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The BCR offers performance and rendering improvements (Xenoblade Chronicles Definitive Edition)</p> <p>Vulkan needed some improvements to be compatible with the BCR. In particular, its <a href="https://github.com/yuzu-emu/yuzu/pull/5297">memory allocator</a> got a complete overhaul, improving its functionality.</p> <p>A performance bottleneck affecting Intel GPUs in Vulkan was fixed by <a href="https://github.com/yuzu-emu/yuzu/pull/5311">using timeline semaphores instead of spin waits.</a></p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/5363">Preliminary work was done</a> to have the compute accelerated texture decoders working in the near future.</p> <p>Assembly shaders are very limited and hard to work with due to their <a href="https://en.wikipedia.org/wiki/ARB_assembly_language#History">ancient origins.</a> A problem faced during the BCR development is keeping compatibility with them while offering their advantage in shader build times to Nvidia users. At release, the first implementation <a href="https://github.com/ReinUsesLisp">Rodrigo</a> tried made use of <code>interops</code>, a feature that allows calling functions of one graphics API from another. In this particular case, he used the new memory allocator of Vulkan from within an OpenGL context. While the results in Windows 10 and Linux were satisfactory, this had some limitations:</p> <ul> <li>Windows 7 was unstable due to broken memory management. A known problem that was never fixed during the lifetime of this now discontinued operating system.</li> <li>Fermi era GPUs (mostly 400 and 500 series) had to skip assembly shaders due to Nvidia never adding Vulkan support.</li> </ul> <p>So, as a workaround for now, the old pre-BCR method is currently in place. Since this method may be slower in some games compared to the updated GLSL implementation, assembly shaders is now disabled by default while Rodrigo works on a different implementation. Feel free to re-enable this setting if you get playable performance in your games. You can find it in <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced tab</code></p> <p>Vulkan users are advised to update their GPU drivers to the very latest version, as the BCR makes the extension <code>VK_EXT_robustness2</code> mandatory, instead of its previous optional status after the release of the Texture Cache Rewrite. All three main GPU companies (Nvidia, AMD, and Intel) now offer support for this extension in their latest driver. AMD users updating from Radeon Software may need to allow <code>Optional</code> driver download support to get the corresponding driver version to have access to this valuable Vulkan extension (at the time of writing).</p> <p>Several games now prefer <code>High</code> GPU accuracy over the default <code>Normal</code> value. Users can change this setting while playing by going to <code>Emulation &gt; Configure… &gt; Graphics &gt; Advanced tab &gt; Accuracy level</code>. We recommend users to play with this setting to find the optimal performance, but to avoid the <code>Extreme</code> value for the moment, as it will either result in very low performance (intended result), or crash the game entirely (not intended, being investigated).</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bcr.png" title=" While there are big improvements across the board, this graph shows the limitations of integrated GPUs constantly fighting the CPU for RAM resources. Having your own fast dedicated on-board VRAM is very important for performance."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/bcr_hu5ff90bbf02fdc73f800d5219bc8c5bf3_26336_1008x0_resize_q90_bgffffff_box_3.jpg" alt=" While there are big improvements across the board, this graph shows the limitations of integrated GPUs constantly fighting the CPU for RAM resources. Having your own fast dedicated on-board VRAM is very important for performance."></a> <p class="has-text-centered is-italic has-text-grey-light"> While there are big improvements across the board, this graph shows the limitations of integrated GPUs constantly fighting the CPU for RAM resources. Having your own fast dedicated on-board VRAM is very important for performance.</p> </div> </div> <p>Analysis time. If you compare this graph to the one of the RX550 in the <a href="https://yuzu-mirror.github.io/entry/yuzu-bcr/">BCR artricle,</a> you will notice that a small integrated Vega manages to beat a dedicated Polaris card in <code>Fire Emblem: Three Houses</code> by a few frames. This is because newer GPU architectures offer features that are useful for Switch emulation. Ray tracing is not the only cool kid in town!</p> <p>The Tegra X1 SoC in the Nintendo Switch offers native support for FP16 with a 2:1 performance ratio, allowing games to double their performance over regular FP32 when doing floating point calculations. A simple way to achieve a higher frame rate on limited hardware. Vega (GCN 5.0), Turing, Gen 9 Intel Graphics and newer offer native support for FP16, or as AMD calls it, “Rapid Packed Math”. Series like Polaris (GCN 4.0), Pascal and older may offer support in their drivers but don’t provide a performance advantage, and in the case of Pascal, it reduces performance considerably (64 times slower than FP32). In those cases FP32 is used to emulate FP16, obviously resulting in no performance gains.</p> <p>This is the main reason our <a href="https://yuzu-mirror.github.io/help/quickstart/#hardware-requirements">Hardware Requirements</a> lists Gen 9.5, Vega, and Turing cards, as the recommended GPUs. Maxwell v2, Vega, Gen9 and later series also offer <code>conservative rasterization</code>, a very useful feature that yuzu can take advantage of in the future.</p> <h2 id="general-bug-fixes-and-improvements">General bug fixes and improvements</h2> <p>Let’s start with good news, Champion Leon can no longer win by default! Thanks to <a href="https://github.com/ogniK5377">ogniK’s</a> work, <a href="https://github.com/yuzu-emu/yuzu/pull/5799">unregistering already registered events</a>, games like <code>Pokémon Let’s Go Eevee/Pikachu</code> and <code>Pokémon Sword/Shield</code> won’t softlock when the game requests playing a video. Gotta beat em all, was it?</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pksw.png" title=" Let’s battle, for real this time! (Pokémon Sword)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/pksw_hu5b17c1705e510283828fb772b25294c0_3603239_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Let’s battle, for real this time! (Pokémon Sword)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Let’s battle, for real this time! (Pokémon Sword)</p> </div> </div> <p>Quality of Life improvements, although seemingly small, can still require several considerations. <a href="https://github.com/Morph1984">Morph</a> made <a href="https://github.com/yuzu-emu/yuzu/pull/5324">docked mode the default option</a>, with the intention to offer users the highest game quality, and to remove flickering experienced in <code>Super Mario Odyssey</code> when running the game with assembly shaders enabled while in undocked mode. Users with integrated, slow, and/or old GPUs should consider using undocked mode, as the reduced resolution and detail level will help avoid performance bottlenecks.</p> <p><a href="https://github.com/german77">german77</a> solved one of the most common problems users had when playing <code>Super Smash Bros. Ultimate</code>, <a href="https://github.com/yuzu-emu/yuzu/pull/5842">the inability to boot the game if more than one user profile was created</a>. Thanks to this fix, users are no longer forced to play the game with the top profile in the list.</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> continues his work on Linux’s <code>AppImages</code>. Now yuzu’s <a href="https://github.com/yuzu-emu/yuzu/pull/5302">AppImage build can be updated</a>, reducing the download size to just around 9MB <a href="https://appimage.github.io/AppImageUpdate/">if you use AppImageUpdate.</a></p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/5279">By improving <code>nvflinger</code>, the display service of the Nintendo Switch,</a> <a href="https://github.com/bunnei">bunnei</a> made <code>Katana ZERO</code> playable again.</p> <p>Serendipity strikes again. By <a href="https://github.com/yuzu-emu/yuzu/pull/5284">fixing a data race</a> introduced by one of the recent kernel changes, <a href="https://github.com/ameerj">epicboy</a> also fixed unlimited FPS mods which previously made the emulator crash.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/5840">fixing invalid buffer index errors,</a> <a href="https://github.com/Morph1984">Morph</a> was able to resolve various crashes in booting <code>Super Mario Maker 2</code> that occurred due to file system issues.</p> <p>In the eternal torture that is audio development, <a href="https://github.com/ogniK5377">ogniK</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5809">implemented <code>FlushAudioOutBuffers</code>,</a> making the <code>Devil May Cry</code> series playable.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dmc2.png" title=" Look at the graphics, that&#39;s you know, what it&#39;s really all about (Devil May Cry 2)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/dmc2_hu68cd14ae9b12778b36946d5ea4525414_3795364_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Look at the graphics, that&#39;s you know, what it&#39;s really all about (Devil May Cry 2)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Look at the graphics, that&#39;s you know, what it&#39;s really all about (Devil May Cry 2)</p> </div> </div> <h2 id="miscellaneous-graphical-improvements">Miscellaneous graphical improvements</h2> <p>We have three public service announcements, one for each GPU vendor:</p> <p>First, a message for AMD users with RX 5000 series graphics cards. In the past, we blacklisted the <code>VK_EXT_extended_dynamic_state</code> Vulkan extension on all RDNA1 based GPUs on Windows. The drivers at the time were unstable when using this extension, causing yuzu to crash to the desktop. <a href="https://github.com/yuzu-emu/yuzu/pull/5814">This block has been removed</a> by <a href="https://github.com/ReinUsesLisp">Rodrigo,</a> but keep in mind that the user needs to be running <code>20.12.1</code> or newer driver versions. “Navi“ users can expect several graphical fixes thanks to this change.</p> <p>Blue team’s turn. On the topic of blacklists, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> had to <a href="https://github.com/yuzu-emu/yuzu/pull/5798">disable FP16 math support from Intel Windows Vulkan drivers</a> to solve stability issues affecting <code>Astral Chain</code>. For now, half-float operations will be emulated using FP32 math. This will result in lower performance if the game manages to make full use of the compute capabilities of the GPU. However, on current Intel Graphics, rasterization (to put it simple, the raw power of the GPU) is usually the first element to bottleneck performance, even before being affected by the aforementioned operations.</p> <p>Thanks to this change and Intel’s native ASTC texture decoding support, Intel Graphics now has the best rendering quality in this particular game. We’re waiting for a driver fix to come relatively soon, so as always, keep your drivers updated!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./acfp16.png" title=" Astral Chain on integrated GPUs, reaching 30 FPS (docked mode)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/acfp16_hu5fc8fe50fb0ee3397e450c3b6cb29323_1322225_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Astral Chain on integrated GPUs, reaching 30 FPS (docked mode)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Astral Chain on integrated GPUs, reaching 30 FPS (docked mode)</p> </div> </div> <p>Finally, regarding Nvidia. If the shader cache is stored in Nvidia’s own provided directory, a 200MB total folder size limit is imposed. BSoD found out that such a limit is easy to surpass if other shader intensive programs are in use, like Adobe’s software suite. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> bypassed this problem <a href="https://github.com/yuzu-emu/yuzu/pull/5778">by moving the cache to yuzu’s own directory,</a> instead of using the default directory the driver provides.</p> <p>With this change, we recommend building your cache with assembly shaders enabled, but once the cache is complete or close to completion, switch to regular GLSL (disable assembly shaders). That way (after a long period of shader compilation at boot), stuttering will be completely avoided. Thanks to <a href="https://github.com/Exzap">Exzap</a> from <a href="https://cemu.info/">Cemu</a> for the help!</p> <p>Our resident shark, <a href="https://github.com/ogniK5377">ogniK,</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5810">implemented the missing services to have <code>Stereo Vision</code>,</a> the Nintendo Switch’s implementation of Virtual Reality using a <code>Nintendo Labo</code> “headset”. Games like <code>The Legend of Zelda: Breath of the Wild</code>, <code>Super Mario Odyssey</code>, <code>Super Smash Bros. Ultimate</code>, and <code>Captain Toad: Treasure Tracker</code> can now render for both eyes.</p> <p>While this doesn’t offer full VR support for PC compatible headsets yet, it allows users to make their own cardboard headsets à la Google, so long as they are handicraft-inclined. Pro tip, stream to a phone or tablet.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vr.png" title=" You will need a lot of cardboard if you want to use this on big displays (The Legend of Zelda: Breath of the Wild)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/vr_hufd87cb5eb5d7828cc219b6b4ecc3801e_2145359_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" You will need a lot of cardboard if you want to use this on big displays (The Legend of Zelda: Breath of the Wild)"></a> <p class="has-text-centered is-italic has-text-grey-light"> You will need a lot of cardboard if you want to use this on big displays (The Legend of Zelda: Breath of the Wild)</p> </div> </div> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/5786">fixing the constant buffer’s size calculation</a>, <code>Undertale</code> can now be run in OpenGL with Assembly Shaders disabled, allowing the game to run on Intel and AMD GPUs. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> will no longer have a <a href="https://www.youtube.com/watch?v=wDgQdr8ZkTw">bad time.</a></p> <p>The Buffer Cache Rewrite helped expose new issues in games, one example is geometry explosions in <code>Zombie Panic in Wonderland DX</code>. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed this by <a href="https://github.com/yuzu-emu/yuzu/pull/5785">flushing the destination buffer on CopyBlock.</a></p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./zpiwbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/zpiwbug_hubc7462f480d3e046b2be3878fa188914_3505955_800x0_resize_q90_bgffffff_box_3.jpg" alt="More work is needed to make this game look right (Zombie Panic in Wonderland DX)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./zpiwfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/zpiwfix_hub84a551538b018ebda566050e9b7cf20_3604113_800x0_resize_q90_bgffffff_box_3.jpg" alt="More work is needed to make this game look right (Zombie Panic in Wonderland DX)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">More work is needed to make this game look right (Zombie Panic in Wonderland DX)</p> <p>One of the important additions of the Texture Cache Rewrite is the support for <code>Format Views</code>, a feature games request and use natively. Unfortunately, AMD and Intel Windows drivers have a broken implementation, and format views had to be disabled to fix rendering problems.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smobug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/smobug_hufe124ec0a5ecb473335c015deb3b2636_725202_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mushroom Dark World? (Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smofix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/smofix_hu14f967056be4d978c9aff8bc1466d76a_1174298_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mushroom Dark World? (Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mushroom Dark World? (Super Mario Odyssey)</p> <p>We reported this problem a long time ago to both vendors, but it seems like OpenGL is not a priority on Windows. The Linux mesa team, on the other hand, <a href="https://gitlab.freedesktop.org/mesa/mesa/-/issues/4034">has <em>fantastic</em> response times</a> to bug reports of any API.</p> <p>For the Linux side, recent changes made the Vulkan Intel driver <code>anv</code> incompatible. By <a href="https://github.com/yuzu-emu/yuzu/pull/5341">removing a not critical requirement</a> (for now), and <a href="https://github.com/yuzu-emu/yuzu/pull/5349">fixing initialization,</a> <a href="https://github.com/ReinUsesLisp">Rodrigo</a> restored functionality.</p> <p>Due to its constant use of ASTC textures of considerable size (way bigger than the display resolution of the Nintendo Switch), <code>Astral Chain</code> is a prime example for testing the stability of yuzu’s software ASTC decoder. Game crashes were common due to reading or writing out of bounds, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixes this by <a href="https://github.com/yuzu-emu/yuzu/pull/5348">improving the robustness of the decoder.</a></p> <h2 id="the-youkai-the-rabbit-and-friendshttpswwwyoutubecomwatchv195xntreomc"><a href="https://www.youtube.com/watch?v=195XntreoMc">The Youkai, the rabbit, and friends</a></h2> <p><a href="https://github.com/MerryMage">MerryMage</a> has recently made some changes to <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a> that improved the performance of some games.</p> <p>We start off with <a href="https://github.com/yuzu-emu/yuzu/pull/5278">a PR that introduces a setting to remove some NaN checks from JITed code.</a> This inherently results in a decrease of accuracy on the representation of these and other special values, which is why this setting is <code>unsafe</code>. However, this also boosts the performance of games that make heavy use of NaN values, such as <code>Luigi's Mansion 3</code> (especially in the <code>basement 2</code> and <code>floor 12</code> areas, where previously performance would decrease greatly). This setting can be found in <code>Emulation &gt; Configure &gt; CPU &gt; Unsafe</code> as a toggle option, <code>Inaccurate NaN handling</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./LM3_1.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Luigi&#39;s Mansion 3, the new and the old. The general performance of the game improved drastically thanks to this PR.</p> </div> </div> <p>On any digital system, all numbers are represented in a binary base in order to be stored and perform operations with them. Naturally, there is a limit to the amount of numbers and the precision with which they can be represented, not to mention that a number can be expressed in many ways by just declaring it as a different type (e.g. integer, <a href="https://en.wikipedia.org/wiki/Floating-point_arithmetic">floating-point</a> number, etc.). Likewise, there are also many mathematical elements that aren&rsquo;t numbers per se, but special cases that result from mathematical operations. Think, for example, about the square root of a negative number: although the result of this operation is a valid <a href="https://en.wikipedia.org/wiki/Complex_number">complex number</a>, it&rsquo;s not a defined type (i.e. a number that the computer understands), therefore, it becomes <em>something else</em>. Or think about dividing any number by zero: this mathematical operation is undefined, and thus it yields a similar result.</p> <p>These types of indeterminations are defined as a special floating-point value called <a href="https://en.wikipedia.org/wiki/NaN"><code>NaN</code></a> - which stands for &ldquo;Not a Number&rdquo;. The architecture of the CPU of the Nintendo Switch (<code>ARM</code>) handles these NaN values differently from the architecture used by any computer CPU (<code>AMD64</code>). For example, while a NaN is always produced as a positive value in <code>ARM</code>, it is always produced as a negative value in <code>AMD64</code>. These NaN values might also be <code>quiet</code> or <code>signaling</code> - a characteristic that determines whether the CPU detects a NaN value at the end of an operation, or in an intermediate step (which can be halted or not, depending on the program). Dynarmic is in charge of translating the code of a game from instructions understood by the <code>ARM</code> architecture into instructions understood by the <code>AMD64</code> architecture. This includes ensuring these NaN values are represented properly. By toggling this optimization, however, many of these checks are now skipped by dynarmic in favor of performance. The reason is quite simple: most software, including games, ignore the sign and payload of these values, so it&rsquo;s safe to ignore them.</p> <p>MerryMage also submitted <a href="https://github.com/yuzu-emu/yuzu/pull/5831">a PR to prevent flushing the cache when an ISB instruction is executed</a>, fixing a wide range of games that ran at 1-2fps, such as <code>Cobra Kai</code>, <code>Megadimension Neptunia VII</code>, <code>Super Robot Wars series</code>, <code>Windbound</code>, and many others.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mn7.png" title=" Megadimension Neptunia VII"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/mn7_hu279ff3f2950de7ed72f9bf6fa7fd970a_3603906_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Megadimension Neptunia VII"></a> <p class="has-text-centered is-italic has-text-grey-light"> Megadimension Neptunia VII</p> </div> </div> <p>In order to process instructions faster, modern CPUs read program code from memory and store it in a cache, because access times are much faster that way. But processing these instructions isn&rsquo;t an instantaneous task. First, an instruction is fetched from the cache, decoded, executed, and the result is written back to a register or memory. To make this process more efficient, the CPU has a dedicated circuit for every one of these steps, and they execute these tasks for different instructions at the same time. This parallelization process is known as <a href="https://en.wikipedia.org/wiki/Instruction_pipelining">Instruction Pipelining</a>.</p> <p>The <code>ARM</code> architecture has a variety of special instructions (called <code>Memory Barrier Instructions</code>) that give the CPU better control over how instructions are written in and from program memory. One of these is <code>ISB</code>, which stands for &ldquo;Instruction Synchronization Barrier&rdquo;, and it&rsquo;s used to flush the CPU pipeline and cache, so that all instructions following the <code>ISB</code> instruction are refeteched from memory. Normally, this is useful when running self-modifying programs, since there is new code being written into executable memory (where the program is stored), and flushing the queued instructions ensures that no old code is run. So, naturally, when Dynarmic executed an ISB instruction, the whole cache was being flushed on the assumption that it was outdated. This resulted in yuzu constantly flushing out and recompiling the cache, which translated as severe slowdowns and performance drops for certain games.</p> <p>Now, here&rsquo;s the catch. The Nintendo Switch is a platform that, with some exceptions, doesn&rsquo;t allow for executable code to be rewritten. So, there will never be a case where yuzu will need to flush the cache this way, because games can&rsquo;t overwrite code in memory. This PR changed the behaviour of dynarmic, so that whenever there&rsquo;s an <code>ISB</code> instruction, it executes a <code>NOP</code> (no operation) instead - a special instruction that does nothing. This way, performance is not affected anymore, as yuzu doesn’t need to rebuild the cache since it safely ignores these <code>ISB</code> instructions.</p> <p>On a different note, <a href="https://github.com/bunnei">bunnei</a> has been continuing with his work on the kernel. The first change introduced last month was <a href="https://github.com/yuzu-emu/yuzu/pull/5779">a PR to rewrite threads to be more accurate</a>. While there are not many visible benefits for the user due to the low-level nature of the change, it helped to fix a lot of smaller inaccuracies, including the softlocks in <code>Animal Crossing: New Horizons</code> when transitioning between scenes.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./acnh.png" title=" We don&#39;t judge you, Isabelle (Animal Crossing: New Horizons)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jan-2021/acnh_huc72e68063250bc36258e05b6d45f87c9_1990875_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" We don&#39;t judge you, Isabelle (Animal Crossing: New Horizons)"></a> <p class="has-text-centered is-italic has-text-grey-light"> We don&#39;t judge you, Isabelle (Animal Crossing: New Horizons)</p> </div> </div> <p>Originally, yuzu started as a fork of <a href="https://github.com/citra-emu/citra">Citra</a>, the 3DS emulator. Naturally, there is a remnant of code that was used on Citra and later modified to work for the Nintendo Switch. While it was fully functional and did the job, it was far from being accurate. <code>KThread</code> is yuzu&rsquo;s implementation of <a href="https://en.wikipedia.org/wiki/Thread_(computing)">computing threads</a>, and this change aims to make it match as closely as possible to the implementation of threads of the real Nintendo Switch kernel.</p> <p>The second change introduced last month is <a href="https://github.com/yuzu-emu/yuzu/pull/5862">Refactoring of KEvent/KReadableEvent/KWritableEvent</a>. A <code>Kernel Event</code> is a kernel primitive that is used to &ldquo;signal events&rdquo;, generally across processes. This is one of the simplest mechanisms used to communicate different threads: one thread signals an event, and then another thread waits for it. The <code>KReadableEvent</code> and <code>KWritableEvent</code> attributes are just an abstraction used to further enhance the synchronization across processes. These three objects are thus used to represent a single &ldquo;signallable event&rdquo;.</p> <p>These mechanisms would be used, for example, when a game needs to play a sound. The audio service will produce a <code>KEvent</code> that will &ldquo;signal&rdquo; when it&rsquo;s ready for more audio data from a game, and this will communicate with the audio thread so that data can be submitted and requested as needed by using these <code>KReadableEvent</code> and <code>KWritableEvent</code> attributes.</p> <p>As always, the major benefit of these rewrites is accuracy. These changes will also make it easier in the long term to add the code of future updates that Nintendo might do to their kernel, since the behaviour of this implementation will be closer to the hardware and the existing code won’t need many changes to accommodate for it.</p> <p>There’s still room for more additions and improvements, so stay tuned for more work on this area.</p> <p>After a period of inactivity, <a href="https://github.com/FernandoS27">FernandoS27</a> is back with a PR to <a href="https://github.com/yuzu-emu/yuzu/pull/5275">optimize clock calculations</a> by introducing a new method to compute time values, such as nanoseconds, microseconds, milliseconds, and also guest clock and cpu cycles, from the native clock of the CPU. This is a relatively small change, but since these calculations are performed often, all optimizations are helpful to reduce the time spent on these transformations.</p> <h2 id="input-changes">Input changes</h2> <p>What can be better than QoL changes that you didn’t know you wanted until you saw them? <a href="https://github.com/german77">german77</a> gives us just that by <a href="https://github.com/yuzu-emu/yuzu/pull/5339">animating the controller input settings image</a> on player actions. You can see the results yourself:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./pro.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./joy.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">I like to move it, move it!</p> <p>The animation will highlight the buttons that are currently being pressed. There’s also a second animation for the analog sticks to make the calibration of deadzones and range more intuitive. Your controller will behave in-game as shown by the animation in the settings, so if you think there’s any problem with your input, it’s a good idea to check if it’s working as intended here.</p> <p>Input lag, the worst enemy of competitive games… And <a href="https://github.com/german77">german77</a> comes to the rescue, by <a href="https://github.com/yuzu-emu/yuzu/pull/5861">preventing overscheduling events.</a></p> <p><code>Pokémon Let’s Go Eevee/Pikachu</code> may disconnect the emulated controller, or fail to recognise the connection. By <a href="https://github.com/yuzu-emu/yuzu/pull/5805">applying a delay to this process</a>, <a href="https://github.com/german77">german77</a> improves the stability of input emulation for this series of games. Handheld or single Joy-Con input modes are still needed to play this game, be sure to check your input settings in <code>Emulation &gt; Configure… &gt; Controls</code>. Swap the default Pro Controller to, for example, Handheld.</p> <p>Users discovered that some games may continue to send vibration signals, this is due to the game never sending a 0 amplitude signal. <a href="https://github.com/Morph1984">Morph</a> fixes those erroneous vibrations by <a href="https://github.com/yuzu-emu/yuzu/pull/5800">adding a 1 second maximum time for any vibration.</a></p> <p>In a double combo, <a href="https://github.com/Morph1984">Morph</a> and <a href="https://github.com/german77">german77</a> hit us with fixes regarding Handheld mode. <a href="https://github.com/yuzu-emu/yuzu/pull/5743">A wrong behaviour regarding player 1 was addressed</a>, which used to result in input changes not saving, especially in Handheld mode. <a href="https://github.com/yuzu-emu/yuzu/pull/5757">A check was added to ensure Handheld mode is connected</a> only in the correct <code>npad_index</code> value.</p> <p>Holding a button would sometimes stutter, resulting in unstable behaviour. <a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5366">adds a new method to check the duration of the press or hold of the buttons</a>, resulting in stable behaviour.</p> <h2 id="future-projects">Future projects</h2> <p>The merge of the Buffer Cache Rewrite will open the way to some improvements and fixes on the roadmap, epicboy will have some interesting things to show thanks to this. Morph is up to something. german77 is up to something. ogniK is up to something. bunnei continues to suffer with the Kernel rewrites. Rodrigo is making the first tests on Project Hades, while also planning a couple of nice Vulkan and video memory management improvements.</p> <p>That’s all folks! Thank you so much for staying with us. See you in the February report!</p> <p>And remember kids, winners update their GPU drivers to the latest version!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - Buffer Cache Rewrite https://yuzu-mirror.github.io/entry/yuzu-bcr/ Sat, 16 Jan 2021 21:00:00 -0300 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-bcr/ <p>Hey there, yuz-ers! The follow-up to our <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">previous big code rewrite</a> is finally here: the Buffer Cache Rewrite! This massive undertaking not only improves performance significantly, but also simplifies the code for our developers. Now let&rsquo;s get this article started!</p> <p>Hey there, yuz-ers! The follow-up to our <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">previous big code rewrite</a> is finally here: the Buffer Cache Rewrite! This massive undertaking not only improves performance significantly, but also simplifies the code for our developers. Now let&rsquo;s get this article started!</p> <h2 id="so-what-does-a-buffer-cache-do">So, what does a Buffer Cache do?</h2> <p>As the name implies, a Buffer Cache — well — caches (stores) buffers. That might not have made much sense, but that&rsquo;s what it does.</p> <p>In graphics programming, for the GPU to render anything it needs data like position, color, etc. Usually, this data is supplied by the application. But when we have large applications dealing with large volumes of data, it becomes increasingly difficult to constantly supply the GPU with data and have it render. Hence, buffer objects were introduced.</p> <p>Buffer objects are memory objects that store the render data in the GPU memory — thereby increasing reusability significantly. There are various types of bindings, commonly referred to as buffer types, like index buffers, vertex buffers, and uniform buffers (among others). This improves the rendering performance because the data is now readily available for the GPU to use.</p> <h3 id="yuzus-buffer-cache">yuzu&rsquo;s Buffer Cache</h3> <p>Coming back to yuzu&rsquo;s case, yuzu initially inherited a stream buffer — originally implemented for <a href="https://citra-emu.org">Citra</a> by <a href="https://github.com/degasus">degasus</a>. A stream buffer works in a modify/use cycle, meaning you frequently update the buffer object and you bind that region. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> and <a href="https://github.com/FernandoS27">Blinkhawk</a> later implemented our existing buffer cache to work alongside the stream buffer.</p> <p>There was nothing inherently wrong with it; stream buffers are in fact one of the fastest ways to upload data to the GPU. But when <a href="https://github.com/ReinUsesLisp">Rodrigo</a> profiled yuzu, the cache management and upload copies were something that kept popping up as slow.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Profiling</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> In software engineering, profiling (&ldquo;program profiling&rdquo;, &ldquo;software profiling&rdquo;) is a form of dynamic program analysis that measures, for example, the space (memory) or time complexity of a program, the usage of particular instructions, or the frequency and duration of function calls. Most commonly, profiling information serves to aid program optimization. </div> </article> <p>The problem lay in the fact that games aren&rsquo;t exactly streaming data all the time. So using immediate uploads (on OpenGL) and faster caching yielded much better performance than having a stream buffer and caching large resources, at least for Nvidia. Upon further testing, we found that this turned out to be false for non-Nvidia drivers on OpenGL (AMD, Intel, and Mesa) and hence had to add a stream buffer for small uploads in these drivers.</p> <h2 id="whats-changed-now">What&rsquo;s changed now?</h2> <p>The technical design goals for the Buffer Cache Rewrite were the same as our Texture Cache Rewrite.</p> <ul> <li>Cleaner code: No more virtual function calls or shared pointers, meaning easier maintenance in the future.</li> <li>Improved efficiency and improved performance.</li> </ul> <p>Resolving which buffer existed in which memory region was a very expensive operation in our old buffer cache implementation. This is why the stream buffer existed — to make it faster.</p> <p>The new Buffer Cache has vastly improved tracking for the various buffers it caches. In the new implementation, when buffers are created in the memory, they are forcibly aligned to 4K <a href="https://en.wikipedia.org/wiki/Page_(computer_memory)">pages</a> (4096 bytes - starting at zero). And to efficiently know what buffer exists on what address, the cache uses a flat array 32 MiB wide to translate from the current CPU page where the buffer exists to what buffer resides in it. <code>e.g., if the address is 4096 or 7000, that is page 1 &amp; if it is 8192, that is page 2.</code> Thus, the new Buffer Cache can track what pages of a buffer have been modified on a page basis instead of being a binary state.</p> <p>Imagine if a buffer has a size of 524288 bytes and a game modifies only 1 byte of the buffer. Since buffers are now aligned to 4096 bytes as mentioned earlier, only those 4096 bytes are uploaded to the GPU. The same thing happens when the GPU tries to update the cache with data modified by the CPU.</p> <p>This tracking is done by making use of bit arrays in the buffers. Each value represents the state of the page - 1 being modified, 0 being clear. Keeping things in a bit array allows us to use efficient bit operations like <code>std::countr_zero</code> and <code>std::countr_one</code> (C++20). This results in fewer instructions yielding the same results (much faster).</p> <h2 id="all-right-lets-talk-performance-gains">All right, let&rsquo;s talk performance gains!</h2> <p>The main focus of this work is to improve performance, but some graphical improvements also resulted from this rewrite.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./otbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-bcr/otbug_hu0ec6382faaaf32c00049fcfadfdd40c4_2193721_800x0_resize_q90_bgffffff_box_3.jpg" alt="Vertex explosions are no longer a problem in OCTOPATH TRAVELER"></a> </div> <div class="column is-bottom-paddingless"> <a href="./otfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-bcr/otfix_hud63d13bc8babcd429f7907e35e65356a_3183308_800x0_resize_q90_bgffffff_box_3.jpg" alt="Vertex explosions are no longer a problem in OCTOPATH TRAVELER"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Vertex explosions are no longer a problem in OCTOPATH TRAVELER</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./acnhbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-bcr/acnhbug_hu0cc6930dfef1b11bf677342bf378c70d_2387401_800x0_resize_q90_bgffffff_box_3.jpg" alt="Font rendering is now working for all GPU vendors in Animal Crossing: New Horizons"></a> </div> <div class="column is-bottom-paddingless"> <a href="./acnhfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-bcr/acnhfix_hud9375e742820c8045efe0c112ebdeea7_1986227_800x0_resize_q90_bgffffff_box_3.jpg" alt="Font rendering is now working for all GPU vendors in Animal Crossing: New Horizons"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Font rendering is now working for all GPU vendors in Animal Crossing: New Horizons</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xbdebug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./xbdefix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Item drops stop flickering in Xenoblade Chronicles Definitive Edition</p> <p>With that out of the way, let&rsquo;s talk about performance. Of course, metrics will vary greatly depending on the hardware and API in use. Here are some examples measured after a couple of runs in the most demanding or common areas of the games listed:</p> <p>Nvidia, in this example represented by an RTX3070, shows up to 84% improved performance in OpenGL. <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./nvbench.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-bcr/nvbench_huad6f813e0bcdc09d1b005b82dabdc18c_134004_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> </p> <p>AMD on the other hand, represented by a small RX550, shows an up to 55% improvement in Vulkan. <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./amdbench.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-bcr/amdbench_huad6f813e0bcdc09d1b005b82dabdc18c_133299_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> </p> <p>Regarding Intel, an unsurprising problem arises. All currently released products bottleneck due to immature drivers and simply lacking the raw power for Switch emulation. This results in little to no performance improvements with this rewrite. Hopefully this can be addressed with future improvements to both yuzu and Intel&rsquo;s future drivers and hardware releases.</p> <p>As a special mention, AMD Vega based integrated GPUs show an up to 223% increase in <code>Paper Mario the Origami King</code>, reaching the same level of performance as dedicated cards of a much higher calibre.</p> <h2 id="fin">Fin</h2> <p>With that, we conclude our coverage of the new Buffer Cache Rewrite. As always, we would like to remind users that the features released in <a href="https://yuzu-mirror.github.io/help/early-access/">Early Access</a> are still being worked on. If you come across any bugs, issues, performance loss, crashes, or regressions with this new feature, please reach out to us on our <a href="https://discord.com/invite/u77vRWY">Discord server</a> and share your findings.</p> <p>See you next time, <br> - yuzu development team!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report December 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/ Sun, 10 Jan 2021 12:00:00 -0300 Honghoa https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/ <p>Happy New Year, dear yuz-ers! 2020 is finally behind us, so what better way to start 2021 than with a progress report? Follow us for a summary of the last changes yuzu saw in 2020, and a small preview of what will come. This time we offer you kernel changes, new input and user interface additions, and the first changes applied to get the Buffer Cache Rewrite finished.</p> <p>Happy New Year, dear yuz-ers! 2020 is finally behind us, so what better way to start 2021 than with a progress report? Follow us for a summary of the last changes yuzu saw in 2020, and a small preview of what will come. This time we offer you kernel changes, new input and user interface additions, and the first changes applied to get the Buffer Cache Rewrite finished.</p> <h2 id="general-improvements-and-bug-fixes">General improvements and bug fixes</h2> <p><a href="https://github.com/ameerj">epicboy</a> has been busy squashing bugs, in this case <a href="https://github.com/yuzu-emu/yuzu/pull/5201">killing two with one PR.</a> In some instances, we were trying to read data from an nvflinger buffer before it even existed. By adding a check addressing this, <code>Yoshi’s Crafted World</code> now boots, albeit with several graphical glitches. This PR also fixes how buffers are accessed, so several games now boot for the first time. Some examples include: <code>Katana ZERO</code>, <code>DELTARUNE Chapter 1</code>, <code>Dragon Ball FighterZ</code> and <code>Wonder Boy: The Dragon’s Trap</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./katanazero.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/katanazero_hud52150ff875e7c6216ff5a4dc317b0c9_975697_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./wonderboy.png" title=" Now booting!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/wonderboy_hufc8c073bbbd3000c4a96650a8b0e4f4c_3914969_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Now booting!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Now booting!</p> </div> </div> <p>A PSA for our Intel graphics users. With the release of the Windows driver version <code>27.20.100.9126</code>, Intel added support for not only the much needed <code>VK_EXT_robustness2</code>, but also <code>VK_EXT_custom_border_color</code>, improving performance and stability with the former extension and solving rendering issues in <code>The Legend of Zelda: Breath of the Wild</code> with the latter. Nothing better than free improvements for our integrated graphics crew running Vulkan. Latest is best!</p> <p>Linux distributions compatibility, and the dependency issues that come with it, have been a long standing problem for our tuxedo-wearing users&hellip; Until now.</p> <p>Thanks to <a href="https://github.com/lat9nq">toastUnlimited,</a> we now provide <a href="https://appimage.org/">AppImage builds,</a> simplifying the installation process considerably. AppImages eliminate the dreaded dependencies issues, and bringing back support for Ubuntu 18.04, Debian Buster, CentOS 8, and many older distributions.</p> <p>In the future, Early Access will finally be able to be distributed pre-compiled like this, the promise has been made. Thanks to the reduced source code compilation work hours, the CPU Union approves of this change.</p> <p>During the time the Texture Cache Rewrite spent in Early Access, several regressions have been fixed. One of the notorious ones is related to the camera rune in <code>The Legend of Zelda: Breath of the Wild</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./camera.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/camera_hue4298eaa992741d378a41b83a500a10f_5196_344x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>As you can clearly see with <a href="https://github.com/ReinUsesLisp">Rodrigo’s</a>&hellip; art, the game informs two different size values for the same texture, named <code>pitch</code> and <code>width</code>, so yuzu didn’t transfer needed information between them as it considered them different textures. By changing this behaviour, entities like animals, flowers, enemies, etc. are properly registered by the camera now.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botwbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/botwbug_huc050f897e4929f5dff1db36b4e9b0ad9_2896577_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tony, get the boulder (The Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botwfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/botwfix_hu25273836066bb8a267b004559c6e3fc0_2895776_800x0_resize_q90_bgffffff_box_3.jpg" alt="Tony, get the boulder (The Legend of Zelda: Breath of the Wild)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Tony, get the boulder (The Legend of Zelda: Breath of the Wild)</p> <p>There were some crashes when exiting yuzu that was related to the telemetry process. <a href="https://github.com/FearlessTobi">Tobi</a> ported a fix from <a href="https://github.com/citra-emu/citra">Citra</a> that <a href="https://github.com/yuzu-emu/yuzu/pull/5127">changes the type of <code>AddField</code> to a string,</a> squashing one bug down.</p> <p>A commonly reported issue was that configuration changes are lost if yuzu crashes. <a href="https://github.com/lat9nq">toastUnlimited</a> changed this behaviour to simply <a href="https://github.com/yuzu-emu/yuzu/pull/5217">save the current settings before booting a game.</a> This change saves several headaches.</p> <p><a href="https://github.com/Morph1984">Morph</a> implemented the <a href="https://github.com/yuzu-emu/yuzu/pull/5200">new OSS fonts</a> that <a href="https://github.com/Its-Rei">Rei</a> put together. With this, users no longer require to dump the Switch firmware to get proper button fonts. The firmware dumping process is still needed for games that have Mii related content.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smm2fontbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/smm2fontbug_hu597fde90544b471be1d7ba63746ea27c_207784_800x0_resize_q90_bgffffff_box_3.jpg" alt="It’s far cleaner to have ZL and ZR as a trigger button, than just the letters alone, don’t you agree? (Super Mario Maker 2)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smm2fontfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/smm2fontfix_hu176d17ff27ff10d81b162616ebe0acf3_134193_800x0_resize_q90_bgffffff_box_3.jpg" alt="It’s far cleaner to have ZL and ZR as a trigger button, than just the letters alone, don’t you agree? (Super Mario Maker 2)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It’s far cleaner to have ZL and ZR as a trigger button, than just the letters alone, don’t you agree? (Super Mario Maker 2)</p> <p>A separate PR <a href="https://github.com/yuzu-emu/yuzu/pull/5205">added +/-</a> to the fonts.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smashfontbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/smashfontbug_hu3b89098057e67b89ef9d2b26b5841303_129288_800x0_resize_q90_bgffffff_box_3.jpg" alt="THE anime swordsman (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smashfontfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/smashfontfix_hu3b89098057e67b89ef9d2b26b5841303_129914_800x0_resize_q90_bgffffff_box_3.jpg" alt="THE anime swordsman (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">THE anime swordsman (Super Smash Bros. Ultimate)</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fonts.png" title=" Some insight in the process behind this."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/fonts_hud1468dc3746d218c9bc5d427914edd1a_33804_800x0_resize_q90_bgffffff_box_3.jpg" alt=" Some insight in the process behind this."></a> <p class="has-text-centered is-italic has-text-grey-light"> Some insight in the process behind this.</p> </div> </div> <p>Some games report the wrong device handle when sending vibration signals, like <code>NEKOPARA Vol. 3</code> (don’t Google this series). <a href="https://github.com/Morph1984">Morph</a> fixed this by <a href="https://github.com/yuzu-emu/yuzu/pull/5190">validating the device handles before use.</a> Man of culture.</p> <h2 id="kernel-rewrites">Kernel Rewrites</h2> <p>yuzu&rsquo;s kernel received important changes this month, focused on refactoring the code for thread management and synchronization. <a href="https://github.com/bunnei">bunnei</a> started working on these changes two months ago, as covered on the previous progress report. Although a bit technical, these modifications are essential for accurate Nintendo Switch emulation. They also improve yuzu&rsquo;s code quality and make it easier to work with. There are still many changes planned for the kernel, so stay tuned for even more improvements in the very near future.</p> <p>First, there is an improvement to yuzu <a href="https://github.com/yuzu-emu/yuzu/pull/5206">ensuring safe memory access across threads</a>. A <code>Race Condition</code> happens when multiple threads are running simultaneously, and one thread modifies data while another thread accesses it. Race conditions can cause faulty or unexpected behaviour: a thread can retrieve partial data or even overwrite changes made by another. yuzu emulates the Nintendo Switch&rsquo;s internal memory using a type of abstract data structure called a <code>Page Table</code>, which works as a virtual layer between the physical and the emulated memory. It maps these addresses in a &ldquo;contiguous table&rdquo; that lets the programmer access memory easily without checking where actual memory stores everything. Most memory management operations were written before multicore CPU and asynchronous GPU were implemented. There was only a single thread back then, so there were no guards for thread-safe memory access. bunnei introduced a lock in this PR to alleviate a race condition where the data in the memory pages was being accessed while the GPU was operating on them.</p> <p>bunnei has also been rewriting the <a href="https://github.com/yuzu-emu/yuzu/pull/5131">kernel scheduler</a>. Modern operating systems run many processes simultaneously, however, a single CPU core can only process one of them at any given time. The scheduler is an essential piece of the kernel, as it is in charge of swapping CPU access to the different processes and choosing in which order this happens. This will make yuzu’s kernel match <code>Horizon OS</code> more closely.</p> <p>As a follow-up to this rewrite, bunnei reworked the way service calls were implemented in yuzu, by allocating their calls in their own <a href="https://github.com/yuzu-emu/yuzu/pull/5208">individual service threads</a>. Many services are running in the background on the Nintendo Switch. They are in charge of initializing and managing specific tasks, such as audio, graphics, user input, networking, etc. yuzu emulates these services through HLE - High Level Emulation. This means that, instead of dumping the binary code of these routines from the Nintendo Switch and translating their instructions so that a PC can run them, the programmer reimplements the functionality of these services in C++. Thus, HLE works like a &ldquo;black box&rdquo;: these services are called whenever there&rsquo;s a request from the games, and they send (or ask) for the corresponding data, even though internally they may be different to how the service was originally implemented in hardware. But, as long as the information requested or sent through the service is valid and processed appropriately, the system is being emulated correctly.</p> <p>These service processes are independent of each other, so games call them asynchronously. But before this PR, all of these services were being processed in the <code>CoreTiming</code> thread &ndash; a thread that is used to process events at certain times in the future (for example, when a frame completes rendering). This meant that games would call these processes, but they would not be processed until the <code>CoreTiming</code> thread was run, which resulted in these requests piling up in a queue and possibly introducing lag if the queue wasn&rsquo;t emptied fast enough.</p> <p>Thanks to the changes in this PR, each of these processes was moved to their own thread and is processed more quickly. An immediate benefit of this change is that load times improve significantly, and input lag is also reduced. But another important perk is that this implementation is more accurate, as it resembles the behaviour of services in the Nintendo Switch. GPU emulation also runs on its own thread now, which is synchronized on GPU pushes and flushes. This means that <code>async GPU</code> can be decoupled from multicore and these settings can now be toggled independently from each other.</p> <p>Finally, as a continuation to the previous two PRs, comes the <a href="https://github.com/yuzu-emu/yuzu/pull/5266">rewrite of the kernel synchronization primitives</a> – namely, <code>Synchronization Objects</code>, <code>Condition Variables</code> and <code>Address Arbiters</code>. An in-depth explanation of how these mechanisms work goes beyond the scope of this report, but essentially they are tools used by threads in different processes to communicate with each other and be synchronized properly. The major benefit of these changes is that a lot of code that was being carried over from Citra (and that required major workarounds to make it function properly with multicore) has been changed in favour of mechanisms more appropriate for how yuzu works, besides making it closer to how the <code>Horizon OS</code> of the Nintendo Switch works.</p> <p>Going in hand with these synchronization changes, <a href="https://github.com/ameerj">epicboy</a> introduced a PR to <a href="https://github.com/yuzu-emu/yuzu/pull/5237">incorporate a syncpoint manager for nvdec</a>. This utilizes the tools mentioned previously to implement a more accurate GPU-CPU synchronization mechanism. It is crucial to avoid race conditions when async operations are being performed by the emulator when decoding a video.</p> <h2 id="ui-changes">UI changes</h2> <p>Finally, a very needed User Interface change, <a href="https://github.com/yuzu-emu/yuzu/pull/5239">language support</a> is here. Thanks to work done by <a href="https://github.com/FearlessTobi">Tobi</a> and many, <em>many</em> members of the community from around the globe, we can now offer support for 11 different languages, plus regional variations. ¡Muchas gracias!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./language.png" title=" You can find this in Emulation &gt; Configure &gt; General &gt; UI &gt; Interface language"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/language_hu88a62c38c4596df29ba39fbd8e1795be_14285_1020x0_resize_q90_bgffffff_box_3.jpg" alt=" You can find this in Emulation &gt; Configure &gt; General &gt; UI &gt; Interface language"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can find this in Emulation &gt; Configure &gt; General &gt; UI &gt; Interface language</p> </div> </div> <p>Anyone is welcome to help <a href="https://www.transifex.com/yuzu-emulator/yuzu">expand the available language list.</a></p> <p>For our command-line or shortcut lovers, <a href="https://github.com/Morph1984">Morph</a> adds <a href="https://github.com/yuzu-emu/yuzu/pull/5229">command-line arguments.</a> Current options are:</p> <ul> <li><code>yuzu.exe &quot;path_to_game&quot;</code> - Launches a game at <code>path_to_game</code>.</li> <li><code>yuzu.exe -f</code> - Launches the next game in fullscreen.</li> <li><code>yuzu.exe -g &quot;path_to_game&quot;</code> - Launches a game at <code>path_to_game</code>.</li> <li><code>yuzu.exe -f -g &quot;path_to_game&quot;</code> - Launches a game at <code>path_to_game</code> in fullscreen.</li> </ul> <p>Feel free to create desktop shortcuts of all of your games!</p> <p>Thinking of our fast typers, <a href="https://github.com/lat9nq">toastUnlimited</a> added several <a href="https://github.com/yuzu-emu/yuzu/pull/5223">menubar access hot-keys</a>. Now, for example, a user can press <code>Alt + F, R, ENTER</code> to load the most recently played game. Look Ma! No mouse!</p> <p><a href="https://github.com/german77">german77</a> added the option to <a href="https://github.com/yuzu-emu/yuzu/pull/5178">resize yuzu’s window to 1920x1080</a>, on top of the traditional 1280x720. This ensures a perfect 1:1 pixel ratio with native 1080p games while playing windowed, for those with high-resolution displays.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./resize.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/resize_hu42b5350564af2a33b7845b3ae07584b2_27329_366x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <h2 id="input-changes">Input changes</h2> <p><a href="https://github.com/yuzu-emu/yuzu/pull/5178">german77</a> is back in action with a couple of input improvements.</p> <p>Adding a way to invert an analog stick axis was a problem we did not expect to have on Xbox and PlayStation controllers, but some alternative brands don’t seem to follow the specifications very closely. Now if you right-click on an axis, you get the <a href="https://github.com/yuzu-emu/yuzu/pull/5233">option to invert it.</a></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./invert.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/invert_hu04af81816416b375bba066bab4f9684b_6986_269x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>This is also a great way to invert a camera if a game doesn’t allow it in its own settings, for example in <code>Star Wars Jedi Knight II: Jedi Outcast</code>.</p> <p>Analog triggers were sometimes mapped inverted to what the user intended. As a way to avoid some bad moments to our users, now <a href="https://github.com/yuzu-emu/yuzu/pull/5265">the program takes two samples when mapping an analog trigger,</a> to better determine the direction of movement. This was <a href="https://github.com/citra-emu/citra/pull/5509">ported from Citra</a>, so thanks, guys!</p> <p>A few games like <code>Voez</code> and <code>The Room</code> require specific touch gestures, and to achieve that, <a href="https://github.com/yuzu-emu/yuzu/pull/5270">multitouch support was added.</a> With this, yuzu now offers support for up to 16 touch inputs with the keyboard, touch screen or via UDP services.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./room.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/room_hud87d3f44ab29b2ff5cfd71a6a7d18f8c_1453658_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <h2 id="preliminary-work-for-the-buffer-cache-rewrite">Preliminary work for the Buffer Cache Rewrite</h2> <p>While we sadly couldn’t give you a Christmas present in the form of the <code>Buffer Cache Rewrite</code> (or BCR for short), the preliminary work needed to have it ready has started. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> has his hands full with cleaning up the TCR recently merged into Mainline, the current internal work and testing on the BCR, and his first steps with <code>Project Hades</code>. <em>“Sleep is for the weak”</em> indeed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./rodrigo.png" title=" And you don&#39;t seem to understand... (Rodrigo sleeping)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-dec-2020/rodrigo_hu40eea79643b4062a0b7dbda2b684bdaf_527063_650x0_resize_q90_bgffffff_box_3.jpg" alt=" And you don&#39;t seem to understand... (Rodrigo sleeping)"></a> <p class="has-text-centered is-italic has-text-grey-light"> And you don&#39;t seem to understand... (Rodrigo sleeping)</p> </div> </div> <p>We will go in-depth once BCR is completed, but one of the required features is <a href="https://github.com/yuzu-emu/yuzu/pull/5225">having access to Vulkan at all times</a> to make use of <code>interop</code>, a driver feature (or as Rodrigo calls it, a monstrosity) that allows developers to cross-code between different graphics APIs on Nvidia and AMD products. This way, <a href="https://github.com/yuzu-emu/yuzu/pull/5230">Vulkan can be used from OpenGL if it offers a better solution to a problem.</a></p> <p>A rather interesting change needed is <a href="https://github.com/MerryMage/dynarmic/pull/566">related</a> to <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a>. By <a href="https://github.com/yuzu-emu/yuzu/pull/5249">masking data in three lower pointer bits</a> before reading them, Rodrigo can now store required information of the page tables without needing to use a lock, saving precious execution time and, at most, some 128MB of system memory.</p> <p>Lastly, <a href="https://github.com/yuzu-emu/yuzu/pull/5262">additional granularity in the CPU pages.</a> This PR allows informing if the CPU or the GPU modified a range of data in the CPU page. If the relevant range was modified by the CPU, it must be uploaded to the GPU. Processors supporting the <code>BMI1</code> instruction set will get a slim performance improvement, these include Intel Haswell (Gen. 4) or newer, and AMD Piledriver (2nd Gen. FX)/Jaguar or newer.</p> <h2 id="future-projects">Future projects</h2> <p>It’s no surprise, but the <code>Buffer Cache Rewrite</code> is close to release. Vulkan performance and stability improvements are planned, with kernel improvements continuing to be a high priority. Plus we also have some other interesting things we’ll reveal later on.</p> <p>That’s all folks! Thank you so much for sticking around. See you next time in the January progress report! Take care and stay safe! Thanks to Darkerm and Morph for helping with the pictures.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report November 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/ Wed, 09 Dec 2020 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/ <p>Salutations, yuz-ers! This is the November progress report which, for an unlimited time, will offer you hundreds of graphical fixes, improved performance, kernel changes, input additions, and major code cleanups.</p> <p>Salutations, yuz-ers! This is the November progress report which, for an unlimited time, will offer you hundreds of graphical fixes, improved performance, kernel changes, input additions, and major code cleanups.</p> <h2 id="4-jits-four-of-a-kind">4-JITs, four of a kind</h2> <p><a href="https://github.com/bunnei">bunnei</a> and <a href="https://github.com/FernandoS27">Blinkhawk</a> have been taking a look at yuzu&rsquo;s implementation of the kernel, searching for bugs or code that could be refactored — that is to say, rewritten to gain performance or make it easier to read, without changing the core functionality.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/4996">This kernel refactor PR</a> focuses on modifying how the JIT (Just-in-time) compiler, an essential tool to emulate the Nintendo Switch&rsquo;s CPU, is being used in yuzu. These changes greatly benefit the user since they will mitigate the need to set up a huge pagefile for the emulator. Setting the default pagefile size to <code>auto</code> should now be sufficient, although some games, like <code>Super Smash Bros. Ultimate</code>, might still need a pagefile with a more reasonable size due to the sheer amount of resources being allocated. Users may want to set the pagefile size to 10000MB to cover these worst-case scenarios.</p> <p>Speaking of <code>Super Smash Bros. Ultimate</code>, these changes have also fixed a softlock that occurred quite frequently when the Final Smash of the DLC character “Hero” was used. You can now freely kick your opponents off the screen with all your might without needing to hold your breath and cross your fingers.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./hero.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Hero’s Final Smash (Super Smash Bros. Ultimate)</p> </div> </div> <p>Additionally, the stutters experienced in many games have disappeared. This includes those found while changing character costumes in <code>Super Smash Bros. Ultimate</code> and right before the world map and tutorial videos play in <code>Super Mario Odyssey</code> (the videos also play much more smoothly).</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smobug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smofix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">World map in Super Mario Odyssey, before (left) and after (right) the changes, now stutter-free!</p> <p>So, you might be wondering, what exactly is happening behind the curtains?</p> <p>Computer programs, such as games, are usually written in high-level programming languages. These programs basically consist of a series of statements that will be carried out by the processor in sequential order to accomplish different tasks. The processor, however, does not understand these high-level instructions, so they are converted into a set of more elemental operations in binary called <a href="https://en.wikipedia.org/wiki/Machine_code">machine code</a>, which is directly compatible with the hardware of the system. The process of converting source code into machine code is called <code>compilation</code>, and this produces a file that can be loaded into memory and executed by the processor from there.</p> <p>The Nintendo Switch uses a 4-core ARM-based CPU, so naturally the generated machine code of any Switch game will be fully compatible with that architecture. This arises a problem, however, since yuzu was designed to run on computers using a processor with a AMD64 architecture, which is not capable of understanding these instructions. For this reason, they must be interpreted or translated from guest machine code (ARM) to host machine code (AMD64). There are different approaches to accomplish this, and yuzu does so by using <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a>: a dynamic recompiler written by <a href="https://github.com/MerryMage">MerryMage</a> that performs this translation in real time. This process, the so-called JIT Compilation, reads chunks of the program in memory, decodes the instructions, and emits the translated code so the host CPU can run it. By invoking Dynarmic, it is possible to recompile game code into machine code that runs natively on the host architecture.</p> <p>Previously, yuzu would create one instance of Dynarmic per guest thread being emulated on the Switch. This resulted in having multiple instances of the JIT running at the same time, which could be as many as twenty, if not more! As a consequence, a lot of resources were being wasted unnecessarily like this. But with the changes introduced in this PR, yuzu now creates only four instances of Dynarmic: one per core, which is a more efficient solution. The chart shown below compares the usage of memory among some popular titles before and after this PR was implemented; the test was performed during the internal testing phase, while yuzu was being run along Google Chrome and Discord. As it can be seen, the differences in memory usage vary between 3 GB and 6.4 GB, depending on the game. Similar results have been observed across other titles.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./memgraph.png" title=" Memory usage before and after implementing 4-JITs"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/memgraph_hu0d349aca320730e1db3f6032ff7ea1eb_28407_927x0_resize_q90_bgffffff_box_3.jpg" alt=" Memory usage before and after implementing 4-JITs"></a> <p class="has-text-centered is-italic has-text-grey-light"> Memory usage before and after implementing 4-JITs</p> </div> </div> <p>bunnei is still working on more cleanups and looking for things that can be further improved, so expect more updates in the future.</p> <h2 id="the-texture-cache-rewrite">The Texture Cache Rewrite</h2> <p>We’ve already spoken in detail about <a href="https://github.com/yuzu-emu/yuzu/pull/4967">the Texture Cache Rewrite</a> in its <a href="https://yuzu-mirror.github.io/entry/yuzu-tcr/">dedicated article</a>, so in short, the <code>Texture Cache Rewrite</code> (which is not a shader cache change) is work done by <a href="https://github.com/ReinUsesLisp">Rodrigo</a> to reimplement the old texture cache yuzu used, which was forked from <a href="https://github.com/citra-emu/citra">Citra.</a> This effort took over 10000 lines of code, fixing graphical bugs in numerous games and improving performance along the way.</p> <p>This paves the way for future important changes, like the <code>Buffer Cache Rewrite</code>, which is expected to not only continue to improve render accuracy, but to raise performance by optimizing the “hottest” code in the GPU section of our source, according to profiling. Afterwards, development of <code>Project Hades</code> is planned. This is a rewrite of the <code>Shader Cache</code>, with its main focus being improved precision and stability, and increased performance in Intel GPUs that are bottlenecked by the current implementation.</p> <p>Expected soon-ish are the <code>Compute Texture Decoders</code> which will leverage the compute shader capabilities of GPUs to decode the texture formats handled by the Nintendo Switch games. This includes even elusive formats like <code>ASTC</code>, the main cause of non-shader related stuttering on non-Intel GPUs.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./botw.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Prettiest fast-traveling (The Legend of Zelda: Breath of the Wild)</p> </div> </div> <p>One sad point of this rewrite is that the “Vulkan memory manager”, now called the <code>Texture Reaper</code>, which was expected to help reduce VRAM use in Vulkan, will take longer to implement due to technical complications that surfaced during its development. There is more detailed information in the dedicated article.</p> <p>A small PSA, AMD users should install the <code>20.11.3</code> driver version or newer, as it adds <code>VK_EXT_robustness2</code> to all missing Radeon products, helping in stability and precision.</p> <h2 id="project-aether-or-how-to-visit-yuzu-from-within-yuzu">Project Aether, or how to visit yuzu from within yuzu</h2> <p>Nintendo Switch games have access to a <code>web applet</code> that is typically used to show tutorials or guides while playing. Our original implementation using <a href="https://doc.qt.io/qt-5/qtwebengine-index.html">QtWebEngine</a> had some lasting bugs that impeded gameplay in some cases, like the tutorials on a first boot of <code>Super Smash Bros. Ultimate</code>.</p> <p><a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/5042">rewrote yuzu’s web applet</a>, still based on QtWebEngine, but completely overhauled. The web applet now accepts controller input instead of only touch emulation via mouse, and rendering fonts extracted from the native OS on the Switch, or using Open Source Software fallbacks.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./webapplet.png" title=" Working tutorials in Super Smash Bros. Ultimate"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/webapplet_hu2d3b37a01005341b8a7f78318415bbfe_854905_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Working tutorials in Super Smash Bros. Ultimate"></a> <p class="has-text-centered is-italic has-text-grey-light"> Working tutorials in Super Smash Bros. Ultimate</p> </div> </div> <p>Previously non-rendering applets are now working. This includes the few cases where games got stuck due to the previous implementation, like in <code>Super Smash Bros. Ultimate</code>. Mods that bypass the applet are no longer required, like in <code>Super Mario Odyssey</code>.</p> <p>There are limitations listed in the Pull Request that we will continue to work on. Expect this change to force our minimum Ubuntu version requirement to 20.10 in the future due to the need to update Qt to version 5.14.2 or higher.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./yuzu.png" title=" yuzuception!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/yuzu_hu619807f13ac737091a019037b50c750e_636597_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzuception!"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzuception!</p> </div> </div> <h2 id="general-bug-fixes-and-improvements">General bug fixes and improvements</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> brings the Xenoblade fans a nice little fix. <a href="https://github.com/yuzu-emu/yuzu/pull/5013">Implementing <code>early fragment tests</code></a> fixes ghost geometry problems that resulted in dark rendering areas.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xcdebug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/xcdebug_hu03cc0b23bc2277cd9ace912d98e1002b_2952665_800x0_resize_q90_bgffffff_box_3.jpg" alt="Like night and day! (Xenoblade Chronicles Definitive Edition)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xcdefix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/xcdefix_huc9271feb6d3d74d43af8de573b7a9f6d_8324840_800x0_resize_q90_bgffffff_box_3.jpg" alt="Like night and day! (Xenoblade Chronicles Definitive Edition)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Like night and day! (Xenoblade Chronicles Definitive Edition)</p> <p>This fix will be a Vulkan exclusive for now to avoid invalidating the current OpenGL shader cache.</p> <p>More vulkan fixes, now by <a href="https://github.com/ameerj">epicboy!</a> He <a href="https://github.com/yuzu-emu/yuzu/pull/4946">implemented the missing <code>alpha test culling</code> feature</a> from Vulkan, resolving transparency related rendering bugs. This could be easily spotted in the main menu of <code>Super Smash Bros. Ultimate</code> or the vegetation of <code>Tales of Vesperia: Definitive Edition</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smashbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/smashbug_hued13fab351b53fcdef96a61908d1eea9_948422_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> <div class="column is-bottom-paddingless"> <a href="./smashfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/smashfix_hud242f41138fd825ae9af94d9be72adf7_931601_800x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./talesbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/talesbug_hu01c546763ad9a2db806be7a18e47767b_3324196_800x0_resize_q90_bgffffff_box_3.jpg" alt="Those are some weird plants (Tales of Vesperia: Definitive Edition)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./talesfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/talesfix_hu7026470b981a9c662a964fbf01574a50_2618138_800x0_resize_q90_bgffffff_box_3.jpg" alt="Those are some weird plants (Tales of Vesperia: Definitive Edition)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Those are some weird plants (Tales of Vesperia: Definitive Edition)</p> <p>While we are speaking about <a href="https://github.com/ameerj">epicboy</a>, he also improved the quality of the NVDEC video decoder, by <a href="https://github.com/yuzu-emu/yuzu/pull/5002">queueing all frames</a> and cleaning up the code. This results in reduced skipped frames, and greatly improves videos encoded in <code>VP9</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./introbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./introfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Do you need a hand? (Super Smash Bros. Ultimate)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smovidbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smovidfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">An example of embedded videos during gamplay (Super Mario Odyssey)</p> <p>There has been some progress in World of Light playability, the single player campaign of <code>Super Smash Bros. Ultimate</code>. The main problem is not fixed yet, but thanks to <a href="https://github.com/bunnei">bunnei</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4901">stubbing <code>GetAlbumFileList3AaeAruid</code>,</a> now users can do a single fight in World of Light, save, restart yuzu, and do another one. We’re slowly getting there!</p> <p>Later updates of <code>Animal Crossing: New Horizons</code> fail to load, but by <a href="https://github.com/yuzu-emu/yuzu/pull/4951">stubbing <code>OLSC Initialize</code> and <code>SetSaveDataBackupSettingEnabled</code></a>, <a href="https://github.com/bunnei">bunnei</a> restored playability once again. You can now enjoy all the new content and events added with the latest update.</p> <p><a href="https://github.com/ogniK5377">ogniK</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4932">started preliminary work</a> on future fixes for audio emulation. This change currently improves fidelity in games like <code>Shovel Knight</code> and the <code>LEGO</code> series. Expect more audio related changes soon.</p> <p>yuzu has always been unstable when stopping emulation, and there are several reasons for this. <a href="https://github.com/bunnei">bunnei</a> fixed two distinct cases, when <a href="https://github.com/yuzu-emu/yuzu/pull/4978">closing while shaders were compiling, </a> and when closing <a href="https://github.com/yuzu-emu/yuzu/pull/4977">early during the boot process.</a> Quality of life fixes are always welcome.</p> <h2 id="input-improvements">Input improvements</h2> <p>You’ve been asking for it for ages, and <a href="https://github.com/german77">german77</a> delivers. <a href="https://github.com/yuzu-emu/yuzu/pull/4939">Mouse support is here!</a> With this, users can now set their mouse as they desire, be it an analog stick, buttons, motion, or touch screen emulation. A controller with motion support is still the recommended input method, but a mouse can save you in a pinch.</p> <p>As an extra gift for keyboard users, <a href="https://github.com/german77">german77</a> also added support for <a href="https://github.com/yuzu-emu/yuzu/pull/4905">better analog emulation with keyboard inputs.</a> With this change, keyboard players can now “drift” the emulated analog stick to get any angle, not just the fixed eight directions you can get by pressing key combinations.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./analogkey.png" title=" You can find this setting in Emulation &gt; Configure... &gt; Controls &gt; Advanced &gt; Emulate Analog with Keyboard Input"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/analogkey_hu82a94e17b6e55350e07c3cb65b4a403a_38996_1021x0_resize_q90_bgffffff_box_3.jpg" alt=" You can find this setting in Emulation &gt; Configure... &gt; Controls &gt; Advanced &gt; Emulate Analog with Keyboard Input"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can find this setting in Emulation &gt; Configure... &gt; Controls &gt; Advanced &gt; Emulate Analog with Keyboard Input</p> </div> </div> <p><a href="https://github.com/german77">german77</a> also enabled the use of <a href="https://github.com/yuzu-emu/yuzu/pull/4937">up to 8 different UDP servers.</a> This allows for motion controls for each player.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/4959">using <code>NpadStyleSet</code>,</a> <a href="https://github.com/Morph1984">Morph</a> now limits the available input options depending on the game. For example, in <code>Pokémon: Let’s Go</code>, the options are now limited to either Handheld, Left Joy-Con, or Right Joy-Con.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./limit.png" title=" No cheating!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-nov-2020/limit_hua63c74d294ec6624dbb1c26ead1e6fd5_103141_1018x0_resize_q90_bgffffff_box_3.jpg" alt=" No cheating!"></a> <p class="has-text-centered is-italic has-text-grey-light"> No cheating!</p> </div> </div> <p><a href="https://github.com/german77">german77</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4950">tweaked the rumble amplification function,</a> making it more linear and less aggressive. This should help when low strength percentage values are used.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/5021">stubbing both</a> <code>SetNpadCommunicationMode</code> and <code>GetNpadCommunicationMode</code>, <a href="https://github.com/german77">german77</a> made <code>Borderlands: Game of the Year Edition</code> and <code>Borderlands 2: Game of the Year Edition</code> playable!</p> <h2 id="a-silent-guardian-a-watchful-protector">A silent Guardian, a watchful Protector</h2> <p><a href="https://github.com/lioncash">Lioncache</a>, our harsh but fair code reviewer, has been <a href="https://github.com/yuzu-emu/yuzu/pull/5028">removing</a> the <code>global variable accessor</code> from the whole project (the linked PR is just the latest section), work that has taken months. yuzu used to be able to run a single global system instance, but with this change, yuzu can now create as many emulated instances as needed, all separate from each other. This provides full control over the life cycle of the emulated system, allowing among other things, faster game boot times, and maybe more importantly, forcing the devs to keep up cleaner code, which is easier to maintain in the future.</p> <h2 id="future-projects">Future projects</h2> <p>The <code>Buffer Cache Rewrite</code> has been progressing very fast with no delays so far, and Rodrigo is very enthusiastic about starting <code>Project Hades</code> after finishing it. More multicore changes are incoming, along with input improvements.</p> <p>That&rsquo;s all folks! Thank you so much for taking the time to read this progress report. See you next month, maybe Christmas will come early!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Mini-Series - Dev Interview #3 https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/ Thu, 03 Dec 2020 01:45:00 +0100 MysticExile https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/ <p>Hey there yuz-ers, welcome to the third Developer Interview! It&rsquo;s been a while since the last installment of this mini-series, so let&rsquo;s jump right into the good stuff.</p> <p>Hey there yuz-ers, welcome to the third Developer Interview! It&rsquo;s been a while since the last installment of this mini-series, so let&rsquo;s jump right into the good stuff.</p> <hr> <p>This time we&rsquo;re interviewing the myth, the legend, <a href="https://github.com/ameerj">epicboy</a>! He is the main reason why we have <a href="https://github.com/yuzu-emu/yuzu/pull/4729">NVDEC</a> now! If you didn&rsquo;t know already, NVDEC is Nvidia&rsquo;s video decoder used by the Nintendo Switch. Without him, we wouldn&rsquo;t be able to watch videos like <code>Fire Emblem: Three House's</code> intro or <code>The Legend of Zelda: Breath of the Wild's</code> memories. But that&rsquo;s not the only thing he has done! He was also responsible for <a href="https://github.com/yuzu-emu/yuzu/pull/4443">asynchronous shader compilation on the Vulkan renderer</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/4137">GameCube Controller support</a>, and <a href="https://github.com/yuzu-emu/yuzu/pull/4946">Alpha Test Culling on the Vulkan renderer</a>. And now, on to the interview!!</p> <hr> <p><strong>Q: Hey epicboy, why don&rsquo;t you start by telling us a bit about yourself?</strong></p> <p><strong>E:</strong> I&rsquo;m just a typical college student majoring in Computer Science. I&rsquo;m in my fourth year of studies out of five, pursuing both a BS and MS degree. To be honest, I&rsquo;ve been suffering from <a href="https://en.wikipedia.org/wiki/Impostor_syndrome">imposter syndrome</a> in my classes, so I wanted to put my programming skills to the test. That&rsquo;s what drove me to contribute to yuzu; a real-world test of the knowledge and experience I gained from my classes to prove to myself that my time at college hasn&rsquo;t been a waste.</p> <p><strong>Q: Why did you choose yuzu, a Nintendo Switch emulator, specifically?</strong></p> <p><strong>E:</strong> When I first heard of yuzu, back in 2018, I was impressed by the progress made on Switch emulation so soon after the console&rsquo;s release. I continued to follow the project&rsquo;s progress and was inspired by the never ending drive and effort of the developers. Soon after <code>Super Smash Bros. Ultimate</code> was announced as playable on the emulator, which sounded too good to be true, I gave the emulator a shot and was blown away at the compatibility. Of course, it wasn&rsquo;t perfect, especially given that my beloved controller of choice, the Nintendo GameCube controller, was not compatible with the emulator.</p> <p><strong>Q: So you decided that it was time to take matters into your own hands and add support yourself?</strong></p> <p><strong>E:</strong> Knowing that other emulators (notably <a href="https://dolphin-emu.org/">Dolphin</a>) had proper support for the official GameCube adapter, and considering I was looking to sharpen my programming skillset, I decided to take the opportunity and see if I can bring that support over to yuzu, opening the option to use the GameCube controller for anyone on the emulator.</p> <p><strong>Q: I&rsquo;m sure our GC controller users are very happy with your contribution! Why did you choose to tackle such a large task as NVDEC?</strong></p> <p><strong>E:</strong> I found the code review for the GC adapter implementation to be really useful. I wanted to learn more from the very sharp yuzu developers and continued to make more contributions and became more familiar with the yuzu dev team. One feature that I saw many yuzu fans request was for video decoding. I learned that <a href="https://github.com/ogniK5377">ogniK</a> had attempted to implement NVDEC before and reached out to get an understanding of this feature&rsquo;s scope and challenges faced along the way. Before I knew it, I had access to the repository with the old implementation&rsquo;s code and was encouraged to find a way to finish it off.</p> <p>It was intimidating at first, but the encouragement and mentorship from ogniK kept me motivated. It was also the first glimpse I had at the guts of yuzu, and found the work that has gone into the emulation of the Nintendo Switch&rsquo;s GPU to be very interesting.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./zla_0.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/zla_0_hu2af81f6b3cafef181f86346caa3dcd83_2064566_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening"></a> </div> <div class="column is-bottom-paddingless"> <a href="./zla_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/zla_1_hu87f54b6117c2cd9232846812dacab23e_1041880_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Link&#39;s Awakening</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ssbu_0.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/ssbu_0_hud74bbcc6da23859524443dc928109d9d_2298121_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ssbu_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/ssbu_1_hua084218ed0b11de4722d22608ac3ab56_3979061_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Smash Bros. Ultimate</p> <p><strong>Q: What obstacles did you have to overcome when implementing NVDEC?</strong></p> <p><strong>E:</strong> The earliest challenge was to understand what the data I&rsquo;m looking at means. At the GPU command level, everything is hexadecimal numbers with no obvious meaning tied to it. Thankfully, there have been others who reverse engineered and documented the processes that the GPU goes through for the NVDEC functionality. I was able to get quite far with decoding H.264 videos with the help of ogniK&rsquo;s older implementation. But the VP9 encoded videos found in many games were very difficult to decode.</p> <p>In order to decode VP9, I needed the frame data along with a &ldquo;compressed&rdquo; and &ldquo;uncompressed&rdquo; header to be sent to <a href="https://ffmpeg.org/">FFmpeg</a>, a library which is widely used for video decoding. The Switch GPU provided me with the frame data, but the headers needed to be manually constructed based on meta data provided by the GPU. I found myself spending countless hours reading the VP9 specification, and analyzing the video frame-by-frame in a tool that displays each frame&rsquo;s headers. Ultimately, it paid off, and many VP9 videos are decoded accurately.</p> <video width="1280" height="720" controls> <source src="./ssbu_2.mp4" type="video/mp4"> Your browser does not support the video tag. </video> <p><strong>Q: Quite the task I imagine. Why did you opt for the FFMpeg library instead of other alternatives?</strong></p> <p><strong>E:</strong> FFmpeg was kind of a no-brainer. It&rsquo;s fast, it&rsquo;s open sourced, and it&rsquo;s well documented. It handles decoding with little effort on the programmer&rsquo;s part. It also provides API&rsquo;s to re-scale and convert video formats, which proved to be useful. The other alternative would have been writing my own software decoder from scratch, but there&rsquo;s no point in reinventing the wheel!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./botw_0.png" title=" Footage of one of The Legend of Zelda: Breath of the Wild&#39;s memories."> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-3/botw_0_hu333d01a22c75237e468f199bb203144f_2282915_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Footage of one of The Legend of Zelda: Breath of the Wild&#39;s memories."></a> <p class="has-text-centered is-italic has-text-grey-light"> Footage of one of The Legend of Zelda: Breath of the Wild&#39;s memories.</p> </div> </div> <p><strong>Q: No kidding! Is there anything you&rsquo;re currently working on?</strong></p> <p><strong>E:</strong> Of course! I&rsquo;m always looking for the next opportunity to contribute to the project while continuing to learn and grow as a programmer as well. There&rsquo;s still some work left for me to finish up for the NVDEC implementation, so I haven&rsquo;t decided on what I&rsquo;d like to tackle next. All I can say for now is that I genuinely enjoyed GPU related programming.</p> <p><strong>Q: We look forward to your future contributions! Is there anything else you would like to share to our users?</strong></p> <p><strong>E:</strong> I&rsquo;d like to say &ldquo;thank you&rdquo; to all the yuz-ers! They are always appreciative of the work the yuzu developers put into the emulator, and are always excited to know what&rsquo;s next for the project. Their demands can sometimes be overwhelming, but it continues to motivate the developers, and it&rsquo;s always gratifying to see the positive reaction they have when a feature they&rsquo;ve been looking forward to finally becomes a reality.</p> <hr> <p>A huge thanks to epicboy for taking the time to sit down and give us some insight on NVDEC and himself. We hope you all enjoyed it, and we will be back soon with another featured yuzu dev to bring you behind the curtains again. Until then, thank you for your support and stay tuned!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - Texture Cache Rewrite https://yuzu-mirror.github.io/entry/yuzu-tcr/ Sun, 22 Nov 2020 16:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-tcr/ <p>Hi yuz-ers! We’re very excited to offer you one of the biggest code rewrites in yuzu’s history: The Texture Cache Rewrite! Now available to our Early Access members, continue reading to learn more.</p> <p>Hi yuz-ers! We’re very excited to offer you one of the biggest code rewrites in yuzu’s history: The Texture Cache Rewrite! Now available to our Early Access members, continue reading to learn more.</p> <h2 id="but-what-is-the-tcr">But what is the TCR?</h2> <p>yuzu started as a fork of <a href="https://github.com/citra-emu/citra">Citra</a>, so Citra&rsquo;s texture cache (or rasterizer cache, as it was called at the time) was used in the early days of yuzu. However, this cache only supported OpenGL, so one of the first efforts when adding support for <a href="https://yuzu-mirror.github.io/entry/yuzu-vulkan/">Vulkan</a> was to make the code more generic, helping in GPU emulation.</p> <p>When this was being worked on, we were still learning how the Nintendo Switch&rsquo;s GPU worked (we still are, but even more so then). Some design decisions taken at the time stuck with the codebase making things harder to change in the future. It was also easier to break with unrelated changes.</p> <p>So out with the old, in with the new. The previous implementation was no longer sufficient, so <a href="https://github.com/ReinUsesLisp">Rodrigo</a> started working on a complete rewrite from scratch. This includes but is not limited to:</p> <ul> <li>Cleaner code. No more virtual calls or shared pointers, this allows for easier maintenance in the future.</li> <li>Proper handling for texture swizzling.</li> <li>Some operations are now done in the GPU instead of in the CPU, improving performance.</li> <li>Control over when to destroy textures.</li> <li>Previously, textures were removed from the cache on CPU writes, but now they are flagged as dirty. This allows yuzu to cache already visited image views and render targets, saving time.</li> <li>Multiple textures can coexist in the same address now.</li> <li>Aliased images are now emulated through copies on demand.</li> <li>Rendering to compressed textures is properly emulated.</li> <li>3D BC4 textures are emulated with RGBA8.</li> <li>Rendering to texture views of different compatible formats is emulated without copies.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lain.png" title=" A very detailed explanation from our developer"> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/lain_hu72a9222a2273035c3fa0d17aeba6bb0c_8280_542x0_resize_q90_bgffffff_box_3.jpg" alt=" A very detailed explanation from our developer"></a> <p class="has-text-centered is-italic has-text-grey-light"> A very detailed explanation from our developer</p> </div> </div> <h2 id="ok-but-how-does-this-help">OK, but how does this help?</h2> <p>In short: it fixes a lot of graphical bugs, improves performance, and is not limited to any hardware configuration or driver in use. Improvements for everyone, once all parts are finished.</p> <p>Before we talk about performance, here are just a few examples of the rendering fixes you can expect to see with this release:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./splatoon_2_before_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/splatoon_2_before_2_huec3b68ec61adf0a15ec495da37082d50_2525922_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column is-bottom-paddingless"> <a href="./Splatoon_2_after_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/Splatoon_2_after_2_hu8f3689c651e4d08d7e80af73a7adcc3d_3427593_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Splatoon_2_before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/Splatoon_2_before_huec3b68ec61adf0a15ec495da37082d50_2353106_800x0_resize_q90_bgffffff_box_3.jpg" alt="Shadows in Splatoon 2 are now rendered correctly, finally allowing us to admire the beautiful cityscape"></a> </div> <div class="column is-bottom-paddingless"> <a href="./Splatoon_2_after.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/Splatoon_2_after_huec3b68ec61adf0a15ec495da37082d50_3553546_800x0_resize_q90_bgffffff_box_3.jpg" alt="Shadows in Splatoon 2 are now rendered correctly, finally allowing us to admire the beautiful cityscape"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Shadows in Splatoon 2 are now rendered correctly, finally allowing us to admire the beautiful cityscape</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./LM3_before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/LM3_before_hucbb5ea835c095620e567a63bb74a2935_2276532_800x0_resize_q90_bgffffff_box_3.jpg" alt="Lighting and stencil shadow corruption is now fixed in Luigi&#39;s Mansion 3"></a> </div> <div class="column is-bottom-paddingless"> <a href="./LM3_After.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/LM3_After_hucbb5ea835c095620e567a63bb74a2935_2342250_800x0_resize_q90_bgffffff_box_3.jpg" alt="Lighting and stencil shadow corruption is now fixed in Luigi&#39;s Mansion 3"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Lighting and stencil shadow corruption is now fixed in Luigi&#39;s Mansion 3</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./AC_before_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/AC_before_3_huec3b68ec61adf0a15ec495da37082d50_1226964_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column is-bottom-paddingless"> <a href="./AC_after_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/AC_after_3_huec3b68ec61adf0a15ec495da37082d50_1173085_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./AC_Before_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/AC_Before_2_hu335e53870fe7489117032877e3fb8c99_2454408_800x0_resize_q90_bgffffff_box_3.jpg" alt="Astral Chain no longer exhibits black texture corruption"></a> </div> <div class="column is-bottom-paddingless"> <a href="./AC_After_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/AC_After_2_hu504fabd7bb110fed7c52a4c1b1f225df_2403640_800x0_resize_q90_bgffffff_box_3.jpg" alt="Astral Chain no longer exhibits black texture corruption"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Astral Chain no longer exhibits black texture corruption</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./acnh_OLD.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/acnh_OLD_hu335e53870fe7489117032877e3fb8c99_2455751_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column is-bottom-paddingless"> <a href="./acnh_NEW.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/acnh_NEW_hu335e53870fe7489117032877e3fb8c99_2557617_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./acnh_OLD_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/acnh_OLD_2_hu335e53870fe7489117032877e3fb8c99_2611567_800x0_resize_q90_bgffffff_box_3.jpg" alt="Depth of field issues are gone in Animal Crossing: New Horizons"></a> </div> <div class="column is-bottom-paddingless"> <a href="./acnh_NEW_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/acnh_NEW_2_hu335e53870fe7489117032877e3fb8c99_2610005_800x0_resize_q90_bgffffff_box_3.jpg" alt="Depth of field issues are gone in Animal Crossing: New Horizons"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Depth of field issues are gone in Animal Crossing: New Horizons</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc2b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/xc2b_hud6e9a5f60f9e8ceaee010ec66f07b4b0_3603752_800x0_resize_q90_bgffffff_box_3.jpg" alt="Xenoblade Chronicles 2 is free from vertex explosions on AMD Vulkan drivers"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc2f.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/xc2f_hu65bc059f294d47d5090a415d3770f56e_4309355_800x0_resize_q90_bgffffff_box_3.jpg" alt="Xenoblade Chronicles 2 is free from vertex explosions on AMD Vulkan drivers"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Xenoblade Chronicles 2 is free from vertex explosions on AMD Vulkan drivers</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./torna.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Texture swapping &amp; flickering issues are fixed in all Xenoblade Chronicles games</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smashb.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/smashb_hu4d442bf71efcad6dcbc3e48f30039935_2402226_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column is-bottom-paddingless"> <a href="./smashf.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/smashf_hubcdb3cf48918a9f86aa866b666e14508_2706386_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smashb2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/smashb2_hu3354340051381dec03edbc4806acaed0_2798583_800x0_resize_q90_bgffffff_box_3.jpg" alt="Jumbotrons now display correctly in Super Smash Bros. Ultimate. Here’s an example running in the radeonsi mesa OpenGL Linux drivers"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smashf2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/smashf2_hu9b5f0a5540afbf7043b9e295904292ff_2463165_800x0_resize_q90_bgffffff_box_3.jpg" alt="Jumbotrons now display correctly in Super Smash Bros. Ultimate. Here’s an example running in the radeonsi mesa OpenGL Linux drivers"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Jumbotrons now display correctly in Super Smash Bros. Ultimate. Here’s an example running in the radeonsi mesa OpenGL Linux drivers</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./sf1b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/sf1b_hudb89fcc59c9fc9517338b8fae18c5cea_1827468_800x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu now has Multisample anti-aliasing (MSAA) support, as shown in SONIC FORCES here"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sf1f.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/sf1f_hu602c0c9e4499af6458f7ac89014e3b91_1818361_800x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu now has Multisample anti-aliasing (MSAA) support, as shown in SONIC FORCES here"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sf2b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/sf2b_hu1e4eb3885f200cbec502a375b9901806_2735_800x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu now has Multisample anti-aliasing (MSAA) support, as shown in SONIC FORCES here"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sf2f.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/sf2f_hub9226f941173d3c8cfa722cbe79ed000_2851_800x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu now has Multisample anti-aliasing (MSAA) support, as shown in SONIC FORCES here"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">yuzu now has Multisample anti-aliasing (MSAA) support, as shown in SONIC FORCES here</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./rain.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Slow rainfall fixed in The Legend of Zelda: Breath of the Wild (Requires High GPU accuracy)</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./botw.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Rune transportation renders just like native hardware in The Legend of Zelda: Breath of the Wild</p> </div> </div> <h2 id="but-what-about-performance">But what about performance?</h2> <p>On top of the rendering improvements, many games show a 10-30% improvement to framerate, with greatly improved frametime stability as demonstrated below:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./lm3.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Luigi’s Mansion 3 received some huge leaps in rendering accuracy *and* performance, notice the frametime graph</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smo.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Super Mario Odyssey</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./link.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> The Legend of Zelda: Breath of the Wild</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./acnh.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Animal Crossing: New Horizons</p> </div> </div> <h2 id="current-limitations-and-future-progress">Current limitations and future progress</h2> <p>Due to these changes, hardware lacking the <code>VK_EXT_robustness2</code> extension will not produce the optimal experience. In Windows, this includes AMD graphics cards older than Vega (Polaris and older series) and all Intel iGPUs to date. You can check the current support <a href="http://vulkan.gpuinfo.org/listdevicescoverage.php?extension=VK_EXT_robustness2&amp;platform=windows">here</a>. Games requesting this extension on unsupported hardware may behave randomly or crash in rare instances. A fallback code path is being worked on. Make sure to be up to date with your drivers, as the GPU vendor may be able to add support in the future if the hardware allows it.</p> <p>Originally, <code>Bindless Texture</code> support was expected to be added, but several difficulties emerged during development. One of the problems is the lack of native hardware support for ASTC texture decoding. If we used uncompressed textures, GPUs with less than 8GB of VRAM would not be able to load all the game assets, and if we recompressed them in another texture format to avoid this problem, image quality would degrade. True bindless texture support can be considered again in the future.</p> <p><code>Depth Stencil Blits</code> are not implemented on Vulkan for devices that don&rsquo;t offer native support (any AMD and Intel GPU).</p> <p>Another complication that emerged during development is related to memory management. The idea was to release the Texture Cache Rewrite with what the team calls the <code>Texture Reaper</code>, a way to remove textures from VRAM that have not been used after some time. While this has been almost working in OpenGL during testing, managing to run Luigi&rsquo;s Mansion 3 in under 300MB of VRAM, Vulkan on the other hand received no benefit.</p> <p>Vulkan faces one main problem: it fragments the memory when textures need to be mapped to <em>contiguous</em> video memory. There’s no tolerance for fragmentation, so freeing blocks will not help at all if the next texture doesn’t fit in the new empty space. This will require the development of a VRAM defragmentation routine, work that can take quite some time. So we can say that today marks the day <code>Project Texture Reaper</code> starts.</p> <p>A feature that will be added shortly later will be <code>Accelerated Texture Decoding</code>, which will handle any texture format via <code>Compute Shaders</code>, even formats the GPU doesn’t support natively. <a href="https://github.com/ameerj">epicboy</a> is working on the ASTC compute decoder.</p> <p>The next project <a href="https://github.com/ReinUsesLisp">Rodrigo</a> is working on is the <code>Buffer Cache Rewrite</code>. This work promises to solve more rendering issues (for example font rendering problems) and seriously improve performance, especially on memory bandwidth starved hardware like integrated GPUs.</p> <p>And with that, our overview of the Texture Cache Rewrite is finished! Please report any bugs or problems you face with this new feature on our <a href="https://discord.gg/u77vRWY">Discord server</a> or on our <a href="https://community.citra-emu.org/c/yuzu-support/">Forums.</a></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ugg.png" title=" HONK"> <img src="https://yuzu-mirror.github.io/entry/yuzu-tcr/ugg_huf58f67e101014fb38708bdbccb43d91f_2397678_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" HONK"></a> <p class="has-text-centered is-italic has-text-grey-light"> HONK</p> </div> </div> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report October 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/ Tue, 10 Nov 2020 12:00:00 -0300 Honghoa https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/ <p>How&rsquo;s it going, yuz-ers? Here work continues. This month&rsquo;s report offers you mythological hammers dropping, Vulkan and OpenGL stability fixes, and some news on the continued fight to make Super Mario 3D All-Stars render.</p> <p>How&rsquo;s it going, yuz-ers? Here work continues. This month&rsquo;s report offers you mythological hammers dropping, Vulkan and OpenGL stability fixes, and some news on the continued fight to make Super Mario 3D All-Stars render.</p> <h2 id="project-mjölnir">Project Mjölnir</h2> <h3 id="part-3---smite-as-hard-as-you-desire">Part 3 - Smite as hard as you desire</h3> <p><a href="https://github.com/Morph1984">Morph</a> strikes again with <a href="https://github.com/yuzu-emu/yuzu/pull/4866">part 3 of <code>Project Mjölnir</code></a> - a major rewrite of yuzu&rsquo;s <code>Human Interface Device (HID)</code>. This concludes months of hard work that also involved the contributions of <a href="https://github.com/its-rei">Rei</a> (who designed the new user interface) and <a href="https://github.com/jroweboy">jroweboy</a> (who started the original HID rewrite that later Morph continued).</p> <p>Just as <a href="https://en.wikipedia.org/wiki/Mj%C3%B6lnir#Origins_in_the_Prose_Edda">three different gifts</a> were given to the Nordic gods by the dwarves (including the iconic hammer of Thor), this project was divided into three parts focused on different aspects of emulating the input control of the Nintendo Switch.</p> <p>The first part was centered on overhauling the user interface, as well as modifying and fixing errors in the backend that handled the mapping and detection of controllers. These changes allowed yuzu&rsquo;s implementation of input to behave more closely to the hardware, improved the user experience, and also paved the way for the subsequent improvements in the following PRs.</p> <p>The second part took care of implementing the <code>Controller Applet</code>: a service used by games to communicate and set up the kind of controller input they can accept, how many players will use them, what character they will control, etc.</p> <p>And now, at last, comes the third part of this project: introducing bug fixes, <code>Controller Profiles</code>, and an overhaul to the implementation of <code>Rumble</code> realized by <a href="https://github.com/german77">german77</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./load_profile.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Loading a profile for a Sony DS4 controller</p> </div> </div> <p><code>Controller Profiles</code> had been a placeholder since Part 1 of <code>Project Mjölnir</code>. They allow users to set up the configuration of their gamepads and save them in a file, which can be loaded and marked with a distinctive name. This is particularly useful for people who own more than one type of controller, since they store all button and axis information, as well as the port and engine used to read the input data. Changing between one configuration and another becomes as simple as clicking a dropdown menu and choosing the desired profile, and all the settings will then be applied automatically. Users now can create a profile by simply clicking on the &ldquo;New&rdquo; button and writing a descriptive name to save it.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/4809">Modifier Buttons</a> was also another feature that wasn&rsquo;t working well since Part 1. A <code>Modifier Button</code> allows the user to change the range of an axis on the fly by pressing it, which is particularly useful when said axis is mapped to digital buttons instead of an analog stick. This is because digital buttons are interpreted as a &ldquo;virtual axis&rdquo; that is being pushed from the minimum value (0%) to its maximum value (100%) every time they are pressed. With this change, it is now possible to set the maximum value of this axis to a value lower than 100%, effectively limiting its range. Useful for walking or sneaking!</p> <p>Next on the list of fixed bugs, we had a <a href="https://github.com/yuzu-emu/yuzu/pull/4816">controller reconnection issue</a>. Sometimes, a controller instance was being pushed back into memory right after being disconnected. This faulty behaviour was a bug that prevented the controller from being recognized by yuzu when it was reconnected by the user again. <a href="https://github.com/Morph1984">Morph</a> implemented a simple guard to avoid this and solved the problem.</p> <p>For some games, vibrations didn&rsquo;t work properly, or at all. To understand why this was happening, we will need to explain a bit of what’s going on behind the curtains of abstraction, so please bear with us here.</p> <p><code>Rumble</code> in the Nintendo Switch is physically generated by a pair of identical <a href="https://en.wikipedia.org/wiki/Linear_actuator">Linear Resonant Actuator motors</a> that can emit a wide range of frequencies on the low and high spectrum, independently from each other. This contrasts with the approach used in other controllers, which typically have low frequency <a href="https://en.wikipedia.org/wiki/Rotating_unbalance">Eccentric Rotating Mass (ERM) motors</a> at the left side and a high frequency ERM at the right side; depending on the desired frequency band at which one wants to make those controllers vibrate, it is possible to send signals to one or the other and thus accomplish low and high frequency rumble. The Nintendo Switch also characterizes vibration in such a way that it&rsquo;s possible for games to distinguish between the left and right motors of different players. This is because each device has an identifier handler that is used to send the correct vibration commands to the right place.</p> <p>Prior to this PR, the functions that processed this handler information weren’t coded yet, or they were stubbed and returned incorrect information. Even with those limitations, this exceeded the capabilities of the <a href="https://www.libsdl.org/">SDL library</a> (an <a href="https://en.wikipedia.org/wiki/API">API</a> that yuzu uses to communicate with the hardware of the input devices), which was designed to work with generic gamepads that do not present any of these unique features of the Nintendo Switch. As a result, the rumble wasn&rsquo;t being processed correctly. This resulted in inaccurate behaviour, such as the lack of vibration for the controllers of players other than player one, since this handler information wasn&rsquo;t available for SDL to distinguish where to send the vibration signals other than for &ldquo;controller 0&rdquo;. In order to make vibrations work as intended, <a href="https://github.com/Morph1984">Morph</a> investigated how this information was characterized and implemented the functions to process these handlers, so that the vibration data could be sent to the appropriate devices and players. The addition of these functions also fixed a number of games, such as <code>Xenoblade Chronicles: Definitive Edition</code>, <code>Xenoblade Chronicles 2</code>, <code>Hollow Knight</code>, and many others that previously didn&rsquo;t exhibit rumble at all.</p> <p>Previously, some people using certain types of wireless controllers reported in-game performance losses whenever their gamepads rumbled. The root of this issue lied in the rate at which the vibration states were being updated to these controllers, so <a href="https://github.com/german77">german77</a> implemented a solution to reduce the rate to 50 Hz and filter out some of the vibrations. But it was later reported that some vibration effects were missing in games such as <code>Super Smash Bros. Ultimate</code> due to this filter, so an alternative solution was needed. For this reason, <a href="https://github.com/Morph1984">Morph</a> implemented <code>Accurate Vibrations</code>, a toggle option (off by default) that switches between a full implementation and one with the effective vibration rate reduced through heuristics. If this option is disabled, the vibration rate is limited to 100 vibrations per second, excluding vibrations with an amplitude value of 0 (which is considered as the &ldquo;not vibrating&rdquo; state). This rate was determined to be safe through testing done by <a href="https://github.com/Morph1984">Morph</a> and <a href="https://github.com/renA21">Ren</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./configure_vibration.png" title=" Vibration Configuration Window"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/configure_vibration_hufa57987c5ebed781b3cab85ce6aa4609_8899_374x0_resize_q90_bgffffff_box_3.jpg" alt=" Vibration Configuration Window"></a> <p class="has-text-centered is-italic has-text-grey-light"> Vibration Configuration Window</p> </div> </div> <p>These changes were enough to fix the stutters experienced by these users. In order to toggle <code>Accurate Vibrations</code> on, the user should navigate to <code>Emulation &gt; Configure... &gt; Controls</code> and click on &ldquo;Configure&rdquo; under the &ldquo;Vibrations&rdquo; tickbox. They can also change the intensity of the vibrations for each player, if desired.</p> <p>Furthermore, an additional check has been implemented when initializing a vibration device to determine if a controller is apt to rumble or not. It consists in sending vibrations with an amplitude value of 0 and reading the value sent back from the controller. While this approach works fine for the GameCube Adapter, SDL returns an incorrect value if two vibration signals with identical amplitudes are sent to the device. To work around this problem, yuzu first sends a vibration with an amplitude of 1/65535, then one with amplitude 0, and then reads the value returned from the device. This check is extremely important, because it helps in implementing the necessary functions that tell the games if the vibration device is properly mounted and capable of rumble, and it also makes it possible for yuzu to disable rumble capabilities in the backend automatically if a controller doesn&rsquo;t support it.</p> <p>On top of these changes, work has been done so that anyone can plug in their favorite controller and, if it supports vibrations, all configuration related to it will be applied automatically. In the case that the controller doesn’t, however, rumble will be disabled on the backend.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mapping.png" title=" Manually mapping an analog stick"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/mapping_hu6c0c9ef93cc9b44af93ed3c929ec6d80_6654_465x0_resize_q90_bgffffff_box_3.jpg" alt=" Manually mapping an analog stick"></a> <p class="has-text-centered is-italic has-text-grey-light"> Manually mapping an analog stick</p> </div> </div> <p>It is worth noting that, in case the automatic configuration process fails, users can map their analog sticks manually by clicking on any of the axis mappings. This solves issues with certain controllers that have their axis mapped as digital buttons.</p> <p><code>Project Mjölnir</code> has come a long way since it started. Major parts of yuzu’s original code for input were rewritten, tested, and ironed out. Vast parts of the input frontend and backend were overhauled in favour of a more user friendly interface, aiming to make it easy to configure your controllers in the most intuitive way (and many of these configurations are also being applied automatically). Much of the effort done by the devs is easily perceivable, but there’s also a lot of work that went into making things run perfectly behind the scenes. Hours of investigation, lining up the details, and polishing every addition. Indeed, our devs gave it their best, just like the dwarves in the Eddas, to present you with this gift. The Nordic gods debated which among the three presents they received was the best, and they concluded the hammer was, without any doubts, the most precious of them. It is our most sincere wish that you will accept this hammer from us, and smite as hard as you desire!</p> <p>As a small sidenote: In the Edda, the dwarves happened to ask for Loki’s head as compensation for the gifts. But don’t worry, we won’t go that far with you! <em>(Yet)</em>.</p> <h2 id="back-to-the-pokéfuture">Back to the Pokéfuture</h2> <p>A highly requested fix, and understandably so. Pokémon has long been a franchise that uses time as a game mechanic. In yuzu, this feature was not working as intended with <code>Sword and Shield</code>. What would normally be saving, closing yuzu, and loading in later expecting time to naturally pass, ends up as if nothing happened, rendering several events (like berry respawns, changing weather, Pokéjobs, different Pokémon spawns, or just simple time of day changing) useless. We don&rsquo;t have a proper fix to naturally progress the time yet, but for now, thanks to the work done by <a href="https://github.com/bunnei">bunnei</a>, it is now possible to <a href="https://github.com/yuzu-emu/yuzu/pull/4792">bypass this problem by changing the clock from yuzu&rsquo;s settings during gameplay.</a></p> <p>You can find the setting in <code>Emulation &gt; Configure... &gt; System</code>, enable <code>Custom RTC</code>, and then enjoy time travelling!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./rtc.png" title=" Try to avoid changing the divergence value, Doc!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/rtc_huc7dcdc34436e31df241d6a1f1834fe24_12961_971x0_resize_q90_bgffffff_box_3.jpg" alt=" Try to avoid changing the divergence value, Doc!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Try to avoid changing the divergence value, Doc!</p> </div> </div> <h2 id="greetings-professorhttpswwwyoutubecomwatchvxr-aiariea4-fixes-to-report"><a href="https://www.youtube.com/watch?v=xr-aIARiea4">Greetings, Professor!</a> Fixes to report!</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> has for us a couple of stability improvements for <code>Fire Emblem: Three Houses</code>, only involving Vulkan and assembly shaders (GLASM) for now.</p> <p>On the Vulkan side, <a href="https://github.com/yuzu-emu/yuzu/pull/4782">managing primitive topologies as fixed state</a> fixes regressions introduced by recent Nvidia drivers, but it has been reported to also help AMD Radeon users quite a bit too.</p> <p>On the GLASM side, and benefitting our Nvidia users the most, <a href="https://github.com/yuzu-emu/yuzu/pull/4807">implementing robust buffer operations</a> like it is done in GLSL helps make the game playable when using this very useful shader implementation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fe3h.png" title=" I have something to ask of you (Fire Emblem: Three Houses)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/fe3h_hudc9bc45824cc3ec1e7e9eaa2cf34ca25_3981057_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" I have something to ask of you (Fire Emblem: Three Houses)"></a> <p class="has-text-centered is-italic has-text-grey-light"> I have something to ask of you (Fire Emblem: Three Houses)</p> </div> </div> <p>Crashes will still be experienced in specific chapters of the game, like Ch. 15 and Ch. 17. For those cases, we can offer you a workaround:</p> <ol> <li>You need to download one of the following old builds: <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/tag/mainline-0-66">yuzu 66</a> or <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/tag/mainline-0-41">yuzu 41</a>.</li> <li>Set it up as a standalone version by extracting it and creating a <code>user</code> folder where <code>yuzu.exe</code> is located.</li> <li>This folder will replace <code>%appdata%\yuzu</code>, so you need to extract a copy of your keys there, along with any save data you want to transfer to get past the crashes. Make sure to also copy your <code>nand</code> folder so you can transfer all DLC and updates to the standalone yuzu build.</li> <li>Play the game, expect tons of glitches and pretty bad performance for such an old build. Save after progressing past the crashing area and transfer that save to the latest <code>Mainline/Early Access</code> version you are using, and continue playing regularly from there.</li> </ol> <h2 id="emuception">Emuception</h2> <p><a href="https://github.com/bunnei">bunnei</a> seems to have a personal vendetta with <code>Super Mario 3D All-Stars</code>. He has:</p> <ul> <li><a href="https://github.com/yuzu-emu/yuzu/pull/4783">Implemented the nvhost_as_gpu::FreeSpace service.</a></li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/4784">Implemented the BufferQueue::CancelBuffer service.</a></li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/4793">Stubbed IManagerForApplication::StoreOpenContext.</a></li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/4799">Reworked the program loader to better handle multiple processes.</a></li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/4832">Fixed crashes when trying to launch subsequent games.</a></li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/4869">Improved GPU synchronization.</a>.</li> </ul> <p>The last one also improves stability in games like <code>Luigi's Mansion 3</code>. The only thing missing to get <code>Super Mario 3D All-Stars</code> rendering is the <code>Texture Cache Rewrite</code>.</p> <h2 id="nvdec-improvements">NVDEC improvements</h2> <p>Work on video decoding continues, thanks to <a href="https://github.com/ameerj">epicboy</a>. Some games like <code>Onimusha: Warlords</code> and <code>Ni no Kuni</code> had an incompatible <code>BGRA8</code> format in our first NVDEC implementation. Now they render correctly.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./ninokuni.png" title=" Working menu rendering (Ni no Kuni)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/ninokuni_hud9764e7fdee7bd5e304ebb139ca443e1_2612522_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Working menu rendering (Ni no Kuni)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Working menu rendering (Ni no Kuni)</p> </div> </div> <p>Unfortunately, a select few games like <code>FINAL FANTASY XII THE ZODIAC AGE</code>, <code>The Legend of Zelda: Link's Awakening</code>, and <code>Onimusha: Warlords</code> currently have problems with memory addressing, causing incorrect video decoding and various graphical glitches (flashing/flickering). While there is a workaround in place in Early Access builds, this fix is not stable enough to be considered mergeable. Once a more elegant solution is found, we will let you all know.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./onimusha.png" title=" Happy moments (Onimusha: Warlords)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/onimusha_hu999fc57aa755c5c6ab81ff3724858342_2888611_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Happy moments (Onimusha: Warlords)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Happy moments (Onimusha: Warlords)</p> </div> </div> <p>And last but not least, NVDEC is now in Mainline! Anyone can now enjoy the in-game videos in yuzu. As the tradition for all merged Pull Requests, <a href="https://github.com/lioncash">Lioncache</a> didn&rsquo;t take long to <a href="https://github.com/yuzu-emu/yuzu/pull/4837">clean it up.</a></p> <h2 id="non-mythological-input-changes">Non-mythological input changes</h2> <p>We have some great changes made possible from the work of <a href="https://github.com/german77">german77</a>. Thank you!</p> <p>To start with, <a href="https://github.com/yuzu-emu/yuzu/pull/4742">buttons that are impossible to use on certain input configurations are now blocked</a>. For example, if an emulated Pro Controller is changed to a left Joy-Con, the right stick, A, X, Y and Z will no longer be accessible to the games. No cheating!</p> <p>Up next, some devices have access to an accelerometer, but lack a gyroscope. While this setup is basically useless for full motion, it can be used to detect simple shaking motions, <a href="https://github.com/yuzu-emu/yuzu/pull/4757">so we don&rsquo;t see why we shouldn&rsquo;t add support for that.</a></p> <p>And finally, for our traditional fighters out there, we have some improvements for GC adapters. <a href="https://github.com/yuzu-emu/yuzu/pull/4781">Adapters can now be hotplugged, basic rumble support was added, and compatibility with more vendors was improved.</a></p> <p>A new challenger approaches! <a href="https://github.com/FrogTheFrog">FrogTheFrog</a> tuned up <a href="https://github.com/yuzu-emu/yuzu/pull/4727">the shake values</a> to improve compatibility with the rare <code>Steam Controller</code>. Wouldn&rsquo;t having Portal and Portal 2 on the Switch be awesome?</p> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p><a href="https://github.com/bunnei">bunnei</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4805">changed the values for <code>Multicore</code>, <code>Asynchronous GPU</code>, and <code>Assembly Shaders</code></a> to be enabled by default. This will help provide a much better experience out of the box to all users that haven&rsquo;t changed those values already. Some other advanced settings like <code>Asynchronous shaders</code> are not altered by this change as they still require further testing and bug-fixing.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/4766">implementing CUBE textures and fixing an issue with arrays,</a> <a href="https://github.com/ReinUsesLisp">Rodrigo</a> made the <code>Pikmin 3: Deluxe Demo</code> playable. This will most likely help in making the final game playable too.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pikmin3.png" title=" Thanks GG for the capture! (Pikmin 3: Deluxe Demo)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/pikmin3_hub286e21e37bdfdfa85eb1da0a89926ed_3719286_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Thanks GG for the capture! (Pikmin 3: Deluxe Demo)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Thanks GG for the capture! (Pikmin 3: Deluxe Demo)</p> </div> </div> <p>In a minor change to Vulkan, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4765">changed the way GPU devices are sorted in yuzu,</a> helping pick the best GPU according to yuzu&rsquo;s current compatibility and needs.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vklist.png" title=" A developer&#39;s system, gotta render &#39;em all!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/vklist_hu6982ba926845bc96850a97aaf7d3c773_18265_887x0_resize_q90_bgffffff_box_3.jpg" alt=" A developer&#39;s system, gotta render &#39;em all!"></a> <p class="has-text-centered is-italic has-text-grey-light"> A developer&#39;s system, gotta render &#39;em all!</p> </div> </div> <p>The current method follows these rules:</p> <ul> <li>Priority will be given to the GPU vendor following the <code>Nvidia &gt; AMD &gt; Intel</code> order.</li> <li>Dedicated hardware will take priority over integrated. For example an RX 570 will have a higher priority than an Intel UHD630.</li> <li>The device name will be considered, a GTX 1650 will be selected over a GTX 1060. Most of the time, newer architecture generations offer better performance benefits than pure raw performance.</li> </ul> <p>In the previous progress report, we mentioned that we removed a blacklist on AMD GPUs for the <code>VK_EXT_extended_dynamic_state</code> Vulkan extension. Turns out, RDNA1 GPUs crash to the desktop while using this extension, so <a href="https://github.com/ReinUsesLisp">Rodrigo</a> (while using your writer&rsquo;s PC) had to <a href="https://github.com/yuzu-emu/yuzu/pull/4772">manually add a new blacklist only including current Navi based GPUs.</a> One would expect that a reported extension is tested before releasing the drivers that start supporting it&hellip; The 20.10.1 driver version from AMD seems to revert to an older Vulkan version lacking this extension, so the Red Team is aware of the issue.</p> <p><a href="https://github.com/ameerj">epicboy</a> changed how <code>Asynchronous Shaders</code> <a href="https://github.com/yuzu-emu/yuzu/pull/4865">determines the amount of threads to use,</a> increasing it for higher thread count CPUs. Past the 8 threads mark, one shader thread is added every two CPU threads.</p> <table> <thead> <tr> <th style="text-align:center">CPU Threads</th> <th style="text-align:center">Shader Threads</th> <th>Example CPUs</th> </tr> </thead> <tbody> <tr> <td style="text-align:center">1 - 7</td> <td style="text-align:center">1</td> <td>R3 3200G, i5-9400</td> </tr> <tr> <td style="text-align:center">8</td> <td style="text-align:center">2</td> <td>R3 3100, i3-10100</td> </tr> <tr> <td style="text-align:center">12</td> <td style="text-align:center">4</td> <td>R5 3600, i5-10400</td> </tr> <tr> <td style="text-align:center">16</td> <td style="text-align:center">6</td> <td>R7 3700X, i7-10700K</td> </tr> <tr> <td style="text-align:center">32</td> <td style="text-align:center">14</td> <td>R9 3950X, i9-9960X</td> </tr> <tr> <td style="text-align:center">128</td> <td style="text-align:center">62</td> <td>Threadripper 3990X</td> </tr> </tbody> </table> <p><a href="https://github.com/Kewlan">Kewlan</a> is back again, fixing another important UI bug. This time, yuzu will <a href="https://github.com/yuzu-emu/yuzu/pull/4817">no longer ask for a profile if there is a single one created.</a> The devil is in the details.</p> <p><a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4785">added a check to see if a directory is a <code>nullptr</code>.</a> This fixes save file creation in <code>Hades</code>. However, more work is needed to get the game playable.</p> <p>With the demo just released, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> started the work to get <code>Hyrule Warriors: Age of Calamity - Demo Version</code> playable. By implementing <a href="https://github.com/yuzu-emu/yuzu/pull/4853">FCMP immediate</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/4854">texture CUBE array shadows</a> the game starts to render.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./aoc.png" title=" Where are my glasses? (Hyrule Warriors: Age of Calamity - Demo Version)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/aoc_hu1b4f8eed53d262bb47871bb8232555e8_4320994_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Where are my glasses? (Hyrule Warriors: Age of Calamity - Demo Version)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Where are my glasses? (Hyrule Warriors: Age of Calamity - Demo Version)</p> </div> </div> <p> </p> <p>We personally want to thank <a href="https://github.com/lioncash">Lioncache.</a> He&rsquo;s not mentioned much in the progress reports due to the technical nature of his work, but he is without a doubt one of the top contributors to the project. Thank you Lion, for the patience you have, and the huge help you give us.</p> <h2 id="future-changes">Future changes</h2> <p>There are some important core fixes incoming: <code>Local Wireless</code> emulation continues to progress well, we have more plans for <code>NVDEC</code> progress on their way, and there is now a roadmap of what will follow the <code>Texture Cache Rewrite</code> once it&rsquo;s finished, but we will tell you more about that later.</p> <p>As an early gift, here&rsquo;s a preview of the Texture Cache Rewrite&rsquo;s progress:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tcr.png" title=" "> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/tcr_hu4edd1fc0f06fd862b764a407c20b2fe8_1277266_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" "></a> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <p>And that&rsquo;s all folks! Thank you so much for reading, and see you all in the next progress report! Thanks GG for the pics!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./burgy.png" title=" Image by https://twitter.com/JamesTurner_42"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-oct-2020/burgy_hu0d414d3d2a23737df3eb18fbe11e286b_32552_128x0_resize_q90_bgffffff_box_3.jpg" alt=" Image by https://twitter.com/JamesTurner_42"></a> <p class="has-text-centered is-italic has-text-grey-light"> Image by https://twitter.com/JamesTurner_42</p> </div> </div> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Online Support Removed https://yuzu-mirror.github.io/entry/yuzu-x-raptor/ Mon, 02 Nov 2020 18:00:00 -0800 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-x-raptor/ <p>We are saddened to report that we have removed online support from yuzu, indefinitely, and effective immediately. We apologize to our community for the confusion and disappointment surrounding this release, and especially to those who were excited to try this feature.</p> <p>We are saddened to report that we have removed online support from yuzu, indefinitely, and effective immediately. We apologize to our community for the confusion and disappointment surrounding this release, and especially to those who were excited to try this feature.</p> <p>We have received valid and insightful feedback from our fans and members of the broader Switch and emulation communities. Truthfully, we are all just a bunch of enthusiastic people from around the globe, who were genuinely excited about something we thought we could offer. In hindsight, we 100% understand your concerns.</p> <p>As always, we will continue working on other features and improvements within yuzu, to make it the best emulator we possibly can. Thank you to everyone who has continued to support us, provided us feedback and been open to constructive discussion on this topic. Now, as always, we value your opinions.</p> <p>– The yuzu development team</p> Progress Report September 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2020/ Wed, 30 Sep 2020 12:00:00 -0300 Honghoa https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2020/ <p>Greetings yuz-ers! Welcome to September&rsquo;s progress report. This month we offer you the joy of motion, video playback, more input fixes and additions, small Vulkan improvements, and the initial groundwork needed to get Super Mario 3D All-Stars playable.</p> <p>Greetings yuz-ers! Welcome to September&rsquo;s progress report. This month we offer you the joy of motion, video playback, more input fixes and additions, small Vulkan improvements, and the initial groundwork needed to get Super Mario 3D All-Stars playable.</p> <h2 id="ya-like-to-move-it">Ya like to (move it!)</h2> <p>Many popular Nintendo Switch titles have mechanics designed with motion controls in mind, so naturally this was a long-awaited feature that a lot of people wanted to see implemented in yuzu. We are very happy to announce that, thanks to the efforts of the developer <a href="https://github.com/german77">german77</a>, it is now possible to <a href="https://github.com/yuzu-emu/yuzu/pull/4594">use any controller that supports motion sensing</a> and play these games the way they were meant to be played. Just be careful not to hit anything when you shake it!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./motion1.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Functional Motion Input (&#39;A SixAxis tester by German77&#39;, a homebrew application).</p> </div> </div> <p>This feature&rsquo;s development began back in July, when german77 was working on the implementation of a <a href="https://github.com/yuzu-emu/yuzu/pull/4411">native Joy-Con adapter for yuzu</a> (a task still in the works). While he was analyzing the data sent by the controllers, he realized he could read the values reported by the accelerometer and the gyroscope as well. Feeling curious about what could be done with this knowledge, he experimented with implementing new inputs and feeding them the output from these sensors. The result was quite satisfactory: not only did this work, but it became the main motivation to investigate and implement motion controls the same way they work on the Switch.</p> <p>german77 was aware of a previously discontinued <a href="https://github.com/yuzu-emu/yuzu/pull/3882">PR for motion</a> by <a href="https://github.com/anirudhb">anirudhb</a> and decided the best course of action would be to take it from there, fix any incompatibilities, and sort out the subsequent bugs introduced. As he ironed out the implementation, he tested how it performed with the game <code>Captain Toad: Treasure Tracker</code>. The results this time, however, were far from satisfactory. Controls felt unnatural and responded quite differently compared to the Switch, indicating an error in how the values sent by the controllers were processed. To better understand the problem, german77 developed two homebrew applications to identify and fix these inaccuracies.</p> <p>After a long period of extensive testing, and with the help of <a href="https://github.com/theboy181">theboy181</a> (who focused on testing the feature on different games), german77 finally realized the problem laid in the implementation&rsquo;s logic: there was an error transforming a <a href="https://en.wikipedia.org/wiki/Quaternion">quaternion</a> into a <a href="https://en.wikipedia.org/wiki/Rotation_matrix">rotation matrix</a>. For the people allergic to math, you can think of a quaternion as a system to describe orientations and rotations in a 3D space, and a rotation matrix as a &ldquo;translation&rdquo; from a quaternion to a familiar (x, y, z) Cartesian coordinate. Thankfully, once this error was fixed, almost all the games that showed problems started to work flawlessly!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./motion2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> </p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./motion3.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Motion in action. Top: &#39;Super Mario Odyssey&#39;, bottom: &#39;The Legend of Zelda: Breath of the Wild&#39;.</p> </div> </div> <p>Motion controls currently work with Wiimotes, Joy-Cons, Pro Controllers, DualShock 4 Wireless Controllers, and even cellphones (provided they have an accelerometer and a gyroscope). To bridge these devices to yuzu, the implementation makes use of the DSU protocol (also known as &ldquo;CemuHook UDP&rdquo;), so users need to utilize <a href="https://github.com/Davidobot/BetterJoy">BetterJoy</a> (for Nintendo controllers), <a href="http://ds4windows.com/">ds4windows</a> (for Sony controllers), or any app that supports CemuHook for cellphones or other compatible devices. You can check <a href="https://wiki.cemu.info/wiki/Motion_Controls">this guide</a> for more information regarding how to set up your controller. Make sure to try it out!</p> <p>Bear in mind that devices such as generic copies of official Nintendo or Sony controllers may work, although it&rsquo;s not guaranteed. Needless to say, no matter how hard you shake your keyboard and mouse, that&rsquo;s not going to work, so please don&rsquo;t do it!</p> <h2 id="i-have-no-motion-and-i-must-shake">I have no motion, and I must shake</h2> <p>If your favorite controller has no support for motion controls (such as Xbox controllers), don&rsquo;t worry, not everything is lost. After implementing functional motion controls, <a href="https://github.com/german77">german77</a> also made this follow-up PR to <a href="https://github.com/yuzu-emu/yuzu/pull/4677">implement a button to simulate a shake</a>. This will allow you to configure any key of your liking to work as if you were physically swinging your controller and activating the in-game motion mechanics.</p> <p>While this should work with games such as <code>Super Mario Odyssey</code> and others, do note it won&rsquo;t be able to cover all cases or titles. Every game is different, and the required input is not always just a shake.</p> <h2 id="remember-the-rumble-pak">Remember the Rumble Pak?</h2> <p>Also thanks to <a href="https://github.com/german77">german77</a>, yuzu can now proudly boast <a href="https://github.com/yuzu-emu/yuzu/pull/4291">Rumble support</a>. Any SDL2 compatible device will vibrate when asked by your Switch games. This includes but is not limited to: DualShock, Xbox, and Nintendo controllers.</p> <p>HD Rumble is not possible, yet. The SDL2 specification is incompatible, and not everyone will play with Nintendo peripherals. This means that a Pro Controller or a pair of Joy-Cons cannot reach the same level of precision as the Switch. Additionally, some games seem to use different ways to ask for rumble and are not supported yet. We are investigating this.</p> <p>Soon, german77 has plans to add native Joy-Con pairing support. This will allow for real HD Rumble compatibility.</p> <h2 id="video-decoding-or-how-to-suffer-for-so-long-with-a-single-codec">Video decoding, or how to suffer for so long with a single codec</h2> <p>It&rsquo;s finally here! After such a long wait, and thanks to the work from <a href="https://github.com/ogniK5377">ogniK</a> and <a href="https://github.com/ameerj">epicboy</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/4729">yuzu can now play videos in-game!</a> For now, only <code>H.264</code> and <code>VP9</code> videos are supported, which thankfully seems to cover all released games until now. Support for <code>H.265</code> and <code>VP8</code> will come later.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./mk8.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Video Killed the Radio Star (Mario Kart 8 Deluxe)</p> </div> </div> <p>This is possible by using <a href="https://ffmpeg.org/">FFmpeg.</a> For now, decoding happens in a single CPU thread, and support for multiple threads and GPU decoding is currently being worked on.</p> <p>We have an entire article dedicated to showing how this feature came to be, how it works, its challenges, and current limitations in more detail <a href="https://yuzu-mirror.github.io/entry/yuzu-nvdec-emulation/">here.</a> Please take your time to read it: it also includes a list of games confirmed working and not-so-working yet.</p> <h2 id="an-emulator-inside-an-emulator">An emulator inside an emulator</h2> <p><code>Super Mario 3D All-Stars</code> is a special case in several aspects. For starters, the game is just a container for several other binary executables (known as <code>Program NCAs</code>), each one with their own Title ID. Step one to get this game to boot is <a href="https://github.com/yuzu-emu/yuzu/pull/4675">to correctly handle these multi-content games</a>, a job <a href="https://github.com/Morph1984">Morph</a> did.</p> <p>Good, finished, right? Wrong. Turns out, handling several integrated programs with different title IDs will make XCI game dumps conflict, as they include games and even firmware updates to account for users without internet access. <a href="https://github.com/Morph1984">Morph</a> also <a href="https://github.com/yuzu-emu/yuzu/pull/4710">had to add checks for cases like this.</a></p> <p>Next step, unimplemented functions. <a href="https://github.com/Morph1984">Morph</a> did a <a href="https://github.com/yuzu-emu/yuzu/pull/4678">partial implementation of <code>LoadOpenContext</code></a>, a function that several collections games use. Some examples are <code>Clubhouse Games: 51 Worldwide Classics</code>, <code>Grandia HD Collection</code>, <code>XCOM 2 Collection</code>, <code>Baldur's Gate I and II</code>, <code>Dr Kawashima's Brain Training</code>, and of course <code>Super Mario 3D All-Stars</code>.</p> <p>Similarly, <a href="https://github.com/yuzu-emu/yuzu/pull/4676"><code>GetPreviousProgramIndex</code> needed to be stubbed</a>. The result is getting the game-selector/menu working.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./menu.png" title=" For now, just the menu and soundtrack sections! (Super Mario 3D All-Stars)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2020/menu_huc4ea349968606ca682e6c5579c4fa352_3649568_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" For now, just the menu and soundtrack sections! (Super Mario 3D All-Stars)"></a> <p class="has-text-centered is-italic has-text-grey-light"> For now, just the menu and soundtrack sections! (Super Mario 3D All-Stars)</p> </div> </div> <h2 id="vulkan-changes">Vulkan changes</h2> <p><code>VK_KHR_timeline_semaphore</code> is a relatively recent Vulkan extension only supported by <em>desktop or laptop</em> GPUs. In the past, resources were being assigned with <code>VkFence</code> and freed when arbitrarily asked, leading to a possible small pileup. With <code>VK_KHR_timeline_semaphore</code>, each resource is tied to a periodically checked &ldquo;GPU tick,&rdquo; and you only need to verify on which tick you are at the moment to know if that resource is now free.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vk.png" title=" Our implementation is not that complex. This is just an example provided by Khronos"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2020/vk_hu9b4ec87ce1d165ee0384e4e55e2af75c_68977_1006x0_resize_q90_bgffffff_box_3.jpg" alt=" Our implementation is not that complex. This is just an example provided by Khronos"></a> <p class="has-text-centered is-italic has-text-grey-light"> Our implementation is not that complex. This is just an example provided by Khronos</p> </div> </div> <p><a href="https://github.com/yuzu-emu/yuzu/pull/4674">Adding support for timeline semaphores in yuzu</a> helps simplify the code a lot, improves VRAM use a small amount, and paves the way for the finalization of the <code>Texture Cache rewrite</code>. Thank you, <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, for its addition! The result should be transparent for the user with no perceptible change besides a bit of VRAM savings.</p> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p>A missing feature in the input rewrite was the ability to merge two separate single left and right Joy-Cons into a single dual Joy-Con, a function <code>Super Mario Odyssey</code> needs. <a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4629">implemented <code>MergeSingleJoyasDualJoy</code></a>, so this is no longer a problem for Mario. He can return to work once again for nothing. Thirty-nine years and no rewards for the best hero the Mushroom Kingdom ever saw.</p> <p>A small PSA for our Linux users, the <a href="https://github.com/yuzu-emu/yuzu/pull/4638">required Qt version has been raised to <code>5.12.8</code></a> now. Thanks <a href="https://github.com/Morph1984">Morph</a> for the update! We need those new Plasma functions.</p> <p>Users have been reporting input latency, so <a href="https://github.com/FearlessTobi">Tobi</a> decided to <a href="https://github.com/yuzu-emu/yuzu/pull/4643">test some changes</a> and see if the situation improves. To further mitigate this issue if you experience it, be sure to enable <code>Radeon Anti-Lag</code> or <code>Nvidia Ultra-Low Latency</code> in your respective driver control panel. Nothing makes you ragequit more than losing in Smash due to lag.</p> <p><a href="https://github.com/yuzu-emu/yuzu/pull/4618">Gamecube controllers will now be autoconfigured!</a> Thanks to work done by <a href="https://github.com/german77">german77</a>, Gamecube Adapter controllers will show up as devices in the input window, and their buttons will be mapped automatically. Laziness is the best.</p> <p><code>Clubhouse Games: 51 Worldwide Classics</code> now manages to boot and, with a save, load the board games. <a href="https://github.com/Morph1984">Morph</a> managed this by <a href="https://github.com/yuzu-emu/yuzu/pull/4683">implementing the <code>Get/SetNpadHandheldActivationMode</code> functions</a>. However, the game will still render almost everything in black, so don&rsquo;t consider it playable yet.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./51a.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2020/51a_hu449afde6e02898c03be3f1f13c986bb8_122163_800x0_resize_q90_bgffffff_box_3.jpg" alt="Paint it all black (Clubhouse Games: 51 Worldwide Classics)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./51b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-sep-2020/51b_hua4a12870f859aa635356b119d08d1a10_158875_800x0_resize_q90_bgffffff_box_3.jpg" alt="Paint it all black (Clubhouse Games: 51 Worldwide Classics)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Paint it all black (Clubhouse Games: 51 Worldwide Classics)</p> <p>If you ran a game in fullscreen and a pop-up needed to display (for example, naming a character), it used to render behind the main yuzu window, forcing you to exit fullscreen, focus the pop-up, complete the action, and then continue with your game. Quite annoying indeed. <a href="https://github.com/Morph1984">Morph</a> is our savior for this one, by <a href="https://github.com/yuzu-emu/yuzu/pull/4728">using the <code>Qt::WindowStaysOnTopHint</code> flag</a>, the pop-ups will now display on top of your game. Thanks a lot, poyo.</p> <h2 id="gpu-vendor-specific-fixes-and-changes">GPU vendor specific fixes and changes</h2> <p>Recent Nvidia Geforce drivers (past the 446.14 version) introduced a performance regression mainly affecting <code>Paper Mario: The Origami King</code> and <code>Super Smash Bros. Ultimate's</code> menus, important enough that we had to recommend our users to stay on older driver versions until we could figure out what was going on. Turns out, the new drivers don&rsquo;t seem to like how Qt handles VSync, so <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed it by <a href="https://github.com/yuzu-emu/yuzu/pull/4692">calling <code>SwapBuffers</code> from the emulation thread</a>. This change means that Nvidia users are free to use the latest driver version without fearing low framerates.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./SSBU-broken.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./SSBU-fixed.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Just in time for Ampere, eh! Good luck getting one for now (Super Smash Bros. Ultimate)</p> <p>As mentioned in <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/">July&rsquo;s progress report</a>, <a href="https://github.com/lat9nq">toastUnlimited</a> continued to work on solving crashes only experienced with recent Nvidia Vulkan drivers in Linux. Thanks to work done by DXVK, <a href="https://github.com/yuzu-emu/yuzu/pull/4724">toast&rsquo;s current implementation aims to be global</a>, and so far we haven&rsquo;t got any report on getting the issue or any sort of regression. Please feel free to contact us if you are still affected by this issue.</p> <p>Not a fix in yuzu&rsquo;s code, but in fact a fix AMD implemented in their drivers. As mentioned in the previous <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/">August progress report</a>, <code>VK_EXT_extended_dynamic_state</code> was giving problems on the AMD Vulkan Windows driver. This has been fixed in the latest 20.9.2 driver version, allowing <a href="https://github.com/goldenx86">yours truly</a> to <a href="https://github.com/yuzu-emu/yuzu/pull/4735">remove the previously needed blacklisting.</a> No more nightmares when playing <code>Super Mario Odyssey</code>.</p> <h2 id="future-projects">Future projects</h2> <p>Not much information can be given right now, but you all should know that <a href="https://www.youtube.com/watch?v=zHalXjs0cDA">Raptor</a> is advancing at a very impressive speed. Our devs are so preoccupied with whether they can, they don&rsquo;t stop to think if they should.</p> <p>That&rsquo;s all she wrote, folks! See you next time in the October progress report!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - NVDEC emulation! https://yuzu-mirror.github.io/entry/yuzu-nvdec-emulation/ Tue, 29 Sep 2020 23:20:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-nvdec-emulation/ <p>Hello, yuzu fans! Tired of broken cutscenes and having to mash your controller buttons in hopes of skipping them? Well, look no further! Thanks to the efforts of <a href="https://github.com/ameerj">epicboy</a>, yuzu can now play (most of) your favorite in-game cutscene videos. Jump right in to find out more!</p> <p>Hello, yuzu fans! Tired of broken cutscenes and having to mash your controller buttons in hopes of skipping them? Well, look no further! Thanks to the efforts of <a href="https://github.com/ameerj">epicboy</a>, yuzu can now play (most of) your favorite in-game cutscene videos. Jump right in to find out more!</p> <p>  <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/usvAZosD16o" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> </p> <h1 id="nvdec---what-is-it">NVDEC - What is it?</h1> <p>For a long time, one of the most noticeable missing features of yuzu was support for NVDEC. <br> What is <a href="https://en.wikipedia.org/wiki/Nvidia_NVDEC">NVDEC</a>? NVDEC stands for <strong>Nvidia Video Decoder</strong> and is a feature in Nvidia GPUs that performs video decoding. And since the Switch has an Nvidia Tegra X1 SoC, it too makes use of its NVDEC module to offload all CPU intensive video decoding tasks to the GPU.</p> <p>NVDEC supports video codecs like <code>MPEG-2</code>, <code>VC-1</code>, <code>H.264 (AVC)</code>, <code>H.265 (HEVC)</code>, <code>VP8</code>, and <code>VP9</code>, but Nintendo only exposes <code>H.264</code>, <code>H.265</code>, <code>VP8</code> and <code>VP9</code>. Most games seem to use <code>H.264</code> because of its wide support and efficiency ratio. But many first party games are known to use <code>VP9</code> too - eg. Super Smash Bros. Ultimate, Pokémon: Let&rsquo;s Go, Pikachu/Eevee!</p> <p>With NVDEC support, users no longer have to rely on old save files or crazy button mashing to bypass broken cutscenes. Grab the latest yuzu Early Access build to try it out now!</p> <p>  <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/XsXpxZE2rcc" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div>  </p> <h1 id="development">Development</h1> <p>The Switch uses NVDEC along with VIC (Video Image Composer) in the GPU for video decoding. Games are exposed to higher level APIs by Nintendo which abstract the configuration of these modules.</p> <p>NVDEC and VIC work together to decode incoming videos and the process usually goes like this:</p> <pre><code>- Allocate memory - Place encoded video frame data in known memory location - Decode and place frame data into GPU memory - Clear intermediary allocated memory </code></pre> <p>Although this seems fairly simple, implementing it was quite the task. <a href="https://github.com/ameerj">epicboy</a> began working on this by implementing the service/command calls to NVDEC and VIC. It was decided to use the <a href="https://github.com/FFmpeg/FFmpeg">FFmpeg</a> library to decode the frame data once we knew its codec (<code>H.264</code> or <code>VP9</code>).</p> <p>  <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/EGDodmeKGWY" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div>  </p> <h3 id="vp9">VP9</h3> <p><code>VP9</code> was the biggest challenge as its decoding required knowledge on the different attributes of a specific frame. Each frame carries two headers and raw frame data with it. The headers contain the information as to which previous frame the current frame refers to or depends on. Frames usually refer to previously decoded frames, along with transformations to be done on various parts of those, to compose new frames. This is done in an effort to reduce the memory footprint of each frame.</p> <p>Here is where things got complicated. On the Switch, these headers are parsed by the Nvidia library in the games; therefore, NVDEC never receives this data. But for us to decode the frames using FFmpeg, we need to provide it with the full frame - Two headers and raw frame data from NVDEC. And since NVDEC hardware doesn&rsquo;t expose all of the data of the two <code>VP9</code> headers, <a href="https://github.com/ameerj">epicboy</a> had to manually compose these headers from the provided information.</p> <p><a href="https://github.com/ameerj">epicboy</a> took an interesting approach to this problem - he buffered two frames in advance. As the frame data from NVDEC holds some data on previous frames, knowing two frames in advance was useful. But this wasn&rsquo;t sufficient as a few games resulted in issues with this approach. We are currently researching these edge cases to properly fix it for all games.</p> <p>  <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/xHYYntEB05o" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div>  </p> <h3 id="h264">H.264</h3> <p><code>H.264</code> was relatively easier compared to <code>VP9</code>. Each <code>H.264</code> frame contains two headers and raw frame data with it. Unlike <code>VP9</code>, <code>H.264</code> doesn&rsquo;t have different headers for each frame but has same headers for entire video.</p> <p><a href="https://github.com/ogniK5377">ogniK</a> had, long ago, already implemented <code>H.264</code> support in his experimental branch. <a href="https://github.com/ameerj">epicboy</a> based his work off of <a href="https://github.com/ogniK5377">ogniK</a>&rsquo;s and fixed a bug in it which caused distorted videos. It turned out that <a href="https://github.com/ogniK5377">ogniK</a> was using incorrect dimensions when writing the pixel location.</p> <p>Currently NVDEC operations are synchronous, but are asynchronous compatible. This means that in the future, NVDEC operations can be made asynchronous thus yielding even better performance. Also, thanks to the FFmpeg library, we have access to hardware acceleration for faster decoding. And in the future, this will allow yuzu to offload video decoding to the host GPU (user&rsquo;s GPU).</p> <p>  <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/ImXim7BXl0E" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div>  </p> <h3 id="vp8--h265">VP8 &amp; H.265</h3> <p>The Switch officially supports <code>VP8</code> and <code>H.265</code> too, along with <code>VP9</code> and <code>H.264</code>. However, we are yet to see games make use of these codecs for in-game videos and hence support for these codecs remains unimplemented for now.</p> <h1 id="testing">Testing</h1> <p>As development work progressed, there were a lot of challenges and issues with games. <strong>Link&rsquo;s Awakening</strong>, for example, wasn&rsquo;t providing the proper memory locations to write frame data to and the NVDEC/VIC service/command calls were inaccurate as well. This led to data corruption when we wrote frame data to wrong memory locations.</p> <p>  <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/4Lz1NqZsYlA" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div>  </p> <p><a href="https://github.com/ameerj">epicboy</a> and our testers spent tens of hours testing various games in yuzu to make sure any minor issues were ironed out. This rigorous testing also brought to our attention more games that exhibit weird edge cases. Over the next couple of weeks, we plan to fix these bugs and make our decoding even more accurate.</p> <p>Huge shoutout to our testers for testing and compiling these lists.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Games that work</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p>The following games were tested by our team and work well with minor occasional glitches:</p> <ul> <li>1-2-Switch</li> <li>AI: The Somnium Files</li> <li>Animal Crossing: New Horizons</li> <li>Attack on Titan 2</li> <li>Atelier Ryza: Ever Darkness &amp; the Secret Hideout</li> <li>Bloodstained: Ritual of the Night</li> <li>Bulletstorm</li> <li>Children of Morta</li> <li>Dark Souls Remastered</li> <li>Deadly Premonition Origins</li> <li>Devil May Cry</li> <li>Devil May Cry 2</li> <li>Devil May Cry 3</li> <li>Disgaea 5 Complete</li> <li>Donkey Kong Country: Tropical Freeze</li> <li>Dragon&rsquo;s Dogma</li> <li>Dragon Quest Builders</li> <li>Dragon Quest XI:S</li> <li>Dragons: Dawn Of New Riders</li> <li>Fairy Tail</li> <li>Final Fantasy IX</li> <li>Fire Emblem: Three Houses</li> <li>Fire Emblem Warriors</li> <li>Go Vacation</li> <li>Hollow Knight</li> <li>Huntdown</li> <li>Hyrule Warriors: Definitive Edition</li> <li>Indivisible</li> <li>Just Dance 2020</li> <li>Kirby Star Allies</li> <li>LEGO City Undercover</li> <li>Mario Kart 8 Deluxe</li> <li>Marvel Ultimate Alliance</li> <li>Monster Boy and the Cursed Kingdom</li> <li>ŌKAMI HD</li> <li>Paper Mario: The Origami King</li> <li>Pokkén Tournament DX</li> <li>Psyvariar Delta</li> <li>Resident Evil</li> <li>Resident Evil 0</li> <li>Resident Evil 4</li> <li>Resident Evil 5</li> <li>Resident Evil 6</li> <li>Resident Evil Revelations</li> <li>Resident Evil Revelations 2</li> <li>Ring Fit Adventure</li> <li>Rune Factory 4 Special</li> <li>Shantae and the Seven Sirens</li> <li>Star Ocean First Departure R</li> <li>Steins;Gate Elite</li> <li>Super Mario 3D All-Stars</li> <li>Super Mario Odyssey</li> <li>Super Smash Bros. Ultimate</li> <li>TLOZ - Breath of the Wild</li> <li>Tokyo Mirage Sessions #FE Encore</li> <li>Trials of Mana</li> <li>Xenoblade Chronicles Definitive Edition</li> <li>Yu-Gi-Oh: Legacy of the Duelist</li> </ul> </div> </article> <article class="message"> <div class="message-header is-dropdown"> <p>Games with known issues</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p>The following games are known to have issues, and we are actively working on fixing them:</p> <ul> <li>Alien: Isolation</li> <li>Ni no Kuni: Wrath of the White Witch</li> <li>Onimusha: Warlords</li> <li>Persona 5 Scramble</li> <li>Resident Evil 0</li> <li>TLOZ: Link&rsquo;s Awakening</li> <li>The Legend of Heroes: Trails of Cold Steel III</li> <li>Final Fantasy VIII Remastered</li> <li>Pokémon Let&rsquo;s Go</li> <li>Pokémon Sword</li> </ul> </div> </article> <h1 id="fin">Fin</h1> <p>As always, we would like to remind users that the features released on Early Access are still being worked on. Hence not all games might behave in the way we want them to. If you come across more games (other than the ones mentioned above) that encounter bugs or issues, feel free to reach out to us on our <a href="https://discord.com/invite/u77vRWY">Discord server</a> and share your findings.</p> <p>See you next time, <br> - yuzu development team!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report August 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/ Sun, 30 Aug 2020 12:00:00 -0300 flamboyant_ham https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/ <p><a href="https://www.youtube.com/watch?v=s28a3nVHCLo">Yahallo</a> yuz-ers! We hope you are doing well. This monthly report has a few critical topics to cover. Yet another major rewrite is done, some graphical bugs are fixed, the UI is further refined, and ghosts from our past are expelled. Here we go!</p> <p><a href="https://www.youtube.com/watch?v=s28a3nVHCLo">Yahallo</a> yuz-ers! We hope you are doing well. This monthly report has a few critical topics to cover. Yet another major rewrite is done, some graphical bugs are fixed, the UI is further refined, and ghosts from our past are expelled. Here we go!</p> <h2 id="project-mjölnir">Project Mjölnir</h2> <h3 id="part-1---input-rewrite">Part 1 - Input Rewrite</h3> <p>Let&rsquo;s start with the biggest change. One of yuzu&rsquo;s weakest aspects was its input support. It was riddled with bugs, not very intuitive, and lacked several critical features. Earlier this year, <a href="https://github.com/jroweboy">jroweboy</a> and <a href="https://github.com/Its-Rei">Rei</a> decided to start working on what would end up a complete rewrite of the input UI and its internal workings, dubbed <code>Project Aphrodite</code>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./oldinput.png" title=" Never gonna give you up"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/oldinput_huac776aa75bbe8a9c6284a2d763f8fe45_16651_402x0_resize_q90_bgffffff_box_3.jpg" alt=" Never gonna give you up"></a> <p class="has-text-centered is-italic has-text-grey-light"> Never gonna give you up</p> </div> </div> <p>As you can see in the following images, the original draft lacked some of the features we have working right now and some that we plan to add in the future. No code is ever complete, better ideas and new implementations can always be achieved. So that&rsquo;s exactly what happened, Rei continued to iterate on the concept design that is inspired by <a href="https://github.com/RPCS3/rpcs3">RPCS3&rsquo;s</a> controller UI.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./concept.png" title=" The first draft, in all its glory"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/concept_hu317c07a073a3eb14c24c64d838270ad8_137086_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" The first draft, in all its glory"></a> <p class="has-text-centered is-italic has-text-grey-light"> The first draft, in all its glory</p> </div> </div> <p>With this concept in mind, jroweboy implemented an automapping feature which correctly maps all the inputs upon selecting an input device.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./automap.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Finally, no more spending hours mapping controls!</p> </div> </div> <p>Since jroweboy&rsquo;s departure from emulator development, <a href="https://github.com/Morph1984">Morph</a> continued his legacy and picked up where he left off, not wanting to have all this work go to waste. With renewed hope, both Morph and Rei have taken the reins and are continuously refining the UI to achieve the best user experience possible. Their efforts have culminated in the UI we have today.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./light.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/light_hub11f8a5bdd4e035499395f7b367d8e78_68473_800x0_resize_q90_bgffffff_box_3.jpg" alt="The fruits of our labor, the triforce of themes is complete!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./dark.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/dark_hufba4d97bf10ab1b481899c3aab01ca6d_74841_800x0_resize_q90_bgffffff_box_3.jpg" alt="The fruits of our labor, the triforce of themes is complete!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./midnightblue.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/midnightblue_hu6a4f3f57668abe15217cf9406d0a02bd_81625_800x0_resize_q90_bgffffff_box_3.jpg" alt="The fruits of our labor, the triforce of themes is complete!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The fruits of our labor, the triforce of themes is complete!</p> <p>The user experience would not be complete unless a <a href="https://github.com/yuzu-emu/yuzu/issues/2906">long standing issue where updating controllers in the UI will not update them in game</a> is fixed. Knowing this, Morph decided to find out what is causing this issue and fix it along with the UI changes. With some guidance from the shark <a href="https://github.com/ogniK5377">ogniK</a>, he discovered that 1. The frontend was not signalling to the backend when a controller changes configuration and 2. <code>StyleSetChangedEvents</code> were not being signalled on a controller change. By fixing these two issues, he managed to fix input issues in a wide array of games and allowed users to change their controller and input devices while in game without needing to restart yuzu.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./controllerselect.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Smash players rejoice!</p> </div> </div> <p>The games that demonstrated the most benefit from these fixes are <code>Pokemon Let's Go: Pikachu</code> and <code>Pokemon Let's Go: Eevee</code>, as single joycons can now be properly detected in game, bringing us one step closer to hardware accuracy.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./plgjoycon.png" title=" Professor Oak! Input is now in working order!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/plgjoycon_hu8dd131a9d55dd5193bc0f12b056af319_715365_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Professor Oak! Input is now in working order!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Professor Oak! Input is now in working order!</p> </div> </div> <h3 id="part-2---controller-applet">Part 2 - Controller Applet</h3> <p>Morph began on <a href="https://github.com/yuzu-emu/yuzu/pull/4597">Part 2</a> knowing that yuzu lacked an implementation of a Controller Applet, which is crucial for a lot of multiplayer games such as <code>Super Mario Maker 2</code>, <code>Kirby Star Allies</code>, <code>Hyrule Warriors: Definitive Edition</code> and many more. It had previously been <a href="https://github.com/yuzu-emu/yuzu/pull/1940">attempted</a> by <a href="https://github.com/DarkLordZach">DarkLordZach</a> but was riddled with issues due to the immature input implementation at the time. Therefore, Morph decided that it was time to implement it after gaining knowledge of and fixing HID in <a href="https://github.com/yuzu-emu/yuzu/pull/4530">Part 1</a>.</p> <p>While Morph was completing the backend implementation of the applet, Rei was designing the UI that was inspired by DarkLordZach&rsquo;s initial implementation, with an error box showing all the issues with the current controller configuration as shown.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./firstapplet.png" title=" The very first concept of the Controller Applet inspired by DarkLordZach&#39;s initial implementation"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/firstapplet_hu429f9128a53ee58f934d4302edc2013a_30690_429x0_resize_q90_bgffffff_box_3.jpg" alt=" The very first concept of the Controller Applet inspired by DarkLordZach&#39;s initial implementation"></a> <p class="has-text-centered is-italic has-text-grey-light"> The very first concept of the Controller Applet inspired by DarkLordZach&#39;s initial implementation</p> </div> </div> <p>After taking a look at this first concept, they decided that it wasn&rsquo;t very intuitive for the user. One morning, as Morph was about to finish the backend implementation, <a href="https://github.com/Its-Rei">Rei</a> had an epiphany to replicate the Switch&rsquo;s native UI for the <code>Controller Applet</code> and whipped up the concept design you see below:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./secondapplet.png" title=" The one that started it all"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/secondapplet_hue87b2dc649a879ee2eeadaae57336395_55679_852x0_resize_q90_bgffffff_box_3.jpg" alt=" The one that started it all"></a> <p class="has-text-centered is-italic has-text-grey-light"> The one that started it all</p> </div> </div> <p>As you can see, this was much closer to the design we have now, but was lacking some features such as the number of supported controllers, LED pattern, border color, and explain text. Wanting to get as close to the Switch&rsquo;s design as possible, Morph implemented these features one by one, and the frontend UI was adapted by Rei to include these features, bringing us to the final design we have now.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./supportedplayers.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/supportedplayers_hu95e0e689b9d348b6411e866150343d34_46503_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column is-bottom-paddingless"> <a href="./ledpatterns.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/ledpatterns_hucbfbd3aa669ad5189c086f21b133a127_67097_800x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bordercolor.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/bordercolor_hu5829a1639729c7fd792b703e13d76c8f_30514_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s all coming together now"></a> </div> <div class="column is-bottom-paddingless"> <a href="./explaintext.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/explaintext_hufa0243c3b409c757204d36a4dd6dfa6f_36477_800x0_resize_q90_bgffffff_box_3.jpg" alt="It&#39;s all coming together now"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">It&#39;s all coming together now</p> <p>As the design was now complete, Morph hooked up all of these features from the backend to the frontend and produced these clean and pretty results!</p> <p>Below are comparisons between the Nintendo Switch&rsquo;s and yuzu&rsquo;s Controller Applets:</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mariokart8deluxe-switch.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/mariokart8deluxe-switch_huf0d9286e767b5fbd90360b1f690819e6_634740_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mariokart8deluxe-yuzu.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/mariokart8deluxe-yuzu_hu140f144cd3481949765887021a123481_973312_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Kart 8 Deluxe"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mario Kart 8 Deluxe</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kirbystarallies-switch.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/kirbystarallies-switch_hua797bc24ba1b5d3ebb115aaa828596f1_362296_800x0_resize_q90_bgffffff_box_3.jpg" alt="Kirby Star Allies"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kirbystarallies-yuzu.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/kirbystarallies-yuzu_huc0b5078c892bbe16104f5ee6d222a0f6_349246_800x0_resize_q90_bgffffff_box_3.jpg" alt="Kirby Star Allies"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Kirby Star Allies</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smm2-switch.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/smm2-switch_hu11e66a375114d406580736546aead0d5_394708_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Maker 2"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smm2-yuzu.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/smm2-yuzu_hu38418bc988ae78b07679e30958d70dba_161034_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Maker 2"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Maker 2</p> <h3 id="there-is-still-more-to-come">There is still more to come!</h3> <p>There is always room for improvement, keep your eyes peeled for future additions and features!</p> <p>As we cannot fit in all the changes present in both parts, our more tech savvy users can read about all the changes in the following PRs: <a href="https://github.com/yuzu-emu/yuzu/pull/4530">[Mjölnir Part 1]</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/4597">[Mjölnir Part 2]</a>.</p> <h2 id="bugfixes-and-improvements">Bugfixes and improvements</h2> <p><a href="https://www.khronos.org/">Khronos</a> recently added the new <code>VK_EXT_extended_dynamic_state</code> extension to the Vulkan API, and driver support is slowly being completed by the vendors. Per the norm with newly supported extensions, you can expect stuff to be in a <em>non-perfect</em> state, or as we like to say, &ldquo;Expect Dragons.&rdquo; AMD recently added support for this extension in the 20.8.3 Windows driver, but part of it is glitched, resulting in graphical errors in games like <code>Super Mario Odyssey</code>. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> temporarily solved this by <a href="https://github.com/yuzu-emu/yuzu/pull/4599">blacklisting the extension on the AMD Windows drivers until it is fixed</a>. Intel doesn&rsquo;t support <code>VK_EXT_extended_dynamic_state</code> at the time of writing this, and Nvidia had already fixed their issues with the extension.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smobug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/smobug_hu29d76e0c715b33afd6b9e504c7eb35d9_2019254_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario stared into the abyss, and the abyss stared back (Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smofix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/smofix_hu92d4ae83699bc956b8c57e242e8352f0_1963968_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mario stared into the abyss, and the abyss stared back (Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mario stared into the abyss, and the abyss stared back (Super Mario Odyssey)</p> <p>Continuing with <code>VK_EXT_extended_dynamic_state</code>, a glitch affecting <code>Super Smash Bros. Ultimate</code>, and others, was discovered when using this new extension. Attack sprites were missing during gameplay, but <a href="https://github.com/ReinUsesLisp">Rodrigo</a> was able to <a href="https://github.com/yuzu-emu/yuzu/pull/4555">solve the issue on all compatible drivers</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smashbug.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./smashfix.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Master Sword can&#39;t just look like a regular sword (Super Smash Bros. Ultimate)</p> <p>Thumbnail pictures in in-game save slots were a black rectangle for most games up until now. By <a href="https://github.com/yuzu-emu/yuzu/pull/4453">fixing block linear copies</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> prevented users from loading up the wrong save or course by mistake in games such as <code>The Legend of Zelda: Breath of the Wild</code> and <code>Super Mario Maker 2</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smm2bug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/smm2bug_hu4b2b5525ad852db99ed63b5fd60e203f_155389_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ohh, this one was my good course! (Super Mario Maker 2)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smm2fix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/smm2fix_hu6a2b714de5241d9e6287f4ba3636e3a8_471917_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ohh, this one was my good course! (Super Mario Maker 2)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Ohh, this one was my good course! (Super Mario Maker 2)</p> <h2 id="precision-has-a-cost">Precision has a cost</h2> <p>Up until now, CPUs lacking the FMA instruction set had to run generic code as fallback. After a lot of work, <a href="https://github.com/MerryMage">Merry</a> added <a href="https://github.com/yuzu-emu/yuzu/pull/4541">optimizations intended for CPUs lacking the <code>FMA instruction set</code></a>.</p> <p>This means that users with CPUs from the AMD Phenom II series or older, Intel 3rd generation Core-i series or older, and all Pentium, Celeron and Atom CPUs can now select the &ldquo;Unsafe&rdquo; setting and see major performance improvements in almost all games. Don&rsquo;t bother to try this setting on CPUs that have FMA, as it will not improve your performance in that case.</p> <p>However, due to being a less precise alternative, expect emulation inaccuracies if you decide to enable it. Here be dragons, as they say.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./fma.png" title=" You can find it here"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/fma_huc55a6b6bb383e5106b7b84f50541fb5e_18124_887x0_resize_q90_bgffffff_box_3.jpg" alt=" You can find it here"></a> <p class="has-text-centered is-italic has-text-grey-light"> You can find it here</p> </div> </div> <h2 id="ui-changes">UI Changes</h2> <p>As part of the input rewrite, <a href="https://github.com/Its-Rei">Rei</a> fixed several consistency bugs affecting the <code>Midnight Blue</code> UI theme. You can see the results below.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./input_before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/input_before_huae35c3e4ebf6b3b945d5eb6272e9cbda_107980_800x0_resize_q90_bgffffff_box_3.jpg" alt="Input window fixes, before (left) and after (right)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./input_after.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/input_after_hubc1e2a048c0e0fd36709ef298ea74692_108721_800x0_resize_q90_bgffffff_box_3.jpg" alt="Input window fixes, before (left) and after (right)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Input window fixes, before (left) and after (right)</p> <p> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./main_before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/main_before_hu132fb3f1c52866edb312316c6981b879_74016_800x0_resize_q90_bgffffff_box_3.jpg" alt="Gamelist fixes, before (left) and after (right)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./main_after.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/main_after_hu4d07e450fcd465eecebfe6f8e98db147_61441_800x0_resize_q90_bgffffff_box_3.jpg" alt="Gamelist fixes, before (left) and after (right)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Gamelist fixes, before (left) and after (right)</p> <p>Both of our dark themes (Dark and Midnight Blue) had a transparency bug affecting the per-game settings pop-up window. <a href="https://github.com/lat9nq">toastUnlimited</a> made the necessary changes to fix this by <a href="https://github.com/yuzu-emu/yuzu/pull/4420">setting QLabel background color to transparent</a>. You can see the changes below.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./darkbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/darkbug_hu8d5b89c3bb8baa90072867a0e6e6dc2e_204301_800x0_resize_q90_bgffffff_box_3.jpg" alt="Dark theme, before (left) and after (right)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./darkfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/darkfix_hu8d5b89c3bb8baa90072867a0e6e6dc2e_204610_800x0_resize_q90_bgffffff_box_3.jpg" alt="Dark theme, before (left) and after (right)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Dark theme, before (left) and after (right)</p> <p> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./midnightbug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/midnightbug_hu77c5d9fb6bbc6f4df2a87400cca42e4d_196395_800x0_resize_q90_bgffffff_box_3.jpg" alt="Midnight Blue theme, before (left) and after (right)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./midnightfix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/midnightfix_hu77c5d9fb6bbc6f4df2a87400cca42e4d_196818_800x0_resize_q90_bgffffff_box_3.jpg" alt="Midnight Blue theme, before (left) and after (right)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Midnight Blue theme, before (left) and after (right)</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a> also added an option to <a href="https://github.com/yuzu-emu/yuzu/pull/4515">access game specific settings while playing.</a> This makes it easy to change graphics accuracy or other settings on the fly.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pergame.png" title=" Found it!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-aug-2020/pergame_hu2da4860b6af3545cca95d1f456df4353_1054381_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Found it!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Found it!</p> </div> </div> <p><code>Force 30FPS</code> was an option that was used for debugging, and as an emergency brake for the old days when yuzu lacked a proper frame limiter. The fate of this tick-box was undecided for long, moving it to the <code>Debug</code> tab was considered at one point. But in the end, it was finally <a href="https://github.com/yuzu-emu/yuzu/pull/4446">removed by</a> <a href="https://github.com/Morph1984">Morph</a>. This option was no longer functional after the changes of <code>Project Prometheus</code> took effect, so this was a necessary sacrifice.</p> <p>Our users reported that some checkboxes were duplicated after the addition of Vulkan. These were <code>Dump Decompressed NRO</code> and <code>Dump ExeFS</code> which could be found both in <code>General &gt; Debug</code> and <code>System &gt; Filesystem &gt; Patch Manager</code>. <a href="https://github.com/FearlessTobi">Tobi</a> put an end to this clone war, <a href="https://github.com/yuzu-emu/yuzu/pull/4429">removing the duplicates in Debug</a>.</p> <h2 id="future-projects">Future Projects</h2> <p><a href="https://github.com/ameerj">epicboy</a> is working on a universal, GPGPU (General-Purpose GPU) accelerated method to decode ASTC textures. We shall hear more of this after the Texture Cache rewrite is finished.</p> <p>Whispers of more audio changes have been heard, and a certain shark will be responsible for this.</p> <p><a href="https://www.youtube.com/watch?v=D8zlUUrFK-M">Devs uh&hellip; find a way.</a></p> <p>That&rsquo;s all for now folks! See you again in the September progress report!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report July 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/ Tue, 04 Aug 2020 12:00:00 -0300 Morph https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/ <p>Hey yuz-ers, what is up and welcome back to the… progress report. In this monthly report, we offer you major rewrites to critical components, another successful attack on shader compilation times, tons of game fixes, and the promise of a very bright future ahead. Let’s get started!</p> <p>Hey yuz-ers, what is up and welcome back to the… progress report. In this monthly report, we offer you major rewrites to critical components, another successful attack on shader compilation times, tons of game fixes, and the promise of a very bright future ahead. Let’s get started!</p> <h2 id="paper-mario-the-origami-king-fixes">Paper Mario: The Origami King fixes</h2> <p>To begin with, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> implemented several fixes to make <code>Paper Mario: The Origami King</code> playable:</p> <ul> <li>By <a href="https://github.com/yuzu-emu/yuzu/pull/4359">clamping the host’s compute shared memory limit</a>, the game doesn’t get stuck when trying to start rendering.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./pmm.png" title=" Now in A4 format! (Paper Mario: The Origami King)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/pmm_hu987f401940ede79e0951bed96f6bc4a0_1495468_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Now in A4 format! (Paper Mario: The Origami King)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Now in A4 format! (Paper Mario: The Origami King)</p> </div> </div> <ul> <li>Some graphical artifacts affecting OpenGL can be fixed in GLASM by executing the shader instruction <a href="https://github.com/yuzu-emu/yuzu/pull/4360">BAR inside control flow</a>.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./pmcastlebug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/pmcastlebug_hu827e28dd90285eb2040982dec78946b3_2149990_800x0_resize_q90_bgffffff_box_3.jpg" alt="That is one big sheet of paper! (Paper Mario: The Origami King)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pmcastlefix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/pmcastlefix_hu360cef78d7c65342ef057d3e5bc85944_2829702_800x0_resize_q90_bgffffff_box_3.jpg" alt="That is one big sheet of paper! (Paper Mario: The Origami King)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That is one big sheet of paper! (Paper Mario: The Origami King)</p> <ul> <li>Lighting issues were fixed by <a href="https://github.com/yuzu-emu/yuzu/pull/4361">implementing the S2R.LaneId instruction in the shader decoder</a>.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./pmintrobug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/pmintrobug_hu69a53ee47d310d59a8e4cc0a9d3987d1_544685_800x0_resize_q90_bgffffff_box_3.jpg" alt="Lights, please! (Paper Mario: The Origami King)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pmintrofix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/pmintrofix_hu0ebf7999b3d82f8ee7076669f7436835_2896246_800x0_resize_q90_bgffffff_box_3.jpg" alt="Lights, please! (Paper Mario: The Origami King)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Lights, please! (Paper Mario: The Origami King)</p> <h2 id="new-gpu-virtual-memory-manager">New GPU Virtual Memory Manager</h2> <p><a href="https://github.com/bunnei">bunnei</a> brings the big guns. The complete <a href="https://github.com/yuzu-emu/yuzu/pull/4430">rewrite of the <code>GPU Virtual Memory Manager</code></a> fixes <em>several</em> bugs in many games, with the two strongest examples being <code>Mario Kart 8 Deluxe</code> and <code>Super Smash Bros. Ultimate</code>. Now several graphical bugs are fixed in Mario Kart 8, including tracks that show invisible terrain or missing graphics. In Smash&rsquo;s case, there are no more vertex explosions now.</p> <p>This rewrite also should reduce committed memory a bit, hopefully reducing the size of the required page file, and opens the possibility to implement new features in the future. We have to clarify that this doesn&rsquo;t fix the high VRAM usage in Vulkan.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mk8bug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/mk8bug_hufa8bbb3175015e6912e205fc787d04a5_1735813_800x0_resize_q90_bgffffff_box_3.jpg" alt="That&#39;s not what I meant when I said Anti-Gravity! (Mario Kart 8 Deluxe)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./mk8fix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/mk8fix_huef951a87af1cfe81fd7d29faac0c1242_1593594_800x0_resize_q90_bgffffff_box_3.jpg" alt="That&#39;s not what I meant when I said Anti-Gravity! (Mario Kart 8 Deluxe)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">That&#39;s not what I meant when I said Anti-Gravity! (Mario Kart 8 Deluxe)</p> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p>Accompanying the recent addition of 32-bit emulation support, <a href="https://github.com/bunnei">bunnei</a> implemented <a href="https://github.com/yuzu-emu/yuzu/pull/4292">support for the creation of random and default Miis</a>. This does not include full support for custom ones for now. With Miis in place, games like <code>Mario Kart 8 Deluxe</code> and <code>New Super Mario Bros. U Deluxe</code> can now get past their menus and become playable.</p> <p>For this service to work, the user needs to dump the system archives from their Nintendo Switch. The process requires the <a href="https://github.com/XorTroll/Goldleaf">Goldleaf homebrew</a>.</p> <p>To obtain the files, you must open Goldleaf from the Homebrew menu, select &ldquo;Console and Goldleaf settings,&rdquo; select &ldquo;Firmware and updates,&rdquo; pick &ldquo;Export update,&rdquo; confirm on the &ldquo;Directory&rdquo; option, and the files will be dumped in the <code>switch\Goldleaf\dump\update</code> location. After that, just copy the files to <code>%AppData%\yuzu\nand\system\Contents\registered</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./mk8.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/mk8_hu7df8f6209c40d3672ff6da59df478cdf_3205127_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ports, ports everywhere! (Mario Kart 8 Deluxe &amp; New Super Mario Bros. U Deluxe)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smbud.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/smbud_huffafb9b53a612d65514b10b8943faa4c_2064400_800x0_resize_q90_bgffffff_box_3.jpg" alt="Ports, ports everywhere! (Mario Kart 8 Deluxe &amp; New Super Mario Bros. U Deluxe)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Ports, ports everywhere! (Mario Kart 8 Deluxe &amp; New Super Mario Bros. U Deluxe)</p> <p>This is tradition by now. <a href="https://github.com/Morph1984">Morph</a> fixed another bug in <code>Kirby Star Allies</code>, this time by <a href="https://github.com/yuzu-emu/yuzu/pull/4082">implementing MirrorOnceClampOGL</a>. This is done by using the <code>GL_EXT_texture_mirror_clamp</code> extension on the OpenGL drivers that support it. The Intel driver doesn’t, so, with those GPUs, yuzu falls back to <code>GL_MIRROR_CLAMP_TO_EDGE</code>.</p> <p>Improvements to the texture cache by <a href="https://github.com/yuzu-emu/yuzu/pull/4176">implementing additional checks</a>, done by <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, fixed crashing issues on Turing GPUs (RTX 2000 and GTX 1600 series) in <code>The Legend of Zelda: Breath of the Wild</code>. Now you can load saves normally! So get moving and save the princess!</p> <p>Our GLASM users experienced black textures on top of the vegetation in <code>The Legend of Zelda: Link’s Awakening</code>. By using the extensions <a href="https://github.com/yuzu-emu/yuzu/pull/4168"><code>NV_shader_buffer_load</code> and <code>NV_shader_buffer_store</code></a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> solved this issue for good.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./zlabug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/zlabug_hu88d2cc18a8384ae40768a2ccd2946843_2824223_800x0_resize_q90_bgffffff_box_3.jpg" alt="Beware of the dark weeds, legend says rupoors lay there (The Legend of Zelda: Link&#39;s Awakening)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./zlafix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/zlafix_hude97f95c428121c9bde3836e25bae6db_2983057_800x0_resize_q90_bgffffff_box_3.jpg" alt="Beware of the dark weeds, legend says rupoors lay there (The Legend of Zelda: Link&#39;s Awakening)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Beware of the dark weeds, legend says rupoors lay there (The Legend of Zelda: Link&#39;s Awakening)</p> <p>We talked about this in the previous June progress report, and we&rsquo;re happy to announce that <a href="https://github.com/ReinUsesLisp">Rodrigo</a> finished <a href="https://github.com/yuzu-emu/yuzu/pull/4150">implementing support for <code>VK_EXT_extended_dynamic_state</code></a>. This fixes the “triangle glitch” that affects <code>Super Mario Odyssey</code> on all Vulkan drivers that support this new extension.</p> <p>Thanks to help from <a href="https://github.com/gdkchan">gdkchan</a> and <a href="https://github.com/FernandoS27">Blinkhawk</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> added support for <a href="https://github.com/yuzu-emu/yuzu/pull/4242">copying 2D arrays of pixels into 3D voxels</a>, fixing rendering bugs in games like <code>LEGO Marvel Super Heroes 2</code> and possibly others.</p> <p><a href="https://github.com/lat9nq">toastUnlimited</a>, along with <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, started preliminary work to fix crashes only happening in recent Nvidia Linux Vulkan drivers. Through trial and error, it was found that <a href="https://github.com/yuzu-emu/yuzu/pull/4283">increasing the Vulkan device allocable size</a> mitigates this issue on most GPUs, but some still remain affected for now.</p> <p><a href="https://github.com/ameerj">epicboy</a> is working on <a href="https://github.com/yuzu-emu/yuzu/pull/4137">implementing support for GameCube adapters</a>, allowing players to use original GameCube controllers! Veteran Smash players will surely enjoy it.</p> <p><a href="https://yuzu-mirror.github.io/entry/yuzu-prometheus/"><code>Project Prometheus</code></a> introduced so many changes that we are still working on reaching feature parity with the original single-core implementation. <a href="https://github.com/ogniK5377">ogniK</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4219">improved the audio timing</a>, fixing audio bugs that were introduced with the implementation of the new multicore and single-core emulation methods.</p> <p>Since its introduction, enabling multicore was the only way to reach stable gameplay on Linux systems, as the single-core option would lead to a crash in every game. Thanks to <a href="https://github.com/yuzu-emu/yuzu/issues/4424">comex&rsquo;s report</a>, <a href="https://github.com/lioncash">Lioncache</a> fixed it by <a href="https://github.com/yuzu-emu/yuzu/pull/4426">using the return value of Lock() in the nvflinger surface compositor</a>. Thanks to this fix, games that are not yet stable with multicore, like <code>Luigi’s Mansion 3</code>, can now be safely played in the Tux OS (Linux).</p> <h2 id="project-kobra">Project Kobra</h2> <p>Six months ago, <a href="https://github.com/Morph1984">Morph</a> proposed an <a href="https://github.com/yuzu-emu/yuzu/pull/3385">implementation of a batch installer to yuzu</a>, which allowed users to install many updates and DLCs at the same time. This was a boon for many users, but it remained in Early Access for a long time due to several issues and anticipation of a new VFS implementation dubbed <code>Project Viper</code>. With renewed hope and motivation from the shark (<a href="https://github.com/ogniK5377">ogniK</a>), <a href="https://github.com/Morph1984">Morph</a> went on to fix all of its remaining issues, allowing it to finally be merged into the master/Mainline branch of yuzu.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./batch_install.png" title=" I can finally install all the DLCs of Super Smash Bros. Ultimate!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/batch_install_hu63a799c8d95c6fab22f6a0ed998e43b5_34019_908x0_resize_q90_bgffffff_box_3.jpg" alt=" I can finally install all the DLCs of Super Smash Bros. Ultimate!"></a> <p class="has-text-centered is-italic has-text-grey-light"> I can finally install all the DLCs of Super Smash Bros. Ultimate!</p> </div> </div> <p>Additionally, as <code>Project Viper</code> has been delayed until further notice, <a href="https://github.com/Morph1984">Morph</a> took it upon himself to fix the list of Virtual File System (VFS) bugs that had been plaguing yuzu.</p> <p>It was well known that yuzu had problems with installing Updates and DLC into the NAND and reading them correctly. Due to the inability to easily remove individual game files, users had to delete all their installed game files just to ensure that their new Update or DLC got detected properly.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./uninstall_before_fix.png" title=" Not again, my precious write cycles! *sobs*"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/uninstall_before_fix_hu51e2103eb7c182883fe1a3d1d83247dc_24255_872x0_resize_q90_bgffffff_box_3.jpg" alt=" Not again, my precious write cycles! *sobs*"></a> <p class="has-text-centered is-italic has-text-grey-light"> Not again, my precious write cycles! *sobs*</p> </div> </div> <p>Upon closer inspection of the inner workings of the VFS, <a href="https://github.com/Morph1984">Morph</a> found that the previous Updates or DLC were not removed when a newer one was being installed, leading to issues with the detection of these files in yuzu. He solved this by <a href="https://github.com/yuzu-emu/yuzu/pull/4249">properly removing the previous update or DLC if it exists on installation</a>. In addition to this, he also <a href="https://github.com/yuzu-emu/yuzu/pull/4250">corrected a small oversight in the way yuzu stores autogenerated titlekeys</a>. Now invalid titlekeys will no longer be written into the <code>title.keys_autogenerated</code> file, ensuring that only valid ones are written. If your game, update or DLC is not being detected by yuzu, ensure you have the latest key files dumped from your switch, as newer game updates and DLC require newer firmware keys to decrypt. With these fixes in place, yuz-ers no longer have to delete all installed game files to install a newer update or DLC as this properly overwrites the previously installed ones.</p> <p>Next, he looked into fixing one of the oldest and well known VFS bugs - the <code>Luigi's Mansion 3</code> autosave issue. Every time an autosave was triggered, the game would softlock. This had also affected other games such as <code>KATANA KAMI: A Way of the Samurai Story</code> and <code>Okami HD</code>. Building upon the initial research by theboy181 (the creator of the mod that bypassed the Luigi&rsquo;s Mansion saving issue), Morph dug into the VFS code and found that files were not closed prior to being renamed or moved, leading to a <a href="https://github.com/yuzu-emu/yuzu/pull/4265">simple fix</a> for any games that use this function.</p> <p>Keeping the ball rolling, he went on to find out why <code>Diablo III: Eternal Collection</code> was not able to get past the EULA screen and thus needing a save file to bypass it. It turned out that an <a href="https://github.com/yuzu-emu/yuzu/pull/1012">old PR</a> was causing <em>folders</em> instead of <em>files</em> to be created. After this discovery, the PR was immediately removed from Mainline/Early Access and closed as it was no longer needed.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./diablo3fixed.png" title=" EULAs can&#39;t stop me! (Diablo III)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/diablo3fixed_hu10e64b98b28bac0166e21aa745286656_1763068_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" EULAs can&#39;t stop me! (Diablo III)"></a> <p class="has-text-centered is-italic has-text-grey-light"> EULAs can&#39;t stop me! (Diablo III)</p> </div> </div> <p>Looking for the next meal, Morph took a bite at the saving issues of the Bioshock Trilogy. These games were unable to save due to checking for free space prior to saving. This was fixed by <a href="https://github.com/yuzu-emu/yuzu/pull/4282">ensuring that the NAND partition sizes were set to their defaults</a> and are read correctly by the relevant filesystem service commands.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bioshock_out_of_space.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/bioshock_out_of_space_hu27a759dcd4e232efd777666696676110_1688424_800x0_resize_q90_bgffffff_box_3.jpg" alt="Game saves are for the weak! (Bioshock Remastered)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bioshock_saved.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/bioshock_saved_hu63f34347933b616d2bb367e4911c2dc2_2282830_800x0_resize_q90_bgffffff_box_3.jpg" alt="Game saves are for the weak! (Bioshock Remastered)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Game saves are for the weak! (Bioshock Remastered)</p> <p>After this little treat, the Kirby embarked on an adventure to fix the last remaining issues with the VFS. After 3 days of debugging the Pokemon Sword and Shield RomFS weather bug, he discovered that these games contained a 0 byte file called <code>global_setting.bin</code> which caused the file right after it called <code>weather_data.bin</code> to be skipped entirely. And you may have guessed by now - this file contains all the data for weather and without it, no weather can be generated within the game! This eureka moment led to an extremely simple fix which <a href="https://github.com/yuzu-emu/yuzu/pull/4309">accommodates for 0 byte files during RomFS building</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./swsh_weather.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/swsh_weather_hu03c6af4947b5d45044574a72bedd06d6_3610393_800x0_resize_q90_bgffffff_box_3.jpg" alt=" Let it snow, let it snow, let it snow! (Pokemon Sword and Shield)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./swsh_weather2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/swsh_weather2_hu27c3ba76c13a8e9410882ac1f9806635_2571972_800x0_resize_q90_bgffffff_box_3.jpg" alt=" Let it snow, let it snow, let it snow! (Pokemon Sword and Shield)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light"> Let it snow, let it snow, let it snow! (Pokemon Sword and Shield)</p> <p><a href="https://github.com/Morph1984">Morph&rsquo;s</a> adventures have led him to save <del>Zelda</del> Link from the eternal softlocks after awakening from his slumber, seems like Ganon may have known Zelda&rsquo;s plan after all. Our Kirby traveled to the shattered Kingdom of Hyrule and foiled Ganon&rsquo;s plans by <a href="https://github.com/yuzu-emu/yuzu/pull/4345">creating the save subdirectories</a> that would allow Link to save his progress. Finally, he can save the princess without wasting his time eternally stuck after his slumber.</p> <p>Hearing stories of Nook Inc&rsquo;s deserted islands, Kirby flew off to visit some of them, only to be met by a barrier preventing access to the other realms. He managed to bypass the barrier by <a href="https://github.com/yuzu-emu/yuzu/pull/4456">stubbing two filesystem service commands</a> which were blocking access to the islands. Now he can view all the latest treats added in the islands since the last update.</p> <p>Wrapping up his adventures, he went and brought peace to Dreamland once again by adding an option to <a href="https://github.com/yuzu-emu/yuzu/pull/4372">remove individual NAND or SDMC installed games, updates, and DLCs</a> and fixing the last remaining issues with the game list, such as <a href="https://github.com/yuzu-emu/yuzu/pull/4381">opening the Save/Mod Data Location of installed titles</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/4450">game list subdirectory scanning</a>, and <a href="https://github.com/yuzu-emu/yuzu/pull/4448">game list metadata detection</a>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./title_removal.png" title=" Removal of installed game files has never been easier!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/title_removal_hu87408c56235a287b976e4d5f7e7185c8_12694_461x0_resize_q90_bgffffff_box_3.jpg" alt=" Removal of installed game files has never been easier!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Removal of installed game files has never been easier!</p> </div> </div> <h2 id="the-old-guard">The old guard</h2> <p>When yuzu started using <a href="https://conan.io/">Conan</a>, most of yuzu&rsquo;s dependencies were migrated to it. Unfortunately, our audio decoding dependency, Opus, had bad settings in the Conan version. These settings forced the use of the <code>AVX/AVX2 instruction set</code> even on old CPUs that don&rsquo;t support it, such as AMD Phenom CPUs or any Intel Pentium, Celeron, or Atom CPU. This caused some games to crash when processing audio on the affected CPUs. <a href="https://github.com/ogniK5377">ogniK</a> fixed this by <a href="https://github.com/yuzu-emu/yuzu/pull/4218">replacing our included Opus version</a>.</p> <p><a href="https://github.com/MerryMage">Merry</a> finished the preliminary work needed to <a href="https://github.com/yuzu-emu/yuzu/pull/4294">fix a performance regression affecting CPUs that lack the <code>FMA instruction set</code></a>. This includes AMD Phenom series or older, Intel 3rd generation Core-i series or older, and all Pentium, Celeron and Atom CPUs. For now this shows up as a debug CPU configuration in yuzu’s settings. We recommend that our users not play with these settings, as altering them will only produce a worse experience than the default settings.</p> <h2 id="ui-changes">UI changes</h2> <p>A very requested feature from our users. <a href="https://github.com/lat9nq">toastUnlimited</a> rose to the challenge and decided to <a href="https://github.com/yuzu-emu/yuzu/pull/4098">add per-game configurations</a> to yuzu! For now it lacks support for input settings, but this will be added in the future. To access this new feature, right click a game in yuzu&rsquo;s game list and select Properties.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./settings.png" title=" No need to remember specific settings before booting a game!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/settings_hu3dd9986a0c65624dbf50bfd8804df04a_197501_802x0_resize_q90_bgffffff_box_3.jpg" alt=" No need to remember specific settings before booting a game!"></a> <p class="has-text-centered is-italic has-text-grey-light"> No need to remember specific settings before booting a game!</p> </div> </div> <p><a href="https://github.com/Morph1984">Morph</a> added <a href="https://github.com/yuzu-emu/yuzu/pull/4377">a new theme for our anti-light themes users</a>, <code>Midnight Blue</code>! You can access it in Configuration &gt; General &gt; UI.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./midnight.png" title=" Oooh, Spooky"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/midnight_hu9b4e4d1d8256f104eec62c8b80029473_102848_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Oooh, Spooky"></a> <p class="has-text-centered is-italic has-text-grey-light"> Oooh, Spooky</p> </div> </div> <p>Fixing small annoyances is something that is overlooked most of the time, but very appreciated when done. <a href="https://github.com/FearlessTobi">Tobi</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4297">removed the need to confirm which Switch profile to use when there is only a single one created</a>. Thank you so much Tobi.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./profile.png" title=" Bye little fella!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/profile_hud9870886460edec56c277a5f39213e68_5556_552x0_resize_q90_bgffffff_box_3.jpg" alt=" Bye little fella!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Bye little fella!</p> </div> </div> <h2 id="the-sharkman-episode-one">The Sharkman, episode one</h2> <p><a href="https://github.com/ogniK5377">ogniK</a> has been working for a long time on a <a href="https://github.com/yuzu-emu/yuzu/pull/4310">major audio rewrite</a> for yuzu. To avoid a very long explanation of the complexity of Nintendo’s audio renderer systems, we recommend our more tech savvy readers to read the Pull Request’s description where you will find more detailed information.</p> <p>This is “Part 1,” several fixes and more complex (or annoying to code) features will be finished at a later date. Right now the results speak for themselves. Tons of games with broken audio of any kind - like missing sound effects, fading music, mixing errors, crackling or even no sound at all - are either running perfectly or are starting to sound a lot more like the native hardware. Some bugs are to be expected for now, for example, <code>Shovel Knight</code> and <code>Fast RMX</code> experience choppy audio, and the voices in <code>Animal Crossing: New Horizons</code> will play from only one ear.</p> <p>You would think that this is enough, but <a href="https://github.com/ogniK5377">ogniK</a> has another fantastic gift for us. Up until now, when several new shaders had to be built during gameplay, they could only be done one at a time. Thanks to some good help provided by <a href="https://github.com/Exzap">Exzap</a>, Cemu&rsquo;s lead developer, <a href="https://github.com/yuzu-emu/yuzu/pull/4273">yuzu can now decode shaders asynchronously!</a> This means that, depending on the amount of threads your CPU has, the shader compilation will happen on several threads at the same time. Thus cutting down shader build time significantly, especially if you can also use assembly shaders.</p> <p>To top it off, <a href="https://github.com/ameerj">epicboy</a> added <a href="https://github.com/yuzu-emu/yuzu/pull/4443">async shader support for Vulkan</a>!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./async.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Thanks to BSoD Gaming for the video comparison (Super Smash Bros. Ultimate)</p> </div> </div> <p>Due to limitations in the AMD Windows OpenGL driver, we recommend that you avoid using asynchronous shaders in OpenGL if you have a Radeon GPU, as it will only produce frame skipping and lead to a very poor gameplay experience. The Linux OpenGL drivers are unaffected by this, as well as any of the Vulkan drivers.</p> <p>The number of threads used for asynchronous shader compilation (along with example CPUs to illustrate the number of CPU threads) are as follows:</p> <table> <thead> <tr> <th style="text-align:center">CPU Threads</th> <th style="text-align:center">Shader Threads</th> <th>Example CPUs</th> </tr> </thead> <tbody> <tr> <td style="text-align:center">1 - 7</td> <td style="text-align:center">1</td> <td>R3-1200, i3-6100</td> </tr> <tr> <td style="text-align:center">8 - 11</td> <td style="text-align:center">2</td> <td>R3-3300X, i7-7700K</td> </tr> <tr> <td style="text-align:center">12 - 15</td> <td style="text-align:center">3</td> <td>R5-3600, i7-8700K</td> </tr> <tr> <td style="text-align:center">16+</td> <td style="text-align:center">4</td> <td>R7-3700X, i7-10700K</td> </tr> </tbody> </table> <h2 id="future-projects">Future projects</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> started rewriting the Texture Cache and once the work is finished, this should positively affect both OpenGL and Vulkan by introducing bug fixes, better performance, and a better experience in Vulkan in particular.</p> <p>There are also some other yet undisclosed but very impressive projects that we will reveal soon enough. Stay tuned!</p> <p>That’s all for now, folks! Until the August progress report!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./starallies.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jul-2020/starallies_hu10b5aa621bf1577972948936f0eeae9e_776878_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report June 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/ Wed, 01 Jul 2020 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/ <p>Hello fellow yuz-ers! We hope you are doing well. Once again, we&rsquo;re here to tell you about some of the exciting changes that were implemented last month in both yuzu Mainline and Early Access.</p> <p>Hello fellow yuz-ers! We hope you are doing well. Once again, we&rsquo;re here to tell you about some of the exciting changes that were implemented last month in both yuzu Mainline and Early Access.</p> <p>In this episode, we have lots of fixes and optimizations, a feature many have been requesting, and as always, some hints of what the future will bring.</p> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p>How should we start? Oh, I know! With <a href="https://github.com/Morph1984">Morph</a> fixing another Kirby issue of course! By <a href="https://github.com/yuzu-emu/yuzu/pull/4092">reserving 4 image bindings</a> in the fragment stage, instead of just one as before, he was able to fix several shader compilation errors that affected both <code>GLSL</code> and <code>GLASM</code> in <code>Kirby Star Allies</code>. Check out the results below, <a href="https://www.youtube.com/watch?v=ObHK_K853k4">Poyo!</a></p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./Kirby_before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/Kirby_before_hu0dc5c48af48215b4aef1fe2d4be64677_2112795_800x0_resize_q90_bgffffff_box_3.jpg" alt="Here you can see the bug affecting an attack (Kirby Star Allies)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kirby_after.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/kirby_after_hu5d3758d4475af7eff58b88900809be07_2277619_800x0_resize_q90_bgffffff_box_3.jpg" alt="Here you can see the bug affecting an attack (Kirby Star Allies)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Here you can see the bug affecting an attack (Kirby Star Allies)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kirby_before2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/kirby_before2_hua99c554f90980fcee61c1891ef46ec01_2164296_800x0_resize_q90_bgffffff_box_3.jpg" alt="And here affecting terrain (Kirby Star Allies)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kirby_after2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/kirby_after2_hua2ec9ccc744fdbb50ba0129368f133ce_2307171_800x0_resize_q90_bgffffff_box_3.jpg" alt="And here affecting terrain (Kirby Star Allies)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">And here affecting terrain (Kirby Star Allies)</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed a bug that previously manifested as random black flickering by <a href="https://github.com/yuzu-emu/yuzu/pull/4064">marking vertex buffers as dirty after a cache invalidation</a>. This issue primarily affected <code>Animal Crossing: New Horizons</code>, but the bugfix should affect a lot of other games as well. Feel free to share any other games you discover that benefit from this!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./acnh.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light"> Now that doesn&#39;t look nice, does it? (Animal Crossing: New Horizons)</p> </div> </div> <p>A very elusive bug in <code>Super Mario Odyssey</code>, dubbed the &ldquo;triangle glitch,&rdquo; had been tormenting us for ages. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> managed to solve the issue, but only in OpenGL with Nvidia GPUs due to the exclusive <code>NV_vertex_buffer_unified_memory</code> extension. However, due to both a yuzu and driver bug, we&rsquo;re unable to use this extension on Turing based GPUs (RTX 2000 and GTX 1600 series) for the moment.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo-bug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/smo-bug_hu31de0ab1d3fd4e9b758afc1bc843a3f5_2845758_800x0_resize_q90_bgffffff_box_3.jpg" alt="Dark and glitchy (Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-fix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/smo-fix_hub425b565030904fd2ce5a691434ee207_1780191_800x0_resize_q90_bgffffff_box_3.jpg" alt="Dark and glitchy (Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Dark and glitchy (Super Mario Odyssey)</p> <p>We are working on a <a href="https://github.com/yuzu-emu/yuzu/pull/4150">universal implementation in Vulkan</a> that requires the <code>VK_EXT_extended_dynamic_state</code> extension, but it is not yet available in all the GPU vendors&rsquo; drivers. At the time of writing, only the Intel Mesa <code>ANV</code> Linux driver and the latest Nvidia Vulkan Beta driver support it.</p> <p>A rare bug was affecting <code>Xenoblade Chronicles 2</code>, causing fantastic vertex explosions on time-of-day transitions. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> managed to solve the issue by <a href="https://github.com/yuzu-emu/yuzu/pull/4194">improving the shader cache</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xc2-bug.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/xc2-bug_hu286068597869ec7079314fac6990bf2e_1116284_800x0_resize_q90_bgffffff_box_3.jpg" alt="Exactly the same spot (Xenoblade Chronicles 2)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xc2-fix.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/xc2-fix_hu1979630a1f33784b67740e8f69b599ba_2563638_800x0_resize_q90_bgffffff_box_3.jpg" alt="Exactly the same spot (Xenoblade Chronicles 2)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Exactly the same spot (Xenoblade Chronicles 2)</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/4080">implementing RendererInfo</a> into yuzu’s audio emulation, <a href="https://github.com/ogniK5377">ogniK</a> solved the softlocks affecting the credit sequence in <code>Animal Crossing: New Horizons</code> and the softlocks in several areas of <code>The Legend of Zelda: Link's Awakening</code>. Now you can enjoy both games without the fear of getting stuck, and even listen to some newly working sound effects!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./acnh-credits.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/acnh-credits_hu26eec7177a2526557682ca2a9fd1a6fe_598028_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nothing to report! (Animal Crossing: New Horizons &amp; The Legend of Zelda: Link&#39;s Awakening)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./zla-mermaid.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/zla-mermaid_huffa22ed650f37f1ebb1df0bd7439b75d_3269213_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nothing to report! (Animal Crossing: New Horizons &amp; The Legend of Zelda: Link&#39;s Awakening)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Nothing to report! (Animal Crossing: New Horizons &amp; The Legend of Zelda: Link&#39;s Awakening)</p> <p>Also thanks to <a href="https://github.com/ogniK5377">ogniK</a>, <code>Animal Crossing: New Horizons</code> no longer needs the crash-fix patch we were distributing in our compatibility article for the game. This was done by <a href="https://github.com/yuzu-emu/yuzu/pull/4070">improving the emulation of the Tegra X1 GPU drivers</a>. As a bonus, this also fixed T-posing on the later updates in <code>Super Smash Bros. Ultimate</code>!</p> <p>Not all games are native to the Nintendo Switch, with a portion of its library consisting of ported games from other consoles or the PC. Up until now, yuzu failed to run PC game ports that were originally developed for <code>Direct3D</code> (a Windows graphics API), even though they ran perfectly fine in <code>NVN</code> (a Switch exclusive graphics API). However, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> found a <a href="https://github.com/yuzu-emu/yuzu/pull/4049">way to translate this behavior</a> to yuzu’s OpenGL and Vulkan implementations, resulting in tons of western games going in-game. This change was also accompanied by a shader cache invalidation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./bioshock.png" title=" Would you kindly? (BioShock Remastered)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/bioshock_huc304775e99420f20d3217072e41d9e44_1579589_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Would you kindly? (BioShock Remastered)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Would you kindly? (BioShock Remastered)</p> </div> </div> <p>By implementing a <a href="https://github.com/yuzu-emu/yuzu/pull/4005">missing texture format</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed dark surface glitches that appear in <code>Xenoblade Chronicles Definitive Edition</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xcde_before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/xcde_before_hu35a29192b0edb89b76161127168adf7b_1562178_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is the Monado&#39;s power!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xcde_after.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/xcde_after_hud3fbb58df331203c0d926e3f181bd44f_1884327_800x0_resize_q90_bgffffff_box_3.jpg" alt="This is the Monado&#39;s power!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">This is the Monado&#39;s power!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./xcde_before2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/xcde_before2_hu5a6564292039b2dd1dd3f8dc6bcbc387_529964_800x0_resize_q90_bgffffff_box_3.jpg" alt="(Xenoblade Chronicles Definitive Edition)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./xcde_after2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/xcde_after2_hue07302a9d4775ad2ca26b2f2ddb4b756_3061350_800x0_resize_q90_bgffffff_box_3.jpg" alt="(Xenoblade Chronicles Definitive Edition)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">(Xenoblade Chronicles Definitive Edition)</p> <p>Intel used to have a bug in their OpenGL driver causing many games using <code>Compute Shaders</code> to crash or render effects incorrectly. This forced us to disable them on any supported Intel GPU, which introduced adverse effects in many games. One game of note is <code>Super Smash Bros. Ultimate</code>, wherein compute shaders are used to render character model animations and without them, character models will be in a <code>T-pose</code>.</p> <p>Additionally, Intel&rsquo;s OpenGL <code>Geometry Shader</code> implementation (unlike AMD&rsquo;s and Nvidia&rsquo;s one) lacks an OpenGL extension called <code>GL_ARB_shader_viewport_layer_array</code>. This forces us to re-evaluate yuzu&rsquo;s implementation of it.</p> <p>By <a href="https://github.com/yuzu-emu/yuzu/pull/4025">re-enabling Compute Shaders</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/4031">changing the way yuzu handles Geometry Shaders</a>, <a href="https://github.com/Morph1984">Morph</a> closed a big box of issues that previously affected only our Intel GPU users.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./octopath-before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/octopath-before_hud55d48f2c127b11a9dd6bba46d47b902_1596660_800x0_resize_q90_bgffffff_box_3.jpg" alt="Gone are the rainbows on Intel (Octopath Traveler)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./octopath-fixed.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/octopath-fixed_hub42d2039d1e7ef4a0cb7003a158084e9_625273_800x0_resize_q90_bgffffff_box_3.jpg" alt="Gone are the rainbows on Intel (Octopath Traveler)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Gone are the rainbows on Intel (Octopath Traveler)</p> <p> </p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ssbu-tpose.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/ssbu-tpose_hu4225895ef550d0a7ad7056bd02219c59_2351348_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more T-posing (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ssbu-fixed.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/ssbu-fixed_hu57a961147091bf633988fc3707416833_2342888_800x0_resize_q90_bgffffff_box_3.jpg" alt="No more T-posing (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No more T-posing (Super Smash Bros. Ultimate)</p> <p><a href="https://github.com/VolcaEM">Volca</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4032">stubbed an input instruction</a> allowing <code>Minecraft: Nintendo Switch Edition</code> to go in-game.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./minecraft.png" title=" Don&#39;t dig too deep! (Minecraft: Nintendo Switch Edition)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/minecraft_hu489609e1246540616df7ecff7260258b_983391_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Don&#39;t dig too deep! (Minecraft: Nintendo Switch Edition)"></a> <p class="has-text-centered is-italic has-text-grey-light"> Don&#39;t dig too deep! (Minecraft: Nintendo Switch Edition)</p> </div> </div> <p>Not all games have to be in 3D. <a href="https://github.com/Morph1984">Morph</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4081">replaced the default texture filtering behaviour</a> to achieve crisp graphics in 2D games like <code>Undertale</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./undertale-before.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/undertale-before_hu6d3d4968df527bbcaa1cb9fc81543511_74102_800x0_resize_q90_bgffffff_box_3.jpg" alt="Crisp, just the way I like it"></a> </div> <div class="column is-bottom-paddingless"> <a href="./undertale-after.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/undertale-after_hu438855e46f38770052fd0253d7171efb_11627_800x0_resize_q90_bgffffff_box_3.jpg" alt="Crisp, just the way I like it"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Crisp, just the way I like it</p> <p>Now on to our final bug fix of last month. Old AMD GPUs from 2012 lack the OpenGL <code>GL_EXT_texture_shadow_lod</code> extension, leading to shaders that failed to build in <code>The Legend of Zelda: Breath of the Wild</code>. As described <a href="https://github.com/KhronosGroup/SPIRV-Cross/issues/207">here</a>, by using the <a href="https://github.com/yuzu-emu/yuzu/pull/4129">textureGrad function</a>, <a href="https://github.com/Morph1984">Morph</a> achieved similar results, improving compatibility with such old devices.</p> <h2 id="vulkan-improvements">Vulkan improvements</h2> <p><code>OCTOPATH TRAVELER</code> got some Vulkan love thanks to <a href="https://github.com/ReinUsesLisp">Rodrigo</a>. By implementing a <a href="https://github.com/yuzu-emu/yuzu/pull/4033">missing image format</a> and <a href="https://github.com/yuzu-emu/yuzu/pull/4034">storage texels and atomic image operations</a>, the game can now reach in-game status in Vulkan, and with some very beautiful visuals!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./octopath.png" title=" This is how nostalgia makes us remember the SNES era (OCTOPATH TRAVELER)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/octopath_hu9341315c0438b29f58b59153162d15c4_4308990_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" This is how nostalgia makes us remember the SNES era (OCTOPATH TRAVELER)"></a> <p class="has-text-centered is-italic has-text-grey-light"> This is how nostalgia makes us remember the SNES era (OCTOPATH TRAVELER)</p> </div> </div> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> also worked on <a href="https://github.com/yuzu-emu/yuzu/pull/4110">multiple</a> <a href="https://github.com/yuzu-emu/yuzu/pull/4111">performance</a> optimizations for the Vulkan API. This results in lower frametimes and higher framerates on average.</p> <h2 id="user-interface-changes">User Interface changes</h2> <p>An old misconception our users had with yuzu had to do with the <code>Internal Resolution</code> option in the graphics settings. This was carried over from <a href="https://citra-emu.org/">Citra&rsquo;s</a> UI, but it wasn&rsquo;t coded to do anything in yuzu. So, lots of users set it up at higher values expecting an image quality increase that could never happen. <a href="https://github.com/Morph1984">Morph</a> decided it was time to <a href="https://github.com/yuzu-emu/yuzu/pull/3966">remove it for good</a>, and so he did.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./res-scaler-removed.png" title=" Until we meet again, Internal Resolution!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/res-scaler-removed_hubbaba8fa7c285c60e738f7bfca2b80bf_8489_549x0_resize_q90_bgffffff_box_3.jpg" alt=" Until we meet again, Internal Resolution!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Until we meet again, Internal Resolution!</p> </div> </div> <p>Thanks to users requesting it, <a href="https://github.com/VolcaEM">Volca</a> added <a href="https://github.com/yuzu-emu/yuzu/pull/4136">Open Mods</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/4166">FAQ, and Quickstart</a> shortcuts to yuzu&rsquo;s interface. This is a great way for users to find helpful information on how to use the emulator — you just need to click on <code>Help</code>!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./volca-ui.png" title=" Just an easier way. Thanks Volca!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/volca-ui_huc719ab8e90628c11cd46beef4f6060bd_3336_184x0_resize_q90_bgffffff_box_3.jpg" alt=" Just an easier way. Thanks Volca!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Just an easier way. Thanks Volca!</p> </div> </div> <p>Continuing with UI changes, <a href="https://github.com/Kewlan">Kewlan</a> added a <a href="https://github.com/yuzu-emu/yuzu/pull/4164">mute audio hotkey</a>. They also fixed a bug with the <a href="https://github.com/yuzu-emu/yuzu/pull/4182">fullscreen hotkey</a>, where the default hotkey would still function even when changed.</p> <h2 id="dreams-and-reality">Dreams and reality</h2> <p><code>Project Maribel Hearn</code> has been released, and is available in Mainline too! Native 32-bit Switch games are now starting to work, with some of them even being fully playable! This means that games like <code>New Super Mario Bros. U Deluxe</code> and <code>Captain Toad: Treasure Tracker</code> work almost perfectly and with great performance, while games like <code>Mario Kart 8 Deluxe</code> still need more work.</p> <p>This has been a highly requested feature for a very long time, but implementing it required a major rewrite of the kernel, and official support for ARMv7 was needed in <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a>, our ARM JIT recompiler. This took a tremendous amount of work from several of our developers, including, but not limited to: <a href="https://github.com/MerryMage">Merry</a>, <a href="https://github.com/lioncash">Lioncache</a>, <a href="https://github.com/FernandoS27">Blinkhawk</a>, <a href="https://github.com/bunnei">bunnei</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, <a href="https://github.com/FearlessTobi">Tobi</a>, <a href="https://github.com/ogniK5377">ogniK</a>, <a href="https://github.com/Morph1984">Morph</a>, and many others. Special mention goes to Merry and Lioncache: they are the soul of this project, and without them we couldn&rsquo;t have even started it. Several of their pull requests are &ldquo;too technical&rdquo; to be included in the progress reports, but it should be known that Merry and Lioncache are the main code contributors at the heart of yuzu.</p> <p>You may not have noticed that four months ago, <a href="https://github.com/bunnei">bunnei</a> and <a href="https://github.com/FearlessTobi">Tobi</a> laid down the <a href="https://github.com/yuzu-emu/yuzu/pull/3478">initial framework</a> towards 32-bit support in yuzu.</p> <p>They accomplished this by refactoring the ARM interface to support 32-bit and 64-bit JIT backends, implementing a 32-bit ARM interface based on Citra&rsquo;s ARMv6 dynarmic backend by adding CP15 coprocessor support, and implementing several 32-bit SVCs such as <code>GetThreadPriority32</code>, <code>WaitSynchronization32</code>, and many more.</p> <p>While rewriting the kernel for Prometheus, <a href="https://github.com/FernandoS27">Blinkhawk</a> and <a href="https://github.com/bunnei">bunnei</a> saw an excellent opportunity to include support for 32-bit ARMv7 CPU instructions and services. With this spark of motivation, they worked with <a href="https://github.com/MerryMage">Merry</a> and <a href="https://github.com/lioncash">Lioncache</a> to make the dream of 32-bit support a reality, by ramping up the implementation of various ARMv7 instructions such as <code>VPADD</code>, <code>VCVT</code>, and <code>VSHL</code> in Dynarmic, and 32-bit SVCs such as <code>CreateTransferMemory32</code>, <code>MapSharedMemory32</code>, and <code>CreateThread32</code> in yuzu. There are many other ARMv7 instructions and SVCs that we cannot cover here, but the culmination of this work allowed us to get the very first 32-bit games up and running!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./toad.png" title=" Good performance even on low-end hardware!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-jun-2020/toad_hua53a037795929c754e1f60c8c829602c_2243215_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Good performance even on low-end hardware!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Good performance even on low-end hardware!</p> </div> </div> <p>Additionally, the merge of this work into the Master branch also means that Multicore support is now working in Mainline! Thanks <a href="https://github.com/FernandoS27">Blinkhawk</a> for all your hard work on this! Please refer to our previous <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/">May progress report</a> and the dedicated <a href="https://yuzu-mirror.github.io/entry/yuzu-prometheus/">Project Prometheus article</a> to read more about this crucial new feature.</p> <h2 id="future-projects">Future projects</h2> <p>With Multicore finally in Master, some of the ideas we have &ldquo;in the oven&rdquo; can start to take shape. <code>Project Apollo</code> is starting to be nice and sound. And finally, I&rsquo;ve heard <a href="https://github.com/bunnei">bunnei</a> is up to something, <em>again</em>.</p> <p>That’s all for now, folks! We hope to see you in our July progress report! Special thanks to gidoly for providing screenshots.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report May 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/ Sun, 07 Jun 2020 03:15:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/ <p>Hello yuz-ers! How are you all doing?</p> <p>In this monthly episode of &ldquo;yuzu — Trials and Tribulations,&rdquo; we offer you: major rewrites, massive performance gains, stability improvements, bug fixes and graphical corrections. <em>More after the commercial break.</em></p> <p>Hello yuz-ers! How are you all doing?</p> <p>In this monthly episode of &ldquo;yuzu — Trials and Tribulations,&rdquo; we offer you: major rewrites, massive performance gains, stability improvements, bug fixes and graphical corrections. <em>More after the commercial break.</em></p> <h2 id="the-worst-kept-secret">The worst kept secret</h2> <p>It has its own <a href="https://yuzu-mirror.github.io/entry/yuzu-prometheus/">article</a>, and it had been guessed to hell and back before the official announcement. <code>Project Prometheus</code> is a proper multithreaded emulation of the 4 CPU cores the Nintendo Switch offers. This brings a massive performance boost to users with CPUs with 4 physical cores or more, but for this to happen, a lot of groundwork was needed. Besides changes previously discussed in past reports, old external libraries (which yuzu needs to operate) needed to be updated, and with that, some changes were needed for our Linux users.</p> <p>Thanks to <a href="https://github.com/jroweboy">jroweboy’s</a> work, yuzu now uses <a href="https://conan.io/">Conan</a>, helping the project <a href="https://github.com/yuzu-emu/yuzu/pull/3735">manage dependencies</a>, and letting Linux distributions use their native ones when possible.</p> <p>With the previous VMM rewrite reducing memory use, the dependencies updated, and all the groundwork done, <a href="https://github.com/FernandoS27">Blinkhawk</a> pressed the metaphorical nuclear launch button and <a href="https://github.com/yuzu-emu/yuzu/pull/3955">released Project Prometheus</a>. yuzu can now use up to 6 or 7 CPU threads (in ideal conditions) compared to the previous 2 or 3. You should expect a performance boost in a lot of games, but still see some titles perform mostly the same due to being coded to only use a single thread.</p> <p>Now, some clarifications are needed for this change. Multicore support can’t be merged into our <a href="https://github.com/yuzu-emu/yuzu-mainline">Mainline</a> release for now due to incompatibilities between Multicore and the <a href="https://github.com/yuzu-emu/yuzu">Master</a> branch of yuzu. Work is being done to resolve the conflicts, but please have patience. Additionally, users with 2 cores, and either 2 or 4 threads, should not enable multicore as it will most likely result in a performance loss for them due to the lack of physical cores on their CPUs. Our <a href="https://yuzu-mirror.github.io/help/quickstart/#hardware">hardware recommendations</a> have been updated accordingly.</p> <h2 id="unreal-engine-fixes">Unreal Engine fixes</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> implemented <a href="https://github.com/yuzu-emu/yuzu/pull/4027">rendering more than one slice of 3D textures</a>, fixing the most glaring issue in Unreal Engine 4 games, known as “the Rainbow”. This also improves the previous implementation that was used in Xenoblade games.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./01.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/01_hu68c02814a9c40805a6f6276911f7bd80_2255367_800x0_resize_q90_bgffffff_box_3.jpg" alt="Your Excellency (OCTOPATH TRAVELER)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./02.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/02_hu46b9a796253ad79e835e0857de220e84_1139184_800x0_resize_q90_bgffffff_box_3.jpg" alt="Your Excellency (OCTOPATH TRAVELER)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Your Excellency (OCTOPATH TRAVELER)</p> <h2 id="animal-crossing-new-horizons-changes">Animal Crossing: New Horizons changes</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed <code>Animal Crossing: New Horizons</code> terrain borders in Vulkan by implementing <a href="https://github.com/yuzu-emu/yuzu/pull/3930">constant attributes</a>. This is not a native extension, constant attributes have to be emulated in Vulkan as there is currently no official support for it.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./04.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/04_huaf039df4fe51f25751a4dbe9f895ebff_2342374_800x0_resize_q90_bgffffff_box_3.jpg" alt="Beautiful beaches, now in Vulkan too (Animal Crossing: New Horizons)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./05.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/05_hue38c3a6b0b2c360419e88546b0f46b38_2584961_800x0_resize_q90_bgffffff_box_3.jpg" alt="Beautiful beaches, now in Vulkan too (Animal Crossing: New Horizons)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Beautiful beaches, now in Vulkan too (Animal Crossing: New Horizons)</p> <p><a href="https://github.com/bunnei">bunnei</a> implemented <a href="https://github.com/yuzu-emu/yuzu/pull/3909">time zone support</a>, and Windows users will find that yuzu automatically detects their time zone. For those not on Windows (or want to spice up their life), you can manually change your system time via the &ldquo;Custom RTC&rdquo; option in the System settings. Previously, yuzu always assumed the user was located in the GMT+0 time zone.</p> <p><a href="https://github.com/bunnei">bunnei</a> also improved the <a href="https://github.com/yuzu-emu/yuzu/pull/3665">saving mechanism</a>. Most games save their data in each user profile, but <code>Animal Crossing: New Horizons</code> does it via a “device” profile, so yuzu had to accommodate for that.</p> <h2 id="xenoblade-specific-fixes">Xenoblade specific fixes</h2> <p>Rendering bugs are abundant in Xenoblade games due to the complexity of their engine, and they are not trivial to solve. However, with the help of <a href="https://github.com/gdkchan">gdkchan</a> and using this <a href="https://github.com/Ryujinx/Ryujinx/pull/1277">Pull Request</a> from <a href="https://github.com/Ryujinx/Ryujinx">Ryujinx</a>, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed one of the major rendering issues in <code>Xenoblade Chronicles 2</code> related to <a href="https://github.com/yuzu-emu/yuzu/pull/3996">front face flipping</a>. Additional <a href="https://github.com/yuzu-emu/yuzu/pull/3991">improvements to texture depth samplings</a> resolved some rendering glitches, such as the clouds and start menu. Additionally, a better handling of <a href="https://github.com/yuzu-emu/yuzu/pull/4012">mipmap overlaps</a> solved the constantly moving textures the games previously had. You can see the results below.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./06.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/06_hu08449bb71dd3e3a414afd604db068078_732247_800x0_resize_q90_bgffffff_box_3.jpg" alt="Who said yuzu can’t run JRPGs? (Xenoblade Chronicles 2)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./07.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/07_hu983d50849e9dcebc8188ba9bf67cb49b_2231832_800x0_resize_q90_bgffffff_box_3.jpg" alt="Who said yuzu can’t run JRPGs? (Xenoblade Chronicles 2)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Who said yuzu can’t run JRPGs? (Xenoblade Chronicles 2)</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> also optimized the performance in Xenoblade games, one method of which was <a href="https://github.com/yuzu-emu/yuzu/pull/3999">profiling the texture cache</a> line by line and finding where it bottlenecks. By improving the code, you get a faster frametime, which translates to better performance.</p> <p>Another way, and not an expected one, was to <a href="https://github.com/yuzu-emu/yuzu/pull/4007">log less information</a>. This avoids saturating the GPU thread, giving more room to actual processing and rendering.</p> <h2 id="general-performance-improvements">General performance improvements</h2> <p><a href="https://github.com/ogniK5377">ogniK</a> wrote a new <a href="https://github.com/yuzu-emu/yuzu/pull/4009">Macro JIT</a> (Just-in-Time) to improve the performance of games that spend too much time in the macro interpreter. This should be a global performance boost independent of GPU vendor or API.</p> <p>When <a href="https://github.com/ReinUsesLisp">Rodrigo</a> improved yuzu’s ASTC decoding, he also added a rule to use native hardware decoding whenever possible. The Nvidia driver tells yuzu it supports ASTC decoding, but as it turns out, they actually use an internal software decoder that is much slower than our own implementation. <a href="https://github.com/yuzu-emu/yuzu/pull/4014">Ignoring the Nvidia driver-level software decoder</a> produced a massive performance improvement when facing the dreaded ASTC texture format in games. It will still be immediate with Intel GPUs, as no software optimizations will beat a dedicated hardware decoder.</p> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p>Vulkan development is an ongoing process in yuzu, and it has stability problems as expected of a relatively new and complex feature. <a href="https://github.com/FernandoS27">Blinkhawk</a> made a couple of <a href="https://github.com/yuzu-emu/yuzu/pull/3905">critical changes to Vulkan and Asynchronous GPU</a>, improving stability considerably.</p> <p>Speaking of Vulkan, many 2D games had their sprites flipped or completely wrong, and once again, we currently lack the extension required to fix this. Therefore, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> implemented <a href="https://github.com/yuzu-emu/yuzu/pull/3885">support for <code>NV_viewport_swizzle</code></a>. This Nvidia-exclusive extension is the only way to solve this problem in a clean manner for now, but a universal method is being developed.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./10.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/10_hu5bc37863ae395e8f63b469db84011c07_84752_800x0_resize_q90_bgffffff_box_3.jpg" alt="Quack (Duck Game)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./11.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/11_huc121b961c859fb588ca03fd6434d8bcd_118199_800x0_resize_q90_bgffffff_box_3.jpg" alt="Quack (Duck Game)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Quack (Duck Game)</p> <p>The updated libraries (that the migration to Conan brought us) also gave us a new version of the <a href="https://github.com/kinetiknz/cubeb">cubeb</a> audio engine which adds support for 6 channel audio, allowing <a href="https://github.com/ogniK5377">ogniK</a> to add <a href="https://github.com/yuzu-emu/yuzu/pull/3827">support for surround sound</a>.</p> <p>Our good shark, <a href="https://github.com/ogniK5377">ogniK</a>, also fixed <a href="https://github.com/yuzu-emu/yuzu/pull/3926">keyboard emulation support</a>, so expect compatible games to have proper direct input from your keyboards now.</p> <p><a href="https://github.com/Morph1984">Morph</a> implemented the missing support for <a href="https://github.com/yuzu-emu/yuzu/pull/3839"><code>R8G8UI</code> textures</a>, fixing both the performance problems and saving crashes that <code>The Walking Dead</code> games experienced.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./08.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/08_hu2ca46b7ecc062c4514f50dddad426bb5_2093679_800x0_resize_q90_bgffffff_box_3.jpg" alt="Thank you Toxa for the screenshot (The Walking Dead: The Final Season)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Thank you Toxa for the screenshot (The Walking Dead: The Final Season)</p> <p>Although objectively a small issue, the mouse cursor didn&rsquo;t hide when running yuzu in full screen, causing a subjectively significant annoyance. Thankfully, <a href="https://github.com/FearlessTobi">Tobi</a> implemented an <a href="https://github.com/yuzu-emu/yuzu/pull/3892">option to automatically hide the mouse</a> once it has been inactive after some time.</p> <h2 id="an-elegant-feature-of-a-more-civilized-age">An elegant feature of a more civilized age</h2> <p>Recently released in the Early Access build, and coming soon to Mainline, is support for <code>assembly shaders</code> (<code>GLASM</code>), usually referred to as <code>ARB shaders</code>.  </p> <p>A couple decades ago, there was no common language for the then newly added programmable shading units in GPUs, so the <code>OpenGL Architecture Review Board</code> decided to create a proper standardised shading language they called <code>GLASM</code>. In broader terms, this is an assembly language used to communicate with the GPU. This makes it very difficult to work with, and the difficulty is only exacerbated by the limited set of debugging tools available. Furthermore, the language was developed with the hardware limitations of the time in mind. In the present, <code>GLASM</code> has been mostly deprecated in favour of easier-to-work-with, high-level shader representations like <code>GLSL</code> or <code>SPIR-V</code>. While this means faster results for game developers due to less time spent looking at the code, it also has the disadvantage of being far slower for emulators that have to constantly intercept, decode, and recompile shaders on the fly.  </p> <p>In the beginning, support for <code>GLASM</code> started as just an experiment. Armed with <a href="https://apitrace.github.io/">apitrace</a> as his only debug tool, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> set to his task. Luckily, and for no apparent sane reason, Nvidia still maintains support for such an old feature, even on the latest OpenGL versions. As such, support for <code>GLASM</code> soon became a reality and with this initial <a href="https://github.com/yuzu-emu/yuzu/pull/3964">assembly shading</a> support in place, Nvidia OpenGL users can enjoy extremely fast shader compilation times.  </p> <p>Due to being closer to the native hardware of the Nintendo Switch, we can also expect some precision fixes, with more coming in the future.  </p> <p>Unfortunately, <code>GLASM</code> has some limitations. To list some of them:</p> <ul> <li> <p>This is an Nvidia and OpenGL only feature — other vendors (AMD and Intel) only offer support for the specific assembly shaders that old games require and this is highly unlikely to change in the future.</p> </li> <li> <p>Currently, some games experience bugs that will need to be ironed out, such as: <code>Luigi’s Mansion 3</code>, <code>Astral Chain</code>, and <code>The Legend of Zelda: Link’s Awakening</code>.</p> </li> <li> <p>There are architecture specific bugs; a Pascal GPU may face different issues than a Turing or Kepler GPU.</p> </li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./12.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/12_hu6c5aba462fd289696cbda2635b51a0b8_43219_800x0_resize_q90_bgffffff_box_3.jpg" alt="You can see the progress from simple things… (Cave Story)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./13.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/13_hu7cfea12d61672bf73678f7207d1e252d_234117_800x0_resize_q90_bgffffff_box_3.jpg" alt="You can see the progress from simple things… (Cave Story)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">You can see the progress from simple things… (Cave Story)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./14.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-may-2020/14_hu122ce749756c68d2d01df4646c083c54_1773825_800x0_resize_q90_bgffffff_box_3.jpg" alt="To more complex tests (Fire Emblem Warriors)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">To more complex tests (Fire Emblem Warriors)</p> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/Oj5ntdszfyQ" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> <h2 id="future-projects">Future projects</h2> <p>I can’t say much here, but there is something going on with both <code>Project Viper</code> and <code>Project Hearn</code>.</p> <p>That’s all for now, folks! See you in the June article! Special thanks to BSoD Gaming for the comparative <code>GLASM</code> video, and Toxa for providing some screenshots.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report April 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/ Thu, 28 May 2020 12:00:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/ <p>Hello awesome yuz-ers! We hope you are all doing well. We have lots of material to cover in this April progress report: some new additions, bug and regression fixes, and the groundwork for future improvements that affect both Mainline and Early Access. But first, let&rsquo;s discuss a few really big changes.</p> <p>Hello awesome yuz-ers! We hope you are all doing well. We have lots of material to cover in this April progress report: some new additions, bug and regression fixes, and the groundwork for future improvements that affect both Mainline and Early Access. But first, let&rsquo;s discuss a few really big changes.</p> <h2 id="the-big-changes">The Big Changes</h2> <p>This month brought us huge improvements to compatibility, fidelity and resource management. Our master of serendipity, <a href="https://github.com/bunnei">bunnei</a>, fixed a softlock in <code>FINAL FANTASY VIII Remastered</code>. What he didn’t know at the time is that this small fix also made <code>Super Smash Bros. Ultimate</code> playable. Thanks to this, you can now enjoy local multiplayer battles with your friends, either locally or even via Parsec!</p> <p>For quite a while, Nvidia Turing users (GTX 16 series and RTX 20 series GPUs) had to deal with several rendering bugs, like black and white terrain in <code>Fire Emblem: Three Houses</code>, or black areas in <code>Super Monkey Ball: Banana Blitz HD</code>. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed most of them by improving the accuracy of the shader decoder. This also fixes some bugs on older Nvidia GPUs too.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./29.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/29_hu1c387f36a7b26f5836f1311f502b7a95_730796_800x0_resize_q90_bgffffff_box_3.jpg" alt="Monochrome no more (Fire Emblem: Three Houses)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./30.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/30_hu772b32b3317bb80b3b6d5eb83dbb52d6_2666273_800x0_resize_q90_bgffffff_box_3.jpg" alt="Monochrome no more (Fire Emblem: Three Houses)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Monochrome no more (Fire Emblem: Three Houses)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./27.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/27_hu8e85566b403055c51a5288990c23023a_1687805_800x0_resize_q90_bgffffff_box_3.jpg" alt="No greasy black peels (Super Monkey Ball: Banana Blitz HD)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./28.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/28_hue1c1ad1e83b6735416912c0127e48f00_2207792_800x0_resize_q90_bgffffff_box_3.jpg" alt="No greasy black peels (Super Monkey Ball: Banana Blitz HD)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">No greasy black peels (Super Monkey Ball: Banana Blitz HD)</p> <p>Speaking of shader decoding accuracy, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> improved the precision of the <code>HADD2</code> and <code>HMUL2</code> instructions, fixing some long standing bugs like the fog in <code>Fire Emblem: Three Houses</code> and the excessive brightness in most maps in <code>Super Smash Bros. Ultimate</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./33.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/33_hu6acd07259f34cae7f0101f5e27c7a505_2829551_800x0_resize_q90_bgffffff_box_3.jpg" alt="You can now take off your sunglasses (Super Smash Bros. Ultimate)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./34.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/34_hu18d1f8715d32b90e92241497a222210f_3213871_800x0_resize_q90_bgffffff_box_3.jpg" alt="You can now take off your sunglasses (Super Smash Bros. Ultimate)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">You can now take off your sunglasses (Super Smash Bros. Ultimate)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./15.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/15_hu829916c4e1efc27c2b6ea7afea89f263_1252717_800x0_resize_q90_bgffffff_box_3.jpg" alt="From steampunk, to the proper medieval fantasy setting (Fire Emblem: Three Houses)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./16.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/16_hu7e57abd66240737ffb6c54023f7b4570_1676323_800x0_resize_q90_bgffffff_box_3.jpg" alt="From steampunk, to the proper medieval fantasy setting (Fire Emblem: Three Houses)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From steampunk, to the proper medieval fantasy setting (Fire Emblem: Three Houses)</p> <p>We talked about this in its own <a href="https://www.patreon.com/posts/35856792">article</a>, but it deserves a mention here: <a href="https://github.com/bunnei">bunnei</a> rewrote the Virtual Memory Manager (known internally as <code>Project Epimetheus</code>), which drastically reduced the amount of RAM games use, and helped Multicore support (also known as<code>Project Prometheus</code>) become a reality.</p> <p>One of the features in yuzu, and a common one in other emulators, is the ability to separate the rendering thread from the main emulation thread. This makes better use of the CPU&rsquo;s resources, while also helping deliver better performance. That is exactly what Asynchronous GPU does in yuzu. Thanks to <a href="https://github.com/FernandoS27">Blinkhawk</a>, our Emulated GPU improved drastically, achieving better performance, stability, and accuracy. These changes introduce the option to adjust the GPU accuracy level while playing.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./31.png" title=" Performance may be reduced with more accurate levels"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/31_hu874a6b174b586e4799eca14c8c0a620a_14302_635x0_resize_q90_bgffffff_box_3.jpg" alt=" Performance may be reduced with more accurate levels"></a> <p class="has-text-centered is-italic has-text-grey-light"> Performance may be reduced with more accurate levels</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./v1.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> <div class="column is-bottom-paddingless"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./v2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Normal accuracy (left) and High accuracy (right) (Super Mario Odyssey)</p> <h2 id="one-line-to-fix-em-all">One Line to Fix &rsquo;em All</h2> <p><code>Toki Tori</code> had sound problems that were related to a floating point instruction, and while investigating the issue, <a href="https://github.com/MerryMage">Merry</a> and <a href="https://github.com/bunnei">bunnei</a> were worried that it may be a problem in <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a>, our ARM to x64 recompiler. It turns out the problem was just a bad default value in yuzu’s Dynarmic configuration. Remember what we said about bunnei and serendipity? With a simple one line change, a plethora of bugs were resolved! A special mention goes to <code>Pokémon Sword/Shield</code>, as that single line fixed the softlock that plagued us for months and made the game fully playable!</p> <p>Here&rsquo;s only a <em>partial</em> list of fixes:</p> <ul> <li><code>Pokémon Sword/Shield</code> - All softlocks fixed, running in tall grass fixed, hair salons fixed</li> <li><code>The Legend of Zelda</code>: Link&rsquo;s Awakening - Miniature placing fixed</li> <li><code>Toki Tori</code>, <code>Final Fantasy 7</code>, <code>Diablo 3</code>, <code>Project DIVA MegaMix</code> - Distorted audio fixed</li> <li><code>Team Sonic Racing</code> - Physics fixed</li> <li><code>Onimusha Warriors</code>, <code>Tales of Vesperia</code>, <code>The Messenger</code> - Game logic fixed</li> <li><code>Skyrim</code> - Audio looping fixed, game progresses further</li> <li><code>Oninaki</code> - Elevator softlock fixed</li> <li><code>All Unreal Engine 4 games</code> - Motion jitter fixed</li> <li><code>Super Smash Bros. Ultimate</code> - Fighter select jitter / flickers fixed</li> <li><code>Starlink</code> - Softlock fixed, game progresses further</li> </ul> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./32.png" title=" This sofa is no longer our enemy (Pokémon Sword/Shield)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/32_hu00d73d1c5fefdcd338d5aa6f12727654_2125108_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" This sofa is no longer our enemy (Pokémon Sword/Shield)"></a> <p class="has-text-centered is-italic has-text-grey-light"> This sofa is no longer our enemy (Pokémon Sword/Shield)</p> </div> </div> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p><a href="https://github.com/Morph1984">Morph</a> used some Kirby magic and implemented the first steps to get World of Light working in <code>Super Smash Bros. Ultimate</code>. Even though it doesn’t work yet, the first step is always the most important one!</p> <p><a href="https://github.com/Kewlan">Kewlan</a> strikes once again with more quality-of-life UI improvements. This time, they&rsquo;ve fixed the placement of button mappings in the input settings for single joycons.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./03.png" title=" From this"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/03_hu357ec922ff78c325504c869013d98453_4149_369x0_resize_q90_bgffffff_box_3.jpg" alt=" From this"></a> <p class="has-text-centered is-italic has-text-grey-light"> From this</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./05.png" title=" To this"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/05_hue994b5aea6167cafbf51207b2347098d_3907_365x0_resize_q90_bgffffff_box_3.jpg" alt=" To this"></a> <p class="has-text-centered is-italic has-text-grey-light"> To this</p> </div> </div> <p>Not stopping there, Kewlan added a slider for the analog stick modifier, allowing keyboard users to half press the emulated sticks. Additionally, the sliders now show percentages, making them easier to read.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./07.png" title=" Precision"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/07_hu031754dc94e2eaf02f8c86aab7420009_12194_391x0_resize_q90_bgffffff_box_3.jpg" alt=" Precision"></a> <p class="has-text-centered is-italic has-text-grey-light"> Precision</p> </div> </div> <p>And to top it off, he also added a way to restore the default value for a hotkey. An important part of the user experience is having a tidy and useful interface.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./08.png" title=" More customization"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/08_hu082283d31a9f1bb2515d6b460b2f5a5e_18327_457x0_resize_q90_bgffffff_box_3.jpg" alt=" More customization"></a> <p class="has-text-centered is-italic has-text-grey-light"> More customization</p> </div> </div> <p><a href="https://github.com/FearlessTobi">Tobi</a> fixed some of the internal workings of the input settings, and improved the games list sorting process. He also reworded some of our error and warning popups to be more user friendly.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./19.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/19_hu2e74790b89be0a5abc517fcc17d7bf16_13362_800x0_resize_q90_bgffffff_box_3.jpg" alt="The old errors"></a> </div> <div class="column is-bottom-paddingless"> <a href="./21_b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/21_b_hu88916568adb7a043d3f5269192d71c7f_8808_800x0_resize_q90_bgffffff_box_3.jpg" alt="The old errors"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The old errors</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./20_b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/20_b_huf49f42fdd1283251a8d91751553f4d7a_8155_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new errors"></a> </div> <div class="column is-bottom-paddingless"> <a href="./22_b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/22_b_hu734d13a26ac7a5aca7a017500560473f_7489_800x0_resize_q90_bgffffff_box_3.jpg" alt="The new errors"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The new errors</p> <p>Waluigi is not part of Smash, yet, but that doesn&rsquo;t mean he can&rsquo;t enjoy some limelight. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> decided to help the purple fellow and fixed the shadows in <code>Mario Tennis Aces</code>. The border color of textures in this game are in sRGB format, and we had some small precision errors. Now you can enjoy those intense matches!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./09.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/09_hu2cd678affd34c60a8c1532f398dbe061_2304772_800x0_resize_q90_bgffffff_box_3.jpg" alt="WAA! (Mario Tennis Aces)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./10.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/10_hu5075ef5a11e40e650ecfb5b4aeb72520_2462206_800x0_resize_q90_bgffffff_box_3.jpg" alt="WAA! (Mario Tennis Aces)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">WAA! (Mario Tennis Aces)</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> added indexed QUADS to Vulkan, this brings major graphical fixes to <code>Xenoblade Chronicles 2</code> and <code>Fast RMX</code>! Some barrier fixes are still required to get <code>Xenoblade Chronicles 2</code> rendering properly, but work on these rendering fixes is on-going.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./23.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/23_hu03958a2d5124a68158ceb78d6a42239e_20631_800x0_resize_q90_bgffffff_box_3.jpg" alt="From a dark void to RPG (Xenoblade Chronicles 2)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./24.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/24_hue36bd19c2254c20522554c6d81776f87_3177617_800x0_resize_q90_bgffffff_box_3.jpg" alt="From a dark void to RPG (Xenoblade Chronicles 2)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">From a dark void to RPG (Xenoblade Chronicles 2)</p> <p><a href="https://github.com/FernandoS27">Blinkhawk</a> implemented some optimizations to the GPU command list, improving performance in Diablo 3 and many other games. He also ported a <a href="https://github.com/Ryujinx/Ryujinx">Ryujinx</a> hack made by <a href="https://github.com/gdkchan">gdkchan</a>, <code>Fast GPU Time</code>. This helps force games to render at their maximum resolution, when they would otherwise dynamically lower it due to not hitting their target framerate. Some examples include <code>ARMS</code>, <code>Super Mario Odyssey</code>, <code>Splatoon 2</code>, <code>Luigi’s Mansion 3</code>, and <code>Mario Tennis Aces</code>. This is not only a graphical improvement, but also a way to avoid very high memory usage in dynamic resolution games. We still recommend the use of resolution mods, but if such mods are not available for your game, Fast GPU Time will help you. A good example of this is <code>The Legend of Zelda: Breath of the Wild</code> with the latest 1.6.0 update.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./35_b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/35_b_hu9d0923b791931155ddc089fb60ae6566_2704204_800x0_resize_q90_bgffffff_box_3.jpg" alt="Milk baths are over Link, go save Zelda or something (Legend of Zelda: Breath of the Wild)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./36_b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/36_b_huf4216eaae252d312688400257e01b494_3303545_800x0_resize_q90_bgffffff_box_3.jpg" alt="Milk baths are over Link, go save Zelda or something (Legend of Zelda: Breath of the Wild)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Milk baths are over Link, go save Zelda or something (Legend of Zelda: Breath of the Wild)</p> <h2 id="fixed-regressions">Fixed regressions</h2> <p><a href="https://github.com/Its-Rei">Rei</a> found a 3D texture regression in the Wooden Kingdom of <code>Super Mario Odyssey</code> that was affecting both Vulkan and OpenGL. <a href="https://github.com/FernandoS27">Blinkhawk</a> investigated it and found that there was a bug in the texture cache. Now it works as intended again, with no more fog stripes on trees.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./17.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/17_hu939536a217955857c4f75e3d7b91a28f_1143396_800x0_resize_q90_bgffffff_box_3.jpg" alt="As it should be (Super Mario Odyssey)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./18.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/18_hue7802322f4cfe58e9d60ec68535c9d43_988284_800x0_resize_q90_bgffffff_box_3.jpg" alt="As it should be (Super Mario Odyssey)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">As it should be (Super Mario Odyssey)</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> fixed a regression found in <code>Puyo Puyo Tetris</code> while running in OpenGL. With it in place, character portraits have their proper white border rendered.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./01.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/01_hua42d190de8642d5f029bd6b98b2e77a8_100257_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better, right? (Puyo Puyo Tetris)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./02.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/02_hu74420c7672f04a87ea1fa8bc32ead37c_81105_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better, right? (Puyo Puyo Tetris)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Better, right? (Puyo Puyo Tetris)</p> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> also fixed a regression in <code>Kirby Star Allies</code>, which restored the shading and life to this cute game. Kirby deserves a colorful world for his adventures!</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./25.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/25_hue5f718bcb836a91df26c2104dd4b6527_3897531_800x0_resize_q90_bgffffff_box_3.jpg" alt="Poyo! (Kirby Star Allies)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./26.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-apr-2020/26_hu134fd2fb7363546a46cf2142d7b178be_3938667_800x0_resize_q90_bgffffff_box_3.jpg" alt="Poyo! (Kirby Star Allies)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Poyo! (Kirby Star Allies)</p> <h2 id="future-plans">Future plans</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> also removed the need to have a Qt build with Vulkan support in Linux, which will help get Vulkan support in our Ubuntu pre-built packages.</p> <p>That’s all for now, folks! See you in the May report!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - Prometheus https://yuzu-mirror.github.io/entry/yuzu-prometheus/ Sat, 09 May 2020 05:37:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-prometheus/ <p>Hello there, yuzu fans! We are very excited to share the news of another major feature release. Thanks to the efforts of our dev Blinkhawk, yuzu now supports <code>Multicore CPU emulation</code>. Hop right in, to read more about it!</p> <p>Hello there, yuzu fans! We are very excited to share the news of another major feature release. Thanks to the efforts of our dev Blinkhawk, yuzu now supports <code>Multicore CPU emulation</code>. Hop right in, to read more about it!</p> <pre tabindex="0"><code>In Greek mythology, Prometheus is a Titan that aided humanity by teaching how to make fire. In modern society, it symbolizes the strive for scientific knowledge. The Prometheus Project is about that - the journey to new emulation techniques. </code></pre><p>Since we cannot really show performance boosts in pictures, here is a video by BSoD Gaming that takes you through all the improvements. <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/rbNd67vIO78" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> </p> <h2 id="what-is-multicore-cpu-emulation">What is Multicore CPU emulation?</h2> <p>As many of you might know, yuzu is considered a HLE (high level emulation) emulator. This means that instead of running the real Switch OS (known as <code>Horizon</code>), yuzu has recreated its own version of the OS, built entirely from the ground up. Like your PC, the Switch has multiple cores (4, actually), and the <code>Horizon OS</code> can run multiple tasks in parallel on these cores using a kernel construct known as a <a href="https://simple.wikipedia.org/wiki/Thread_(computer_science)">thread</a>. However, due to limitations of our old kernel design taken from Citra, yuzu was actually emulating this behavior using a single core on your host PC! This had led to an absurdly high CPU requirement for users.</p> <p>So, what is <code>&quot;Multicore CPU emulation&quot;</code>? Put simply, instead of emulating the CPU on a single thread yuzu will now emulate the CPU using multiple threads; <code>4</code> to be precise - one for each Switch CPU core. Although it might sound simple or easy, it is nevertheless the biggest undertaking this project has seen up until now.</p> <h2 id="yuzu-cpu-emulation">yuzu CPU emulation</h2> <p>yuzu&rsquo;s initial CPU emulation and kernel were heavily based on Citra&rsquo;s. The kernel emulated the external behavior of the Switch&rsquo;s kernel but vastly differed from the Switch OS. Instead of saving contexts and switching from one guest thread to another within the kernel, we used a mechanism within Citra&rsquo;s kernel that emulated the same behavior but with a complex system of <code>stops</code> and <code>callbacks</code>.</p> <p>Not only that, but in the typical tradition of previous emulators, yuzu used something called a <code>cycle timer</code>. A cycle timer is a mechanism to emulate <code>time</code> on consoles by counting each guest instruction executed and adding it to global <code>CPU ticks</code>. These ticks can then be transformed into time units like nanoseconds by using the guest&rsquo;s CPU frequency.</p> <h3 id="drawbacks">Drawbacks</h3> <p>Citra&rsquo;s model was perfectly fine for single core emulation. It was accurate, simple, and worked perfectly for the 3DS as it used only one of its two cores for apps/games. However, in the case of yuzu, this wouldn&rsquo;t hold true.</p> <p>The Switch is a much more complicated and modern system that pushes 4 CPU cores, where 3 are used for apps/games. Not only that, but the scheduling is more robust and can be used in some more interesting and more complicated ways. Using Citra&rsquo;s model for scheduling was all possible in yuzu but it had a few flaws of its own:</p> <ol> <li>The code didn&rsquo;t match the Switch OS and even though it had the same behavior, it was hard to keep track of changes and replicate them.</li> <li>The code was very complex as there was a callback for everything and was hard to maintain.</li> <li>This model would be extremely hard to run on multiple host threads.</li> </ol> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smash.png" title=" Super Smash Bros. Ultimate"> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/smash_hu101f8f5629c33cc11c22bc644a6e8b48_1889482_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Super Smash Bros. Ultimate"></a> <p class="has-text-centered is-italic has-text-grey-light"> Super Smash Bros. Ultimate</p> </div> </div> <h2 id="prometheus">Prometheus</h2> <p>You might&rsquo;ve heard rumors and whispers about this in the community recently. <code>Prometheus</code> is the internal codename for this feature&rsquo;s development and it is a total rework of three things:</p> <ul> <li>Kernel scheduling</li> <li>Boot management</li> <li>CPU management</li> </ul> <p><code>Prometheus</code> aims to ensure that emulation behaves the same as on the Switch while matching the code with the Switch&rsquo;s original OS code. And, as a by-product, host multicore support using host timing has been added to yuzu. Host timing is just yuzu using the host&rsquo;s (user&rsquo;s) internal clock for timing.</p> <p>The multicore feature of <code>Prometheus</code> is a beast in terms of thread handling. Originally yuzu used at best <code>2</code> threads: one for the CPU and one for the emulated GPU. Technically we also use a thread each for the UI, logging, the host GPU driver, and the host audio driver, but let&rsquo;s ignore them for the time being.</p> <p>With multicore, there are now <code>6</code> threads in use: four for the CPU, one for the timer, and one for the emulated GPU. It is worth noting that CPU core 4 is rarely used. Of these 6, effectively 5 threads have considerable use but not all will be running constantly.</p> <h3 id="planning">Planning</h3> <p><code>Prometheus</code> was a big undertaking that was set in two phases: planning phase and development phase. The planning phase was all about studying our current setup to make it work under this new scheme. This happened roughly over 8 months, and was mostly just research and brainstorming.</p> <p>During this phase, <a href="https://github.com/FernandoS27">Blinkhawk</a> encountered multiple challenges and considerations for development. He started studying other emulators that already did multicore emulation such as Cemu, RPCS3, and Ryujinx.</p> <p>These emulators all differed in their approaches to multicore. Some used Fibers for guest threads, 1:1 guest-host kernel threads, cycle timing, or host timing. In computer science, Fibers are lightweight threads of execution (<a href="https://en.wikipedia.org/wiki/Fiber_(computer_science)">Wikipedia</a>).</p> <p>For yuzu, we initially planned to use Fibers and cycle timers. We chose Fibers over kernel threads because changing a Fiber is at worst 50 host CPU cycles, whereas a kernel thread can be thousands of cycles and there&rsquo;s no guarantee that the host OS will start running it right away.</p> <p>In the case of cycle timers for yuzu multicore, they ended up being quite a pain. Cycle timers have many advantages over host timers:</p> <ol> <li>They are deterministic,</li> <li>They don&rsquo;t leak the host state, and</li> <li>They always advance for every instruction that Cycle timers are run.</li> </ol> <p>We tried many theoretical models for multicore cycle timers and they all were pretty hard to set up while still having flaws. Sadly, cycle timers don&rsquo;t work too great for multicore settings, because it is very hard to keep all the cores advancing at the same pace and to emulate idling accurately. For all these reasons, we opted for host timing instead.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bayo.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/bayo_hu19299866e2cf58365e376d05984f745f_2432767_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bayonetta 2"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bayo2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/bayo2_hu675859afa04abcaf1cd2c00333877b20_1663252_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bayonetta 2"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bayo3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/bayo3_hue187bf6f8d5b0cd2a83687ca303a3bd3_2726965_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bayonetta 2"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Bayonetta 2</p> <h3 id="development---issues">Development - Issues</h3> <p>Development started on February 1st of 2020. The first thing <a href="https://github.com/FernandoS27">Blinkhawk</a> did was to implement <a href="https://en.wikipedia.org/wiki/Spinlock">Spinlocks</a>, Fibers, and host timing. Afterwards, he went ahead with the massive overhaul.</p> <p>As he started the overhaul, the first issue he encountered was that for some reason yuzu was creating and destroying JITs (just-in-time compilers). Thus, whenever we resumed code from a guest thread and it went back to the JIT, it would hard crash. This was fixed by caching the JITs depending on the state of the page table, instead of creating a JIT every time. This way we could also avoid creating more JITs than necessary.</p> <p>The second issue occurred on booting the first homebrew on multicore, where we found that guest vsync was messed up. By redesigning the server session we were able to identify the cause and fix it.</p> <p>Here is where things started getting interesting. <a href="https://github.com/FernandoS27">Blinkhawk</a> implemented Condition Variables and Mutexes, which are the base syncing mechanisms in any multithreaded environment, and found an issue with how our JIT functions. Our JIT was heavily designed to work like Citra&rsquo;s and it expected that on any <code>SVC (Supervisor call)</code> call to kernel, the code returned back afterwards.</p> <p>Under the new architecture, a thread could easily call an <code>SVC</code> and be paused there, while another thread started running on that same JIT, thus causing a conflict. The easy solution was that instead of making a JIT per core, we would make a JIT per thread. This solution, however, costs us additional memory usage.</p> <p>After fixing these issues, we were finally able to boot <em>Super Mario Odyssey</em> on multicore, but many games were still soft-locking due to an old bug we thought eradicated: <code>Mutex Corruption</code>. Mutex Corruption happens due to issues with exclusive memory handling in ARMv8. As it turned out, <a href="https://github.com/MerryMage/dynarmic">dynarmic</a> had to be modified to fix it.</p> <p>After looking into it, <a href="https://github.com/FernandoS27">Blinkhawk</a> realized exclusive memory in <a href="https://github.com/MerryMage/dynarmic">dynarmic</a> was prone to a race condition when the exclusive address was written by a non-exclusive write. The solution was to save the current value on exclusive read and then atomic exchange it with a new value on exclusive write. By fixing this, most of the games were able to go in-game and many of them were fully playable.</p> <p>Two games had interesting bugs on multicore: <code>Luigi's Mansion 3</code> &amp; <code>Hyrule Warriors</code>.</p> <p><code>Luigi's Mansion 3</code> had an issue in which two threads, <code>A</code> &amp; <code>B</code>, were running on cores 0 and 1 and after some scheduling, <code>B</code> was rescheduled to core 0 and <code>A</code> to core 1. But a thread cannot start running on a new core until it is liberated (freed). So core 0 scheduler was holding <code>A</code> and waiting for <code>B</code> to be freed, while core 1 scheduler was holding <code>B</code> and waiting for <code>A</code> to be freed, thereby causing a deadlock. The solution was that instead of exchanging threads on scheduling switch, we free the current thread and switch to an “intermediary” thread and then from there proceed to the next thread.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lm3.png" title=" Luigi&#39;s Mansion 3"> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/lm3_hubad3a22faa814b510ae136b0698635f6_1703373_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Luigi&#39;s Mansion 3"></a> <p class="has-text-centered is-italic has-text-grey-light"> Luigi&#39;s Mansion 3</p> </div> </div> <p><code>Hyrule Warriors</code> had an issue that was caused by host timing. Our host timing implementation was based on Cemu&rsquo;s approach and used x64 architecture&rsquo;s hardware timer directly. This timer is way more accurate than ARMv8&rsquo;s hardware timer present in the Switch.</p> <p>The game soft locked at a point because a thread infinitely looped on a <code>TimedWait</code> of 30 nanoseconds. This function did some time calculations and later checked with the current time. If the timeout wasn&rsquo;t reached at that moment, an <code>SVC</code> was called which paused the thread for some time and let the next thread run, effectively causing a <code>yield</code>.</p> <p>In the Switch&rsquo;s hardware, the timer&rsquo;s accuracy isn&rsquo;t too great and a <code>TimedWait</code> of 30 nanoseconds always resulted in the thread calling the <code>SVC</code>. Our host timer, however, was way more accurate and that function would never call the <code>SVC</code>. The solution, ironically, was to reduce the accuracy of our host timer a bit, to better match actual hardware.</p> <p>Another interesting challenge was implementing pausing/resuming in multicore. As you know, you can pause and resume yuzu in our current versions. This was simple before because emulation occurred in steps and you just had to stop on the next step. But on multicore, emulation is continuous and unmanaged in the same sense.</p> <p>Thus, implementing this was very hard due to how multicore scheduling worked. The original solution was to modify scheduling to support it but that proved very complicated to do. After a while, we figured out a pretty easy solution without having to modify anything. We would create a kernel thread for each core and make that kernel thread pass control from and to the CPU Manager to the emulation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./acnh.png" title=" Animal Crossing: New Horizons"> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/acnh_hud544a227aae853be9bb13f0d81072e1f_1500385_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Animal Crossing: New Horizons"></a> <p class="has-text-centered is-italic has-text-grey-light"> Animal Crossing: New Horizons</p> </div> </div> <h2 id="what-to-expect-with-games">What to expect with games?</h2> <p>Many of you may be eager for multicore but have in mind that there are other bottlenecks as well. Not every game utilizes multithreading effectively and makes the most use of the Switch&rsquo;s CPU. Some games, like <code>Super Mario Odyssey</code>, barely use cores 1 &amp; 2, by doing all processing in core 0, effectively making them gain nothing from multicore. However, games like <code>Breath of The Wild</code> see <em>some</em> performance boost but are still bottlenecked by the emulated GPU.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/botw_1_huc53f1013d404a2d6a3fba25ccf9772c1_1937783_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-prometheus/botw_2_hubf29e1a8ac456615b9efd479b77587de_1891626_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild</p> <p>The emulated GPU depends on four things:</p> <ol> <li> <p>Your CPU&rsquo;s single-core speed. A single host CPU core translates all the commands from guest GPU (Switch) into host GPU (User) commands. So, having a CPU with great single-core speeds is most beneficial.</p> </li> <li> <p>Your GPU Bus Speed. yuzu heavily relies on the bandwidth available in the GPU bus. This is the speed at which data is uploaded to and from your GPU and this varies depending on PCIe generation and allocated lanes.</p> </li> <li> <p>The quality of your GPU drivers. AMD&rsquo;s drivers for OpenGL are terrible while NVIDIA&rsquo;s are great.</p> </li> <li> <p>Your host GPU itself, be it NVIDIA, AMD, or Intel.</p> </li> </ol> <p>Lastly, be aware that RAM speed, amount of RAM, and the type of processor in your system, will also influence your experience. The initial release may use additional memory (100mb to 3Gb depending on the game). We are currently stability-testing a fix for this additional memory usage.</p> <h3 id="current-known-issues">Current Known Issues</h3> <p>Getting multicore to run perfectly is a big deal and in our internal testing we found that <code>audio</code> can be slower in multicore. Activate <code>Audio Stretching</code> to mitigate the issue. If you come across any softlock or bug that is not present in mainline but present in early access, notify us and include the following data with it.</p> <pre tabindex="0"><code>* Game name * Version of the game * Game savefile * Steps to reproduce the softlock * Whether the softlock is random or consistent (always happens in the same spot) </code></pre><p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report March 2020 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/ Mon, 20 Apr 2020 07:11:00 -0300 GoldenX86 https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/ <p>How are you doing in this quarantine, yuzu fans? We hope you are all staying in your homes safe and sound. Today, we are bringing you a report on a few changes from the past month for both the Early Access and regular Mainline versions of yuzu.</p> <p>How are you doing in this quarantine, yuzu fans? We hope you are all staying in your homes safe and sound. Today, we are bringing you a report on a few changes from the past month for both the Early Access and regular Mainline versions of yuzu.</p> <p>We have on our plate a couple of bug fixes, some graphical improvements, the first “performance win” for Intel GPUs, a really serious case of serendipity, and some groundwork for amazing improvements that will be coming to you in a “near-ish” future.</p> <h2 id="bug-fixes-and-improvements">Bug fixes and improvements</h2> <p>After some intensive debugging by <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, an OpenGL rendering bug in <em>ARMS</em> (that was with us since the game started to boot), was solved by simply updating our buildbot virtual machine from Visual Studio 2017 to the latest 2019 version. Thanks to <a href="https://github.com/DarkLordZach">DarkLordZach</a> for the change!</p> <p>PSA - Please update to or install the latest <a href="https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads">Visual C++ 2019 x64 redistributable</a>, or else you won’t be able to open yuzu, as it will complain that the library <code>VCRUNTIME140.dll</code> cannot be found.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./03.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/03_huba731c05b2030af474625a750c3c6b98_1508838_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better, right?"></a> </div> <div class="column is-bottom-paddingless"> <a href="./04.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/04_huba731c05b2030af474625a750c3c6b98_2290030_800x0_resize_q90_bgffffff_box_3.jpg" alt="Better, right?"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Better, right?</p> <p><a href="https://github.com/perillamint">perillamint</a> and <a href="https://github.com/bunnei">bunnei</a> stubbed (this means to send a fake <code>everything’s OK</code> signal so the game can continue) some VR related services. These changes are needed for version 1.6.0 of <em>The Legend of Zelda: Breath of the Wild</em>, 1.3.0 of <em>Super Mario Odyssey</em>, and versions 3.1.0 and above of <em>Super Smash Bros. Ultimate</em>.</p> <p>Commercial games aren&rsquo;t everything. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> decided to give homebrew lovers and old-school gamers something to play with by implementing some attributes from the old OpenGL 1.X and 2.X days. It’s now possible to run <code>Xash3D</code>, so you can frag in Counter-Strike, or follow G-Man’s orders in Half-Life! Currently, this needs to be manually built with newer dependencies, but that should be solved for good in the near future.</p> <p><a href="https://github.com/Margen67">Margen67</a> and <a href="https://github.com/Morph1984">Morph</a> wanted to improve the graphics for games and so they added Anisotropic Filtering (AF) to yuzu. With this feature in place, distant textures now look much sharper, improving game quality even over what the original Switch can produce! Games like <em>Pokémon Sword</em>, <em>Pokémon Shield</em>, and <em>Fire Emblem: Three Houses</em> benefit a lot from this; however, some other games don’t respond well to this new feature, one example being <em>Astral Chain</em>. Feel free to experiment with it!</p> <p>An example in <em>Pokémon Sword</em>:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./15.png" title=" AF Off"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/15_hub6fd0ed88b11c739593d60d9d70227d6_2376597_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" AF Off"></a> <p class="has-text-centered is-italic has-text-grey-light"> AF Off</p> </div> <div class="column has-text-centered"> <a href="./14.png" title=" AF 16x"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/14_hu47323c1785615f481e268616f3cef3a8_2619321_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" AF 16x"></a> <p class="has-text-centered is-italic has-text-grey-light"> AF 16x</p> </div> </div> <p>And another example in <em>Fire Emblem: Three Houses</em>:</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./01.png" title=" AF Off"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/01_hu64956838eccc65f162b2fcdc624c92ab_4230166_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" AF Off"></a> <p class="has-text-centered is-italic has-text-grey-light"> AF Off</p> </div> <div class="column has-text-centered"> <a href="./02.png" title=" AF 8x"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/02_huab724fcd5e66b238ff86d06cc451908d_4567500_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" AF 8x"></a> <p class="has-text-centered is-italic has-text-grey-light"> AF 8x</p> </div> </div> <p>Shader cache invalidations are something our users don’t like at all. We don&rsquo;t either, but it’s all part of the process of improving yuzu to achieve better performance and accuracy. For example, one of our recent invalidations was needed to fix the reflections in <em>Luigi’s Mansion 3</em>, making certain parts of the game playable.</p> <p>Because the art of dancing is important, <a href="https://github.com/namkazt">namkazt</a> and <a href="https://github.com/ReinUsesLisp">Rodrigo</a> have been fighting with the code, allowing us to enjoy 3D graphics in <em>Hatsune Miku: Project DIVA MEGA39&rsquo;s</em>, and as collateral, fixed some rendering issues in <em>Bayonetta 1</em> and <em>Super Smash Bros. Ultimate</em>.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./07.png" title=" Miku Miku Dance!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/07_hub3fcad4e816063b14bc5f4cec2e99abb_1031672_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Miku Miku Dance!"></a> <p class="has-text-centered is-italic has-text-grey-light"> Miku Miku Dance!</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./08.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/08_huf23a89b7915fd5e96bfc51719849d6bb_452459_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate&#39;s menu (Before &amp; After)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./09.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/09_hu59139d71bd9dea5c1ee169483351f4a3_670564_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Smash Bros. Ultimate&#39;s menu (Before &amp; After)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Smash Bros. Ultimate&#39;s menu (Before &amp; After)</p> <p><a href="https://github.com/Kewlan">Kewlan</a>, a regular in our Discord Server, submitted a small change to our input mapping GUI, changing the position of the shoulder buttons so they no longer make anyone angry.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./11.png" title=" Incorrect."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/11_huba87b04d42b97d6b1ad0d7366d6c2fd6_3249_192x0_resize_q90_bgffffff_box_3.jpg" alt=" Incorrect."></a> <p class="has-text-centered is-italic has-text-grey-light"> Incorrect.</p> </div> <div class="column has-text-centered"> <a href="./12.png" title=" Much better."> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-mar-2020/12_hu132b5e3351c683c044b063a9e9bd8921_2793_193x0_resize_q90_bgffffff_box_3.jpg" alt=" Much better."></a> <p class="has-text-centered is-italic has-text-grey-light"> Much better.</p> </div> </div> <p>We also have a cool improvement by <a href="https://github.com/FearlessTobi">Tobi</a>. The Switch is a surround sound compatible console and our implementation of downmixing removed any channel that wasn’t left or right. By keeping the extra channels and mixing them in the left and right stereo outputs, the sound in tons of games, including <em>Luigi’s Mansion 3</em>, <em>Sonic Forces</em>, and <em>Bayonetta</em>, has been improved.</p> <h2 id="a-peculiar-case-of-even-a-broken-clock-is-right-twice-a-day">A peculiar case of &ldquo;Even a broken clock is right twice a day!&rdquo;</h2> <p>The Nintendo Switch supports <code>ASTC</code>, a type of texture format generally used in mobile hardware, such as phones and tablets, in order to reduce bandwidth usage (a limited resource in those devices). Since it&rsquo;s a heavily compressed format, decoding it via the CPU, like it is normally done on PC, is a time-consuming task.</p> <p>To give an example, Astral Chain is a game that uses <code>ASTC</code> very extensively and in bizarre ways, as previous fixes and optimizations have shown. On NVIDIA and AMD graphics hardware, the first scene of a new game typically takes <code>17</code> seconds to load. The GPU has to wait for the CPU to decode all the <code>ASTC</code> textures, and thus slowing down the whole process.</p> <p>Thanks to <a href="https://github.com/ReinUsesLisp">Rodrigo&rsquo;s</a> research, it was discovered that on any recent Intel GPU this same operation is immediate and occurs with no delay, due to it being the only vendor providing a native <code>ASTC</code> decoder in their hardware. That’s right, the best way to experience Astral Chain in yuzu is with a small, and typically inferior, iGPU (like the ones that come in any desktop or notebook CPU from Intel).</p> <p>On the topic of formats, implementing the <code>RG32</code> and <code>RGB32</code> vertex formats fixed a room that refused to load in The Legend of Zelda: Link’s Awakening in Vulkan. Great work, <a href="https://github.com/ReinUsesLisp">Rodrigo</a>!</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./13.PNG" title=" It works!"><img src="./13.PNG" alt=" It works!"></a> <p class="has-text-centered is-italic has-text-grey-light"> It works!</p> </div> </div> <h2 id="paving-the-road-for-even-bigger-changes">Paving the road for even bigger changes</h2> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a>&rsquo;s initial work on <code>Transform Feedback</code> has concluded and is now partially working. This has already helped games like POKKÉN Tournament DX, Donkey Kong Country: Tropical Freeze and Xenoblade Chronicles.</p> <p>An optimization by <a href="https://github.com/FernandoS27">Blinkhawk</a> reduced the use of RAM by 1GB. When talking about RAM usage, less is best!</p> <p>Now, for an important but also astonishing fix; one that nobody expected, not even our project leader <a href="https://github.com/bunnei">bunnei</a>. While he was working on fixing what seemed to be a simple bug on Final Fantasy VIII, he also accidentally fixed Super Smash Bros. Ultimate fights! This case of serendipity, is without a doubt, a surprise, but a welcome one.</p> <p>Now all users can brawl to their hearts&rsquo; content thanks to a measly 5-line change in yuzu’s code! However, keep in mind that any Super Smash Bros. Ultimate update newer than 3.1.0 will work, but will also make the characters T-pose, resulting in hilarious fights and victory screens. We’re working on resolving this, but for now, stick to update 3.1.0 or older!</p> <p><a href="https://github.com/bunnei">bunnei</a> fixed audio crackling in various games like Crash Team Racing and Super Mario Odyssey. We are slowly but surely improving our audio quality. He also implemented initial support for <code>32-bit ARM</code> emulation. Nothing tangible can be tested yet, but thanks to this, it will be possible in the future to run <code>32-bit</code> games like Mario Kart 8 Deluxe.</p> <p>And last but not least, <a href="https://github.com/FernandoS27">Blinkhawk</a> has been making some serious changes to yuzu&rsquo;s GPU emulation, while also laying the foundation for the recent rework of yuzu&rsquo;s Virtual Memory Manager (codename: Project Epimetheus).</p> <p>These, in turn, will help further advance the development of Project Prometheus, one of the super-secret Projects our devs are currently working on to bring some considerable changes to yuzu’s performance and hardware requirements. Stay tuned to hear more about them in the future!</p> <p>That’s all for now folks, see you in the April report.</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> New Feature Release - Vulkan https://yuzu-mirror.github.io/entry/yuzu-vulkan/ Tue, 03 Dec 2019 21:17:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-vulkan/ <p>A very good day to all you yuz-ers out there. The curtains are up and the most awaited feature of yuzu is finally here! The Vulkan renderer for yuzu is now available for users on Early Access. To find out more about it, jump right in!</p> <p>A very good day to all you yuz-ers out there. The curtains are up and the most awaited feature of yuzu is finally here! The Vulkan renderer for yuzu is now available for users on Early Access. To find out more about it, jump right in!</p> <h2 id="vulkan-for-yuzu">Vulkan for yuzu</h2> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vulk_smo.png" title=" Super Mario Odyssey"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_smo_hu8cd9cc4430f2f9b2fa2caabb14f35697_2047322_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Super Mario Odyssey"></a> <p class="has-text-centered is-italic has-text-grey-light"> Super Mario Odyssey</p> </div> <div class="column has-text-centered"> <a href="./vulk_astral.png" title=" Astral Chain"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_astral_huc5bd5ce52d09c0f12b37480978ecc03a_1015632_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Astral Chain"></a> <p class="has-text-centered is-italic has-text-grey-light"> Astral Chain</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vulk_zla_1.png" title=" Link&#39;s Awakening"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_zla_1_hu54046471266d12fa48299d33cb3e6d50_1700823_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Link&#39;s Awakening"></a> <p class="has-text-centered is-italic has-text-grey-light"> Link&#39;s Awakening</p> </div> <div class="column has-text-centered"> <a href="./vulk_botw.png" title=" Breath of the Wild"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_botw_hub1593c4000ffd165749ae4f8cea9943e_1375163_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Breath of the Wild"></a> <p class="has-text-centered is-italic has-text-grey-light"> Breath of the Wild</p> </div> </div> <p>For the past year, the most awaited and requested feature for yuzu has been the Vulkan Renderer. Many users, especially those with AMD GPUs, have been patiently waiting for this day. <br> Download the latest <a href="https://yuzu-mirror.github.io/help/early-access/">Early Access</a> build via the installer now to try it out! After you download the build, go to <code>Emulation -&gt; Configure -&gt; Graphics</code> and select <code>Vulkan</code> in the API dropdown.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Vulkan_GUI.png" title=" yuzu Configuration"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/Vulkan_GUI_hub8ee885c80f97483703f814752312c0a_11470_573x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Configuration"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Configuration</p> </div> </div> <blockquote> <p style="color:lawngreen;"><b>We highly recommend using the latest drivers, or beta drivers, as vendors are actively fixing bugs in their Vulkan drivers. Nvidia appears to encounter the least bugs, but it is still strongly recommended to keep your drivers up to date.</b></p> </blockquote> <h2 id="how-it-all-started">How It All Started&hellip;</h2> <p>Barely a year had passed since the Nintendo Switch launched, but there it was, <code>yuzu - The Nintendo Switch Emulator</code> - already running several games with stellar performance and stunning graphics. But it came with a caveat; to deliver that performance, yuzu exclusively needed an Nvidia GPU among several other hardware requirements.</p> <p>This was mainly due to the low performance on AMD GPUs OpenGL Windows drivers. For AMD users, this meant that they either had to start using Linux, where the drivers were a <em><strong>little</strong></em> better, or had to buy an Nvidia GPU, and neither of those was an easy choice. Thus we quickly realized the need for a way to deliver the same performance to our AMD users, and Vulkan seemed to be the answer!</p> <p>To tackle this, one of our resident GPU emulation experts - <a href="https://github.com/ReinUsesLisp">Rodrigo</a> (aka ReinUsesLisp) - set out to master Vulkan and implement a renderer in yuzu using this API. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> started experimental work on the Vulkan renderer, with the customary <code>Hello World</code> - by rendering a <code>RED screen</code>.</p> <p>He used existing switch homebrew like <code>SpaceNX</code> and <code>Push A button</code>, and later wrote his own homebrew app of a <code>blinking screen</code> and got them to render using the Vulkan renderer successfully. With some progress, it was now time for him to implement shaders on the Vulkan renderer. (If you are interested, you can check out the homebrew <a href="./clear-color.nro">here</a>.) <br></p> <p> </p> <h4 id="before-we-get-into-deeper-technical-details-we-need-to-understand-a-few-things">Before we get into deeper technical details, we need to understand a few things:</h4> <ul> <li>The Nintendo Switch has an Nvidia GPU and games can use either OpenGL or NVN API (Nvidia proprietary API), to communicate with the GPU and render visuals. (Games might use Vulkan, but we are yet to see any games using it)</li> <li>GPUs use small programs called shaders to control the GPU rendering pipeline. <a href="https://www.khronos.org/opengl/wiki/Rendering_Pipeline_Overview">For more info, read here.</a></li> <li>Shaders have instructions inside them for the GPU to perform various types of operations.</li> <li>yuzu decodes these shader instructions from games to guest GPU (Switch), turns them into GLSL (OpenGL Shading Language) code, and then rebuilds those shaders to work on the Host GPU (User GPU) to get games rendering.</li> <li>SPIR-V is an intermediate language for defining shaders in Vulkan, which is sort of similar to OpenGL&rsquo;s GLSL. <a href="https://www.khronos.org/registry/spir-v/">For more info, read here.</a></li> </ul> <p> </p> <h4 id="now-that-we-have-some-context-lets-dive-deeper">Now that we have some context, let&rsquo;s dive deeper!</h4> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> wrote <a href="https://github.com/ReinUsesLisp/sirit"><strong>Sirit</strong></a> - a runtime SPIR-V assembler to generate SPIR-V code easily. Basically, there isn&rsquo;t a built-in way to generate SPIR-V code. Most game developers actually use a high level shader language and compile them statically. And as yuzu could only convert the game shaders to GLSL, he used <code>Sirit</code> to generate SPIR-V shaders, instead of GLSL, for Vulkan.</p> <blockquote> <p style="color:lawngreen;"><b>Game developers usually write shaders using GLSL or HLSL and compile it to SPIR-V with a compiler and send that to the driver. </blockquote> <p>However, yuzu Vulkan generates SPIR-V on the go and sends that to the driver.</b></p></p> <p>When development began, yuzu didn&rsquo;t have a shader IR (intermediate representation). As a result, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> had to copy and adapt many parts of the code, to the point that it became bug ridden and unmaintainable. At this stage, we decided to write a shader IR that would allow us to share the shader decoding logic on both GLSL and SPIR-V.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./vulk_bork1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_bork1_hu6aebe2672ab3c54937577d1315462b2e_695111_800x0_resize_q90_bgffffff_box_3.jpg" alt="Vulkan experiments - Super Mario Odyssey (broken)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_bork2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_bork2_hu82f36afe6f115b95e868b5b351dda87b_451524_800x0_resize_q90_bgffffff_box_3.jpg" alt="Vulkan experiments - Super Mario Odyssey (broken)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Vulkan experiments - Super Mario Odyssey (broken)</p> <article class="message"> <div class="message-header is-dropdown"> <p>What is shader IR?</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> An IR (intermediate representation) is a representation of the program &ldquo;between&rdquo; source and target languages. A shader IR in yuzu&rsquo;s context would be the representation of game shaders decoded from their actual form and before they were rebuilt for GLSL or SPIR-V. </div> </article> <p>In regards to Shader IR, <a href="https://github.com/FernandoS27">Blinkhawk</a> rewrote how guest shaders are analysed in control flow (the code that tells how a shader diverges in execution) from the ground up. He created a decompiler that removes stack based branches which result in under performant shaders in Intel and AMD, and created a more advanced decompiler that could convert all the branches in the shaders into higher level structures (ifs, loops, etc). He also corrected control flow in SPIR-V shaders and fixed some crashes that occurred on AMD due to unoptimized control flow structures.</p> <p>Simply put, he redid the whole system on which shader IR is based, after <a href="https://github.com/ReinUsesLisp">Rodrigo</a> converted most of the instructions into IR and setup the foundation. <br></p> <p style="color:lawngreen;"><b><i>Kind of like reorganizing a messy closet, after segregating its contents.</i></b></p> <p>While the shader IR was being worked on, <a href="https://github.com/ReinUsesLisp">Rodrigo</a> was parallelly working on the Vulkan renderer, and managed to get more homebrew working, but soon ran into further issues. As a result, development of Vulkan didn&rsquo;t continue for a few months, and quite some time was spent implementing the Shader IR.</p> <h2 id="problems-and-solutions">Problems and Solutions&hellip;</h2> <h4 id="problem-1-texture-cache">Problem 1: Texture Cache</h4> <article class="message"> <div class="message-header is-dropdown"> <p>What is a Texture Cache?</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> The texture cache handles everything related to texture management. When a game asks to sample a texture, we create a texture like the game wants and we fill its texels (pixels) from guest data. When the game wants to render to a texture, we do the same process. The texture cache is full of border cases that need to be properly handled. </div> </article> <p><a href="https://github.com/ReinUsesLisp">Rodrigo</a> and <a href="https://github.com/FernandoS27">Blinkhawk</a>, our GPU emulation experts, had just started working on the shader IR and <a href="https://github.com/ReinUsesLisp">Rodrigo</a> ran into issues with the Vulkan renderer. Upon investigation, they realized that the existing texture cache was too heavily embedded in OpenGL and there was no easy way to make it API agnostic. In other words, they found it was very difficult to decouple the texture cache&rsquo;s backend logic from the frontend, so that they could use it for both OpenGL and Vulkan.</p> <p>Though <a href="https://github.com/ReinUsesLisp">Rodrigo</a> (with some help from <a href="https://github.com/FernandoS27">Blinkhawk</a>) implemented a primitive texture cache on Vulkan to get <code>Sonic Mania</code> &amp; <code>Cave Story+</code> rendering, <a href="https://github.com/FernandoS27">Blinkhawk</a> saw the need for a better approach to solve this problem. He (<a href="https://github.com/FernandoS27">Blinkhawk</a>) then reimplemented the texture cache from scratch, using some of <a href="https://github.com/ReinUsesLisp">Rodrigo&rsquo;s</a> ideas and some inspiration from the original texture cache. This is a generic texture cache that is able to handle all of the border cases, in generic code that can be implemented on both OpenGL and Vulkan.</p> <p> </p> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/phz9zJqAv2I" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> <p> </p> <h4 id="problem-2-buffer-cache">Problem 2: Buffer cache</h4> <article class="message"> <div class="message-header is-dropdown"> <p>What is a Buffer Cache?</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> A buffer cache stores &amp; caches most guest GPU memory objects (like vertex data, index data, constant buffers, global memory and others) into host GPU memory objects, thus avoiding having to continuously upload/download data in between Host &amp; Guest GPUs. This is needed because the Host GPU can&rsquo;t normally use Guest GPU&rsquo;s data directly. <code>Host GPU = yuzu user's GPU</code> &amp; <code>Guest GPU = Switch GPU</code> </div> </article> <p>yuzu&rsquo;s original buffer cache was a stream based buffer, which was brought from Citra. <a href="https://github.com/ReinUsesLisp">Rodrigo</a> observed that this buffer cache couldn&rsquo;t handle large buffers properly. So he made a dual cache - with a stream buffer for small buffers and a single buffer for large buffers, which allowed him to handle memory more easily on Vulkan.</p> <p>Later, <a href="https://github.com/FernandoS27">Blinkhawk</a> took over and sought to improve it further by using ideas from texture cache. While it worked as an experiment, it had some performance issues. So, he rewrote the buffer cache from scratch, based on a completely new approach, so that it was compatible with both OpenGL and Vulkan. This new approach for the buffer cache was to map 1:1 guest GPU memory with host GPU memory i.e., yuzu will now automatically allocate GPU memory chunks depending on the game&rsquo;s utilization and a single chunk on guest memory will be mapped to a single chunk on host memory.</p> <h4 id="benefits-of-a-buffertexture-cache">Benefits of a buffer/texture cache</h4> <ul> <li>Improves performance significantly,</li> <li>reduces syncing between Guest/Emulated GPU and Host GPU,</li> <li>allows controlling host memory capacity, etc.</li> </ul> <blockquote> <p style="color:lawngreen;"><b><i>Trivia: The Buffer Cache is what got animations working on Smash Ultimate (along with compute shaders)</i></b></p> </blockquote> <h2 id="vulkan-continued">Vulkan Continued&hellip;</h2> <p>As a result of fixing the aforementioned problems, we had managed to abstract away the OpenGL backend from the frontend. This was very crucial for the progress of Vulkan development, as it allowed us to narrow down issues from <code>something is broken and I don't know what it is</code> to <code>this is a Vulkan exclusive bug</code>. Along the way, we fixed many long standing bugs on popular games like fog and water interactions in Super Mario Odyssey, and found new ones, like broken shadows in the same game.</p> <h4 id="now-lets-get-to-the-part-that-everyone-cares-about">Now, let&rsquo;s get to the part that everyone cares about:</h4> <p><code>How is the performance compared to OpenGL?</code> <br> With Vulkan on yuzu, AMD GPUs now perform mostly on par with Nvidia GPUs. As an added benefit, Intel onboard graphics now have better or around the same overall performance too. On average, the performance is still a bit lower than what you&rsquo;d observe on OpenGL, but that could change very soon with future optimisations.</p> <blockquote> <p style="color:lawngreen;"><b><i>Note 1: <br> </blockquote> <p>Some games don&rsquo;t yet work with Vulkan on Nvidia GPUs. This is a known issue and we are investigating. </i></b></p></p> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./Vulkan_AMD.png" title=" yuzu Vulkan vs OpenGL (on AMD GPU)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/Vulkan_AMD_hud71a87c48a0f8c2131b7ab69eb4dad65_140642_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Vulkan vs OpenGL (on AMD GPU)"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Vulkan vs OpenGL (on AMD GPU)</p> </div> <div class="column has-text-centered"> <a href="./Vulkan_Nvidia.png" title=" yuzu Vulkan vs OpenGL (on Nvidia GPU)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/Vulkan_Nvidia_hu8452ad24c87958cd484d58762741d7c3_145720_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Vulkan vs OpenGL (on Nvidia GPU)"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Vulkan vs OpenGL (on Nvidia GPU)</p> </div> <div class="column has-text-centered"> <a href="./Vulkan_Intel.png" title=" yuzu Vulkan vs OpenGL (on Intel iGPU)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/Vulkan_Intel_hud71a87c48a0f8c2131b7ab69eb4dad65_137767_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Vulkan vs OpenGL (on Intel iGPU)"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Vulkan vs OpenGL (on Intel iGPU)</p> </div> </div> <blockquote> <p style="color:lawngreen;"><b><i>Note 2: <br> </blockquote> <p>Some games perform worse with Vulkan due to how they change framebuffers. <br> This is a result of how the games were developed, and might change with vendor driver improvements.</i></b></p></p> <p> </p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vulk_intel.png" title=" yuzu Vulkan (on Intel iGPU)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_intel_hu11acb9a2630ae145a45e09e9654cd2d6_1461191_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" yuzu Vulkan (on Intel iGPU)"></a> <p class="has-text-centered is-italic has-text-grey-light"> yuzu Vulkan (on Intel iGPU)</p> </div> </div> <p>One noticeable improvement is the shader build times. We didn&rsquo;t profile the others, but Nvidia&rsquo;s SPIR-V compiler is surprisingly fast. Where some effects on OpenGL GLSL may take 4 to 5 seconds to build, Vulkan SPIR-V may take only a few milliseconds.</p> <p>yuzu&rsquo;s OpenGL and Vulkan backends are now close in feature parity, but both still lack some features the other has. <a href="https://github.com/Rodrigo">Rodrigo</a> has been recently experimenting with adding tessellation shaders to Vulkan instead of OpenGL, since the Vulkan codebase is better laid out which makes things easier to implement for him. Vulkan also lacks a few texture formats that we have yet to add, since we haven&rsquo;t seen games using them.</p> <blockquote> <p style="color:lawngreen;"><b><i>Fun Fact: Tessellation shaders are used in the recently released Luigi's Mansion 3!</i></b></p> </blockquote> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vulk_tess.png" title=" Testing Tessellation shaders in Vulkan"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_tess_hu6f420012e14f2fba372bc812f6f69214_151839_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Testing Tessellation shaders in Vulkan"></a> <p class="has-text-centered is-italic has-text-grey-light"> Testing Tessellation shaders in Vulkan</p> </div> </div> <h2 id="behold---vulkan-in-all-its-glory">Behold - Vulkan in All It&rsquo;s Glory!</h2> <p>Here are a few screenshots taken with yuzu using the Vulkan renderer.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./vulk_smo_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_smo_1_hu02af87b290c05c51dd9bd6b66cf5abca_1806095_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_smo_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_smo_2_hua0b76da85fe5c66b4937c41ba51bba02_2253210_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_smo_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_smo_3_hu9ec2fa93e98883fd362d7f02a2d2d5f6_1535979_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_smo_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_smo_4_hu4c0a853d451edaa2e4e42b9d264c0313_4858627_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./vulk_zla_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_zla_2_hubea012bfd620d288d9ba30c3eac16dbf_4938941_800x0_resize_q90_bgffffff_box_3.jpg" alt="Link&#39;s Awakening"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_zla_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_zla_3_hu8dc95f068d7031160d70c10964e84bbd_5987753_800x0_resize_q90_bgffffff_box_3.jpg" alt="Link&#39;s Awakening"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_zla_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_zla_4_hu67af7c6d92f29c294d653f8680a42d66_4967353_800x0_resize_q90_bgffffff_box_3.jpg" alt="Link&#39;s Awakening"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_zla_5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_zla_5_hu16e635b5b6950195c4d4cf0319c56b9d_3189181_800x0_resize_q90_bgffffff_box_3.jpg" alt="Link&#39;s Awakening"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Link&#39;s Awakening</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./vulk_marvel.png" title=" Marvel Ultimate Alliance 3"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_marvel_hufb06a06f4f6102042da2631d58d96d38_2607665_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Marvel Ultimate Alliance 3"></a> <p class="has-text-centered is-italic has-text-grey-light"> Marvel Ultimate Alliance 3</p> </div> <div class="column has-text-centered"> <a href="./vulk_oni_1.png" title=" Onimusha: Warlords"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_oni_1_hu056751bd811bd707d35e36df80711465_3924551_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Onimusha: Warlords"></a> <p class="has-text-centered is-italic has-text-grey-light"> Onimusha: Warlords</p> </div> <div class="column has-text-centered"> <a href="./vulk_re4.png" title=" Resident Evil 4"> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_re4_hua2711e782e139970a5b16aeff3200812_4019003_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Resident Evil 4"></a> <p class="has-text-centered is-italic has-text-grey-light"> Resident Evil 4</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./vulk_sw_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_sw_1_hu16d2a398b1fa7635a7a0d42e739c3640_2214856_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Sword/Shield"></a> </div> <div class="column is-bottom-paddingless"> <a href="./vulk_sw_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-vulkan/vulk_sw_2_hu9221102cd49fc9a3745fa3cf5a27d657_2437614_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon Sword/Shield"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon Sword/Shield</p> <h2 id="vulkan-and-its-shortcomings">Vulkan and Its Shortcomings</h2> <p>While many uninformed users believe Vulkan to be a saviour and a single answer to all performance issues with OpenGL, even though their issues were because of their old hardware, Vulkan is not without any shortcomings. To understand these, let us first understand the situation with the Nintendo Switch&rsquo;s GPU.</p> <p>Maxwell and Pascal Nvidia GPUs are heavily optimized in hardware for D3D11 and OpenGL software. It seems that whenever Nvidia gets a chance to put something in the hardware, they take it. Since the Nintendo Switch&rsquo;s GPU is a 2nd generation Maxwell GPU, it comes with additional features like <a href="https://www.khronos.org/opengl/wiki/ASTC_Texture_Compression">ASTC</a> textures and efficient <a href="https://en.wikipedia.org/wiki/Half-precision_floating-point_format">half-precision float</a> math.</p> <p>Nvidia&rsquo;s OpenGL driver is a scary monstrosity, it&rsquo;s <code>really</code> fast. And to achieve this Nvidia has, over the years, invested resources heavily to make their OpenGL software (the driver) and their hardware really efficient. They have not only optimized their software to be fast for OpenGL, but also their hardware.</p> <p>Both NVN and OpenGL expose Nvidia&rsquo;s Maxwell hardware at its greatest. Lots of OpenGL features that are (sometimes wrongly) considered &ldquo;legacy&rdquo;, &ldquo;old&rdquo;, or even &ldquo;emulated by the driver&rdquo; are actually natively supported by the hardware (in the case of Nvidia). The problem arises when Switch games use these features.</p> <p>Vulkan wasn&rsquo;t designed with these features in mind. Some of these features were intentionally left out of the standard and the committee does not want to add them (not even as extensions) unless they really have to, or big companies behind CAD software require it. To sum it up, if a Switch game uses <code>X feature</code> supported natively by the hardware, and this feature is not available on Vulkan; it has to be emulated with a slower path or not emulated at all.</p> <p style="color:lawngreen;"><b>Here is a reduced list of features that are supported by Nvidia Maxwell hardware - exposed in OpenGL, but not supported in Vulkan:</b></p> <table> <thead> <tr> <th>OpenGL Feature</th> <th>Games that use it</th> </tr> </thead> <tbody> <tr> <td>Minus one to one depth space - <code>(-1 to +1)</code></td> <td>Used in nearly all Nintendo games</td> </tr> <tr> <td>Quads, quad strips, polygons and line loops primitive topologies (e.g. rendering geometry with quads instead of triangles)</td> <td>Used by Xenoblade Chronicles 2</td> </tr> <tr> <td>Bindless textures</td> <td>Used by Super Mario Party, Super Mario Odyssey and others</td> </tr> <tr> <td>Legacy varyings (vertex attributes from the D3D9 era, like front colors and fog coordinates)</td> <td>Used by Dragon Quest Builders</td> </tr> <tr> <td><code>GL_CLAMP</code> texture filtering</td> <td>Used by Hollow Knight</td> </tr> <tr> <td><code>uint8</code> indices (available as an extension, not supported on all vendors)</td> <td>Used by Pokémon Let&rsquo;s Go: Eevee and many others</td> </tr> <tr> <td>Conditional rendering (available as an extension, but not exposed on AMD&rsquo;s proprietary driver)</td> <td>Used by Super Mario Odyssey and others</td> </tr> <tr> <td>Copying depth images to color images and vice-versa (only on Nvidia)</td> <td>Used by Super Mario Odyssey, Zelda Breath of the Wild and others</td> </tr> <tr> <td>Alpha testing (eliminating pixels with some transparency)</td> <td>Used by Smash Ultimate, Bayonetta and Astral Chain</td> </tr> </tbody> </table> <p> </p> <p>Not having these features forces the Vulkan renderer to emulate them with slower techniques. At the moment of writing this article, features that are not known to be used by Switch games and some with extensions widely available, have been excluded from the above list.</p> <p>In addition to these, Vulkan also doesn&rsquo;t yet support a feature that has been supported by OpenGL since 1992 - <code>a mutable pipeline state</code>. In Vulkan, to define how a triangle is going to be rendered, you create a PSO (Pipeline State Object). For instance: &ldquo;the clockwise side of a triangle is the front face&rdquo;, &ldquo;cull the back face of the triangle&rdquo;, &ldquo;render triangles&rdquo;, &ldquo;enable blending (transparency)&rdquo;, &ldquo;use these shaders&rdquo;.</p> <p>In case you want to change <em><strong>any</strong></em> of these attributes, an entire new pipeline has to be created. This has the advantage of eliminating &ldquo;shader recompilations&rdquo; that cause micro-stutter at boot on some games. The problem is that, again, Nvidia hardware can change this atomically.</p> <p>If you want to change what faces of a triangle to cull (to render shadows for instance); you just queue the change on the GPU and it&rsquo;s done. And on OpenGL too, it&rsquo;s the same thing. yuzu currently doesn&rsquo;t take much advantage of this feature, but we do have plans to optimize the current OpenGL backend for this.</p> <p>In summary, for Switch emulation, OpenGL is the API to rule them all (unless Nvidia decides to release NVN on desktop, but that&rsquo;s doubtful). Vulkan is great to take advantage of hardware that is not OpenGL friendly and it receives more love from some vendors and the market, so better tools, more extensions and better driver support will appear in the future.</p> <h2 id="conclusion">Conclusion</h2> <p style="color:cyan;"><b>Vulkan is still EXPERIMENTAL!</b></p> <p>The Vulkan renderer for yuzu is still experimental and doesn&rsquo;t yet have all the features implemented. In addition to that, the Vulkan renderer currently <code>DOES NOT</code> support shader caches and the infamous <code>Resolution rescaler</code> is not yet integrated into the Vulkan renderer. While some games like Zelda: Link&rsquo;s Awakening work really well on Vulkan, many games like ARMS, Crash Team Racing, and Luigi&rsquo;s Mansion 3 crash on it.</p> <blockquote> <p style="color:lawngreen;"><b>As this feature release is a monumental one, we want to make sure that all the rough edges are polished before making it available to normal users. </blockquote> <p>And as such, the Vulkan release will take more time to become available on Mainline. We&rsquo;ll be slowly rolling it out in December.</b></p></p> <p>As always, we’re so thankful to our supporters. Please enjoy testing out Vulkan on your own games, and remember to reach out to us with any feedback/bugs you experience on our Discord&rsquo;s exclusive Patreon channels!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Introducing yuzu Early Access https://yuzu-mirror.github.io/entry/yuzu-early-access/ Sun, 01 Dec 2019 20:15:00 +0530 bunnei https://yuzu-mirror.github.io/entry/yuzu-early-access/ <p>A very good day to you all out there! Today, we are excited to announce a new yuzu official release channel for our Patreon subscribers — yuzu Early Access. It comes with all the perks you&rsquo;re already accustomed to and more.</p> <p>A very good day to you all out there! Today, we are excited to announce a new yuzu official release channel for our Patreon subscribers — yuzu Early Access. It comes with all the perks you&rsquo;re already accustomed to and more.</p> <p> </p> <div style="text-align:center;"> <img src="./yuzu-banner-early-access-white.svg" width="400" height="150"/> </div> <p> </p> <p>This new release channel includes all the same daily yuzu updates that you are accustomed to, plus the early releases of features that you have typically seen in special Patreon releases!</p> <blockquote> <p><strong>Note:</strong> <br> <code>Early Access</code> builds are currently only available for <code>Windows</code> users. <br> <code>Linux</code> users won&rsquo;t have access to <code>Early Access</code> builds due to limitations of the installer, and how we bundle the source with the binary. If enough users request a <code>Linux</code> port, we may look into it in the future.</p> </blockquote> <h2 id="what-does-it-mean-for-you">What does it mean for you?</h2> <p>If you are a Patreon subscriber at the <code>Early Access tier</code>, you will be able to install this new release channel. You will not need to worry about manually checking in on the yuzu Patreon and downloading one-off releases — as these updates will be pushed directly to you through the installer. You’ll also get all of the other daily updates with this release channel, so there will not be a need to switch back and forth between Patreon releases and daily releases.</p> <p>If you are not a Patreon subscriber and use the regular yuzu builds, not much will change! You’ll still get the same daily yuzu updates, which will include new features and bug fixes once they are ready for mainstream use.</p> <blockquote> <p><strong>Note:</strong> <br> All build downloads are bundled with the source code within in the download.</p> </blockquote> <h2 id="how-do-i-install-yuzu-early-access">How do I install yuzu Early Access?</h2> <p>Follow this detailed step-by-step guide, to install yuzu <code>Early Access</code> via the Installer. <br> <a href="https://yuzu-mirror.github.io/help/early-access/"><strong>Click here for the guide</strong></a></p> <h2 id="why-did-we-make-this-change">Why did we make this change?</h2> <p>Since February 2019, we&rsquo;ve released a total of <code>8</code> special Patreon preview builds alongside hundreds of daily regular releases. Like many open source projects, we automate the entire build and release process for the application, so that our developers can spend more time working on the actual project and less time fiddling with building and releasing. This way, the latest and greatest changes are delivered directly to you through the updater.</p> <p>When we made the first preview release, we figured that for a once-a-month preview build it isn&rsquo;t worth the trouble to automate the process. But recently, the process for building and releasing has started to really take up more time than acceptable.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./9.png" title=" (Credits: xkcd)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-early-access/9_huc94bc325b7b73fbdb6f6c6b5bb583d68_26403_404x0_resize_q90_bgffffff_box_3.jpg" alt=" (Credits: xkcd)"></a> <p class="has-text-centered is-italic has-text-grey-light"> (Credits: xkcd)</p> </div> </div> <!-- https://xkcd.com/1319/ --> <p>Each build was made by merging several different developers&rsquo; code together, causing unforeseen errors due to different developers making changes to same sections of the code. For a once-a-month build, we ended up needing to block out at least a week to prepare for the release; we needed time for internal testing, time for squashing every bug we found, and time for fixing any issues found after release.</p> <p>Over the past month, we rebuilt the build process for daily yuzu releases. We built it in such a way that we can easily extend it to include <code>Early Access</code> builds. Today we are pleased to announce that we now have automated the build and release process for <code>Early Access</code> from start to finish, meaning from today, you can now install the latest <code>Early Access</code> build directly through the yuzu installer.</p> <h2 id="so-ive-installed-early-access-now-what">So I’ve installed Early Access, now what?</h2> <p>We’re rolling out the release of <code>Early Access</code> softly — so you may not notice too many new features or bug fixes just yet. This is to give us time to make sure the new release channel is stable, and work out any kinks.</p> <p>But rest assured — we have a really exciting feature coming, that many of you have been asking for, and it’s right around the corner! This feature is <code>days away…</code> not weeks… So, hang tight!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> yuzu Patreon Release October 2019 https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/ Tue, 08 Oct 2019 04:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/ <p>Hey there <em><strong>yuz-ers</strong></em>! Curious about what we have in store for you? It&rsquo;s the October Patreon preview release! This build showcases the new game in town, <strong>The Legend of Zelda: Link&rsquo;s Awakening</strong>, in yuzu! Hop right in to find out more.</p> <p>Hey there <em><strong>yuz-ers</strong></em>! Curious about what we have in store for you? It&rsquo;s the October Patreon preview release! This build showcases the new game in town, <strong>The Legend of Zelda: Link&rsquo;s Awakening</strong>, in yuzu! Hop right in to find out more.</p> <h2 id="changelog">Changelog</h2> <p>Since the last Patreon release, we&rsquo;ve made great progress in the OS emulation and GPU emulation areas. While some of the changes listed below are already in master or tagged for Canary, some are being released as early access to the patrons, with this build.</p> <h3 id="os-emulation-os-hle">OS Emulation (OS HLE)</h3> <p><code>Public Changes</code></p> <ul> <li> <p><a href="https://github.com/yuzu-emu/yuzu/pull/2877">#2877</a> - Implemented <code>REV5 Audio</code>&rsquo;s frame count.</p> </li> <li> <p><a href="https://github.com/yuzu-emu/yuzu/pull/2873">#2873</a> - Implemented <code>ioctl2</code> &amp; <code>ioctl3</code> interfaces in <code>NVDRV</code> (Nvidia Services).</p> </li> <li> <p><a href="https://github.com/yuzu-emu/yuzu/pull/2912">#2912</a> - Fixes and Improvements to Asynchronous GPU:</p> <ul> <li>New games boot with <code>Async</code> - <strong>Fire Emblem: 3 Houses</strong>, <strong>Cadence of Hyrule</strong>, and <strong>Pokkén Tournament</strong>.</li> <li>Fixed the issue where games would suddenly slowdown and report wrong framerates.</li> <li>Fixed the issue where some games would surpass frame limiting.</li> <li>Fixed the issue where dynamic resolution re-scaler would trigger in <strong>Super Mario Odyssey</strong> with full-speed and wouldn&rsquo;t trigger heavily for under-speed games.</li> <li>Removed artificial fence which limited <code>Async</code> to <code>9 ms</code>. Now <code>Async</code> will be limited by the game and this gives performance boosts in many graphic intensive games.</li> </ul> </li> </ul> <p><code>Patreon Changes</code></p> <ul> <li>Implemented a new <code>Fair Cycle Core Timer</code> in order to spread work evenly on the four emulated cores.</li> <li>Improved the <code>New Scheduler</code> even further, by fixing bugs and implementing <code>Thread Pre-emption</code>. These improvements to the scheduler have improved performance in games like <strong>Fire Emblem:3 Houses</strong>, <strong>Hyrule Warriors</strong> and <strong>Resident Evil 4</strong>. <br> It also has allowed <strong>Astral Chain</strong> and other games to boot (<em><strong>Not fully playable yet!</strong></em>).</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./AC%201.png" title=" Astral Chain"> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/AC%201_hu98efe697c684150608b0fd61c795b91e_2014273_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Astral Chain"></a> <p class="has-text-centered is-italic has-text-grey-light"> Astral Chain</p> </div> </div> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./FE%201.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/FE%201_hu1ab527fdd07b20debd227765d04383c3_1506581_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Three Houses"></a> </div> <div class="column is-bottom-paddingless"> <a href="./FE%202.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/FE%202_hu268eb570657cb54597c069541b9b2b68_1659427_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Three Houses"></a> </div> <div class="column is-bottom-paddingless"> <a href="./FE%204.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/FE%204_hu8d1417ed8143c4c404726dd07100e578_1875947_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem: Three Houses"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fire Emblem: Three Houses</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./RE%204%20Title.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/RE%204%20Title_hueca4017c5f8d6fa5ac88b568aff7ee15_2394124_800x0_resize_q90_bgffffff_box_3.jpg" alt="Resident Evil 4"></a> </div> <div class="column is-bottom-paddingless"> <a href="./RE%204.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/RE%204_huc63381ee93489f39ace15d61c31f621a_2486663_800x0_resize_q90_bgffffff_box_3.jpg" alt="Resident Evil 4"></a> </div> <div class="column is-bottom-paddingless"> <a href="./RE%204%20II.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/RE%204%20II_hu282d9495ad5a7643b2e7f2dff07c7385_2310911_800x0_resize_q90_bgffffff_box_3.jpg" alt="Resident Evil 4"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Resident Evil 4</p> <h3 id="gpu-emulation">GPU Emulation</h3> <p><code>Public Changes</code></p> <ul> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2891">#2891</a> - Implemented <code>RGBX16F Format</code> which is used by <strong>Rocket League</strong> to render graphics.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2870">#2870</a> - Implemented a <code>MME draw calls in-liner</code> which accumulates draw calls from the Macro Interpreter Engine (MME) and sends them as a single unified draw call, thus improving performance significantly in some titles.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2869">#2869</a>, <a href="https://github.com/yuzu-emu/yuzu/pull/2878">#2878</a>, and <a href="https://github.com/yuzu-emu/yuzu/pull/2855">#2855</a> - Implemented shader instructions: <code>SULD</code>, <code>ICMP</code>, <code>SHFL</code>(Nvidia only) and <code>SUATOM</code>.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2872">#2872</a> - Fixed memory mapping so that it won&rsquo;t call GPU flushing unnecessarily anymore.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2868">#2868</a> - Fixed mipmap filtering.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2833">#2833</a> - Fixed stencil testing.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2914">#2914</a> - Corrected <code>Fermi2D</code> to work within crop areas in order to avoid issues in Vulkan.</li> <li><a href="https://github.com/yuzu-emu/yuzu/pull/2917">#2917</a> - Added deduction method for <code>blits</code> which helps figure if a <code>blit</code> is on depth textures. This avoids using the fall-back method of buffer copy.</li> </ul> <p><code>Patreon Changes</code></p> <ul> <li>Implemented <code>fast BRX</code> and fixed <code>TXQ</code>. This fixes graphics in <strong>Crash Team Racing</strong> &amp; <strong>The Legend of Zelda: Link&rsquo;s Awakening</strong>, and also makes shaders a lot easier to be read by AMD and Intel drivers.</li> <li>Reworked shader cache system to support <code>fast BRX</code> and <code>TXQ</code> fixes.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./title.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/RE%204%20Title_hueca4017c5f8d6fa5ac88b568aff7ee15_2394124_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening"></a> </div> <div class="column is-bottom-paddingless"> <a href="./intro_house.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/intro_house_hu6f9368b4b7885101a0976a243b42077b_1346550_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening"></a> </div> <div class="column is-bottom-paddingless"> <a href="./no_blur_fox.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/no_blur_fox_hu4def2fdefe60334cdccd6c6e800b012a_1952192_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Link&#39;s Awakening"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Link&#39;s Awakening</p> <article class="message"> <div class="message-header is-dropdown"> <p>Link&#39;s Awakening needs some stuff!!</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p><strong>The Legend of Zelda: Link&rsquo;s Awakening</strong> currently needs a few things to work:</p> <ul> <li>a save file, to skip the initial movie.</li> <li>set your controller settings to <code>Custom &gt; Docked &gt; Pro Controller</code>.</li> <li>And <code>Async</code> needs to be <code>OFF</code>.</li> </ul> <p>A save file is being linked here for users&rsquo; convenience <code>--&gt;</code> <a href="./savedata1.bin">Click here to Download</a></p> </div> </article> <article class="message"> <div class="message-header is-dropdown"> <p>Shader caches need to be regenerated!!</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> Because of the reworked shader cache system, all previously generated shader caches are <code>no longer valid</code>.<br> <strong>Users will have to regenerate their shader caches for all games.</strong> </div> </article> <h2 id="screenshots">Screenshots</h2> <p>Here are some more screenshots from <strong>The Legend of Zelda: Link&rsquo;s Awakening</strong>, just for you.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./shield_get.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/shield_get_hu6e4d9c35aef124940abf0c51f37675ae_1627473_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./sword.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/sword_hue276e9acfe51234605f95c6b74eb40f3_2236048_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./sword_get.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/sword_get_hu99a6593cee8039ce67afca7f61144f1d_1664036_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./graveyard.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/graveyard_hu5a23ede2213fd54292be5266f66f427b_1376180_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./swamp.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/swamp_hu60bb6d071e45aa2c8f083fe0fbe11345_1299246_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./fairy.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/fairy_hu26381134e2dab93f5af23471bf288748_1443100_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./forest1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/forest1_huecce6f73f4833b002299a39823a7d852_1643337_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./forest2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/forest2_hu244f5eb54eeb200584fe76d7fbda50c5_1714307_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./dungeon.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/dungeon_huf3cc91fa2647cc33f70e12460b2d4a2a_1214288_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./dungeon1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/dungeon1_hu11f11d2c7b03466d528704bf3c4b1e77_1395978_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./dungeon_maker.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/dungeon_maker_hu469d2e2ddac5e2d865eeaa10f9835a88_2419247_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./dungeon_maker2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-oct-2019/dungeon_maker2_hu940d9745079613b0dbdfec3823a7195d_1706733_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <h2 id="et-al">Et al.</h2> <p>Please remember that the early access features are still being worked on, so if you encounter any bugs or have any feedback, please don&rsquo;t hesitate to share it with us in our patreon channels on our <a href="https://discord.gg/u77vRWY">Discord server</a>.</p> <p>As always, we are thankful to all our 450+ patrons for their continued support. We will keep working diligently to bring you many more improvements, so that you can keep enjoying your favourite games on yuzu.</p> <p>Until next time, keep playing on yuzu! <br></p> <ul> <li>yuzu development team</li> </ul> <hr> <p><strong>If you&rsquo;d like to try out this preview release, please head on over to our <a href="https://www.patreon.com/yuzuteam">Patreon</a> to get access! Thank you again for your support!</strong></p> yuzu - The Migration https://yuzu-mirror.github.io/entry/yuzu-migration/ Mon, 07 Oct 2019 06:20:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-migration/ <p>A very good day to all the <em><strong>yuz-ers</strong></em> out there! We are currently in the process of merging both the Canary and Nightly versions of yuzu into a single release channel. Jump right in to find out more about this!</p> <p>A very good day to all the <em><strong>yuz-ers</strong></em> out there! We are currently in the process of merging both the Canary and Nightly versions of yuzu into a single release channel. Jump right in to find out more about this!</p> <hr> <h2 id="announcement">Announcement</h2> <article class="message"> <div class="message-header is-dropdown"> <p>We are merging yuzu Nightly and yuzu Canary releases into a single "yuzu" release!</p> </div> </article> <p>Don&rsquo;t fret, we are just doing some reorganization to make things easier for both the users and the developers. Today marks the retirement of both yuzu Nightly and yuzu Canary release channels. From tomorrow, yuzu will have only a single release channel, simply dubbed &ldquo;yuzu&rdquo;.</p> <p>Most of you might be thinking, &ldquo;why are they doing this?&rdquo; or &ldquo;what does this mean for the users?&rdquo;. Let&rsquo;s go back in time for a bit to understand the &ldquo;why?&rdquo; part.</p> <h2 id="a-big-why">A big &ldquo;Why?&rdquo;</h2> <p>When yuzu was first forked from Citra and was setting up shop as a separate project, it borrowed a few things from Citra (apart from the code). In those, were the general ideas about build releases, build generating infrastructure, and release channel naming convention. For a good while, these ideas served the purpose - that is to generate builds and distribute them, but it was high time for some improvements.</p> <p>In the initial days of yuzu development, due to the large list of missing/unknown functionality, we had to add <code>asserts</code> (or <code>assertions</code>) wherever necessary in the codebase. Assertions are statements used to test assumptions made by the programmers. This allowed us to understand what functionality we were missing and which games used those, if we needed to test them.</p> <p>The philosophy behind the nightly channel was to have a release channel with asserts enabled, so that the developers keep getting data on what games were missing what functionality. But having yuzu assert and crash while playing a game rendered it unusable for normal users. To overcome this, we decided to release the canary builds with specific <code>IGNORE ASSERTS</code> code included.</p> <p>This made yuzu ignore all those assertions and allowed normal users to test or play games on it. But as yuzu progressed further, the canary builds gained increased popularity among the users as the nightly builds were absolutely unusable. As a result, the developers had to concentrate more on the canary builds, so that they could get users to test their code and thus improve yuzu.</p> <p>As we were making good progress in reducing the assertions, the nightly release branch no longer had anything to offer to the developers or the users. It was also redundant to have two <code>stable</code> release channels for the same codebase. Hence the reorganization.</p> <h2 id="what-does-it-mean-for-the-users">What does it mean for the users?</h2> <article class="message"> <div class="message-header is-dropdown"> <p>From the user's perspective, this doesn't change anything.</p> </div> </article> <p>We are just reorganizing things internally and it will not have <code>any</code> impact for you, as end-users. With this slight reorganization, instead of multiple branches, we will now have a single stable branch. This will make it easier for new users to use yuzu, and with this new release channel, you will still get the same regular <code>new updates</code> and <code>bug fixes</code> that you&rsquo;ve come to expect with the Canary builds.</p> <p>With the new release channel, we&rsquo;ve migrated our CI from <code>Travis CI</code> &amp; <code>Appveyor CI</code> to <code>Azure Dev Ops</code>. <code>Azure Dev Ops</code> is a free and reliable service provided by Microsoft. That means things like uptime and support are much better than <code>Travis</code> or <code>Appveyor</code>. It is a single service which can generate builds for all of our platforms, which we didn&rsquo;t have before. We also get more dedicated resources and therefore builds are generated much faster with Azure.</p> <p>Starting today, users will be able to get the new and improved yuzu builds via the installer from our <a href="https://yuzu-mirror.github.io/downloads/">website</a> or our <a href="https://github.com/yuzu-emu/yuzu-mainline/releases/">GitHub</a>. And if you are already using our installer, you will be automatically migrated to the latest yuzu build.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./installer.png" title="yuzu Installer (Updated)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-migration/installer_hu4361ee58d68492e7ac1a8c908a9551e1_44909_1024x0_resize_q90_bgffffff_box_3.jpg" alt="yuzu Installer (Updated)"></a> <p class="has-text-centered is-italic has-text-grey-light">yuzu Installer (Updated)</p> </div> </div> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> yuzu Patreon Preview Release September 2019 https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-sept-2019/ Mon, 09 Sep 2019 01:18:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-sept-2019/ <p>Good Day yuz-ers! (<em>yeah, that&rsquo;s sticking!</em>) Many of you thought that yuzu&rsquo;s development slowed down, didn&rsquo;t you? Well, guess again - The team has been working tirelessly to bring you this exciting new feature! What is it? Jump right in to find out!</p> <p>Good Day yuz-ers! (<em>yeah, that&rsquo;s sticking!</em>) Many of you thought that yuzu&rsquo;s development slowed down, didn&rsquo;t you? Well, guess again - The team has been working tirelessly to bring you this exciting new feature! What is it? Jump right in to find out!</p> <hr> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smm2-1.jpg" title=""><img src="./smm2-1.jpg" alt="Super Mario Maker 2 - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smm2-2.jpg" title=""><img src="./smm2-2.jpg" alt="Super Mario Maker 2 - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smm2-3.jpg" title=""><img src="./smm2-3.jpg" alt="Super Mario Maker 2 - Rescaled to 6k"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Maker 2 - Rescaled to 6k</p> <p>We hope everyone had an enjoyable and relaxing summer. While you may have noticed a bit of a lull during August, make no mistake that our team was still hard at work! Behind the scenes, our GPU team has been investing a ton of time and talent into bringing about this patreon releases&rsquo; biggest feature: <code>Resolution Rescaler!</code></p> <h3 id="you-can-download-this-release-on-our-patreonhttpswwwpatreoncompostsseptember-2019-29811265">You can download this release on our <a href="https://www.patreon.com/posts/september-2019-29811265">Patreon</a>!</h3> <p>As you might expect from the name, this feature increases native resolution through a set of rules enforced by a profile, very similar to other emulators such as Cemu. You can select <code>Profile Scanner (Native)</code> option in the <code>Internal Resolution</code> drop-down list.</p> <ul> <li>When this option is selected, yuzu will continuously learn more about your specific games rendering methods, and will help create a resolution profile for that game.</li> <li>Once a profile is generated or obtained, the user can then select what multiplier they would like to increase their resolution by (2x, 4x, etc).</li> <li>You can find these rescaling profiles under <code>%APPDATA%/yuzu/rescaling/</code> on Windows and <code>~/.local/share/yuzu-emu/rescaling/</code> on Linux, or you can right-click the game on the UI and click on <code>Open Rescaling Profile</code>.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./config.png" title="Configuration Option"> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-sept-2019/config_hu8feeee3ebcec5c198c77d76f2a96f9d9_18745_576x0_resize_q90_bgffffff_box_3.jpg" alt="Configuration Option"></a> <p class="has-text-centered is-italic has-text-grey-light">Configuration Option</p> </div> </div> <p>This of course doesn&rsquo;t come without a few kinks that need to be ironed out. For now, some of the dev teams known issues include:</p> <ul> <li><code>Super Mario Odyssey</code> and <code>The Legend of Zelda: Breath of the Wild</code> won&rsquo;t rescale correctly on the edges due to a hardcoded AA shader that those games have. <br> The game itself will still look better and more accurate, but you&rsquo;ll noticed the jagged edges typically associated with hardcoded AA games.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw-1.jpg" title=""><img src="./botw-1.jpg" alt="The Legend of Zelda: Breath of the Wild - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw-2.jpg" title=""><img src="./botw-2.jpg" alt="The Legend of Zelda: Breath of the Wild - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw-3.jpg" title=""><img src="./botw-3.jpg" alt="The Legend of Zelda: Breath of the Wild - Rescaled to 6k"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild - Rescaled to 6k</p> <ul> <li><code>Pokémon: Let's Go</code> and some other games have small rendering artefacts when rescaled, such as the flames on Charizard&rsquo;s tail do not render.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo-1.jpg" title=""><img src="./smo-1.jpg" alt="Super Mario Odyssey - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-2.jpg" title=""><img src="./smo-2.jpg" alt="Super Mario Odyssey - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-3.jpg" title=""><img src="./smo-3.jpg" alt="Super Mario Odyssey - Rescaled to 6k"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey - Rescaled to 6k</p> <p>That&rsquo;s not all that has changed, other notable fixes include:</p> <ul> <li>sRGB has been fixed. This essentially corrects some games that looked lighter than usual.</li> <li>Viewport and scissor testing have been corrected, which fixes a ton of issues in many different games, most notably in <code>Hyrule Warriors</code>.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hw-1.jpg" title=""><img src="./hw-1.jpg" alt="Hyrule Warriors - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hw-2.jpg" title=""><img src="./hw-2.jpg" alt="Hyrule Warriors - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hw-3.jpg" title=""><img src="./hw-3.jpg" alt="Hyrule Warriors - Rescaled to 6k"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hyrule Warriors - Rescaled to 6k</p> <ul> <li>Tons of refactoring changes, to better prepare us for our Vulkan backend and other future improvements.</li> <li>Reworked GPU buffer cache is now more accurate and faster, which lead to fixes in <code>Super Smash Bros. Ultimate</code>, <code>Onimusha Warlords</code>, and many other titles.</li> </ul> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./ssbu-1.jpg" title=""><img src="./ssbu-1.jpg" alt="Super Smash Bros. Ultimate - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ssbu-2.jpg" title=""><img src="./ssbu-2.jpg" alt="Super Smash Bros. Ultimate - Rescaled to 6k"></a> </div> <div class="column is-bottom-paddingless"> <a href="./ssbu-3.jpg" title=""><img src="./ssbu-3.jpg" alt="Super Smash Bros. Ultimate - Rescaled to 6k"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Smash Bros. Ultimate - Rescaled to 6k</p> <ul> <li>Corrected our shader code to help set up preparation for <code>Fire Emblem: Three Houses</code>.</li> <li>Several fixes for <code>Xenoblade 2</code> - character models look better and most vertex explosions are gone.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./xenoblade.png" title="Xenoblade 2"> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-sept-2019/xenoblade_hu35b03a317bd737a67a98836b5b0dacb8_2205509_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Xenoblade 2"></a> <p class="has-text-centered is-italic has-text-grey-light">Xenoblade 2</p> </div> </div> <p>This is a huge release for our testing purposes. The <code>Resolution Rescaler</code> is still being thoroughly worked on, so if you come across any bugs that weren&rsquo;t mentioned above, or have any feedback, please don&rsquo;t hesitate to share it with us in our patreon channels on our discord server.</p> <p>Once again thank you for your patronage, and we look forward to hearing back from you all! <br> Cheers, <br></p> <ul> <li>yuzu development team</li> </ul> <hr> <p><strong>If you&rsquo;d like to try out this preview release, please head on over to our <a href="https://www.patreon.com/yuzuteam">Patreon</a> to get access! Thank you again for your support!</strong></p> Mini-Series - Dev Interview #2 https://yuzu-mirror.github.io/entry/yuzu-mini-dev-2/ Fri, 09 Aug 2019 11:48:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-mini-dev-2/ <p>Good day, yuz-ers (<del>bad pun, I know</del>)! While our devs are hard at work trying to bring you more performance improvements and game compatibility, we are back again with something a little bit more interesting - <strong>Dev Interview #2</strong>. Jump right in, to find out who we&rsquo;re interviewing this time.</p> <p>Good day, yuz-ers (<del>bad pun, I know</del>)! While our devs are hard at work trying to bring you more performance improvements and game compatibility, we are back again with something a little bit more interesting - <strong>Dev Interview #2</strong>. Jump right in, to find out who we&rsquo;re interviewing this time.</p> <hr> <p>Welcome to part 2 of our previously announced <code>Developer Interviews</code> segment. We are extremely proud that we were once again successful in dragging one of our developers away from programming to answer a few questions. This time, it is an interview with one of our resident GPU emulation experts: <em><strong>Rodrigo</strong></em>.</p> <p>Rodrigo (a.k.a <a href="https://github.com/ReinUsesLisp">ReinUsesLisp</a>) is best known for his massive contributions to yuzu in the GPU emulation area. His various contributions have improved the user&rsquo;s visual experience, and his shader disk caches improved the performance of many games on yuzu. He is also the guy who is currently working on implementing the Vulkan API. Below, you&rsquo;ll find an informative conversation we had that should also help you all understand more about what he&rsquo;s doing behind the scenes.</p> <hr> <p><strong>Q: Hi Rodrigo! Wanna tell our patrons a little about yourself?</strong></p> <p><strong>R:</strong> Hi! I&rsquo;m some random guy from Argentina working on emulating the Nintendo Switch&rsquo;s GPU, (<em>and I&rsquo;m totally not ripping off Lioncash with this presentation</em>).</p> <p>Right now, I am a school teacher and don&rsquo;t have a formal programming background, but I&rsquo;d like to get a computer science job in the future. I&rsquo;m also interested in languages (both spoken &amp; programming) and software development.</p> <p><strong>Q: You are entirely self taught?! So, what made you get into emulation?</strong></p> <p><strong>R:</strong> Yes. See, I always used to play games in my childhood through emulators, mostly 90s console emulators (SNES and Genesis). Later on, I remember playing <code>Twilight Princess</code> on Hyrule Fields with Dolphin at <strong>3 FPS</strong>, it was just awesome.</p> <p>Around 7 years ago, I learnt to program small RPGs in plain C++ (and then C), but that never got beyond the prototyping stages, mainly because of boredom and the lack of artistic resources.</p> <p>What got me into emulation mainly was yuzu&rsquo;s very <a href="https://www.youtube.com/watch?v=1VzyIHMTA2Q">first video</a> of three commercial games booting (Cave Story, Isaac Afterbirth and Puyo Puyo Tetris). <strong>There it was!</strong> &ndash; an emulator of a console, that I thought was a successful piece of hardware: A tablet with a somewhat desktop GPU? That would have been madness some years ago.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./first.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-2/first_hu1a5066c6b19d4199d2184b5decfc9f62_190724_800x0_resize_q90_bgffffff_box_3.jpg" alt="Cave Story&#43; (First yuzu build) - We&#39;ve come a long way from that!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Cave Story&#43; (First yuzu build) - We&#39;ve come a long way from that!</p> <p><strong>Q: That&rsquo;s really interesting to hear. Before yuzu and Switch emulation, have you ever worked on other older emulators?</strong></p> <p><strong>R:</strong> No, I&rsquo;ve never worked on a non-Switch emulator. The closest thing I did related to emulation was a clone of Pico-8 Celeste for the NES in 6502 assembly. It was a fun experience because I learnt the curse, and blessing, that it is to work that close to the hardware; it showed me what a pain it was to program classics like Super Mario Bros. 3.</p> <p><strong>Q: Let&rsquo;s get a bit technical. What areas of Switch emulation have you worked on the most, and why? Which other areas keep you interested?</strong></p> <p><strong>R:</strong> I&rsquo;ve worked on the graphics, and compute departments of Switch emulation. Emulating a modern GPU (Tegra) by using other modern GPUs (user end) is my area of interest. Here&rsquo;s a cool fact for those that don&rsquo;t know: the Switch&rsquo;s GPU is an Nvidia Tegra X1, and it utilizes the same architecture of a GTX 960+.</p> <p>As for why I like it, it&rsquo;s because GPUs nowadays are like mini sub-computers inside a machine. The list of functionality present in the Tegra X1 grows bigger the more we look into it; since it’s a Nvidia device, it can execute CUDA kernels (programs that run some computations in the GPU, primarily used for scientific calculations or accelerated computations). It has the 5 traditional shader stages, an extra vertex shader stage, and compute shaders; while at the same time, it supports the supposedly deprecated features from the D3D9 (Direct3D) era, like rendering with quads and alpha testing.</p> <p>From time to time, I try to get into Core emulation, but it never ends up with good results. Funnily enough, while I was investigating the SSBU (Super Smash Bros. Ultimate) crash, I totally thought I made a breakthrough - only to find out I was disassembling the wrong module. (LOL)</p> <p><strong>Q: What are some of the challenges you generally face when working on GPU emulation?</strong></p> <p><strong>R:</strong> One of biggest challenges is the inherent variable state of Nvidia GPUs. Sometimes, graphics APIs like OpenGL and Vulkan have requirements that are the &ldquo;common ground&rdquo;, something that&rsquo;s needed by the lowest denominator. We have to write very annoying workarounds to get that functionality working in the emulator.</p> <p style="color:cyan"><b><i>Here are some sneak peeks from my Vulkan test build. It's still missing a lot of things, but it's not too bad either.</b></i></p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./botw.png" title="The Legend of Zelda - Breath of the Wild"> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-2/botw_hu2f3d8639263ce1cf75e97f6883b98d6b_1264331_1024x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda - Breath of the Wild"></a> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda - Breath of the Wild</p> </div> <div class="column has-text-centered"> <a href="./onepiece.png" title="One Piece - Unlimited World"> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-2/onepiece_hu05ee499615279f2c8815885d30394e65_1619135_1024x0_resize_q90_bgffffff_box_3.jpg" alt="One Piece - Unlimited World"></a> <p class="has-text-centered is-italic has-text-grey-light">One Piece - Unlimited World</p> </div> <div class="column has-text-centered"> <a href="./smo.png" title="Super Mario Odyssey"> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-2/smo_hud1d23ab3f053045469a44d30a1066667_667906_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> </div> </div> <p><strong>Q: What motivates you every day to keep working on this stuff?</strong></p> <p><strong>R:</strong> Emulating modern GPU features, on hardware with those same features, is something that has only been possible in the recent times, due to the increasing similarities in hardware between consoles and desktops. Slowly understanding how some known functionality is implemented by the hardware, and then re-implementing it on the emulator afterwards, really motivates me.</p> <p>There are two things that I enjoy the most:</p> <ul> <li>seeing games run faster, and better than how they ran before.</li> <li>seeing games getting closer and closer to how they look on the console.</li> </ul> <p>And if I manage to get these improvements by writing better code, it&rsquo;s an added bonus.</p> <p><strong>Q: Can you tell us a little about what you are currently working on? A sneak-peek perhaps?</strong></p> <p><strong>R:</strong> That&rsquo;s classified information :P I&rsquo;ve recently worked on an improved &amp; generic texture cache. <a href="https://github.com/FernandoS27">Blinkhawk</a> helped by cleaning up my bugs to get the thing working, and he&rsquo;s done an awesome job. A generic texture cache allows us to share the complex part of it across graphics APIs. That means that we will have the same overall logic for OpenGL and Vulkan, making it easier to maintain and improve.</p> <p>It&rsquo;s not as good as Dolphin&rsquo;s VideoCommon, one of the better examples for generic graphics code, but it&rsquo;s still better than having to copy-paste code everywhere. This is one of the last prerequisites for the Vulkan API.</p> <p>I&rsquo;ve also been working on implementing various compute shader related instructions: shared memory (ARB_compute_shader), atomic operations, memory shuffles (NV_shader_thread_shuffle), votes (NV_gpu_shader5, NV_shader_thread_group), surface operations (SUATOM, SULD). These are all features from the D3D11/12 era, meaning that we are reaching interesting complexity on the shaders we find in recently released games. I am also investigating how to implement some missing functionality in yuzu, but that&rsquo;s a story for another time.</p> <p><strong>Q: Would you like to say something to our audience?</strong></p> <p><strong>R:</strong> Well, there are three things I&rsquo;d like to say.</p> <p><code>First and foremost...</code> most of our GPU work has been possible thanks to research done by the people working on nouveau (mesa&rsquo;s Nvidia free driver) and libnx&rsquo;s nouveau port to Switch. They have been of huge help.</p> <p><code>Second...</code> many people believe that Vulkan will bring lots of performance improvements to the emulator&hellip; I was one of those too. Don&rsquo;t get me wrong, it might boost performance on some hardware vendors, but the main issue resides in Vulkan&rsquo;s design. It is designed in a way that the programmer cooks and reuses its resources, but in emulation you can&rsquo;t easily know what&rsquo;s going to happen in the future. On the other hand, OpenGL, by design, works without backing its commands.</p> <p>Some people might ask, why would we want two APIs? I think one API is going to perform better on two vendors, while the other API is prevalent on the other vendor.</p> <p><code>And last, but not least...</code> We have a console that&rsquo;s just two years old, and it&rsquo;s still lacking the mainstream entries for most Nintendo IPs: Metroid, Donkey Kong Country, the announced Gen 8 Pokémon, Star Fox, Mario Kart, F-Zero (who knows? maybe they will find a way to refresh the franchise) and the end-of-cycle Zelda.</p> <p>I&rsquo;m really excited about what&rsquo;s to come, and how good Switch emulators will perform with these games. Emulation has been surprisingly faster in the last few years. Let&rsquo;s look forward to a wonderful future&hellip;</p> <hr> <p>This has been absolutely wonderful. Huge thanks to <a href="https://github.com/ReinUsesLisp">Rodrigo</a> for taking time off his busy schedule to give us a brief insight into his life. We wish you success in all your future endeavours. Keep making yuzu awesome!</p> <p>We hope you all enjoyed it, and we will be back soon with another featured yuzu dev to bring you behind the curtain again. Until then, thank you for your support and stay tuned!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> yuzu Patreon Preview Release July 2019 https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/ Tue, 02 Jul 2019 21:55:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/ <p>Hey there, people! You won’t believe what we’ve got in store for you this time! The new Patreon preview has a big surprise waiting for you. Hop in now, to find out more details.</p> <p>Hey there, people! You won’t believe what we’ve got in store for you this time! The new Patreon preview has a big surprise waiting for you. Hop in now, to find out more details.</p> <p>For the past couple of weeks, the team has been hard at work getting some important services and functions implemented. It’s thanks to these specific services and functions that you all will now get to play <code>Super Mario Maker 2</code> on yuzu!</p> <p>Yes, you heard right, <code>Super Mario Maker 2</code> now boots and goes in-game, and is mostly playable on yuzu. Grab our latest - Patreon preview build now, to check it out.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./SMM2.png" title="Super Mario Maker 2 (Title screen)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_hu2dc1fadc38e48b4a2aa5c735853c7e08_1688101_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Maker 2 (Title screen)"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Maker 2 (Title screen)</p> </div> </div> <h4 id="you-can-download-this-release-on-our-patreonhttpswwwpatreoncomyuzuteam">You can download this release on our <a href="https://www.patreon.com/yuzuteam">Patreon</a>!</h4> <h3 id="patreon-release-changelog">Patreon Release Changelog</h3> <ul> <li> <p><code>LR Assignment Mode</code> by <a href="https://www.github.com/ogniK5377">ogniK</a> – This handles the press LR to bind controllers screen.</p> </li> <li> <p><code>SwapNpadAssignment</code> by <a href="https://www.github.com/ogniK5377">ogniK</a> – A crucial HID command.</p> </li> <li> <p><code>Audren</code> Event and Audio Fixes by <a href="https://www.github.com/ogniK5377">ogniK</a>.</p> </li> <li> <p><code>Prepo SaveReport</code> by <a href="https://github.com/DarkLordZach">DarkLordZach</a>.</p> </li> <li> <p>Filesystem Access Logging by <a href="https://www.github.com/DarkLordZach">DarkLordZach</a>.</p> </li> <li> <p>Boost Mode by <a href="https://www.github.com/DarkLordZach">DarkLordZach</a> – <br> <code>Note: does NOT make yuzu faster! We do not overclock yuzu.</code></p> </li> <li> <p><code>SetInterfaceVersion</code> by <a href="https://www.github.com/DarkLordZach">DarkLordZach</a> – Another crucial HID command.</p> </li> <li> <p>OSS Mii Model by <a href="https://www.github.com/DarkLordZach">DarkLordZach</a> – An HLE implementation of the Mii Model system archive.</p> </li> <li> <p>Several GPU bug fixes by <a href="https://github.com/ReinUsesLisp">Rodrigo</a> and <a href="https://github.com/Subv">Subv</a>.</p> </li> <li> <p>Implementing Conditional Rendering by <a href="https://github.com/FernandoS27">BlinkHawk</a> – GPU will now execute, manage, and administer queries, avoiding code paths that are not necessary.</p> </li> <li> <p>New Shader Scanner by <a href="https://github.com/FernandoS27">BlinkHawk</a> – A new, faster, and more reliable shader scanner that’s less prone to crashing and corrupting shader caches. This also fixes a bug with fonts.</p> </li> <li> <p>And the baseline <code>Canary version 2425</code>.</p> </li> </ul> <hr> <p>Phew, that’s quite a few new implementations. It’s thanks to the hard work of the yuzu development team, that all of these functions are now ready for testing. A big shout out to Hexagon12 for hunting down all of the service functions that were necessary to get <code>Super Mario Maker 2</code> in game, and also to <a href="https://www.github.com/DarkLordZach">DarkLordZach</a> for orchestrating the entire project.</p> <p>Here are some in-game screenshots from the Patreon preview build, just for you guys.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./SMM2_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_1_hu6942963c63efb79e4a31ed37477180dd_241474_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Maker 2 in-game screenshots"></a> </div> <div class="column is-bottom-paddingless"> <a href="./SMM2_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_2_hu31412893c9c6c2ec6f622985f0ef28ed_1623363_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Maker 2 in-game screenshots"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Maker 2 in-game screenshots</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./SMM2_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_3_hu4356fe6113e6dff9379c2abea766f042_1864402_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./SMM2_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_4_huf169488d077a8d4bd2d07cadb9bad227_1866808_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p><strong>Note: All these screenshots have been taken using the Patreon preview. We removed the yuzu title-bar, to keep the beauty of images intact.</strong></p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./SMM2_5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_5_hufce1df7cf71c20af067623bca684f496_1701942_800x0_resize_q90_bgffffff_box_3.jpg" alt="More Super Mario Maker 2 in-game screenshots"></a> </div> <div class="column is-bottom-paddingless"> <a href="./SMM2_6.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_6_hu7171da7c348fb6ebc65bd89e8f2528a1_118552_800x0_resize_q90_bgffffff_box_3.jpg" alt="More Super Mario Maker 2 in-game screenshots"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">More Super Mario Maker 2 in-game screenshots</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./SMM2_7.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_7_hucefe4cc920a78cb3b3401013b8f4ea62_434888_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./SMM2_8.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-july-2019/SMM2_8_huf480997f88a7ca0c341363884fbf992e_415178_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p><del><strong>Note: Currently saving levels causes yuzu to crash, due to a swkbd (software keyboard) issue. But rest assured, we are working on a fix.</strong></del> The issue with the software keyboard has now been fixed. Please download the latest build from our patreon page.</p> <p>As always, we bring this to you as a <code>thank you</code> for your patronage and dedication to our team! Please hop on Discord and use the Patreon channels to report any new bugs, or to just say Hi and discuss the new features. We will keep working diligently to improve yuzu and deliver you with the best possible experience while playing.</p> <p>Until next time, keep playing on yuzu and have fun! <br></p> <ul> <li>yuzu development team.</li> </ul> <p><strong>If you&rsquo;d like to try out this preview release, please head on over to our <a href="https://www.patreon.com/yuzuteam">Patreon</a> to get access! Thank you again for your support!</strong></p> Mini-Series - Dev Interview #1 https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/ Sun, 16 Jun 2019 23:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/ <p>Hey there, people! This is a new mini-series of dev interviews, with which we sneak a peek into the lives of our developers.</p> <p>Hey there, people! This is a new mini-series of dev interviews, with which we sneak a peek into the lives of our developers.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Disclaimer</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> This mini-series has already been underway for our Patreon supporters and we realized that you all deserve this too. So, here it is. Enjoy. </div> </article> <p>We already know and I guess most of you would agree, when we say our devs are awesome! They are modern day wizards and the work they do is nothing short of magic. But as they don&rsquo;t interact much with normal users, you guys might not know much about them. This needs to change and we are here to fix that!</p> <p>So to start off this new mini-series, let&rsquo;s interview - <em><strong>The Silent Guardian, The Watchful Protector, and The Amazing - Lioncache!!</strong></em></p> <p><img src="./lion.png" alt="Lioncache"></p> <p><a href="https://github.com/lioncash/">Lioncache</a> has been in the emulation scene for ages. You may also know him from the Nintendo GameCube/Wii emulator <a href="https://dolphin-emu.org/">Dolphin</a>, as he is one of the core maintainers there as well! <a href="https://github.com/lioncash/">Lioncache</a> has also worked on other emulators like <a href="https://citra-emu.org/">Citra</a>, and even dabbling with Commodore 64 emulation! We managed to pull him away from programming for a few minutes so that he could sit down and talk with us.</p> <hr> <p><strong>Q: Hi Lioncache! Could you tell our audience a little bit about yourself?</strong></p> <p><strong>L:</strong> Heya! I&rsquo;m Lioncache. I&rsquo;m some rando Canadian that likes working on system emulators because I find them fun.</p> <p><strong>Q: So what got you into emulation in the first place?</strong></p> <p><strong>L:</strong> Honestly, it just looked fun. CPU&rsquo;s are really cool (when they&rsquo;re not being silly) and reverse engineering looked cool (turns out, it really is). You genuinely learn quite a bit about software and hardware by working on emulation-related things. It also helps out with one of the many facets of game preservation, which is always nice.</p> <p><strong>Q: Speaking of game preservation, why is that so important to you?</strong></p> <p><strong>L:</strong> It&rsquo;s important mainly because without external preservation, there&rsquo;s no guarantee that certain games will always be available. Companies aim to turn a profit from backwards compatibility when they re-release older games from previous consoles on newer hardware.</p> <p>Businesses generally aim to strive for a profit (welcome to Econ-101, y&rsquo;all). So what this usually means is that only the most popular games with a sizable demand will generally have official re-releases considered for them. I may not totally agree with that, but it&rsquo;s generally the way things are. This is generally, why you&rsquo;ll see re-releases of Mario games, Legend of Zelda, etc, but certain other games will, &ldquo;fall through the cracks of time&rdquo;.</p> <p>For example, consider <code>Marvelous: Mōhitotsu no Takarajima</code> for the SNES. This is a fantastic RPG released in 1996, which was directed by <code>Eiji Aonuma</code> (who went on to become the series producer for <code>The Legend of Zelda</code>). The game itself reused the engine that was made for <code>The Legend of Zelda: A Link to the Past</code>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./marv_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/marv_1_hud83859be302e6ce43dc222a268a33896_19869_800x0_resize_q90_bgffffff_box_3.jpg" alt="Marvelous: Mōhitotsu no Takarajima (SNES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./marv_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/marv_2_hub9440d3d49f22da45bdf371ed8801811_22667_800x0_resize_q90_bgffffff_box_3.jpg" alt="Marvelous: Mōhitotsu no Takarajima (SNES)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./marv_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/marv_3_hub9440d3d49f22da45bdf371ed8801811_19080_800x0_resize_q90_bgffffff_box_3.jpg" alt="Marvelous: Mōhitotsu no Takarajima (SNES)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Marvelous: Mōhitotsu no Takarajima (SNES)</p> <p>So, much of the movement and characteristics are similar but it also had its own unique party system and other things that made it it&rsquo;s own distinct game, and it was really fun to play. To my knowledge, it hasn&rsquo;t had a re-release in any capacity, nor was it ever localized. However in 2016 an English fan translation of the game was released, making the game accessible to the English-speaking community.</p> <p>Another popular game, which is kind of infamous for not actually being localized and released in North America or Europe during the era of the GameBoy Advance was <code>Mother 3</code>. Plans were initially made to localize it, but it never occurred&ndash;plans fell through. This too, also had an English fan translation made for it. Which would have been difficult, had the game not been preserved in some form.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./m3_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/m3_1_huba5992bf45c10e3e5820cc7655ab3359_30153_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mother 3 (GBA)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./m3_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/m3_2_huab87e54867de37a2cf0edc143894362a_26854_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mother 3 (GBA)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./m3_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-mini-dev-1/m3_3_hu37ddbcbcc14d6a2613738522317b6e2d_35156_800x0_resize_q90_bgffffff_box_3.jpg" alt="Mother 3 (GBA)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Mother 3 (GBA)</p> <p>When you have preserved games (in any capacity), along with emulators, it allows potentially doing more with that game. Consider the scenario where all known cartridges of the game have bit rotten to the degree that they&rsquo;re no longer playable: the game would be considered lost (as far as the public is concerned).</p> <p>No one would be able to experience that game, no one would have been able to start a fan translation and made such a great game accessible to those that know English, but not Japanese. Preservation makes sure that the effort people put into making a game is not lost, while allowing being transformative with the game itself. It prevents an experience from completely vanishing.</p> <p>Game preservation also acts as a secondary backup in the event the actual owning body of the game screws up. Companies, development teams, anything with a human (or other animal :P) is prone to making mistakes. Without other people preserving those games, you essentially have a single-point of failure. No preserved dumps of the game, no emulators, and someone accidentally deletes the source code for said game? Gone. Forever (unless it&rsquo;s completely remade). This is why I find game preservation and archiving important.</p> <p><strong>Q: This is some really great insight and we appreciate you sharing with us! Well let&rsquo;s get into the meat and potatoes. Can you tell us what you&rsquo;ve been working on for yuzu?</strong></p> <p><strong>L:</strong> I mostly bounce all over the place because I prefer staging all my changes as their own PR, so I usually end up waiting on stuff to be merged, so I have a few areas I work on stuff:</p> <h4 id="display">Display</h4> <p>You&rsquo;ve probably seen me breaking out stuff into classes and reorganizing things there. That&rsquo;s all the busywork before I can actually start implementing things.</p> <p>These are the main display services and what they do:</p> <ul> <li><code>vi:u</code>: the application level display services—this is what general applications (as the name suggests) will access for basic display stuff.</li> <li><code>vi:m</code>: the manager level services—this is what something running in the background, like a compositor, would use. It can fiddle around with display layers and stuff. This service has the most access to everything out of all vi: services. It has no restrictions.</li> <li><code>vi:s</code>: the system level services—this is used by, well, the system. This service is like vi:u, except it can also retrieve info about various things related to the display.</li> </ul> <p>Handling this stuff properly would be nice, since we can properly see how games are trying to interact with displays in a nicer manner.</p> <h4 id="audio">Audio</h4> <p>Inputs go in, bangin&rsquo; tunes come out. We need more of the &ldquo;bangin&rsquo; tunes&rdquo; portion. So basically I just try to implement things that make audio-related functionality work much nicer.</p> <h4 id="cpu">CPU</h4> <p>Our recompiler, dynarmic, isn&rsquo;t complete. The 64-bit side of things almost is, but it&rsquo;s not totally complete. We&rsquo;re missing some instructions, but they&rsquo;re instructions where it doesn&rsquo;t really make sense to use them from a performance standpoint if you&rsquo;re a game dev. So most of the time users of yuzu don&rsquo;t need to care about it. However, until we implement all of them, we can&rsquo;t kick our interpreter library (unicorn) into the sun. So over time I&rsquo;ll be working on that. We also still need to support 32-bit games, that&rsquo;ll come after the 64-bit side of things is all done.</p> <h4 id="kernel">Kernel</h4> <p>We don&rsquo;t implement everything the kernel is able to do, so this is quite a large area all on its own. It&rsquo;s also one of the most fundamental parts of Switch emulation, given it drives almost everything else in the emulator in terms of backing functionality (emulated processes, threads, memory mappings, etc). There&rsquo;s no real specific part of the kernel that I focus on.</p> <p>It&rsquo;s more of a cascading effect when working on it: <code>Oh, so I make [x] work right, then, with that in place, I can follow up with making [y] work properly.</code>, etc.</p> <p><strong>Q: Phew, is that all you do? Just kidding! Do you ever find time to eat during all of this?</strong></p> <p><strong>L:</strong> Hit me with that phat spicy Japanese food any day or any spicy food in general.</p> <hr> <p>Big thanks to <a href="https://github.com/lioncash/">Lioncache</a>, for sitting with us for this interview and also to special thanks to Jon S. for being the interviewer. We hope you guys enjoyed it, and we will be back soon with another featured Yuzu dev to bring you guys behind the curtain again. Until then, thank you for your support and stay tuned!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> yuzu Patreon Preview Release June 12th https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-jun-12/ Wed, 12 Jun 2019 03:48:00 +0530 flamesage https://yuzu-mirror.github.io/entry/yuzu-patreon-preview-jun-12/ <p>Good day, yuzu fans! Today we bring you another exciting yuzu update with the June 2019 Patreon Preview Release! We heard your feedback - this time around, we have some major graphical fixes!</p> <p>Good day, yuzu fans! Today we bring you another exciting yuzu update with the June 2019 Patreon Preview Release! We heard your feedback - this time around, we have some major graphical fixes!</p> <p>The team has been hard at work to constantly improve yuzu, and these additions are extremely important in painting the whole picture.</p> <p><strong>You can download this release on our <a href="https://www.patreon.com/yuzuteam">Patreon</a>!</strong></p> <h2 id="what-youll-find-in-this-new-build">What you&rsquo;ll find in this new build:</h2> <ol> <li><strong>A brand new Texture Cache:</strong> As certain members of our yuzu team inch ever closer to a Vulkan implementation, they realized the current OpenGL backend has an old yet heavily modified (for yuzu) texture cache that would be incompatible with Vulkan. There were also several bugs in our current cache and not everything was being emulated correctly. Now, we have a brand new API-agnostic texture cache that works with both OpenGL (and will work with Vulkan once we complete that renderer)! It&rsquo;s much more accurate and performant over the old/current implementation, and should also provide several graphical fixes!</li> <li><strong>Basic GPU Sync Mechanisms:</strong> We&rsquo;re well aware the current Async GPU emulation has major issues. The problem was that our current implementation lacked the real syncing mechanisms used by the Nintendo Switch, thus making it very unstable and caused crashes. With this new implementation, you can expect games to work much better with Async enabled!</li> <li><strong>Swap Interval Emulation:</strong> yuzu will now properly emulate the swap interval between window&rsquo;s refresh times, allowing us to correctly detect a games actual refresh rate. What this basically means is that if a game natively runs at 30fps, you will no longer need the option to &ldquo;force 30fps&rdquo; and yuzu automatically detects the games refresh rate! We still however provide this option, as it&rsquo;s useful to emulate some games at lower framerates when a full 60fps cannot be achieved.</li> </ol> <p>As always, we look to our dedicated Patrons to not only enjoy this new build, but to report how the build&rsquo;s new features are working for you. Find us on the Patreon section of discord to report issues, or just drop in to leave a comment. We look forward to continuing to lead the way in proper Switch emulation, and we again thank you for your continued support!</p> <p>All the best, yuzu Development Team</p> <p><strong>If you&rsquo;d like to try out this preview release, please head on over to our <a href="https://www.patreon.com/yuzuteam">Patreon</a> to get access! Thank you again for your support!</strong></p> New Feature - Boxcat https://yuzu-mirror.github.io/entry/yuzu-boxcat/ Thu, 23 May 2019 23:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-boxcat/ <p>Good day, yuzu fans! Today we bring you another exciting Switch feature which will create opportunities, for new in-game content across various games! Without further ado, let&rsquo;s get started!</p> <p>Good day, yuzu fans! Today we bring you another exciting Switch feature which will create opportunities, for new in-game content across various games! Without further ado, let&rsquo;s get started!</p> <h3 id="what">What?</h3> <p>Yes, you heard that correctly. New in-game content across various games, with events held occasionally.</p> <h3 id="how">How?</h3> <p>The Nintendo Switch has a network service called <code>BCAT</code>, using which games can add new content dynamically, i.e. new content without updating the game itself. Nintendo can push new content to various games via this service, whenever it wants. Some examples of this type of content would be - Super Mario Odyssey hints, Super Mario Odyssey costumes, and Splatoon 2 items.</p> <p><article class="message"> <div class="message-header is-dropdown"> <p>Note</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <strong>Users should possess the following versions of the games at minimum.</strong> <br> SMO - <code>1.2.0</code> || BOTW - <code>1.1.0</code> || Splatoon 2 - <code>3.2.0</code> </div> </article> <article class="message"> <div class="message-header is-dropdown"> <p>Surprise!</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <em>The Legend of Zelda - Breath of The Wild, now boots with updates and DLC enabled.</em> </div> </article> </p> <h3 id="then">Then?</h3> <p>Thanks to the efforts of our developer <a href="https://github.com/DarkLordZach">DarkLordZach</a>, we now have an open source replacement of the service in yuzu. By emulating the <code>BCAT</code> service at a high-level, yuzu is able to intercept the game&rsquo;s calls to Nintendo&rsquo;s servers and reroute them to yuzu&rsquo;s servers. This means that games running on yuzu, will now check for new content on yuzu&rsquo;s servers instead of Nintendo&rsquo;s.</p> <p>This allows us to add new in-game content for games that use this service. For the inaugural run, our team members have added some cool content across different games which you can check out <a href="https://yuzu-mirror.github.io/help/feature/boxcat/">here</a>. We will have new events occasionally, so users will have even more fun while playing games on yuzu.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./boxcat.png" title="Boxcat Settings Configuration"> <img src="https://yuzu-mirror.github.io/entry/yuzu-boxcat/boxcat_hucffa826a9f0df672451c592ed63a979a_54596_635x0_resize_q90_bgffffff_box_3.jpg" alt="Boxcat Settings Configuration"></a> <p class="has-text-centered is-italic has-text-grey-light">Boxcat Settings Configuration</p> </div> </div> <h3 id="when">When?</h3> <p>We will be testing this feature in our Patreon preview builds first and it will be available to Canary users in the near future.</p> <p>We would like to take this opportunity to ask that our users show their support by subscribing to our <a href="https://www.patreon.com/yuzuteam">Patreon</a>.</p> <p>By subscribing to our Patreon, you will be creating more incentive for developers to spend even more time working on yuzu. For example - Using Patreon funds, several internal bounties have been setup, which have lead to various new features or fixes you might have seen on our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a> or our <a href="https://discord.gg/u77vRWY">Discord</a>.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Want more information on Boxcat?</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> Refer to our help page for Boxcat. <a href="https://yuzu-mirror.github.io/help/feature/boxcat/">https://yuzu-mirror.github.io/help/feature/boxcat/</a> </div> </article> <h3 id="fin">Fin!</h3> <p>We thank all of our 300+ patrons for their continued love and support. We thank the entire yuzu community for the love and support they have shown to the project. We will be working even more diligently to bring many more new, and exciting features in the future. <br> Keep playing on yuzu, and have fun!</p> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> yuzu Patreon Preview Release https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/ Mon, 11 Feb 2019 03:48:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/ <p>A very good day to all you yuzu fans out there! Today we are here to share with you some very exciting news for our biggest supporters!</p> <p>A very good day to all you yuzu fans out there! Today we are here to share with you some very exciting news for our biggest supporters!</p> <h2 id="foreword">Foreword</h2> <p>As a start, let&rsquo;s talk about how emulator development works from a bird&rsquo;s-eye view. We all know that developing emulators requires significant reverse-engineering and programming knowledge, as well as lots of coding, testing, and bug fixing. That&rsquo;s the <strong>technical</strong> stuff. But before we can even get there, we need people who have the required skills and are willing to invest their time and effort into the project. These people, our Developers, work tirelessly to keep Switch emulation progressing. They work mostly in their free time and are very passionate about the project.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo-2.png" title="Super Mario Odyssey"> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/smo-2_hu02347dcc430ed080637b8e814a1b599b_2662642_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> </div> </div> <p><code>Wait a second, you guys probably already know all this stuff.</code> What you might not know is that, most of the time these developers work for free. They don&rsquo;t get paid for their efforts nor do they ask to be paid. In addition to our development costs (Switch consoles and games, web services, etc.), some of our developers are in situations that would really benefit from even a small amount of income from this project.</p> <p>As you probably know, we created a <a href="https://www.patreon.com/yuzuteam">Patreon</a> to address this need. We have asked the community to help us by subscribing and they heard. We now have over 200 patrons who collectively contribute to our project! We would like to sincerely thank them for their love, support, and contributions!</p> <p>When we decided to create a Patreon, we promised our patrons that they would get access to exclusive content as a thank you. Until now, we have only partially fulfilled our promise - by means of exclusive Discord support. It&rsquo;s about time we fulfilled on our promise.</p> <h2 id="big-news">Big News</h2> <p><strong>As a token of our thanks, we are announcing today that we will be releasing a special Preview of yuzu to our patrons!</strong></p> <p>We&rsquo;ve made lots of incredible progress that we&rsquo;d like to share first with the folks who have been our biggest supporters and fans.</p> <blockquote> <p>Starting today, patrons with donations of 5$/month and above (Patreon Roles: Supporter, Member, VIP) will get early access to new features via a <strong>yuzu Patreon Preview</strong>, before this content becomes available in our Nightly and Canary releases.</p> </blockquote> <p>Features found in this preview are not exclusive and will definitely be available for regular users within a few days. In accordance with our <a href="https://github.com/yuzu-emu/yuzu/blob/master/license.txt">open source license</a>, the source code for these previews will be made available to our patrons.</p> <p>This is just a preview release and is not similar to our Nightly or Canary builds - which get updated daily. We may do similar releases like this in the future as we have more exciting new features to share, but not with any set regularity. Support for this preview version will be given exclusively via the Patreon channels on our <a href="https://discord.gg/u77vRWY">Discord server</a>.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/botw_hu29bf85342407fe01fef2913587279d91_2727510_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda - Breath of the Wild"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/botw-1_hue5aef65a3bbdc69e0cd159dbd0fd61b7_3420834_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda - Breath of the Wild"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda - Breath of the Wild</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/smo_hu1bfdf14dda55b9d1adc7b742ef16d223_2796137_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-patreon-preview/smo-1_huffeae7701a7c1a0c9b6198c4e01a39f6_2313974_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> <p><strong>If you&rsquo;d like to try out this preview release, please head on over to our <a href="https://www.patreon.com/yuzuteam">Patreon</a> to get access! Thank you again for your support!</strong></p> Progress Report 2018 Part 4 https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/ Mon, 03 Dec 2018 04:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/ <p>Sorry for keeping you guys waiting! A whole slew of new updates and a ton of progress await you. Let&rsquo;s not waste anymore time and get the party started.</p> <p>Sorry for keeping you guys waiting! A whole slew of new updates and a ton of progress await you. Let&rsquo;s not waste anymore time and get the party started.</p> <p>These past couple of months have been absolutely fantabulous. If you were following us closely on <a href="https://twitter.com/yuzuemu">twitter</a>, you might have seen a few tweets but, strictly speaking, they don&rsquo;t even come close to describing the amount of work that has been accomplished.</p> <p>Also, a new remake was released on the Switch a few days back and with it a bunch of contributors raced to fix some of the new issues it uncovered. We will be covering that in a separate section, so hold on to your seats and enjoy the ride.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./lgpe.png" title="Pokémon: Let&#39;s Go, Eevee!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe_hub90f35d784dfb67992007de09962f74c_1562148_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Eevee!"></a> <p class="has-text-centered is-italic has-text-grey-light">Pokémon: Let&#39;s Go, Eevee!</p> </div> </div> <h2 id="cpu--core">CPU / Core</h2> <p><a href="https://github.com/MerryMage">MerryMage</a> has added a lot of new ARMv8 instructions to <a href="https://github.com/MerryMage/dynarmic">dynarmic</a>, our ARM dynamic recompiler, which further reduce our fallbacks to <a href="https://www.unicorn-engine.org/">unicorn</a>. Code generation has also been improved by making use of more recent CPU instructions (e.g. SSE4.1, AVX, AVX512, etc). We are slowly moving towards completely phasing out unicorn in favor of dynarmic, with nearly 85% of the work done. While there are still a few missing instructions in dynarmic, we didn&rsquo;t observe any games hitting them.</p> <p>Support for Linux <code>perf</code> command has been added, which allows us to profile the time we spend in recompiled game code. In simple terms, it helps us identify areas of code which are being used by games frequently, so that we can optimize those areas. For more info on <code>perf</code>, visit <a href="https://perf.wiki.kernel.org/index.php/Main_Page">here</a>.</p> <p><a href="https://github.com/lioncash">Lioncash</a> found and fixed a bug in dynarmic&rsquo;s <code>ExclusiveWrite128()</code> function. Due to this bug, when the second half of the value was being written, it would overwrite the first half. Thankfully this wasn&rsquo;t a bug that was being encountered, as the function is currently unused.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/botw_hu24e037a757197f2a05e5a3f91fd9dc74_1944526_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda - Breath of the Wild"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/botw-1_hua40f04b72d673b2dd6ed01b14526d5f8_2422246_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda - Breath of the Wild"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/botw-2_hu39497b9b5d3b2244e9ae64c13d760bf9_1878791_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda - Breath of the Wild"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda - Breath of the Wild</p> <h2 id="general-improvements">General Improvements</h2> <p>To ensure general feature parity between the sister projects, whenever we have new features implemented in <a href="https://citra-emu.org/">Citra</a>, we port them to yuzu and vice versa. Recently we have had new features like Joystick Hot-plugging support and Touch Input handling implemented in Citra. While Joystick hot-plugging allows us to connect/disconnect controllers on-the-go, without crashing the emulator, Touch Input handling allows us to use a physical touch screen for input, in the place of a mouse.</p> <p>Web Services &amp; Telemetry features are used to gather anonymous user statistics and for other backend stuff like user authentication. We now have a <a href="https://yuzu-mirror.github.io/game/">Compatibility Database</a> which lists the playability information for various games. Mind you that this list is a work-in-progress and is community driven. Play games on yuzu and while playing, go to <code>Help -&gt; Report Compatibility</code> and submit info to help improve the database. <code>Discord Rich Presence</code>, a novelty feature, was also added so that yuzu fans could show off in their discord statuses.</p> <p>Apart from these, we&rsquo;ve also had a few minor improvements like:</p> <ul> <li>Unsupported OpenGL extensions pop-up - which tells you if your GPU isn&rsquo;t suitable for yuzu.</li> <li>Background color changer - to change background color.</li> <li>Fixed logging initialization, default <code>username</code>, and default language in our SDL frontend.</li> </ul> <p><strong>Note</strong>: The Multi-core option has been temporarily removed, due to inaccuracies in our kernel and scheduler. We will likely support multi-core at some point in the future.</p> <h2 id="audio">Audio</h2> <p><a href="https://github.com/fearlesstobi">FearlessTobi</a> and MerryMage teamed up to bring audio-stretching to yuzu! While the implementation shares a lot in common with audio-stretching in Citra, it&rsquo;s been tuned and optimized for yuzu to decrease the performance impact on emulation and reduce delay and crackling as much as possible.</p> <p>If fixes are more your thing, <a href="https://github.com/ogniK5377">ogniK</a> fixed an annoying softlock in Super Mario Odyssey (SMO). This game expects various Effect States (for sound effects) to be initialized, even if they aren&rsquo;t updated. Because SMO hasn&rsquo;t been observed to actually update these states, assertions have been placed to see if they are ever updated. For now though, his changes mean that various hangs in SMO are fixed, making the game much easier to play.</p> <h2 id="gpu">GPU</h2> <p>Thanks to tons of contributions the past few months, yuzu&rsquo;s GPU core has seen a lot of fixes, optimizations and new features making emulated games look a lot more like their console experience. At the forefront of these efforts is getting the sublime 3D platformer, Super Mario Odyssey, to playable status.</p> <h4 id="super-mario-odyssey-smo">Super Mario Odyssey (SMO)</h4> <p>As you probably know, while yuzu technically could boot Super Mario Odyssey, it was neither able to properly render graphics nor run the game at decent speeds. To get the game working, was like an exciting challenge to the developers which, at the end, held a hidden treasure. So, they set out on a journey - to dig deeper into the internal workings of the game, as well as the console.</p> <p>But, as with any treasure hunt, you need clues to start somewhere. The only way to move forward was to try fixing the existing bugs and graphical issues, which could give more insight into what else might be broken. And thus started the journey, with 2 goals in mind - to fix issues in SMO and to make it run at playable speeds in yuzu.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./SMO-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/SMO-2_hu8171c30d957d27d8ccff2b7e02302b32_905716_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> <div class="column is-bottom-paddingless"> <a href="./SMO.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/SMO_huc75cf6737fc23d5ca9677d66c91f97ba_898909_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> <div class="column is-bottom-paddingless"> <a href="./SMO-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/SMO-1_hu9abbd01631f76a16c6e5b03f49d7c21e_1219029_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> <p><a href="https://github.com/bunnei">bunnei</a> and <a href="https://github.com/Subv">Subv</a> together implemented <code>multiple color attachments</code> for the framebuffers. A color attachment is a texture, which attaches to a framebuffer as a render target and is used for off-screen rendering. These are used in several techniques including reflection, refraction, and deferred shading.</p> <p>A render buffer, or render target, is any specially created single buffer to which part of rendering may be directed. Some examples would be color buffers and depth buffers. A framebuffer is a bound collection of several such render buffers. While all of these changes fixed many graphical issues in SMO and other games, performance still left a lot to be desired.</p> <p><strong>What if, for a change, instead of fixing bugs, we try to improve rendering in the game?</strong> bunnei independently set out to scrutinize the way we were rendering graphics and found out that we could improve the accuracy of how we cached and copied our framebuffers. And the result was improved rendering in SMO&rsquo;s Ruined Kingdom, without even having to use the <code>Accurate Framebuffers</code> setting in yuzu.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo-1295-b.png" title="Before"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1295-b_hue32881e8cc368d961f67b12247ba614d_220172_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> <p class="has-text-centered is-italic has-text-grey-light">Before</p> </div> <div class="column has-text-centered"> <a href="./smo-1295-a.png" title="After"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1295-a_huc3c41afeff2618892ce394c8d27dfb8d_756136_1024x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> <p class="has-text-centered is-italic has-text-grey-light">After</p> </div> </div> <p>Our further efforts to improve rendering led to the fact that we needed to properly provide textures to shaders.</p> <blockquote> <p>A texture is an OpenGL Object that contains one or more images that all have the same image format. A texture can be used in two ways - it can either be the source of a texture access from a Shader, or it can be used as a render target.</p> </blockquote> <p>There are a number of different types of textures in OpenGL and not all of them are 2D - some are arrays and some are cubemaps. These are special kinds of textures generally called Layered Textures. <a href="https://github.com/FernandoS27">Blinkhawk</a> found that we were incorrectly reading these special textures, which was causing various graphical glitches in games. He then reworked the code to account for size of mipmaps and made sure that we read these textures properly.</p> <p><a href="https://en.wikipedia.org/wiki/Mipmap">Mipmaps</a> are generally pre-calculated, optimized sequences of images, each of which is a progressively lower resolution representation of the same image. If the image to be rendered is big or close to the camera, the renderer uses a bigger texture map, while if it is smaller or farther away, then smaller textures are used.</p> <p>The absence of these mipmaps was yet another reason for glitchy rendering in several games. Blinkhawk identified this, and implemented mipmaps and texture processing modes - which are needed to access said mipmaps. Mipmaps are intended to increase rendering speed and reduce aliasing artifacts, while texture processing modes change the way games access a texture&rsquo;s mipmaps.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo-mip.png" title="Before"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-mip_hu80b73dd9c075af31373980c2841be77d_755027_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> <p class="has-text-centered is-italic has-text-grey-light">Before</p> </div> <div class="column has-text-centered"> <a href="./smo-map.png" title="After"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-map_hu5654db4c7bd2deab63f7336e94182610_915568_1024x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> <p class="has-text-centered is-italic has-text-grey-light">After</p> </div> </div> <p>Another missing texture type was Cubemaps. Cubemaps aren&rsquo;t unique to Super Mario Odyssey - in fact most games use cubemaps. Essentially, a cubemap is a texture that contains six individual 2D textures that form each side of a textured cube. The thing that sets SMO apart in this case is <em>how</em> it uses cubemaps in an unusual way. As with emulation, it&rsquo;s easy to emulate <em>expected</em> behaviors, but when a game uses a feature for something unanticipated, it can trip up an incomplete implementation. SMO tends to use a single render target for all six sides of the cubemap surface, necessitating yuzu to allow copying between render targets and cubemaps for correct emulation.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./metro1-b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/metro1-b_hud78500119ba29173362f1fdd3da305ba_1422697_800x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sand1-b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/sand1-b_hu49d181e2baf1544b0f11262f71050a52_858528_800x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Before</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./metro1-a.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/metro1-a_hue8e40f4df7a7f5899dd120add0a8bfec_1498591_800x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> </div> <div class="column is-bottom-paddingless"> <a href="./sand1-a.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/sand1-a_hufd1d4c27e61e14af6d2f5dc8ec47010e_864543_800x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">After</p> <p>Blinkhawk also implemented 3D textures, which are used for global illumination caching and to enable correct coloring. 3D textures work like regular textures, but they are truly 3D and are usually used for volumetric effects like smoke, fire, light rays, realistic fog, etc. The way in which Switch games create these is very interesting from an emulation perspective. It turns out that most games compute them on loading, instead of having them pre-computed and they are generated through some sort of hack over Nvidia&rsquo;s memory layout.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo-1505-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1505-1_hua8be62c8c6f9f38306716058437776cf_663231_800x0_resize_q90_bgffffff_box_3.jpg" alt="After 3D textures"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-1505-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1505-2_hu36f3a6d7edcc4ae551fcf2abf470ddca_1110664_800x0_resize_q90_bgffffff_box_3.jpg" alt="After 3D textures"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">After 3D textures</p> <article class="message"> <div class="message-header is-dropdown"> <p>XtraByte</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> The game tries to render 2d textures with a block depth of 16, (block depth should only be used on 3d textures), then overlaps them in a specific order of rendering and reinterprets that as a 3d texture. The solution we came up with was, to flush all textures in that memory area in the order of modification from last modified to newest and then read that memory as a 3D Texture. </div> </article> <p>While all the others were trying to fix graphical bugs, bunnei was still searching for ways to optimize performance of the game. He and Subv identfied a major issue - that we weren&rsquo;t flushing data properly.</p> <blockquote> <p>Flushing is the process of taking render buffers that were modified in the host-GPU and write them back to the guest RAM (Host - hardware, Guest - Switch). If you modify render buffers that were cached on the host-GPU but never flush them, then the games won&rsquo;t see the latest version of those render buffers when they try to access them.</p> </blockquote> <p>bunnei, over a couple of weeks, implemented flushing in the rasterizer cache and also for DMA transfers. Along with these, he also implemented accelerated Fermi2D copies. Fermi2D is one of the engines inside the GPU. It is like a 2D transformation engine, where you feed it 2D images and you can do a bunch of transformations on it in the GPU. With accelerated copies, the surface copying was now simpler and faster and as an additional bonus, it fixed several things like the ice effect in SMO and the blur effect in One Piece.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo-ice.png" title="Super Mario Odyssey"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-ice_huf4800aac8da81abe052ea46949966a89_2150971_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> </div> <div class="column has-text-centered"> <a href="./op-blur.png" title="One Piece"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/op-blur_hu6fb91679e6dbd566c54c1cc13ec73a11_1808009_1024x0_resize_q90_bgffffff_box_3.jpg" alt="One Piece"></a> <p class="has-text-centered is-italic has-text-grey-light">One Piece</p> </div> </div> <p>Days went by without any new findings but then we finally hit a jackpot. Code investigation and reverse engineering led us to an issue where <code>macros</code> could be skipped. <code>macros</code> are command sequences sent to the guest GPU and since they were being skipped, it led to distant objects not being rendered in SMO.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo-1622-b.png" title="Before"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1622-b_hu162abb123aec68a88480ab6f7797fc56_1109864_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> <p class="has-text-centered is-italic has-text-grey-light">Before</p> </div> <div class="column has-text-centered"> <a href="./smo-1622-a.png" title="After"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1622-a_hu59da17bb3168dbc3d1603db109639c83_1151213_1024x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> <p class="has-text-centered is-italic has-text-grey-light">After</p> </div> </div> <p>bunnei fixed this by restructuring the way we uploaded these macros to the guest GPU. Instead of piping macro code into separate memory for each program, we now write it to a single macro memory region and then execute macros via the specified offset into this region. He also found a bug in our memory manager, where buffers were being mapped over memory which was already in use. By fixing that, we fixed the rendering when changing areas in SMO.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo-1630-1b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1630-1b_hucb0a0cc43bdb5affef712ce70e9787fa_57009_800x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-1630-2b.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1630-2b_hu2948e888d0959bd3704cf917933a2dc6_93452_800x0_resize_q90_bgffffff_box_3.jpg" alt="Before"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Before</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo-1630-1a.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1630-1a_hub4118632d34200560bdfbf944e6d894c_1711079_800x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo-1630-2a.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/smo-1630-2a_hu420496a912de68cae1316de64bb14dd8_1177467_800x0_resize_q90_bgffffff_box_3.jpg" alt="After"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">After</p> <h4 id="new-features-optimizations-and-fixes">New Features, Optimizations, and Fixes</h4> <p>But <del>SMOzu</del> yuzu isn&rsquo;t a Super Mario Odyssey emulator, it&rsquo;s a Nintendo Switch emulator. And as such, any efforts to fix or improve a single game will definitely impact other games too and thus many other games are reaping the benefits of sustained work.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Back-to-School</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p>Let&rsquo;s go back to school for a bit. <strong>What is rendering and how does it work on modern GPUs?</strong> Rendering is a very generic term which is basically can be defined as &ldquo;creating an image&rdquo;, which can be, obviously, created in many ways.</p> <p>In modern GPUs, say if you want to render a triangle, you supply triangle coordinates to GPU and also load a shader to GPU. Then the GPU starts rendering the data you supplied, it is executing your shader on every triangle vertex (vertex shader) and every triangle pixel (pixel shader). Shaders are simple programs that describe the traits of either a vertex or a pixel. In the shader, you basically transform coordinates (vertex) and change color (pixel) of your final image. Shaders are very powerful and very fast, most effects in modern games are possible because of shaders.</p> <p>But, how does the shader know to transform given data to our exact requirements? That&rsquo;s because the shaders are programs that can be written using shader languages. There are a number of such shader languages, but we use a C-like language GLSL (OpenGL Shader Language). Modern GPUs make use of shader instruction sets, to pass commands to the individual programmable shader units and make them do the work.</p> </div> </article> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kirby.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/kirby_hue124d98fdcc56825f1d9dc59f645f797_1116110_800x0_resize_q90_bgffffff_box_3.jpg" alt="Kirby Star Allies"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kirby-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/kirby-1_hu133b31170ec3e5859097b114152357ac_1328124_800x0_resize_q90_bgffffff_box_3.jpg" alt="Kirby Star Allies"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Kirby Star Allies</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kirby-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/kirby-2_hu7d89c9a7754b19c474e862bd6f0f8100_363328_800x0_resize_q90_bgffffff_box_3.jpg" alt="In Game"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kirby-3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/kirby-3_huf0f26484eaebc5232c8f25ffd0192468_608742_800x0_resize_q90_bgffffff_box_3.jpg" alt="In Game"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">In Game</p> <p>The Nvidia Tegra X1 - which is the brain of the Switch, houses a Maxwell architecture based GPU. Like all other Nvidia GPUs, this too utilizes Nvidia&rsquo;s shader instruction sets to make the shaders render graphics. Unlike most other parts of our code base, which is HLE (High Level Emulation), our GPU emulation is LLE (Low Level Emulation).</p> <blockquote> <p>LLE just translates the native code and is the traditional way of emulating. Simply put, in LLE we interpret the <code>macros</code> sent to the GPU and then read the registers to render stuff. And to do that, we need to emulate the shader instructions that the GPU uses.</p> </blockquote> <p>Our developer Blinkhawk took it upon himself to try and implement the shader instructions in our GPU emulation. He refactored the existing <code>IPA</code> shader instruction, implemented the shader instructions <code>TMML</code>, <code>LEA</code>, <code>PSET</code>, properly implemented <code>TXQ</code> and fixed <code>TLDS</code>, <code>FSETP</code>, <code>FSET</code>.</p> <p>He implemented Cube Arrays, implemented <code>3 coordinate array</code> in <code>TEXS</code> instruction - which is used by Breath of the Wild, improved shader accuracy on Vertex and Geometry shaders, and improved GPU Cache&rsquo;s lookup Speed - which resulted in better overall performance.</p> <p>Another developer <a href="https://github.com/ReinUsesLisp">Rodrigo</a>, also lent a hand by independently researching the shader instructions we were missing and implementing them. He implemented a few instructions like <code>VMAD</code> &amp; <code>VSETP</code>- which are complex instructions used in Geometry Shaders, <code>PBK</code> &amp; <code>BRK</code> - which are flow instructions used by some games, and also implemented the whole set of &ldquo;Half-Float&rdquo; instructions - <code>HADD2</code>, <code>HMUL2</code>, <code>HFMA2</code>, <code>HSET2</code>, and <code>HSETP2</code>.</p> <p>Most games use 32-bit floats, but some use half floats (16-bit floats). These instructions can execute two operations at once and it&rsquo;s easier for the game to send half the data. Games like Xenoblade, Hyrule Warriors and L.A. Noire were found to be using these. As these are not used by <a href="https://nouveau.freedesktop.org/wiki/">nouveau</a>, it required a bit of hardware testing and help from the nouveau team to implement these. For those of you who don&rsquo;t know, the nouveau project develops and builds open source drivers for Nvidia GPUs on Linux.</p> <p>In the meantime, Blinkhawk, in his research efforts, found out that some shader information was going missing. This was because, not all the info of an Nvidia shader is saved in the registers and some can be sent to a temporary shader memory too. By implementing a shader local memory, we now began emulating such memory and thus fixed many graphical issues in games like ARMS and Splatoon 2, among others. He also implemented fast layered copy - which fixed performance regressions in ARMS and Splatoon 2, while improving loading performance in many other games.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./arms.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/arms_hu263730a3a6466737a0108a3e5c819045_1116803_800x0_resize_q90_bgffffff_box_3.jpg" alt="ARMS"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arms-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/arms-1_hu8eeb445a787f9e0a61a933f25f6168fa_1142540_800x0_resize_q90_bgffffff_box_3.jpg" alt="ARMS"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arms-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/arms-2_hu8ea0a16bdb1cf81022a5bc8ad4664b3f_1821330_800x0_resize_q90_bgffffff_box_3.jpg" alt="ARMS"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">ARMS</p> <p>Generally in OpenGL, rendering is done sequentially in multiple steps. It is called the <a href="https://www.khronos.org/opengl/wiki/Rendering_Pipeline_Overview">Rendering Pipeline</a>. While we had a working implementation of vertex shaders, we were still missing the geometry shaders. The geometry shader is an optional shader stage, that sits between the vertex and fragment shaders.</p> <p>Rodrigo did lots of research and finally did a basic implementation of geometry shaders. This shader has the unique ability to create new geometry on-the-fly, using the output of the vertex shader as input. Geometry shaders in Maxwell architecture do not specify input topology anywhere, they just receive the data as is. It doesn&rsquo;t care if it&rsquo;s a point or a triangle list. But in OpenGL, GS requires that input topology is in their source.</p> <p>The implementation isn&rsquo;t complete yet, but gets the job done. Most games that use GS will find correct behavior depending to what extent the games use GS. It still has scope for improvements and is also missing a few features like:</p> <ul> <li>built-in types of output.</li> <li>buffer streams.</li> </ul> <p>Rodrigo found the cause and fixed the infamous &ldquo;half-screen rendering&rdquo; bug on Intel GPUs (Windows). The cause of the bug was an expression, carried from Citra&rsquo;s GPU emulation code. Because of setting a default clip distance, the render was being cut to half. Removing that expression, fixed rendering on Intel GPUs.</p> <p>Also, he optimized our GPU emulation by using <code>ARB_multi_bind</code> for uniform buffers and sampler bindings, and implemented <code>quads</code> topology. The <code>ARB_multi_bind</code> is an OpenGL extension, which reduces OpenGL invokes by binding multiple objects to a single call. <code>quads</code> are rendered using OpenGL core and are used by some indie games and Xenoblade. A <code>quad</code> is a 4 vertex quadrilateral primitive and is not exposed in the modern OpenGL API. So as a workaround, we render <code>quads</code> with a pair of triangles.</p> <p>On a hunch that he could improve performance, Blinkhawk researched swizzling techniques and algorithms. Unsurprisingly, he found out that yuzu&rsquo;s initial implementations were grossly inefficient and took up the task of optimizing the various swizzling techniques. He implemented 3D swizzling and also optimized texture swizzling, fast swizzle, and legacy swizzle. The new Swizzling algorithm is about 6~12 times faster than the old one and adds functionality to read and interpret 3D Textures. For the users, this meant improved performance and FPS boosts.</p> <blockquote> <p>In order to load textures, we must convert them from a guest optimized format to linear format i.e., an Nvidia internal format into a linear format for OpenGL to read them. This process is called Swizzling. The opposite to this i.e., converting the linear format textures to guest optimized format, is called UnSwizzling.</p> </blockquote> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bandicoot.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/bandicoot_huc18c579a187b5e0134b47c76042302cd_1828324_800x0_resize_q90_bgffffff_box_3.jpg" alt="Crash Bandicoot"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bandicoot-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/bandicoot-1_hu78cd0f31784a9f3434e858cda88092f5_1620544_800x0_resize_q90_bgffffff_box_3.jpg" alt="Crash Bandicoot"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Crash Bandicoot</p> <p>Furthermore, he implemented the Scissor test, Alpha test - using shader emulation, depth compare, and shadow samplers. The Scissor test is a per-sample processing operation that discards fragments that fall outside of a certain rectangular portion of the screen. Alpha test is a hardware feature to skip certain pixels. The Alpha channel tells OpenGL which parts of image are transparent and which parts are opaque. Alpha test is used to discard pixels which fall outside of a certain range of alpha values. Depth Compare &amp; Shadow Samplers are used to implement occlusion in games. By adding support for them, games will be able to detect where shadows go by checking a depth texture through a shadow sampler.</p> <p><a href="https://github.com/Tinob">Tinob</a>, well known for Ishiiruka Dolphin, also contributed to the GPU emulation. He implemented <code>sRGB</code> framebuffers and improved OpenGL state handling to reduce redundant state changes and ensure default state to avoid driver implementation issues. Also, he researched and implemented various missing OpenGL states, added tweaks to reduce state handling redundancy, and added support for various registers. These fixed many small graphical bugs in SMO and other games.</p> <p><a href="https://github.com/degasus">degasus</a> fixed few bugs and optimized GPU emulation wherever possible by reducing the overhead per draw call. His optimization of the shader cache resulted in a significant performance boost across all games. <a href="https://github.com/FreddyFunk">FreddyFunk</a>, while profiling yuzu, recognized that in some scenarios a lot of time is taken by allocating memory in calls of <code>CopySurface</code> and optimized it for better performance.</p> <h4 id="pokémon-lets-go-pikachu--eevee">Pokémon: Let&rsquo;s Go, Pikachu! / Eevee!</h4> <p>The Pokémon franchise has been and always will be one of Nintendo&rsquo;s most successful and profitable franchises. And their newest iteration of games for the Nintendo Switch are Pokémon: Let&rsquo;s Go, Pikachu! &amp; Let&rsquo;s Go, Eevee! - remakes of good old Pokémon Yellow from the GameBoy days. For the developers, the thought of booting and emulating a hot new game on release day was very exciting. And thus began the rush - to test the games, fix issues, and essentially make it playable on day one.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./lgpe-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe-1_huead22ab7e594b419f26861f3ce1ae38f_1334383_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Pikachu!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./lgpe-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe-2_huf9309a56cf04c38bcbc4b092014ad323_1265050_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Pikachu!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./lgpe-3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe-3_hud3d4c34fb814e6fa14fed18607071298_1565628_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Pikachu!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon: Let&#39;s Go, Pikachu!</p> <p>ogniK was the first to get the game, thanks to time zones, and he immediately began his RE (reverse engineering) work. He found out that the games checked for the <code>Poké Ball Plus</code> controller on boot and since we didn&rsquo;t support it, the game wasn&rsquo;t booting in yuzu. After further research, he implemented a small set of commands and functions used by the bluetooth driver, which got us to the title screen.</p> <p>And just when we thought that was it, <em><strong>a wild softlock appeared!</strong></em> ogniK identified the cause of this to be in <code>HWOpus</code> and simultaneous RE efforts from <a href="https://github.com/gdkchan">gdkchan</a> of Ryujinx, revealed more info. It seems that the ordering of output parameters within a <code>HWOpus</code> function - <code>DecodeInterleaveWithPerformance</code> was wrong and fixing that resulted in audio output for both the Let&rsquo;s Go games.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./lgpe-4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe-4_huae7f4fb4ff87987d321515ef3ca0212c_1648438_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Eevee!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./lgpe-5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe-5_huef19b8f375da9a6e8707719eeb81cfb0_1249999_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Eevee!"></a> </div> <div class="column is-bottom-paddingless"> <a href="./lgpe-6.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/lgpe-6_hu9704082e155e4627ddf9270e1c4e552b_1257312_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokémon: Let&#39;s Go, Eevee!"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokémon: Let&#39;s Go, Eevee!</p> <p>Hexagon12 implemented a missing predicate comparison, which fixed trainer battle crashes in the games. With these, yuzu was finally able to boot into the game properly but it still crashed when naming the characters. Because the software keyboard applet wasn&rsquo;t implemented in yuzu, the games couldn&rsquo;t load the applet and hence crashed. <a href="https://github.com/DarkLordZach">DarkLordZach</a> was already working on implementing the applet and with a bit of research and testing, he was able to complete his implementation.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./swkbd.png" title="Software Keyboard in Pokémon: Let&#39;s Go, Eevee!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/swkbd_hu7b4045d51c4ac413be9f4a9cec35102a_6356_479x0_resize_q90_bgffffff_box_3.jpg" alt="Software Keyboard in Pokémon: Let&#39;s Go, Eevee!"></a> <p class="has-text-centered is-italic has-text-grey-light">Software Keyboard in Pokémon: Let&#39;s Go, Eevee!</p> </div> </div> <p>Provided that your PC hardware is strong enough to handle yuzu, the new Pokémon games are playable, with a few caveats. Currently, some of the graphics render well, but there are still a lot of flaws - like fonts missing everywhere. But hey! the audio works decently, although you still need a save file to bypass softlocks in the beginning. Even with all these, there are random crashes everywhere - which require more in-depth testing to fix.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./pokken.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/pokken_hu135f7d2502d25dc39b7591a4c10bd2a9_606635_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokkén Tournament"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pokken-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/pokken-1_huc2e1b707c7b8780e9ac8c3b46fa9f728_1190339_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokkén Tournament"></a> </div> <div class="column is-bottom-paddingless"> <a href="./pokken-2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/pokken-2_hub879e20b61cd2e1e74ac2c4173598574_94159_800x0_resize_q90_bgffffff_box_3.jpg" alt="Pokkén Tournament"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Pokkén Tournament</p> <p>Apart from these, there were multiple minor improvements and fixes done by our team and other contributors, which helped us get further into accurate GPU emulation. We also updated the OpenGL&rsquo;s backend version from 3.3 to 4.3 and removed pre 4.3 <code>ARB</code> extensions. With this, the minimum required OpenGl version for yuzu has been bumped up to 4.3 as well.</p> <h2 id="operating-system---hle">Operating System - HLE</h2> <p>In regards, to the operating system, kernel, and various service modules, we have made a lot of progress here as well. Lioncash has been absolutely phenomenal in fixing and optimizing our HLE (High-level emulation) kernel implementation. He spent dozens of hours in RE (reverse engineering), to debug our kernel and made sure that everything was proper. Most of his work in this regard has been:</p> <ul> <li>Adding missing error codes in the kernel.</li> <li>Handling error cases within memory related functions.</li> <li>Handling &ldquo;invalid address&rdquo; cases within SVC (Supervisor Call) functions.</li> <li>Adding missing address range checks in <code>MapMemory</code> &amp; <code>UnMapMemory</code> functions.</li> <li>Fix VMA (Virtual Memory Access) boundary check in <code>svcQueryMemory</code>.</li> <li>Added missing Korean font in our open-source implementation fallback.</li> </ul> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./octo.png" title="Octopath Traveler"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/octo_hu1a9eae6ee954920950c3e477ee218c9b_1463279_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Octopath Traveler"></a> <p class="has-text-centered is-italic has-text-grey-light">Octopath Traveler</p> </div> <div class="column has-text-centered"> <a href="./donkey-kong.png" title="Donkey Kong"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/donkey-kong_hu71f663eee18867987395e2f90accb799_2465611_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Donkey Kong"></a> <p class="has-text-centered is-italic has-text-grey-light">Donkey Kong</p> </div> </div> <p>He implemented an svc function - <code>svcGetThreadContext</code> - which retrieves the the context backing a thread, or the state of the thread at that given moment, and writes it to a provided buffer. The thread context contains the state of CPU execution - such as general purpose registers, stack pointer, program counter, and several other fields. This thread context can be used by the executable for debugging purposes, or to save and reuse it later, or anything else entirely depending on the executable.</p> <p>He also made changes in our virtual memory manager, to load NPDM metadata. NPDM is the Switch equivalent of 3DS exheader. Previously we were never loading NPDM metadata in the event that it was available and it meant that we&rsquo;d be making assumptions about the address spaces. With this, he de-hardcoded our assumption of a 36-bit address space, given that it&rsquo;s possible for a game to demand a 39-bit one or 32-bit one and we can now derive the parameters from supplied NPDM metadata, if the supplied executable supports it.</p> <p>Apart from these notable changes, Lioncash made several other contributions to yuzu. He updated the function tables for various services - based on latest documentation from <a href="http://switchbrew.org">Switchbrew</a>, fixed minor bugs in various svc functions, worked tirelessly on maintaining proper C++ style across the code-base, and made performance optimizations wherever possible.</p> <p>While Lioncash has been handling the kernel stuff, our Switch RE expert - ogniK has been busy fixing and implementing more service functions. ogniK properly implemented the <code>fatal:u</code> service, stubbed the <code>IRS</code> service, and added many missing functions across various services. He reworked the <code>nifm</code> service stubs - which were found to be incorrect, fixed an <code>acc</code> service stub - which allowed us to boot the Nintendo Switch Online NES emulator, implemented a few missing functions in <code>AudRen</code> and <code>HwOpus</code> services - which fixed audio for Sonic Ages. (Although Nintendo Switch Online NES emulator boots, it doesn&rsquo;t mean users can play online.)</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./nso-nes.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/nso-nes_hu30067545b03472f32cc89306767481f3_248483_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nintendo Switch Online - NES emulator"></a> </div> <div class="column is-bottom-paddingless"> <a href="./nso-nes-1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/nso-nes-1_hu4517bbc33ed2c445b1c5c56e2eb94c5d_4093055_800x0_resize_q90_bgffffff_box_3.jpg" alt="Nintendo Switch Online - NES emulator"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Nintendo Switch Online - NES emulator</p> <article class="message"> <div class="message-header is-dropdown"> <p>XtraByte</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> Stubbing means that these services return <code>ok</code> with no errors, so that the games think that the function succeeded and it can continue on without getting back any valid data. As the games boot further and further, we need to start intercepting these function calls and provide a more meaningful response. </div> </article> <p>He added the ability to switch between docked and undocked mode while in-game, added support for Amiibo files &amp; uncompressed NSOs, and fixed a few minor bugs in various service functions. Although, this isn&rsquo;t complete Amiibo support just yet. Only a few games work and more support will be added in the future.</p> <p>ogniK reworked and refactored the entire <code>HID</code> service implementation, dubbed <code>Better HID</code>, and vastly improved it. He replaced lot of stubbed functions with actual implementations and fixed our <code>HID layouts</code>. This allowed the registration of multiple user controllers <strong>AND</strong> different <strong>TYPES</strong> of controllers (handheld, joycon left, joycon right, pro controller), except for <code>tabletop mode</code> - wireless dual joycons.</p> <p>DarkLordZach hasn&rsquo;t been sitting quietly either. He picked up from where ogniK&rsquo;s <code>HID</code> rework left off and made further improvements. He added full UI support to change the connectivity, type/layouts and buttons for all eight players, the handheld controller, the debug controller, mouse, keyboard, and finally touchscreen.</p> <p>He also made many new improvements to the file system and added new features as well. His other notable works include:</p> <ul> <li>Added support for <code>LayeredFS</code> mods - which brings infinite possibilities for games in yuzu.</li> <li>Added support for packed updates - which are basically <code>XCI</code> files with both base game and updates.</li> <li>Implemented DLC loading.</li> <li>Added support for full key-derivation, so that you don&rsquo;t need 3rd party tools for dumping keys, only our <a href="https://yuzu-mirror.github.io/help/quickstart/">quickstart</a> guide.</li> <li>Added support for loading IPS patches.</li> <li>Added support for the more easier IPSwitch format patches.</li> <li>Implemented save data types - <code>TemporaryStorage</code> and <code>DeviceSaveData</code>.</li> <li>Added UI for multiple user profiles (emulated).</li> <li>And many more minor bug fixes and optimizations.</li> </ul> <p>bunnei implemented the <code>loadNRO</code> functions from the <code>ldr:ro</code> service. This was a basic implementation of the functions which allowed us to boot Super Mario Party. DarkLordZach later completed the <code>ldr:ro</code> service implementation, based on research done by bunnei, Subv, and the folks at Atmosphere.</p> <h2 id="conclusion">Conclusion</h2> <p>The improvements we&rsquo;ve covered here are only the major ones. In addition to these, we have had many minor bug fixes &amp; feature implementations done by our valuable contributors. Many thanks to our contributors and also to the devs from various communities who have indirectly helped us progress forward. Special thanks to our patrons who have showed their continued support for our efforts in this project. Also, another special thanks to JMC47 - one of the authors for dolphin-emu blog, for all his inputs and criticism regarding this article.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./splatoon2.png" title="Splatoon 2"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/splatoon2_hu9fd36cf0cc8f01f349d675587d89c3ba_1043593_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Splatoon 2"></a> <p class="has-text-centered is-italic has-text-grey-light">Splatoon 2</p> </div> <div class="column has-text-centered"> <a href="./sonic-forces.png" title="Sonic Forces"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/sonic-forces_hue9e2901d674f9e40db09b6a48a9e18f3_2068754_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Sonic Forces"></a> <p class="has-text-centered is-italic has-text-grey-light">Sonic Forces</p> </div> <div class="column has-text-centered"> <a href="./sonic-forces-1.png" title="Sonic Forces (In game)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p4/sonic-forces-1_hu5647d1d3f6149d1f931bad4d06300fd5_70215_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Sonic Forces (In game)"></a> <p class="has-text-centered is-italic has-text-grey-light">Sonic Forces (In game)</p> </div> </div> <article class="message"> <div class="message-header is-dropdown"> <p>Note</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p>All these screenshots have been taken in docked mode of yuzu, using a PC with the following specs:</p> <ul> <li>CPU - Intel i3 6100</li> <li>GPU - Nvidia GTX 750ti</li> <li>RAM - 12 GB DDR3</li> </ul> </div> </article> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report 2018 Part 3 https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/ Tue, 11 Sep 2018 22:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/ <p>It&rsquo;s only been over a month since our last report, and we have made so much progress already that we simply can&rsquo;t wait to share it with you guys. Without further ado, let&rsquo;s dive in.</p> <p>It&rsquo;s only been over a month since our last report, and we have made so much progress already that we simply can&rsquo;t wait to share it with you guys. Without further ado, let&rsquo;s dive in.</p> <p>  <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo.png" title="Super Mario Odyssey (Title screen)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_hu7812af92d5a5269518ff8fdaee26d84a_712239_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (Title screen)"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (Title screen)</p> </div> </div> </p> <h2 id="cpu--core">CPU / Core</h2> <p>On the CPU emulation front, <a href="https://github.com/MerryMage">MerryMage</a> and <a href="https://github.com/lioncash">Lioncash</a> have been absolutely phenomenal. They have implemented a lot of missing ARMv8 instructions to <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a>, our ARM recompiler, and also fixed many bugs in the existing ones. Because of this, the number of times yuzu has to fallback to <a href="http://www.unicorn-engine.org/">Unicorn</a> has been reduced and has improved the overall performance of yuzu.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./arms.png" title="Title screen"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/arms_hu03753d3ea23a14a1d34f0af9eb1b2d39_1739123_800x0_resize_q90_bgffffff_box_3.jpg" alt="ARMS"></a> </div> <div class="column is-bottom-paddingless"> <a href="./arms_1.png" title="Info"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/arms_1_hud22fed21b0490cf0afc8a194fede4c35_259896_800x0_resize_q90_bgffffff_box_3.jpg" alt="ARMS"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">ARMS</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./arms_2.png" title="Menu"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/arms_2_hu6798de800964c421bf8044579f2de621_823292_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Menu"></a> <p class="has-text-centered is-italic has-text-grey-light">Menu</p> </div> <div class="column has-text-centered"> <a href="./arms_3.png" title="In-game"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/arms_3_huaaeb07098288c828f887931b21978154_1300974_1024x0_resize_q90_bgffffff_box_3.jpg" alt="In-game"></a> <p class="has-text-centered is-italic has-text-grey-light">In-game</p> </div> </div> <p>Thanks to <a href="https://github.com/Hedges">Hedges</a>, the previously Unicorn-only GDBStub now works with Dynarmic as well. GDBStub is a debugging tool which helps the developers find errors/bugs in the code. <a href="https://github.com/Subv">Subv</a> fixed a bug in dynarmic which was causing issues with CPU state management, by preventing writing data to a register.</p> <h2 id="general-improvements">General Improvements</h2> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./octo.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/octo_hu39ce4230b9fcb0b42b7f5f959f1e79c1_38942_800x0_resize_q90_bgffffff_box_3.jpg" alt="Octopath Traveller"></a> </div> <div class="column is-bottom-paddingless"> <a href="./octo_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/octo_1_hucf9a9016aad7632db7e8e56e4c18f94e_21143_800x0_resize_q90_bgffffff_box_3.jpg" alt="Octopath Traveller"></a> </div> <div class="column is-bottom-paddingless"> <a href="./octo_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/octo_2_hubfc6d3624c6332281c3ddca8537944b0_62509_800x0_resize_q90_bgffffff_box_3.jpg" alt="Octopath Traveller"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Octopath Traveller</p> <p>As both Citra and yuzu share common code, <a href="https://github.com/fearlesstobi">FearlessTobi</a> ported over various changes made in Citra to yuzu. Here are some of the things he ported:</p> <ul> <li>Logging the yuzu version - to help us identify yuzu version from log file.</li> <li>Added &ldquo;Continue/Pause&rdquo; &amp; &ldquo;Toggle Speed limit&rdquo; hotkeys.</li> <li>Updated Dark theme to latest version.</li> <li>Added &ldquo;Build-date&rdquo; info to the &ldquo;About&rdquo; dialog.</li> <li>Fixes for Travis CI environment.</li> <li>Added Game Compatibility List to yuzu.</li> <li>Many more code optimizations and minor bug fixes.</li> </ul> <p><a href="https://github.com/DarkLordZach">DarkLordZach</a> implemented the display of game-title in the window title bar. <a href="https://github.com/CaptV0rt3x">CaptV0rt3x</a> ported over the display of version number in the title bar.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./puyo.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/puyo_hu0ce1abe99a6b8c0bd5bfb02895f13c77_888363_800x0_resize_q90_bgffffff_box_3.jpg" alt="Puyo Puyo TETRIS"></a> </div> <div class="column is-bottom-paddingless"> <a href="./puyo_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/puyo_1_hu391a213220bf6a2719575f6f3dca49cf_607120_800x0_resize_q90_bgffffff_box_3.jpg" alt="Puyo Puyo TETRIS"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Puyo Puyo TETRIS</p> <h2 id="os">OS</h2> <p>Lioncash fixed a potential data race condition in the kernel object, by ensuring that the class handles its reference counts atomically.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Info</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> A race condition, is an undesirable situation that occurs when a device or system attempts to perform two or more operations at the same time, but because of the nature of the device or system, the operations must be done in the proper sequence to be done correctly. </div> </article> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./bayo.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/bayo_hu22612c0be3621826b165feadb0d6669d_501774_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bayonetta"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bayo_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/bayo_1_hu99dc714e60391943d8009e4a7f396619_526300_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bayonetta"></a> </div> <div class="column is-bottom-paddingless"> <a href="./bayo_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/bayo_2_hud7499b9647e97377d34900c6d3b57b1b_2107321_800x0_resize_q90_bgffffff_box_3.jpg" alt="Bayonetta"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Bayonetta</p> <p>The atomicity ensures that the change to the reference count is visible to all threads between operations and thus ensuring a race never happens. And since that object class is inherited by all of the kernel objects in yuzu, this pretty much affected every kernel object. Apart from this, he also optimized the code in the kernel scheduler and thread queue list.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./boi.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/boi_huf5f15570818a0840e0a5cea3c6eb0140_652931_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Binding of Issac"></a> </div> <div class="column is-bottom-paddingless"> <a href="./boi_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/boi_1_hu824263e2ec3bafbdef40392061d43b20_271029_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Binding of Issac"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Binding of Issac</p> <h2 id="gpu">GPU</h2> <p><a href="https://github.com/degasus">degasus</a>, who was responsible for the stream buffer implementation in Citra, replaced the existing stream buffer in yuzu with Citra&rsquo;s. For the uninitiated, stream buffers are used for uploading vertex data to the GPU. He has also been doing quite a lot of GPU code profiling and making optimizations. Because of this, we are getting to the point where GPU emulation is not much of a bottleneck anymore.</p> <p>In addition,he&rsquo;s implemented a buffer cache, to avoid redundant uploads, and a VAO (Vertex Array Object) cache, to cache VAO objects. Buffer cache works by caching the uploaded buffers within the stream_buffer and just reusing the old pointers. VAO cache works by caching VAO objects instead of re-emitting all pointers per draw call.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./disg.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/disg_hu867ee525d1034fd3a66f03fbeb03818a_76316_800x0_resize_q90_bgffffff_box_3.jpg" alt="Disgaea 5"></a> </div> <div class="column is-bottom-paddingless"> <a href="./disg_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/disg_1_huc6c7573a68ac5d672f9920ca81f4dcf1_1729097_800x0_resize_q90_bgffffff_box_3.jpg" alt="Disgaea 5"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Disgaea 5</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./disg_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/disg_2_hu702c2b624081631f71196e135b0c952e_1699854_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./disg_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/disg_3_hub18e3b779b1cd922a559f6aa9035b7d7_1537846_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p><a href="https://github.com/bunnei">bunnei</a>, <a href="https://github.com/Subv">Subv</a>, <a href="https://github.com/ogniK">ogniK</a>, and <a href="https://github.com/greggameplayer">greggameplayer</a> have implemented many missing texture formats, pixel formats, and render targets. These implementations allowed us to proceed further in a lot of games like One Piece, Fate Extella, Go Vacation, and Xenoblade. Subv also implemented a few depth buffer formats and added support for depth buffer testing. Depth buffers are used for specifying the depth of each pixel, thereby creating various visual effects.</p> <p>bunnei implemented a couple of vertex attributes, added more texture wrap modes, implemented shader instructions like <code>TLDS</code> &amp; <code>SEL</code>, fixed <code>TEXS</code> shader instruction, implemented <code>TEXS</code> masks, and fixed texture unswizzle. He also made various improvements to the rasterizer cache and improved its performance by avoiding superfluous copies. This fixed rendering issues in Cave Story+, Disgaea 5, and Binding of Issac. ogniK fixed <code>glVertexAttribFormat</code> for integers - which fixed exploding vertices in One Piece Unlimited World. Lioncash refactored, cleaned and made improvements / optimizations to the GPU code.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./doom.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/doom_hudd7b39bbad75b7acb1e29a7f0b83615d_24288_800x0_resize_q90_bgffffff_box_3.jpg" alt="DOOM"></a> </div> <div class="column is-bottom-paddingless"> <a href="./doom_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/doom_1_huca5d12cf04a36e4a904473c7fa8a42f2_819972_800x0_resize_q90_bgffffff_box_3.jpg" alt="DOOM"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">DOOM</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./fe-w.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/fe-w_hu455490eb52f3b9265c0f57b7cf561a82_121846_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem - Warriors"></a> </div> <div class="column is-bottom-paddingless"> <a href="./fe-w_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/fe-w_1_hu67d4aaec83cd32927adbd328ea7908b1_1130895_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fire Emblem - Warriors"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fire Emblem - Warriors</p> <h2 id="service-hle">Service HLE</h2> <p>With the latest documentation available on <a href="https://switchbrew.org/index.php/Main_Page">Switchbrew</a>, we have made various bug fixes to our service implementations and also added new services as well. Lioncash, <a href="https://github.com/mailwl">mailwl</a>, and Hexagon12 worked on stubbing the <code>HID</code> (Human Interface Devices) service and also made a few improvements there as well.</p> <p>The <code>HID</code> service basically manages the controllers. It stores all sorts of information related to controllers in a shared memory region, which we read from. ogniK and bunnei fixed the <code>Friend</code> service, which fixed a crash in Splatoon 2 and also got Retro City Rampage booting.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hb-h.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hb-h_hu02533d1c8e27b72d0817f48be1818751_2122988_800x0_resize_q90_bgffffff_box_3.jpg" alt="Has-Been Heroes"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hb-h_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hb-h_1_hu40cf3495639e86c16a597beb93fda31a_1328165_800x0_resize_q90_bgffffff_box_3.jpg" alt="Has-Been Heroes"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Has-Been Heroes</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hb-h_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hb-h_2_huc7df36579cd7e3dff1c47abe9299e869_1143147_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./hb-h_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hb-h_3_hu3bb0ae2ad768f4960f3f472a755d7c66_947931_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p>The <code>Friend</code> service is mainly for your Nintendo Online friends, your friend list etc. In this current implementation, we are always offline and we send the same response (offline) to the system and games as well. The crash in Splatoon 2 was fixed because it was requesting the friend list and we returned a response of <code>Zero (0) Friends</code> to it. It is not exactly an accurate replication of Switch&rsquo;s behavior, but games seem to accept that response.</p> <p>Similarly, we got Retro City Rampage booting because it was trying to get the User&rsquo;s Presence and we added a stub in place of it. mailwl added more stubs for the <code>Account</code> service. Lastly, the <code>Account</code> service is mainly for management of your local account or registered users on the system.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./fh.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/fh_hufed2e915dc4b51c4575a171ca6024415_2534951_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fantasy Hero"></a> </div> <div class="column is-bottom-paddingless"> <a href="./fh_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/fh_1_huc003a0dbaeda1725d96893f5e3438278_1053697_800x0_resize_q90_bgffffff_box_3.jpg" alt="Fantasy Hero"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Fantasy Hero</p> <p>Each user has an unique UUID (Universally Unique Identifier), which is generated when an account is made, and they each have some information about their profile. This info is typically referenced when saving games. ogniK worked on the necessary foundation to support multiple user accounts and their management, in the future. He also implemented functions to allow setting the username and locale of the Switch.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./hyrule.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hyrule_hu9e2fd1c06dedb9103f0dd9617b2d16b6_413536_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors"></a> </div> <div class="column is-bottom-paddingless"> <a href="./hyrule_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hyrule_1_hufed2acae5d2c42445ae617eefcf2f087_2018219_800x0_resize_q90_bgffffff_box_3.jpg" alt="Hyrule Warriors"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Hyrule Warriors</p> <p>ogniK also implemented support for loading shared fonts in the <code>pl:u</code> service. As we now support loading system <code>bfttf</code> fonts, users who have installed their system nand dumps to yuzu will automatically get shared fonts. For other users, you can now load shared fonts from <code>ttf</code> files as well.</p> <p>Fearlesstobi, by taking inspiration from Citra&rsquo;s implementation, integrated open-source shared fonts into yuzu. This can clearly be observed in above screenshots from the game - Hyrule Warriors.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Info</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p>The fonts need to be named as follows:</p> <ul> <li>FontStandard.ttf</li> <li>FontChineseSimplified.ttf</li> <li>FontExtendedChineseSimplified.ttf</li> <li>FontChineseTraditional.ttf</li> <li>FontKorean.ttf</li> <li>FontNintendoExtended.ttf</li> <li>FontNintendoExtended2.ttf</li> </ul> </div> </article> <p>Lioncash implemented the skeletons for various new services like <code>time:a</code>, <code>es</code>, <code>pm</code>, <code>erpt</code>, <code>eupld</code>, <code>ldr</code>, and many more.</p> <h2 id="file-system">File System</h2> <p><a href="https://github.com/DarkLordZach">DarkLordZach</a> added support for various features like loading encrypted NCA files and XCI files, displaying game icons, parsing metadata, and made error handling more descriptive.</p> <p>Encrypted <code>NCA</code> files are just game files in a container. <code>XCI</code> files are basically raw gamecard dumps. Gamecards have 3 major partitions. An <code>Update</code> Partition - which stores system updates, a <code>Secure</code> Partition - which has the game <code>NCAs</code>, and a <code>Normal</code> Partition - which just stores miscellaneous files. What we want is the <code>Secure</code> Partition. It contains the game <code>NCAs</code> and other metadata as well, which is very useful. <code>XCI</code> files are relatively easy to dump compared to other methods and are very useful.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./game_list.png" title="Gamelist showing games and updates"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/game_list_hu9bb034da2d362bf1e34f1fe3632b480d_118034_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Gamelist showing games and updates"></a> <p class="has-text-centered is-italic has-text-grey-light">Gamelist showing games and updates</p> </div> </div> <p>By adding support for loading <code>NCAs</code> and <code>XCIs</code>, it removes a lot of unnecessary steps when you dump your games. Before, you had to dump your <code>XCI</code>, then extract the <code>Secure</code> partition, and then extract the <code>NCA</code> into the format for yuzu. This left you with nearly 8 different files, which are binaries and a romfs file. Now with this feature, you can directly open your <code>NCA</code> files or, better yet, your <code>XCI</code> files. And because <code>XCI</code> files come with additional metadata, you can also get game icons from them. The icons can be configured to display at various sizes within yuzu.</p> <p>DarkLordZach went a step ahead and implemented support for <code>NAX</code> (Nintendo AesXts) archives. With this, you can load your games from your Switch&rsquo;s SD card <em><strong>directly</strong></em> by connecting it to your PC. He also fixed a few issues with our earlier VFS implementation and made further improvements to it as well.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./runner3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/runner3_huc593916dda20e289841d10b9337f531f_160882_800x0_resize_q90_bgffffff_box_3.jpg" alt="Runner 3"></a> </div> <div class="column is-bottom-paddingless"> <a href="./runner3_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/runner3_1_hu9976f602948844e427a1c7947235ff58_905352_800x0_resize_q90_bgffffff_box_3.jpg" alt="Runner 3"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Runner 3</p> <p>He also added support for the <code>NSP</code> (Nintendo Submissions Package) file format, <code>BKTR</code> format, and added an option to set custom NAND/SD directories. As <code>NSP</code> support will likely become the new format of choice for advanced dumper homebrew and other tools, adding support means less steps while dumping. <code>NSPs</code> contain all the metadata and can contain game updates / DLCs as well. With added support for <code>BKTR</code> format, you can now install game updates from yuzu NAND or SD directly via the UI. He and Lioncash also worked on refactoring the File System code and made optimizations wherever possible.</p> <article class="message"> <div class="message-header is-dropdown"> <p>Warning</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p style="color:#eb152e"><b><i>Keep in mind that, all types of files will still need their decryption keys.</b></i> </div> </article> <h2 id="audio">Audio</h2> <p>As yuzu was progressing at an incredibly fast pace, one of the most sought out features was audio output. We discussed this in our earlier report that the Switch has 2 methods of audio output <code>AudRen</code> and <code>AudOut</code>. First, bunnei emulated <code>AudOut</code> without actually producing audio output. This was used for only a handful of games like One Piece, Snipperclips, Minecraft etc.</p> <p>Emulating <code>AudOut</code> state without actually outputting audio was sufficient to get these games to go into actual game play. This was because games often wait for signaling to indicate that an audio clip has finished playing. We can properly signal this state without actually playing the sound, allowing these games to continue running. Later he added audio output, based on <a href="https://github.com/kinetiknz/cubeb">cubeb</a>, for games that used the <code>AudOut</code> service.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./humanff.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/humanff_huf62aa96df21c21fbaf0727ee64ac6437_424983_800x0_resize_q90_bgffffff_box_3.jpg" alt="Human Fall Flat"></a> </div> <div class="column is-bottom-paddingless"> <a href="./humanff_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/humanff_1_hu40343b8e44141344ddd4e27262bf6538_768470_800x0_resize_q90_bgffffff_box_3.jpg" alt="Human Fall Flat"></a> </div> <div class="column is-bottom-paddingless"> <a href="./humanff_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/humanff_2_hua48623962ca3b470dfc740aefb07c997_338407_800x0_resize_q90_bgffffff_box_3.jpg" alt="Human Fall Flat"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Human Fall Flat</p> <p>ogniK did the reverse engineering and helped with the HLE (High Level Emulation) implementations of <code>Audout</code> and <code>AudRen</code> services. He also added opus library and implemented <code>hwopus</code> service functions, which uses <code>AudOut</code> and <code>AudRen</code>, which fixed Pokemon Quest and Touhou. Since we didn&rsquo;t have <code>AudRen</code> yet, it only worked with games using <code>AudOut</code>.</p> <p>It took a while but bunnei finally implemented the <code>Audren</code> method, which got audio output for most games like Cave Story+, Binding of Issac, Super Mario Odyssey, Puyo Puyo Tetris and many more. bunnei&rsquo;s original implementation of audio output, with cubeb backend, only supported two-channel 48000Hz - which is the most common audio output format. This works well for <code>AudOut</code> games, but games that use <code>AudRen</code> could use variable sample rates. Because we were always playing all sounds at 48000Hz, even though it was working properly, the sounds would be audible but would often sound sped-up or with incorrect pitch.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./opuw.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/opuw_hu5a67d9144ad692efce8a3f3f8f4aafad_1432892_800x0_resize_q90_bgffffff_box_3.jpg" alt="One Piece Unlimited World"></a> </div> <div class="column is-bottom-paddingless"> <a href="./opuw_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/opuw_1_hud189f32c797b9884a1a4a504cd145850_972207_800x0_resize_q90_bgffffff_box_3.jpg" alt="One Piece Unlimited World"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">One Piece Unlimited World</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./opuw_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/opuw_2_huc042e0cc1ffb6d53bec0f9ce3dc31cb8_2194744_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./opuw_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/opuw_3_hu6b0536aa92dacee55c4d258ffc045146_2095852_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p>MerryMage fixed this problem by implementing audio interpolation and filtering, which allowed us to resample these sounds from their original sample rate to 48000Hz. Audio Interpolation is a method of making digital audio sound better than it actually is and filtering helps reduce artifacts that arise when resampling the audio. She also found and fixed threading issues with the cubeb backend. Lioncash did lots of refactoring and made multiple improvements / optimizations to Audio code.</p> <h2 id="super-mario-odyssey">Super Mario Odyssey</h2> <p>As it turns out, Super Mario Odyssey (SMO) has actually been capable of going in-game for quite a while. However, due to really bad performance and some occasional emulator crashes, no one was really testing it.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./smo_3.png" title="Super Mario Odyssey"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_3_hu7bcd28ee584836da9186975e78b0054d_1111036_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey"></a> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey</p> </div> </div> <p>bunnei made a major breakthrough by using save games (dumped from a Switch Console) which enabled him to get in game much quicker, fix crashes, and improve rendering. By being able to expedite this process, the team was quickly able to get the first 3D rendering working in SMO - Mario&rsquo;s head in the title screen. From there, we were able to get in-game rendering working, although with very glitchy graphics and lots of variation depending on the kingdom.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_1_hu0d5d68e334806a93b9b89475e2259784_884757_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (In-game)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_2_hu157ff6500a8d8169b83f7cc4352dd23b_1784759_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (In-game)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (In-game)</p> <p>bunnei and <a href="https://github.com/khang06">khang06</a> implemented various render targets and texture formats necessary to get it booting. bunnei implemented the <code>XMAD</code> shader instruction, improved handling of the <code>KIL</code> shader instruction, improved handling of unknown vertex attributes in shaders, added more accurate floats for shaders, fixed the constbuffer size, added a few vertex attribute types, and stubbed the <code>AM</code> HLE service functions.</p> <p>Subv implemented the <code>SSY</code> and <code>SYNC</code> shader instructions, implemented alternative blending factors, and improved handling of invalid or unset vertex attributes. <code>SSY</code> and <code>SYNC</code> are instructions for control flow in the shaders. <code>SSY</code> tells the shader execution unit where to jump when a <code>SYNC</code> is executed.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./smo_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_4_hudaff7400175795e082b4a3adbcf531fa_1784912_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (In-game)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo_5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_5_huad37b36f56a8239805faa49d51514e57_1488652_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (In-game)"></a> </div> <div class="column is-bottom-paddingless"> <a href="./smo_6.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/smo_6_hu3f01b51ceb9335a775f7003df3e0ba32_1551218_800x0_resize_q90_bgffffff_box_3.jpg" alt="Super Mario Odyssey (In-game)"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Super Mario Odyssey (In-game)</p> <p>Currently SMO goes in game and the menus are running at full speed. However, in-game speeds can vary based on what&rsquo;s in view and your PC&rsquo;s hardware specifications. It is very glitchy, but you <em><strong>can</strong></em> play it. Audio output works well when at full speed. Using a save game helps a lot. There are random softlocks when transitioning to new areas; therefore, a play-through is not possible.</p> <h2 id="breath-of-the-wild">Breath of the Wild</h2> <p>The Legend of Zelda: Breath of the Wild, is a particularly interesting and exciting game to emulate in yuzu. While you can already play this game on cemu using Wii U emulation, we think its important to also have an open source alternative. Furthermore, BotW is a very graphically complicated game to emulate, so it&rsquo;s exciting to use it as an opportunity to improve our rendering.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/botw_hu2a3e8cf4bec5af355d6870e0c37ed408_1661878_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/botw_1_hu9fa8156d33ee75f0cadfeda5cf516a21_56276_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild</p> <p>Random crashing was one of the main issues we faced while trying to get this game working. Upon debugging, we found out that there were a few issues with threading in the kernel. For example, there were a bunch of race conditions when running in multi-core mode, our core timing was inaccurate for multiple cores, and there was a chance of threads being duplicated.</p> <p>Subv fixed these issues by removing most of the race conditions, using approximated amount of ticks when advancing core timing, and added more validation asserts to make sure the threads weren&rsquo;t being duplicated. Before the changes, the four cores incremented the global <code>ticks</code> counter independently, which caused it to be approximately 4 times more than what it should have been.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./botw_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/botw_2_hu6f8d8a6892efcfee41f86a52a907fcc6_1773621_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild"></a> </div> <div class="column is-bottom-paddingless"> <a href="./botw_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/botw_3_hub07aecd06575126248db65f205bc9320_166237_800x0_resize_q90_bgffffff_box_3.jpg" alt="The Legend of Zelda: Breath of the Wild"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">The Legend of Zelda: Breath of the Wild</p> <p>This made games think that the timing was malfunctioning. The reason for this was that the ticks counter was not thread-safe and we were incrementing it more than we should have. This was fixed by amortizing the tick increases by dividing each increment by the number of cores (4). This is not entirely accurate, as not all cores are active all the time, but it should be better than before.</p> <p>bunnei implemented a few necessary render targets, texture formats, vertex attribute types, and some primitive topologies. Currently, BotW goes in-game but has massively broken graphics. The map, items, 3D models of Divine Beasts, and Hyrule Castle are properly displayed though.</p> <h1 id="conclusion">Conclusion</h1> <p>Finally, we would like to thank all of our valuable <a href="https://github.com/yuzu-emu/yuzu/graphs/contributors?from=2018-07-20&amp;to=2018-08-31&amp;type=c">contributors</a> who have worked hard to improve yuzu. yuzu needs contributors like them to become the best it can be. We would also love to thank our generous <a href="https://www.patreon.com/yuzuteam">patrons</a> for supporting our efforts in this project.</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./kamiko.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/kamiko_hub87041fb59505cc4572d5f311142347d_140993_800x0_resize_q90_bgffffff_box_3.jpg" alt="Kamiko"></a> </div> <div class="column is-bottom-paddingless"> <a href="./kamiko_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/kamiko_1_huf116936f6fb316503a7ff625082ef97a_88176_800x0_resize_q90_bgffffff_box_3.jpg" alt="Kamiko"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Kamiko</p> <div class="columns is-img-preview is-bottom-marginless"> <div class="column is-bottom-paddingless"> <a href="./soldam.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/soldam_hu4533aebacf569c0ba8706bed5ad4c4ef_594991_800x0_resize_q90_bgffffff_box_3.jpg" alt="Soldam"></a> </div> <div class="column is-bottom-paddingless"> <a href="./soldam_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/soldam_1_hua2c918d9e4f371fceea837b8e8b7a512_401795_800x0_resize_q90_bgffffff_box_3.jpg" alt="Soldam"></a> </div> </div> <p class="has-text-centered is-italic has-text-grey-light">Soldam</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./mta.png" title="Mario Tennis Aces"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/mta_hued9933d5b2d2adb29e0d719d60a30989_2446161_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Mario Tennis Aces"></a> <p class="has-text-centered is-italic has-text-grey-light">Mario Tennis Aces</p> </div> <div class="column has-text-centered"> <a href="./kirby.png" title="Kirby Star Allies"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/kirby_hu2c4cdcbc1ad4cad398a4d9e80f02e71d_1111570_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Kirby Star Allies"></a> <p class="has-text-centered is-italic has-text-grey-light">Kirby Star Allies</p> </div> <div class="column has-text-centered"> <a href="./splatoon2.png" title="Splatoon 2"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/splatoon2_hubfce7b09794fe94120a0acc1c6a8024a_878147_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Splatoon 2"></a> <p class="has-text-centered is-italic has-text-grey-light">Splatoon 2</p> </div> <div class="column has-text-centered"> <a href="./hwknight.png" title="Hollow Knight"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p3/hwknight_huef49646c552feb3d1e41a57ebaee2ebc_763074_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Hollow Knight"></a> <p class="has-text-centered is-italic has-text-grey-light">Hollow Knight</p> </div> </div> <article class="message"> <div class="message-header is-dropdown"> <p>Note</p> <span class="icon"> <i class="fas fa-lg fa-arrow-circle-down"></i> </span> </div> <div class="message-body is-dropdown-target"> <p>All these screenshots have been taken in handheld mode of yuzu, using a PC with the following specs:</p> <ul> <li>CPU - Intel i3 6100</li> <li>GPU - Nvidia GTX 750ti</li> <li>RAM - 12 GB DDR3</li> </ul> </div> </article> <p>  <h4 style="text-align:center;"> <b>Please consider supporting us on <a href="https://www.patreon.com/yuzuteam">Patreon</a>!<br> If you would like to contribute to this project, check out our <a href="https://github.com/yuzu-emu/yuzu">GitHub</a>!</b> </h4> </p> Progress Report 2018 Part 2 https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/ Sat, 21 Jul 2018 20:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/ <p>We bring you part 2 of the extensive coverage on yuzu&rsquo;s tremendous progress. So buckle up for an exciting ride, cause its gonna blow your mind!  </p> <h5 style="text-align: center;"> ***Haven't read the first part yet? Read it [here](https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1)*** </h5> <p>We bring you part 2 of the extensive coverage on yuzu&rsquo;s tremendous progress. So buckle up for an exciting ride, cause its gonna blow your mind!  </p> <h5 style="text-align: center;"> ***Haven't read the first part yet? Read it [here](https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1)*** </h5> <h2 id="general-improvements">General Improvements</h2> <p>Software development best practices dictate that one should reuse code whenever possible. In line with this rule, yuzu began as a fork of the Citra code base with the core emulation code stripped out. This allows yuzu to focus on the core switch emulation while still having a very functional user interface, but after some time, the code for the user interface will slowly start to diverge. Several people chipped in to bringing the improvements over from Citra, most notably <a href="https://github.com/lioncash">Lioncash</a>, who over a period of time, has made many number of changes to bring yuzu up to date. We also ported over some of Citra&rsquo;s recent features like the new fmtlib-based logging backend (thanks to <a href="https://github.com/jroweboy">jroweboy</a> &amp; <a href="https://github.com/daniellimws">daniellimws</a> ), &lsquo;About&rsquo; dialog, full-screen rendering support, and themes support.</p> <p>We have also implemented features like:</p> <ul> <li>Added decrypted NCA support.</li> <li>OpenGL extensions support - checking, to ensure system requirements are met.</li> <li>64-bit games - checking, to ensure unsupported 32-bit games aren&rsquo;t launched.</li> <li>Switch-specific <em><strong>Docked mode</strong></em> configuration setting.</li> <li>Improved FPS counter.</li> <li>And many more.</li> </ul> <p>All of these improvements were only possible because of the efforts of many contributors.</p> <h2 id="cpu-emulation">CPU emulation</h2> <p>The Nintendo Switch is powered by a custom Nvidia Tegra SoC. For the uninitiated, a SoC (system-on-chip) integrates components like CPU, GPU, memory, input/output ports, storage, etc., on a single chip. The Switch&rsquo;s SoC (Nvidia ODNX02-A2), is a Tegra X1 chip, has 4 ARM Cortex-A57 CPU cores and 4 ARM Cortex-A53 CPU cores. The CPU is based on the ARM architecture, which has already been well documented. We first used <a href="http://www.unicorn-engine.org/">Unicorn</a> for the CPU emulation. However Unicorn is meant to assist developers that are debugging code, and isn&rsquo;t capable of running games at an acceptable framerate. Truth be told, <a href="https://github.com/lioncash">Lioncash</a> even back-ported relevant changes to Unicorn to make AArch64 emulation more complete. Our version of Unicorn (QEMU 2.12.50) is miles ahead of actual mainline Unicorn (QEMU 2.2.1).</p> <p>No one, dev and user alike, wants their emulator to be slow. So our talented developers <a href="https://github.com/MerryMage">MerryMage</a> and Lioncash are working tirelessly to bring ARMv8 support to <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a>, the dynamic recompiler that Merry wrote for Citra. Dynarmic was designed from the beginning to be reusable for many different ARM CPUs, so when we needed a fast and stable recompiler, we already knew what we would use. Thanks to their efforts Dynarmic now supports many ARMv8 instructions and we have shifted to using Dynarmic for CPU emulation. They are currently working to implement complete ARMv8 support in the near future.</p> <p>Dynarmic is generally fast, but it is still missing implementations of a few instructions. When dynarmic hits a missing instruction, it has to fallback to Unicorn, and falling back to using Unicorn is even slower than just using Unicorn directly! In order to fallback to Unicorn, we need to copy all the CPU state from Dynarmic to Unicorn, execute Unicorn, and then copy the state back to Dynarmic. These fallbacks are really slow. Once we implement all instructions in Dynarmic, we will no longer need these and our CPU emulation will be much faster than it is now. The most recent update to Dynarmic has vastly improved performance in almost all games, with games going up to 60FPS in some cases.</p> <h2 id="gpu-emulation">GPU emulation</h2> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./hmbrewgfx.png" title="Testing (yuzu)"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/hmbrewgfx_hud6cef65aee04137f6b0a00ed7a85416b_12931_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Testing (yuzu)"></a> <p class="has-text-centered is-italic has-text-grey-light">Testing (yuzu)</p> </div> <div class="column has-text-centered"> <a href="./hmbrewgfx_nx.jpg" title="Actual (Switch)"><img src="./hmbrewgfx_nx.jpg" alt="Actual (Switch)"></a> <p class="has-text-centered is-italic has-text-grey-light">Actual (Switch)</p> </div> </div> <p>We got to the point where commercial games were running on yuzu around February 2018. We could tell that they were almost ready to draw because they were submitting a command list to the emulated Nvidia GPU services. For a brief explanation, command lists are how games configure the GPU hardware and let the game know that it is ready to start rendering. Subv did a lot of work figuring out how the GPU register writes happen and on the communication protocols to get it working.</p> <p>As mentioned earlier, the Switch uses a Nvidia Tegra Soc which houses a GPU based on Maxwell architecture. Nvidia&rsquo;s hardware is proprietary and has no public documentation on how it works. Fortunately, Maxwell based GPUs were released 3 years ago and there are millions of devices using these GPUs. The people from Linux community and various other places tried to create open source drivers for these GPUs, despite it being proprietary hardware. They did a lot of leg work on finding out how these GPUs work. The <a href="https://nouveau.freedesktop.org/wiki/">Nouveau</a> project creates these open source Linux drivers for Nvidia GPUs and Tegra family of SoCs. Although Linux drivers for desktop/laptop GPUs aren&rsquo;t the same as the GPU driver for a console like Switch, which runs its own OS, there is a fair amount of overlap. There were also tools like <a href="https://github.com/envytools/envytools">envytools</a> and its submodule envydis (disassembler), which did a lot of research into shader decoding. envydis doesn&rsquo;t have any documentation about actual workings of each shader instruction, it just has the name, decoding and parameters. The work done by these projects helped us in bringing initial emulation of GPU.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sonic_glitch.png" title="Sonic Mania - Then"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sonic_glitch_hufdcb4fbaa3c1387a1190faa15bcb61e8_218242_817x0_resize_q90_bgffffff_box_3.jpg" alt="Sonic Mania - Then"></a> <p class="has-text-centered is-italic has-text-grey-light">Sonic Mania - Then</p> </div> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./sonicmania.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light">Sonic Mania - Now</p> </div> </div> <p>With the help of these projects we made good progress in GPU emulation and got games to submit drawing calls, not just configuring the hardware but actually writing to registers, indicating that they were ready to draw triangles on the screen. Even the simplest 2D games are no longer just 2D. As the Switch uses a modern GPU, there is no hardware for drawing 2D. So games instead make 2 triangles in the shape of a rectangle, and then render the current screen as a texture and blits it to the 2 triangles. This way, the game is still a flexible 2D game, but can take advantage of the fast 3D rendering capabilities that the GPU offers.</p> <p>The first game to show graphics was &ldquo;Puyo Puyo Tetris&rdquo; around late February - early March. The game calls this kind of generic <code>write</code> to drawing registers indicating that it was done rendering a batch of triangles. So we knew that we were drawing and we now had to figure out how to decode these triangles and render them on screen. At the end of the day, Switch uses a modern GPU and like most modern GPUs it relies on a programmable pipeline. A programmable pipeline gives game developers the power to control some of the graphics pipeline with a full featured programming language, and these programs that they write are called shaders. Game developers will write shaders in languages such as GLSL and HLSL, and the graphics driver will compile these into a GPU specific assembly language. Shaders are really useful to give game developers the ability to change how the geometry is drawn, and even how the pixels are colored on the screen.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./debug.png" title="Behind the scenes!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_debug_hu35bc4c3521104030c4ec846ff3b9eea3_695450_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Behind the scenes!"></a> <p class="has-text-centered is-italic has-text-grey-light">Behind the scenes!</p> </div> </div> <p>Because of how much shaders influence the whole scenes, GPU emulation development is not just a matter of handling triangles its also about handling shaders. We had to actually implement the shader programs to get more graphics output, meaning we needed to decompile each shader instruction. In case you were wondering, Nintendo Switch games are built with precompiled shader binaries, so we can&rsquo;t just run the original program. Instead we have to analyze the shader instructions and figure out novel ways to get convert it back to a high level shader code again. Figuring out what each shader instruction means wasn&rsquo;t an easy task, as this was all Nvidia&rsquo;s proprietary code. We worked a lot with <a href="https://github.com/gdkchan">gdkchan</a>, as he had made a bit of progress with this, and quickly learned how to decode GPU data based on nouveau and envytools. envytools and envydis (disassembler) did the reverse engineering of how shaders work in Maxwell based GPUs, so we already know most of the disassemblies of the instructions, but not always what they do.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./sonic_1.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sonic_1_hu980a03fb888b9996bd20865fe304049f_1412311_1024x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./sonic_2.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sonic_2_hu12e94855088089fc15ff1a7da97ea99a_231146_776x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./sonic_3.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sonic_3_hue6e99d43a3dc176ed1ed09c1cdc8b4bb_110688_781x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./sonic_4.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sonic_4_hu4c2eba2a952733c66639354d6241ac92_225245_736x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> <div class="column has-text-centered"> <a href="./sonic_5.png" title=""> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sonic_5_hu1bd682b2ba1f779a79c1ca7b2cb1cb99_425045_769x0_resize_q90_bgffffff_box_3.jpg" alt=""></a> </div> </div> <p>For actual shader implementation in yuzu, we decided to base it on a recent addition to Citra, a shader recompiler that converts the emulated 3DS shaders into GLSL so they can be run on the host GPU. Instead of running all these shader programs (which have to run for thousands of vertices) on the CPU, we translate these shaders into OpenGL GLSL and upload the program directly as is to GPU. This is better as GPUs are designed to run these programs in parallel for thousands of vertices, whereas CPUs are not. In Citra, we were running the fragment shaders on the GPU since at least 2015, but the vertex and geometry shaders were run on the CPU. The 3DS vertex and geometry shaders have some very hard to account for corner cases, and it took many years to make sure that our reverse engineering efforts were correct. That way we didn&rsquo;t have to waste effort working on something we couldn&rsquo;t be sure was possible. If you would like to read more about the feature in Citra, check out the blog post about it (<a href="https://citra-emu.org/entry/improvements-to-hardware-renderer/">here</a>).</p> <p>However this isn&rsquo;t an option in case of yuzu, as Switch&rsquo;s GPU is modern and way too powerful for doing this in software. Around April 2018, we were able to get enough of shader instructions implemented to get &ldquo;Puyo Puyo Tetris&rdquo; to show a bit of graphics. It wasn&rsquo;t much, just rendered <code>SEGA logo</code> and <code>Tetris logo</code>, and pretty much hung after that. Furthermore, we were able to get a few other simple 2D games like &ldquo;Cave Story&rdquo; and &ldquo;The Binding of Issac&rdquo; booting as well.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./splatoon2.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light">Splatoon 2 - Then</p> </div> <div class="column has-text-centered"> <a href="./splatoon2_work.png" title="Splatoon 2 - Now"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/splatoon2_work_hu05c9b51f67062ef8cc5110b8c9a835c2_363560_823x0_resize_q90_bgffffff_box_3.jpg" alt="Splatoon 2 - Now"></a> <p class="has-text-centered is-italic has-text-grey-light">Splatoon 2 - Now</p> </div> </div> <p>Another new feature which we implemented was shader <code>constbuffer</code> support by Subv. We have shader programs that we want to reuse for a bunch of different triangles for features like the UI or 3D models. It isn&rsquo;t efficient to have individual shaders for every single thing, instead we can have a couple of shader programs that can be reused for everything. So, shader <code>constbuffer</code> support is the equivalent of OpenGL <code>uniform</code> and <code>uniform buffer objects (UBO)</code>. Uniforms in general are a way to provide constant data to shaders and can also be used to reconfigure the shader as well.</p> <p>Initial rendering support and blending support were done by bunnei. Blending is used for alpha transparency - translating Switch GPU register writes to OpenGL calls. It fixed a bug in &ldquo;Puyo Puyo Tetris&rdquo;, where the <code>Saving...</code> icon in the top left corner had a weird box around it. Initial texture support was done by Subv and mainly involved reading a texture from memory, decoding it, and uploading it to OpenGL.</p> <p>Coming to rasterizer cache, its computationally expensive to upload a texture from the emulated Switch memory to the host GPU every time it&rsquo;s used. The texture will need to be decoded and unswizzled before its uploaded, and then the memory will need to be copied from the CPU RAM into the GPU RAM. It&rsquo;s much more efficient to just keep texture in the GPU memory, similar to how it works on hardware with normal PC games, but is a little bit trickier for emulation. This is because we don&rsquo;t know when the game might change the texture or modify it. bunnei did most of the work to cache these textures, so when a texture is uploaded to OpenGL it is saved in GPU memory and we keep track of it. When the CPU or our emulated Switch kernel reads or writes to the memory address that the texture was uploaded to, we check to see what we need to do, and reload the texture only if necessary. This also applies to framebuffers because in some cases, games can use them as textures. If this caching wasn&rsquo;t existent, we&rsquo;d essentially have to upload every texture to OpenGL memory (host GPU space) on every draw, copy the final framebuffer back to emulated Switch memory (CPU space) so that the game could potentially use it for framebuffer.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./SMO_astc.png" title="Testing Super Mario Odyssey"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_astc_huea4c317be2a84e48a81f8fc5c6a24133_22614_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Testing Super Mario Odyssey"></a> <p class="has-text-centered is-italic has-text-grey-light">Testing Super Mario Odyssey</p> </div> <div class="column has-text-centered"> <a href="./SMO.png" title="Inverted render"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_hu71e63b6275b517287ad472c3566d69e8_506852_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Inverted render"></a> <p class="has-text-centered is-italic has-text-grey-light">Inverted render</p> </div> <div class="column has-text-centered"> <a href="./SMO_2.png" title="Inverted render"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_2_hu0e1690a64cb2977d3a327e994902f2a6_452071_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Inverted render"></a> <p class="has-text-centered is-italic has-text-grey-light">Inverted render</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./SMO_debug.png" title="Debugging"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_debug_hu35bc4c3521104030c4ec846ff3b9eea3_695450_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Debugging"></a> <p class="has-text-centered is-italic has-text-grey-light">Debugging</p> </div> <div class="column has-text-centered"> <a href="./SMO_work.png" title=" Proper render"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_work_hue73d60864b60e406a615333fc6b4f14e_971943_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Proper render"></a> <p class="has-text-centered is-italic has-text-grey-light"> Proper render</p> </div> <div class="column has-text-centered"> <a href="./SMO_2_work.png" title=" Proper render"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/SMO_2_work_hub3c0d23a4d57e4661157b2317266e475_1078903_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Proper render"></a> <p class="has-text-centered is-italic has-text-grey-light"> Proper render</p> </div> </div> <p>We had a couple of fixes to our rasterizer cache mainly because it was based on Citra&rsquo;s rasterizer cache. Because the compressed texture formats that the 3DS uses are not commonly supported by desktop GPUs, Citra&rsquo;s rasterizer cache decodes any compressed textures before uploading and caching them. But since the Switch GPU supports many of the same texture formats that desktop OpenGL does, we sped things up by uploading them without decoding them. At the start, this support was just hacked into Citra&rsquo;s cache, which didn&rsquo;t end up working correctly all the time. One example was the squid texture in &ldquo;Splatoon 2&rdquo;, which was identified and fixed by Subv. We also implemented texture color swizzling, a way to swap color components, which is used by &ldquo;Splatoon 2&rdquo; to swap colors for intro background texture. So, before we implemented this the colors were all wrong. We fixed YUV2 video playback in our shader support, which fixed the previously busted &ldquo;Sonic Mania&rdquo; intro. We had to implement a field parameter called component masks in <code>TEX/TEXS</code> shader instructions, to properly decode <code>YUV2</code> videos. We also implemented texture wrap modes, which gives the ability to specify whether a texture on a triangle is mirrored or repeating etc.</p> <p>There are lots of other things already implemented and many more that have to be implemented. As the Switch&rsquo;s GPU is quite advanced, we have dozens of texture formats, vertex formats, lots of registers, different configuration modes, shader instructions that need to be implemented.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./onepiece.png" title="One Piece - Then"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/onepiece_huaf772a61919fe733bfe426286683d5ac_894607_1024x0_resize_q90_bgffffff_box_3.jpg" alt="One Piece - Then"></a> <p class="has-text-centered is-italic has-text-grey-light">One Piece - Then</p> </div> <div class="column has-text-centered"> <a href="./onepiece_work.png" title="One Piece - Now"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/onepiece_work_hu0d817ea96862751b968ab112fa0f99b0_2359158_1024x0_resize_q90_bgffffff_box_3.jpg" alt="One Piece - Now"></a> <p class="has-text-centered is-italic has-text-grey-light">One Piece - Now</p> </div> <div class="column has-text-centered"> <a href="./steam_world.png" title="Steam World Dig 2"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/steam_world_hu29e93ea3b2aeac1cdf73e14df87e91d6_617522_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Steam World Dig 2"></a> <p class="has-text-centered is-italic has-text-grey-light">Steam World Dig 2</p> </div> </div> <p>Apart from the above mentioned stuff, there have been many more modifications made to yuzu&rsquo;s GPU HLE (high level emulation). These bug fixes or modifications were done on a per-game experimentation basis and as we progress further we will continue to fix our implementations and improve the accuracy of emulation in yuzu. All of the progress we have made until now is thanks to the efforts of yuzu&rsquo;s contributors and the good people from Switch hacking communities.</p> <h2 id="virtual-file-system-vfs-by-darklordzachhttpsgithubcomdarklordzach-herehttpsgithubcomyuzu-emuyuzupull676">Virtual File System (VFS) by <a href="https://github.com/DarkLordZach">DarkLordZach</a> (<a href="https://github.com/yuzu-emu/yuzu/pull/676">here</a>)</h2> <p>A Virtual File System (VFS) is an abstraction layer which allows us to hide the details of where the actual files are stored. The purpose of a VFS is to enable the emulated Switch file system to read and write to many different types of backends, without changing anything in the emulated FS code. In layman&rsquo;s terms, the game will still think its reading and writing to a file on the Switch, but in reality it could be reading from a zip file, or from a custom mod that the user adds. This makes further support for Updates, DLC, new formats, encryption, etc., a little bit easier to implement. <a href="https://github.com/DarkLordZach">DarkLordZach</a> single-handedly worked on VFS for a couple of weeks and successfully implemented it.</p> <h2 id="touch-screen-support-by-darklordzachhttpsgithubcomdarklordzach-herehttpsgithubcomyuzu-emuyuzupull683">Touch-Screen Support by <a href="https://github.com/DarkLordZach">DarkLordZach</a> (<a href="https://github.com/yuzu-emu/yuzu/pull/683">here</a>)</h2> <p>DarkLordZach has been working very actively on various bug fixes, features and has also been lending a hand in testing games too. His latest contribution comes in the form of touch-screen support for yuzu. With this feature, yuzu now emulates mouse clicks to touch inputs and if you happen to have a physical touch screen, that can be used as a input device too.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./12switch.png" title="1-2-Switch"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/12switch_hu5943fcc48ef58a8feeaba4fa91573cc2_1561507_1024x0_resize_q90_bgffffff_box_3.jpg" alt="1-2-Switch"></a> <p class="has-text-centered is-italic has-text-grey-light">1-2-Switch</p> </div> <div class="column has-text-centered"> <a href="./arms.png" title="ARMS"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/arms_hu7a0fddefc8dcb12ec377c9f8e7f63a72_48505_1024x0_resize_q90_bgffffff_box_3.jpg" alt="ARMS"></a> <p class="has-text-centered is-italic has-text-grey-light">ARMS</p> </div> <div class="column has-text-centered"> <a href="./celeste.png" title="Celeste"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/celeste_hu311a023d6fcc022eecfdaba64af14289_1339807_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Celeste"></a> <p class="has-text-centered is-italic has-text-grey-light">Celeste</p> </div> <div class="column has-text-centered"> <a href="./doom.png" title=" Doom"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/doom_hu126a98f7186d74794b810ff434fde879_1040395_1024x0_resize_q90_bgffffff_box_3.jpg" alt=" Doom"></a> <p class="has-text-centered is-italic has-text-grey-light"> Doom</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./farming.png" title="Farming Simulator"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/farming_hu448fa3cba308d87914dc5da254770030_1967677_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Farming Simulator"></a> <p class="has-text-centered is-italic has-text-grey-light">Farming Simulator</p> </div> <div class="column has-text-centered"> <a href="./Lildew.png" title="Ittle Dew"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/Lildew_hu3a7c36d21e5e3fa52ff16079a1fc20c6_237144_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Ittle Dew"></a> <p class="has-text-centered is-italic has-text-grey-light">Ittle Dew</p> </div> <div class="column has-text-centered"> <a href="./minecraft.png" title="Minecraft Story Mode"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/minecraft_hu27e10c8c707ff1f2b36000df43eb5767_1507903_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Minecraft Story Mode"></a> <p class="has-text-centered is-italic has-text-grey-light">Minecraft Story Mode</p> </div> <div class="column has-text-centered"> <a href="./picross.png" title="Picross"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/picross_hue3a288f6a70592db8ac9e207f4dfdd87_422434_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Picross"></a> <p class="has-text-centered is-italic has-text-grey-light">Picross</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./minecraft.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light">Our first 3D rendered game - Minecraft</p> </div> </div> <h2 id="miscellaneous">Miscellaneous</h2> <p>Apart from these improvements, we have had multiple PRs which fixed bugs and deadlocks in various games. We got graphics output in Super Mario Odyssey, fixed saves related issues, launched many new games to the title screen, booted into few networked dependent games like Doom, implemented few SVCs and shader instructions, fixed a major performance regression with controller support, optimized logging system and did many more optimizations. We thank all the contributors for their valuable contributions and applaud their efforts.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./seiken.png" title="Seiken Densetsu Collection"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/seiken_huee7cb9958d903dc908fef7b449c3d000_2067867_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Seiken Densetsu Collection"></a> <p class="has-text-centered is-italic has-text-grey-light">Seiken Densetsu Collection</p> </div> <div class="column has-text-centered"> <a href="./setsuna.png" title="I am Setsuna"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/setsuna_hu87643c50d4857a160ba2f8d5d65e63ab_38452_1024x0_resize_q90_bgffffff_box_3.jpg" alt="I am Setsuna"></a> <p class="has-text-centered is-italic has-text-grey-light">I am Setsuna</p> </div> <div class="column has-text-centered"> <a href="./sm&#43;.png" title="Sonic Mania Plus"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/sm&#43;_hu9ee7a4d5adeda0f541e9c5d3e1a17b13_594606_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Sonic Mania Plus"></a> <p class="has-text-centered is-italic has-text-grey-light">Sonic Mania Plus</p> </div> <div class="column has-text-centered"> <a href="./snipper.png" title="Snipperclips Plus"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2/snipper_hu76b41e8472127447aba499d79b3f7fbd_738517_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Snipperclips Plus"></a> <p class="has-text-centered is-italic has-text-grey-light">Snipperclips Plus</p> </div> </div> <h3 style="text-align: center;"> <b><a href="https://github.com/yuzu-emu/yuzu/">Contributions are always welcome !</a></b> </h3> Progress Report 2018 Part 1 https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/ Sat, 14 Jul 2018 08:00:00 +0530 CaptV0rt3x https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/ <p>It&rsquo;s been a bumpy ride. We have had lots of stuff happen to yuzu and we are excited to share that with you. Let&rsquo;s get started!</p> <p>It&rsquo;s been a bumpy ride. We have had lots of stuff happen to yuzu and we are excited to share that with you. Let&rsquo;s get started!</p> <p>After months of research and countless hours of coding, the developers who gave you <a href="https://citra-emu.org">Citra</a>, an emulator for the Nintendo 3DS, now bring to you yuzu – an experimental emulator for the Nintendo Switch. yuzu is based off of Citra&rsquo;s code, with many changes tailored towards the Switch made. It gives me great pleasure to welcome you all into the world of yuzu.</p> <h2 id="backstory">Backstory</h2> <p>The Switch is the 7<sup>th</sup> major video game console from Nintendo. As the Wii U had struggled to gain external support, leaving it with a weak software library, Nintendo opted to use more standard electronic components to make development for the console easier.</p> <p><a href="https://github.com/bunnei">bunnei</a>, the lead developer of Citra, saw that the Switch hacking scene was very active and that there were signs of the Switch&rsquo;s operating system, called <em>Horizon</em>, being based on the 3DS&rsquo;s operating system. The Switch hacking communities (<a href="https://reswitched.tech/">ReSwitched</a> and <a href="http://switchbrew.org">Switchbrew</a>) had many people working on hacking and documenting the system. Being <em>a huge Nintendo fan</em>, bunnei was very excited at the prospect of an emulator for Switch. Using the available documentation, he worked on yuzu privately for a few months before other Citra developers joined him. They made some progress and finally went public on 14 January, 2018.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline=""> <source src="./homebrew.mp4" type="video/mp4"> Your browser doesn't support mp4 video. :( </video> <p class="has-text-centered is-italic has-text-grey-light">Before (Colors are wrong)</p> </div> <div class="column has-text-centered"> <a href="./homebrew_work.jpg" title="After (fixed)"><img src="./homebrew_work.jpg" alt="After (fixed)"></a> <p class="has-text-centered is-italic has-text-grey-light">After (fixed)</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./homebrew_game.png" title="Very first homebrew on yuzu, Space Game !!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/homebrew_game_hud73a92ce8939123ca6ff643805fbc161_32171_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Very first homebrew on yuzu, Space Game !!"></a> <p class="has-text-centered is-italic has-text-grey-light">Very first homebrew on yuzu, Space Game !!</p> </div> </div> <h2 id="baby-steps">Baby Steps</h2> <p>yuzu shares the same common and core code, with much of the same OS (operating system) HLE, with Citra (as both OSs are similar). For the uninitiated, with HLE (high level emulation), parts of the OS are re-implemented in the emulator, which the emulated game can call directly. This contrasts with low-level emulation (LLE), where the hardware is emulated, and the real OS bits are run within the emulator. Initially, bunnei worked hard to get the Citra code base working for Switch emulation. He updated the core emulation and Citra&rsquo;s memory management to work with 64-bit addresses (as Citra emulates 32-bit apps), did lots of OS HLE, added a loader for the Switch games/homebrew, and integrated <a href="http://www.unicorn-engine.org/">Unicorn</a> into yuzu for CPU emulation. Unicorn was chosen at that time and not <a href="https://github.com/MerryMage/dynarmic">Dynarmic</a> (which is used in Citra) because the Switch has an ARMv8 CPU (64-bit) and dynarmic only had support for ARMv6 at that time. He got some basic SVC (Supervisor Call) implementation hooked up to begin booting some homebrew applications and very simple games. At this time, there was no graphical output yet.</p> <p>Later, <a href="https://github.com/Subv">Subv</a>, another Citra veteran, joined him and together they both got framebuffer rendering support for basic homebrew. It was at this point that yuzu was announced publicly and went open-source. As the project became open-source, many developers and reverse engineers joined the team and as of today, yuzu is able to run 12 games. This fast paced progress is a result of the highly active Switch hacking scene. When bunnei first started Citra (in 2014), the 3DS was already 3 years old, homebrew was barely starting to happen, and game dumps were still encrypted. Contrary to this, Switch has a much more active hacking scene, much earlier on in the console&rsquo;s life-cycle (few months). It is believed that, fueled by the successes with 3DS hacking, a lot of the same teams and people have started working on the Switch hacking as well.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./puyo_boot.png" title="First game rendering triangles (actually SEGA logo) !!"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/puyo_boot_hu192b623cac99dc7ca25c1e872bb3802c_40313_1024x0_resize_q90_bgffffff_box_3.jpg" alt="First game rendering triangles (actually SEGA logo) !!"></a> <p class="has-text-centered is-italic has-text-grey-light">First game rendering triangles (actually SEGA logo) !!</p> </div> </div> <h2 id="pit-crew--their-efforts-so-far">Pit Crew &amp; Their Efforts So Far</h2> <p><em><strong>Rivalry of scholars advances wisdom</strong></em>. This proverb is highly accurate in terms of emulators. The clash of knowledge between peers helps mutual growth. During its early days, Citra had a peer too, <a href="https://github.com/plutooo/3dmoo">3dmoo</a>. In the case of Switch emulation, we have <a href="https://github.com/gdkchan/Ryujinx">Ryujinx</a>. Our developers have worked with <a href="https://github.com/gdkchan">gdkchan</a> (the main developer of Ryujinx) on reverse engineering (RE), figuring out how games work, and how the Switch GPU works.</p> <p>Subv worked on initial framebuffer rendering support, and then went on to do lots of OS reverse engineering and bug fixes. Lately, bunnei and him have been working on GPU emulation. <a href="https://github.com/ogniK5377">ogniK</a> (from the <a href="https://reswitched.tech/">ReSwitched</a> team) also joined us and is one of our RE experts. He has done a lot of Switch OS RE, which helps us to get yuzu booting games further. He has contributed a lot, mostly in audio, kernel, and services.</p> <p><a href="https://github.com/shinyquagsire23">shinyquagsire</a>, another Citra developer, came forward and implemented user input and various other things. <a href="https://github.com/lioncash">Lioncash</a> and <a href="https://github.com/merrymage">MerryMage</a> worked tirelessly on adding ARMv8 support to dynarmic, and thanks to their efforts we are now using <a href="https://github.com/MerryMage/dynarmic">dynarmic</a> for CPU emulation. Apart from these people, there are more than a dozen contributors for yuzu who have worked on minor things. It&rsquo;s because of their invaluable efforts that yuzu now proudly boasts it&rsquo;s ability to boot several commercial games like ARMS, Splatoon 2, One Piece Unlimited Red Deluxe, Cave Story+, and many more. As of now, a few games are actually playable on yuzu – Binding of Isaac, Sonic Mania, Stardew Valley, etc.</p> <h2 id="reverse-engineering-re">Reverse Engineering (RE)</h2> <p>The RE process of yuzu is very similar to that of Citra. We collaborate with the hacking communities, for documenting the workings of Switch and do some RE ourselves as well. It&rsquo;s a mix of learning and implementing things ourselves, using community documentation to validate or guide our process. The fact that the Switch is based on off-the-shelf Tegra SoC does not necessarily make the process easier, because, similar to the PICA200 (3DS GPU), the Maxwell GPU architecture isn&rsquo;t publicly documented.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./setup.jpg" title="ogniK&#39;s janky RE setup"><img src="./setup.jpg" alt="ogniK&#39;s janky RE setup"></a> <p class="has-text-centered is-italic has-text-grey-light">ogniK&#39;s janky RE setup</p> </div> </div> <p>That said, there are more resources and non-Switch related projects (<a href="https://nouveau.freedesktop.org/wiki/">Nouveau</a>, <a href="https://github.com/envytools/envytools">envytools</a>, etc.) that we can use. Switch&rsquo;s GPU is many times more advanced/powerful than 3DS&rsquo;, and so are the challenges in its RE. RE on the OS HLE side of things has otherwise been the same and is moving at the same pace. We currently have a graphics renderer, based off of Citra&rsquo;s graphics renderer, which uses OpenGL 4.1.</p> <p>Mind you, yuzu is at a very young stage in its development. As such, any progress we make would be only possible if we have a proper direction. Right now, most of our development is being done in a trial-and-error manner. Simply put, we are working on making games boot and then we fix our implementations based on further RE and any other new found info.</p> <h2 id="os-emulation">OS emulation</h2> <p>The Switch&rsquo;s OS (operating system), called Horizon, is based on the 3DS&rsquo;s OS. This was a silver lining, as it meant that Citra&rsquo;s OS HLE code could be largely reused. A point to remember, is that both Citra and yuzu are high level emulators. In both of these, we are trying to implement the software rather than the hardware of the consoles.</p> <p>As an emulator, the first necessity in yuzu would be to load the Switch game dumps. So, bunnei started working on a loader and file system service for yuzu. Citra&rsquo;s loader and file system frameworks were reused and modified heavily to support Switch game dump files (<a href="https://github.com/yuzu-emu/yuzu/pull/123">here</a>). Further fixes and improvements to the loader were done by <a href="https://github.com/ogniK5377">ogniK</a>, <a href="https://github.com/Rozelette">Rozelette</a>, <a href="https://github.com/gdkchan">gdkchan</a>, and <a href="https://github.com/shinyquagsire23">shinyquagsire</a>.</p> <p>Next, we would need a way for games to read or load save data. Subv believed that the save data in the Switch has a similar behavior as the save data in the 3DS. He implemented the file system and save data behaviors, which allowed games to read and write files to the save data directory (<a href="https://github.com/yuzu-emu/yuzu/pull/216">here</a>). This implementation allowed us to boot further in &ldquo;Puyo Puyo Tetris&rdquo; and &ldquo;Cave Story&rdquo;.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./cavestory_boot.png" title="First boot - Cave Story&#43;"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/cavestory_boot_hu25b0e5e4e0e375cd089327abb2a0b6c1_57129_1024x0_resize_q90_bgffffff_box_3.jpg" alt="First boot - Cave Story&#43;"></a> <p class="has-text-centered is-italic has-text-grey-light">First boot - Cave Story&#43;</p> </div> <div class="column has-text-centered"> <a href="./cavestory_work.png" title="Now - Cave Story&#43;"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/cavestory_work_huc9bc30a6d1dacaed14ffb35c54d1b581_169539_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now - Cave Story&#43;"></a> <p class="has-text-centered is-italic has-text-grey-light">Now - Cave Story&#43;</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./tetris.png" title="First boot - Puyo Puyo Tetris"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/tetris_hua3aec80e7212fcea0f3cd4d7bb01dd8b_81707_1024x0_resize_q90_bgffffff_box_3.jpg" alt="First boot - Puyo Puyo Tetris"></a> <p class="has-text-centered is-italic has-text-grey-light">First boot - Puyo Puyo Tetris</p> </div> <div class="column has-text-centered"> <a href="./tetris_work.png" title="Now - Puyo Puyo Tetris"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/tetris_work_hu9e28229626aa1ab8a5f20dba7977b4a4_737250_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now - Puyo Puyo Tetris"></a> <p class="has-text-centered is-italic has-text-grey-light">Now - Puyo Puyo Tetris</p> </div> </div> <p>Often, the best way to debug or RE any functionality is to use homebrew. For the uninitiated, homebrew is a popular term used for applications that are created and executed on a video game console by hackers, programmers, developers, and consumers. The good folks at Switchbrew created <code>libnx</code>, a userland library to write homebrew apps for the Nintendo Switch. To support homebrew apps, written using libnx, our developers bunnei and shinyquagsire made various fixes and finally yuzu now supports loading libnx apps.</p> <p>The Switch&rsquo;s OS uses a lot of &lsquo;services&rsquo; to provide the games with functionality which allows it to do things like getting user input, audio output, graphics output, etc. However since the Switch hasn&rsquo;t been completely reverse engineered, we still don&rsquo;t know how to implement some of these services. Currently, some service calls, which we are fairly confident can be ignored, are being stubbed. Stubbing means that these services return <code>ok</code> with no errors, so that the games think that the function succeeded and it can continue on without getting back any valid data. As the games boot further and further, we need to start intercepting these function calls and provide a more meaningful response.</p> <p>Switch IPC (Inter-process communication) is how the OS communicates between the various services running. This was much more robust and complicated than the 3DS&rsquo;s, for a lot of reasons. First of all, it does lot more validation on responses. This means that both our service HLEs or stubs need to have the responses be exactly what it expects with exactly right number of output parameters at right offsets, results have to be at right offsets, data needs to be at right offsets, and a couple of other magic fields need to be present.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./stardew.png" title="First boot - Stardew Valley"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/stardew_hu92fde1a6347d80cb0d587b3f2eecf314_95022_1024x0_resize_q90_bgffffff_box_3.jpg" alt="First boot - Stardew Valley"></a> <p class="has-text-centered is-italic has-text-grey-light">First boot - Stardew Valley</p> </div> <div class="column has-text-centered"> <a href="./stardew_2.png" title="in-game - bugs"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/stardew_2_hu2e893bd3ece27b75a616c39e1d1e9f8c_159751_1024x0_resize_q90_bgffffff_box_3.jpg" alt="in-game - bugs"></a> <p class="has-text-centered is-italic has-text-grey-light">in-game - bugs</p> </div> <div class="column has-text-centered"> <a href="./stardew_work.png" title="Now - Stardew Valley"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/stardew_work_huac633a0637f15cac843d04af9e7bce25_150225_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now - Stardew Valley"></a> <p class="has-text-centered is-italic has-text-grey-light">Now - Stardew Valley</p> </div> </div> <p>In addition to this, we have a couple of different command modes, a typical IPC request response, and something called a <em>Domain</em>. Once a IPC session is opened to a service, the game can use this command to turn that session into what&rsquo;s called a Domain. This is a more efficient way to do lots of service calls. Our implementations were mostly iterations of learning how the IPC worked and implementing it. After facing many issues and fixing them, we finally got things working. We then wrote a wrapper code around this, which allows us to implement service functions without needing intricate knowledge of how the IPC system works.</p> <p>A lot of our work is based on background research the ReSwitched team did with their Switch debug emulators, <a href="https://github.com/reswitched/CageTheUnicorn">CageTheUnicorn</a> (python) and <a href="https://github.com/reswitched/mephisto">Mephisto</a>(C-lang). These emulators were designed for debugging and they implemented the Switch IPC and did most of the work to figure that out. We thank the ReSwitched team for CageTheUnicorn and Mephisto, and a special thanks to <a href="https://github.com/daeken">daeken</a> and <a href="https://github.com/misson20000">misson20000</a>, for without their help with reverse engineering and bug fixing along the way, we wouldn&rsquo;t have gotten as far as we have.</p> <p>The Nvidia services configure the video driver to get the graphics output. Nintendo re-purposed the Android graphics stack and used it in the Switch for rendering. We had to implement this even to get homebrew applications to display graphics. The Switch is very different from older systems, where we could find a physical or virtual address of the framebuffer in memory and start writing to it to get quick output. Here, we actually have to configure the OS to create a render surface and we can start writing to it. Even the simplest homebrew had to implement this graphics layering for rendering. Subv did most of the work to get the initial framebuffer working.</p> <p>Coming to Kernel OS threading, scheduling, and synchronization fixes, most of the OS HLE for yuzu was ported from Citra&rsquo;s OS implementation. As the Switch RE progressed and we learned things, we made multiple fixes to yuzu&rsquo;s OS implementation. The Switch&rsquo;s scheduler is almost identical (if not identical) to the 3DS&rsquo;s. We had to make several changes to support Switch&rsquo;s different synchronization primitives but the rest if it (thus far) has been very similar and has used a similar SVC interface. Hence we&rsquo;ve reused Citra&rsquo;s code here as well.</p> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./1-2-switch.png" title="First boot - 1-2-Switch"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/1-2-switch_huee910661cd639ca6d195553f3ea5ee70_819094_1024x0_resize_q90_bgffffff_box_3.jpg" alt="First boot - 1-2-Switch"></a> <p class="has-text-centered is-italic has-text-grey-light">First boot - 1-2-Switch</p> </div> <div class="column has-text-centered"> <a href="./1-2-switch_jap.png" title="Wrong Language"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/1-2-switch_jap_hu4fbdabbd5d5b0472d1d5514c685372fc_1110216_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Wrong Language"></a> <p class="has-text-centered is-italic has-text-grey-light">Wrong Language</p> </div> <div class="column has-text-centered"> <a href="./1-2-switch_work.png" title="Now - 1-2-Switch"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/1-2-switch_work_hu6905c62dcbaf9f420bac3b04b5a0010f_2336745_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now - 1-2-Switch"></a> <p class="has-text-centered is-italic has-text-grey-light">Now - 1-2-Switch</p> </div> </div> <div class="columns is-img-preview"> <div class="column has-text-centered"> <a href="./boi_2.png" title="First boot - The Binding of Issac"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/boi_2_hu5b87409152cfda0d5d80f37f829b7e42_75496_1024x0_resize_q90_bgffffff_box_3.jpg" alt="First boot - The Binding of Issac"></a> <p class="has-text-centered is-italic has-text-grey-light">First boot - The Binding of Issac</p> </div> <div class="column has-text-centered"> <a href="./boi.png" title="in-game - first renders"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/boi_hud5431ae3818e2525f162ba61079b1070_648682_1024x0_resize_q90_bgffffff_box_3.jpg" alt="in-game - first renders"></a> <p class="has-text-centered is-italic has-text-grey-light">in-game - first renders</p> </div> <div class="column has-text-centered"> <a href="./boi_work.png" title="Now - The Binding of Issac"> <img src="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p1/boi_work_hu3898a91ef435a241a853d18f43e35134_272594_1024x0_resize_q90_bgffffff_box_3.jpg" alt="Now - The Binding of Issac"></a> <p class="has-text-centered is-italic has-text-grey-light">Now - The Binding of Issac</p> </div> </div> <p>As we now have some games booting, the next step along the line would be adding HID (user input support). <a href="https://github.com/shinyquagsire23">shinyquagsire</a> worked on getting initial HID support and made further fixes along the way. HID services maps some shared memory region to which the games can read to, get user input state and gamepad input writes to this. yuzu now supports handheld inputs with analog sticks and buttons. We still have a lot to implement in HID, like support for all 9 controllers, rumble, LEDs, layouts etc., and its going to take a bit of additional work to get it all implemented. As much of this has already been RE&rsquo;d, this is a great place for new developers to make contributions!</p> <p>Currently Audio HLE is in progress, but we do not support audio playback (<em>yet!</em>). <a href="https://github.com/ogniK5377">ogniK</a> did a lot of reverse engineering on the <code>AudRen</code> service (Audio renderer) which most games use for audio output. There is another service called <code>AudOut</code> service, which homebrew and a few games use for audio output. It&rsquo;s a much simpler service and the homebrew community figured this out. We haven&rsquo;t implemented this as not many games use this. ogniK did most of the work on <code>AudRen</code> service and he pretty much figured out how it works. This is a major breakthrough as most complicated games we have seen so far were getting stuck, either hanging or deadlocking because they were waiting for proper <code>AudRen</code> state to be set. ogniK&rsquo;s work on this helped us go further in a few other games.</p> <p>Apart from the work mentioned above, we have also had minor fixes which helped us boot further in games like Super Mario Odyssey, 1-2-Switch, and The Binding of Issac.</p> <p><em><strong>Check out the next part of this report <a href="https://yuzu-mirror.github.io/entry/yuzu-progress-report-2018-p2">here</a></strong></em></p> <h3 align="center"> <b><a href="https://github.com/yuzu-emu/yuzu/">Contributions are always welcome !</a></b> </h3> First games are running! https://yuzu-mirror.github.io/entry/first-games-are-running/ Sun, 15 Apr 2018 01:18:00 -0500 jmc47 https://yuzu-mirror.github.io/entry/first-games-are-running/ <p>A major milestone in yuzu has been reached, as it can now boot a handful of the Nintendo Switch&rsquo;s more primitive games. Don&rsquo;t believe us? Take a look!</p> <p>A major milestone in yuzu has been reached, as it can now boot a handful of the Nintendo Switch&rsquo;s more primitive games. Don&rsquo;t believe us? Take a look!</p> <div class="my-lg"> <div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"> <iframe src="https://www.youtube.com/embed/1VzyIHMTA2Q" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe> </div> </div> <p>These changes are now available in the latest <a href="https://yuzu-mirror.github.io/downloads/">yuzu canary builds</a>!</p> <p>Currently, only a few games are confirmed to boot, including:</p> <ul> <li>The Binding of Isaac: Afterbirth+</li> <li>Puyo Puyo Tetris</li> <li>Cave Story+</li> </ul> <p>While these <em>may</em> not be the Switch titles that emulation hobbyists are looking forward to digging into, the fact that games are starting to work shows that yuzu is heading in the right direction. That doesn&rsquo;t mean it wasn&rsquo;t a bumpy road to get here, though!</p> <h4 id="the-challenge-behind-booting-switch-games">The Challenge Behind Booting Switch Games</h4> <p>Getting to this point hasn&rsquo;t been easy, and has been a massive reverse-engineering challenge. Led by bunnei and Subv with contributions from ogniK and jroweboy the team slowly chipped away at stopping point after stopping point to finally get us to this milestone. Special thanks to gdkchan and Ryujinx, as without collaboration, this wouldn&rsquo;t have been possible.</p> <p>Also, huge thanks to Lioncash and MerryMage, who have been tirelessly working on the ARMv8 JIT that yuzu uses! Without it, we&rsquo;d still be in the dark ages of interpreted CPU emulation.</p> <p>While yuzu is built on top of Citra&rsquo;s kernel infrastructure, a lot of modification had to be done in order to move things over to the Switch&rsquo;s services. But the main issues all had to do with the Switch&rsquo;s GPU.</p> <p>Because it&rsquo;s a NVIDIA product, some information was able to be gleamed by sifting through the <a href="https://en.wikipedia.org/wiki/Nouveau_(software)">Nouveau source</a>. Some of the more particularly difficult stopping points were Kernel Synchronization Primitives and Shader Decompilation, but there were many more smaller bumps along the way. On top of that, the rest of the emulator had to be brought up to snuff in order to get games to the point where they would boot.</p> <p>In the end, this is a small first step toward proper emulation of Nintendo&rsquo;s exciting console/handheld hybrid. None of the games booting are especially stable and emulation is in a very, very early state.</p> <h4 id="what-does-yuzu-require">What does yuzu Require?</h4> <p>Right now, most games won&rsquo;t run, and the games that do run will run incredibly slow and only get so far before encountering issues. We recommend you have as fast of a processor as possible <em>and</em> a GPU that supports OpenGL 4.3 or newer.</p> <div class="columns mt-md"> <div class="column"> <figure class="image"> <img src="./img1.png"> </figure> </div> <div class="column"> <figure class="image"> <img src="./img2.png"> </figure> </div> </div> <div class="columns"> <div class="column"> <figure class="image"> <img src="./img3.png"> </figure> </div> <div class="column"> <figure class="image"> <img src="./img4.png"> </figure> </div> </div> <h4 id="whats-next">What&rsquo;s next?</h4> <p>Currently, yuzu has two major development fronts that are ongoing: First, we are trying to get more games booting further, to the point that they are trying to render frames, and second, to try to emulate the Nvidia Maxwell GPU. Even for simple games such as these, Maxwell emulation has shown to be quite challenging - and we suspect that this will be our biggest focus in the coming months. As always, we welcome newcomers to join our team and help us toward these goals! If you&rsquo;re interested in contributing, please checkout our <a href="https://github.com/yuzu-emu/yuzu/blob/master/CONTRIBUTING.md">Contributing Guide</a> or <a href="https://discord.gg/u77vRWY">join us on Discord</a>.</p>