Welcome to July’s Progress Report! Firstly we would like to apologise for the delay in publishing this report. RPCS3’s progress reports are solely written by volunteers and a few of our regular writers could not contribute to this report due to personal commitments. If you hate seeing RPCS3’s reports get delayed and would like to contribute to them, please apply here.
July was an absolute whirlwind of development that saw 60 pull requests merged from both our regular developers as well new contributors. That’s almost 2 pull requests merged everyday! This month, Nekotekina focused on improving TSX performance while kd-11 implemented a second round of bug-fixes that improved multiple AAA titles. On the other hand, eladash ironed out new features to help games go beyond their existing framerate caps and GalCiv implemented microphone support to finally allow RPCS3 to better emulate SingStar and other similar titles. Ohh and let’s not forget the surprise progress made with Metal Gear Solid 4 as well! There’s a lot to cover, so let’s jump straight into it.
In addition to the following report, further details of Nekotekina and kd-11’s work during July and upcoming contributions can be found in their weekly reports on Patreon. This month’s Patreon reports are:
Table of Contents
For the compatibility list, it was another quiet month as testers were predominantly occupied with testing pull requests before they were merged. The Playable category remained the largest, while the Ingame category showed a small increase. A similar decrease can be seen in the Intro and Loadable categories, dropping the Loadable category to an all-time low of just 20 titles. Finally, the Nothing category doubled in size to 4 games, although it should be noted this was possibly due to an inaccurate report from a tester, which is to be corrected soon.
On Git statistics, there have been 7396 lines of code added and 3334 removed through 60 pull requests by 15 authors.
Major RPCS3 Improvements
The Gran Turismo series has recently been identified as a competent litmus test for RSX accuracy. kd-11 has frequently had to overhaul sections of code to properly render graphics in these titles as they are tied very intimately to PlayStation 3 hardware, making even the smallest of inaccuracies apparent. This month saw several pull requests come in attempting to fix various graphical corruption bugs and other oddities found in these games.
The first improvement came from CookiePLMonster, a prominent member of the emudev community, who tracked down the cause of headlights and taillights being incorrectly rendered blue in Gran Turismo HD Concept, an issue that was leftover from kd-11’s last set of GT fixes. This game was using the less common SET_BLEND_COLOR series of commands to render the taillights. Very few games use these, so RPCS3 was using RGBA for color decoding without realizing that this was incorrect, and that the colors are supposed to be decoded as BGRA. This swapping of red and blue channels caused the error in rendering.
On the same day, kd-11 opened a pull request, appropriately titled “GT Fixes 2”, as a follow up to his previous set of changes to correct the RSX behaviour late last year. Gran Turismo 6 in particular had some bizarre rainbow texture corruption caused by poor handling of non-linear textures, since these textures have 4 border texels that need to be decoded properly. Another element of this pull request was adding proper clamping to clip dimensions for framebuffer mappings, which solved the issue of blit requests being denied excessively.
Later in the month, kd-11 further improved the MSAA implementation in RPCS3, fixing a number of transparency bugs in games that used AA to handle transparent texture effects. After this, he focused on implementing other relevant AA methods, which in this case was Coverage Sample Anti-aliasing (CSAA). Gran Turismo 6 and Gran Turismo Academy used CSAA on foliage and would render broken graphics without the implementation of the same in the emulator. With CSAA now implemented, foliage was fixed in Gran Turismo 6, Gran Turismo Academy and also GTA V!
Finally, kd-11 implemented a viewport raster clip by combining viewport clip region with the scissor clip region. However, this caused regressions in some games because buffer clears were clipped to viewport. With some debugging, it was identified that the viewport only clips during rendering but not during clear operations. This was promptly fixed by not clipping scissor to viewport when doing buffer clears. These changes fixed the broken split screen rendering and out of bounds elements in games like Sly 3, Hotline Miami, Dragon Ball: Raging Blast, Initial D Extreme Stage and many others!
Microphone support (#5446)
Anyone who has been following our progress reports would be familiar with GalCiv’s journey to adding support for various peripherals in RPCS3. In the past few months, he’s expanded the cellPad implementation to add support for emulation of guitars, drums, DJ pads and Dance mats, and also implemented proper support for the DualShock 3 allowing the use of pressure sensitive buttons and motion controls in RPCS3. Now, he’s set his sights on the cellMic library that was used by the PlayStation 3 to accept audio from microphones. With a bit of debugging on how cellMic works on the PlayStation 3, GalCiv was able to easily implement a basic passthrough for audio input from any microphone recognised by the Operating System to the game. This was a straightforward approach that worked surprisingly well, allowing Karaoke Revolution, Guitar Hero 5 and many other titles to properly recognise audio input. In addition, users can now play all instruments in games like Rock Band, Rock Band 2 and all Rock Band track packs perfectly allowing these titles to be fully playable!
The final piece to the puzzle, vocal levels in Rock Band titles are now playable thanks to microphone support!
However, nothing is ever as simple as it seems and the same was the case with cellMic. While Rock Band showed great results, SingStar did not work with this approach. With a little debugging, it was evident that SingStar titles are coded to recognise only the SingStar-branded microphones and ignore audio input from any other microphone. After identifying the device ID for the SingStar dongle, GalCiv implemented an option to emulate the regular microphones connected as a SingStar microphone. This promptly addressed the issue and allowed the original SingStar to progress ingame! After this, certain users expressed their wish to use an actual SingStar microphone with the emulator as well. GalCiv implemented this option allowing users to connect an original SingStar dongle and use the same in RPCS3. In addition, support for using the original Rocksmith dongle has also been implemented.
This allowed multiple titles to progress ingame and adds yet another set of peripherals to RPCS3’s list of supported devices. However, users should note that these improvements only benefit titles that detect audio input using the cellMic library. Many titles from the SingStar series use cellUsbd, instead of cellMic, to directly communicate with the microphones. However, not one to leave a job unfinished, GalCiv is hard at work on implementing support for sys_usbd (lv2 syscalls used by cellUsbd). Once finalised, users will hopefully be able to use peripherals such as the Skylander Portal and SingStar microphones in many more titles!
For people interested in playing PlayStation 3 games at frame rates beyond their original targets, it’s time to rejoice! Thanks to some new features by eladash, it’s now possible to play a significant portion of the PlayStation 3 library at high framerates without altering any of the original game code.
The first of elad’s pull requests added the ability to configure the vertical blanking (vblank for short) frequency. On old CRT televisions vblank was a period in which the television would not be drawing anything onto the screen. This was necessary for electron beam to return from the bottom of the screen back to the top of the screen so that it could get ready to draw the next image to the screen. With older game consoles such as the Atari 2600 or the NES the beginning of the vblank period would generate a vblank interrupt which would signal that the current frame has finished. On these old consoles, the vblank interrupt was often the only way to tell that time has passed. As such, game speed was closely tied to framerate for games targeting these older machines.
Fast forward to the PlayStation 3 era, and game consoles all include high resolution clocks that can be used to tell the time with great accuracy. Many game developers opted to tie game speed to the passage of real time, which allows their games to keep correct game speed even when the framerate is unstable. However, most developers stuck to what they knew best and opted to tie the max framerate to the vblank frequency. For these games, simply changing the vblank frequency will get you correct game speed at higher framerate with no extra effort required!
Sadly, not all games can have their framerate unlocked in this way while maintaining correct game speed. Some games may have their game speed tied to framerate, while others may use another method to cap their framerate. However, even in such cases, the new vblank option can make the process of achieving higher framerates at correct game speed easier since the people interested in making FPS patches will now only need to correct the game speed for higher framerates instead of first finding out how to unlock the framerate and then fixing the game speed after that. This hybrid method is exactly what was used to allow users to now play Demon’s Souls at 60FPS and beyond!
Following the inclusion of configurable vblank frequency, elad added two more options to the emulator. The “Clocks scale” option allows you to change the speed of various clocks and timers, making games think that time is passing slower or faster. Another option was added to allow you to configure the accuracy of sleep timers. Over a year ago it was discovered that a real PlayStation 3 has extreme accuracy with the sys_timer_usleep call, and the implementation of the same in RPCS3 was made more accurate to match the PlayStation 3. However, making it more accurate requires spinning to increase the accuracy, which means that your CPU spends a lot of time not doing useful work. Setting the accuracy to “as host” will get you the original accuracy that RPCS3 had, possibly reducing CPU usage in some games, but also dramatically reducing framerate in some games that rely on sys_timer_usleep to be hyper accurate such as NieR. Finally, another option was added that extends the accurate handling of timers beyond sys_timer_usleep to some other syscalls as well. This setting is known as “All timers”.
In the current master of RPCS3, these options are all available under the new “Advanced” tab of the Settings menu. If you wish to configure the vblank frequency or adjust clocks scale, then you must right-click on your game from the game list and select “Configure”, since these settings can only be set on a per-game basis.
Finally, let’s go over some of the improvements made to RPCS3’s GUI. Apart from our GUI whiz Megamouse, this month saw contributions to the GUI from CookiePLMonster and MSuih. The first set of changes aimed to fine tune how the UI reacts to controller input. CookiePLMonster observed that a few UI buttons did not follow the standard UI behaviour by executing their actions on button press instead of reacting to button click (press and release), This led to an inconsistent experience and in some cases difficulty navigating through the menus. Not many users would notice such a subtle difference but for those who did, this issue has now been addressed.
While the above change may seem trivial, the concept did have implications in relation to how input is handled by games while system dialogs are open. The PlayStation 3 hides button presses from the game when a system dialog is active to prevent the game from recognising unnecessary input. In order to achieve that a pad interception flag is activated and passed to the game whenever it requests for pad information and the input data passed to the game is basically empty as well. Megamouse had implemented this in RPCS3 a couple years ago and to put it simply, it just works. Except it didn’t. As we found recently, Hotline Miami 2 would immediately activate a menu option after a system dialog was closed without any additional input from users. This was obviously not the expected behaviour as the game recognised the last input made to the system dialog. Thanks to debugging from CookiePLMonster, it was identified that the game did not receive new input immediately after a dialog was closed until Cross, Square, Circle, Triangle, Start and Select were released (L1, L2, L3, R1, R2, R3, direction buttons and analog sticks did not matter). In the previous implementation, input was resumed on button press instead of button click (press and release). Megamouse promptly implemented this accurate behaviour in RPCS3 to resolve the issue.
Previously, the button click from the system dialog would immediately trigger the New game option to be selected as well. This has now been addressed and users can navigate the menu screen correctly.
Next, Megamouse fixed issues with background images shown during shader compilations screen and game titles. The background images are recognised from the directory of the PARAM.SFO that was used to boot the game. However, where a game has updates installed, the image are taken from the the update directory in dev_hdd0/game/ instead of the actual disc directory. This ensured that we picked up the latest image available. But in a situation where PIC1.PNG isn’t present in the game update directory, we end up loading the lower resolution ICON0.PNG as a fallback. Since loading a lower resolution image is not preferred when the high resolution image is available in the disc directory, the emulator will now look for PIC1.PNG in the disc directory before using ICON0.PNG as a fallback. In the same manner, the game title was previously taken from the game update directory (if present) and shown in the game window resulting in titles such as “Beyond: Two Souls Update Data (EU3)” instead of “Beyond: Two Souls”. Now if a game is detected as a disc game, then the emulator will read the original disc’s PARAM.SFO again and reset the title to match the actual disc.
Previously, the lower resolution ICON0.PNG was incorrectly used when the PIC1.PNG was available in the disc directory
This month also saw an improvements to the Virtual File System dialog and Save Manager dialog. First up, let’s look at the work CookiePLMonster did with the virtual file system dialog. To bring the dialog in line with the rest of RPCS3’s UI, the Add New Directory and Reset buttons were replaced with “+” and “-” buttons, the Reset All button was renamed to Reset Directories, the Okay button was renamed to Save and a Close button was added to allow users to quit the dialog without saving the changes made. CookiePLMonster also added the ability to delete a single item from the list which was previously not possible and a confirmation dialog was also added for the Reset Directories button to prevent accidental resets.
The Save Manager dialog also saw some notable improvements thanks to MSuih. When a save is highlighted, it now displays an icon along with the details to the right of the list instead of a separate popup dialog. This allows for much quicker navigation of the Save Manager and provides for a smoother experience.
Finally, Megamouse wrapped the month off with improvements to icon rendering and resolution in the game list, Save manager and Trophy manager for high DPI monitors. In addition, the trophy icons now display the same background icon colour that is used for the game icons. The controller image size in the Pad settings dialog was also fixed for both normal and high DPI configurations.
Improvements made to to icon rendering for high DPI monitors
The controller image size in the Pad settings dialog was also fixed for both normal and high DPI configurations
Metal Gear Solid 4: Guns of the Patriots
The promised day has finally arrived! Thanks to the sys_overlay improvement made by eladash, the coveted PlayStation exclusive title, Metal Gear Solid 4, reached intros towards the end of July. But it wasn’t soon after that eladash made further improvements to allow the title to progress ingame!
NieR Replicant and Gestalt
Thanks to Whatcookie’s recent patch for NieR Replicant and Gestalt, both games are able to break past their previous 30FPS framerate cap! And since NieR isn’t a very intensive game achieving a locked 60FPS with RPCS3 isn’t difficult at all. Check it out in the video below.
Megazone 23 – Aoi Garland
Now let’s kick off with some Playable titles! First off is the PlayStation 3 exclusive title Megazone 23 – Aoi Garland. When tested back in February 2018, this title was graphically accurate but suffered from low performance keeping it from being Playable. Thankfully, these performance issues have been resolved and the game fares well even on low-end systems.
One Piece: Pirate Warriors 2
Unlike its sequel, One Piece: Pirate Warriors 2 never reached PC. However, users needn’t fret as it was confirmed to be playable on RPCS3 from start to finish this month. Sadly, the original One Piece: Pirate Warriors, which also missed out on a PC release, still remains ingame for now.
Mist of Chaos
The last playable title from this showcase is Mist of Chaos. This title previously suffered from significant graphical issues keeping it from being playable. Thanks to the recent improvements by kd-11, these issues have been addressed and this game is now playable.
While SSX has been progressing ingame since mid-2018, the PSN versions of the game would consistently crash during the intros. Thanks to the various improvements made to the emulator, the PSN versions also progress ingame. Sadly low performance and graphical bugs prevent this title from being fully playable.
WWE SmackDown vs. Raw 2011
The last entry in the SmackDown vs. Raw series, WWE SmackDown vs. RAW 2011 finally progresses ingame. With this, all titles from WWE series that were available on the PlayStation 3 are now at least Ingame in RPCS3.
Miyazato Sankyoudai Naizou Sega Golf Club
While it may not seem that impressive, this PlayStation 3 exclusive title was one of the first titles released in 2006 as part of the console’s launch. It progressed ingame for the first time this month. Further testing is necessary to determine if this title is indeed Playable on the emulator.
There have been numerous other pull requests merged during the month that couldn’t make it to the Major Improvements section. We have collected a list of all such improvements here, and attached a brief overview to each. Make sure to check out the links provided for them if you are interested, as their GitHub pages usually uncover further details as well as the code changes themselves. To see this whole list right on GitHub, click here.
6172 – Build with no-strict-aliasing flag for GCC and Clang compiler;
6147 – Improved SPU implementation with the TSX path by fixing “Preferred SPU Threads” option adding vm::temporary_unlock to various syscalls;
6210 – Fixed SPU Interpreter regression after the above pull request; Added experimental TSC frequency detection; Added forward declarations of vm::_ref_base and removed default AT = u32 in _ptr_base and _ref_base; Also includes a commit from elad335 that fixed a typo in the kernel explorer;
6211 – Fixed a regression caused by the above pull request;
6225 – Optimised SPU Recompiler memory consumption by not rebuilding trampoline for every function at startup which should address the Out of Memory error in some cases;
6237 – Expanded thread affinity mask to u64 and also fixed and noted __APPLE__ path;
6249 – Improved TSX compatibility by Implementing low_lock and vip_lock (for shared_mutex) and simplifying suspend_all implementation with the updated shared_mutex;
6267 – Implemented waitable atomics, used atomic wait in shared_mutex and semaphore; Corrected get_int_t to get_uint_t;
6283 – Improved implementation of waitable atomics; Fixed sys_config_get_io_event syscall name; Also includes commits from elad335 that improved sys_lwcond implementation, made sys_fs_closedir atomic and added EAGAIN check for sys_memory_container_create.
6162 – Fixed native pitch computation in OpenGL;
6164 – Fixed frameskip in Vulkan; Fixed image_in functionality to avoid use-after-free. Marked empty inline draws as such to avoid a divide-by-zero later; Fixed unsupported GL format error in GLTexture.cpp; Fixed a regression noticed in Gran Turismo 6; Made AMD hardware tweaks for driver compatibility;
6224 – Implemented separate viewport raster clipping. Fixed broken split screen and/or elements out of bounds in Sly 3, Dragon Ball: Raging Blast, Initial D Extreme Stage and Beyond Two Souls. See coverage in major improvements here;
6261 – Fixed aliased memory surface loss when doing intersection tests. When doing memory inheritance across the DEPTH<->COLOR barrier, it was possible for data to be lost due to incomplete succession. Fixed a graphical regression in The Last of Us caused by PR 5937;
6285 – Optimised conditional render syncs to avoid unconditionally flushing the queue unless the upcoming reference is contained in the active command buffer. This avoids spamming queue flush, which frees up resources and improves performance by evading a GPU hard sync. Improves performance in Ratchet & Clank Future: A Crack in Time and Resistance 3.
6159 – Fixed possible inconsistencies for sys_memory mem stats report;
6167 – Clamped fragment shaders address to the relevant 31 bits;
6168 – Refactored rsx_decode.h to explicitly truncate bitfields to the destination type where the new bf_decoder resolves smallest type possible at compile time and truncates the result; Fixed a typo with NV4097_SET_BLEND_COLOR::green16/red16() that led to a loss of 8 upper bits (using u8 instead of u16);
6177 – Fixed a regression from the above pull request;
6173 – Added ability to log last PPU HLE function executed and full registers (SPU/PPU) state after access violation; Fixed MFC tag status report for explicit mfc barriers commands which affects only status report because it is already blocking all tags; Improved memory ordering of cpu_init() a little;
6190 – Fixed Emu.Stop() by not attempting to join the vulkan device enumeration thread;
6184 – Fixed access violation address reporting on PPU executable memory
and allows to detect access violations that were previously silent before;
6239 – Fixed sys_rsx_context_iounmap partial unmapping with entry indexing when part of the targeted unmap area has already been mapped or unmapped into non-continues EA addresses;
5345 – Prefetch MFC list elements to protect them from destruction by the previous elements processing in the GET list. This occured when the destination of the command overlapped the list entries. Fixed Calling All Cars, making it go from Intro category directly to the Playable category!
6262 – Fixed unmap key value in cellGCM by correctly handling non-contiguous unmappings and other miscellaneous improvements;
6268 – Fixed a regression from the above pull request;
6102 – Improved sys_overlay implementation of sys_overlay_load_module_by_fd and implemented special segment allocation when ppc_seg flag is specified. With this improvement, Metal Gear Solid 4 progressed to Intros for the first time!
6280 – Improve ORI and ORIS disassembly for PPU modules.
6201 – Fixed the outdated app versions of games by properly refreshing the game list after a patch was removed;
6245 – Allows users to select all labels in the About RPCS3 window using a mouse and keyboard. Also, allows users to open links in that window using the keyboard.
6271 – Added improvements for high DPI monitors in the game list, save data manager and trophy manager. Also, added the background icon color that is already used for the game icons to the trophy icons. See coverage in major improvements here;
6148 – Added a workaround for slow PBO usage with the OpenGL renderer using Mesa drivers for AMD GPUs on Linux;
6196 – Fixed a case where float16_t was wrongly disabled on non-Vega AMD GPUs on Linux with the Vulkan renderer;
6230 – Fixed .BIN decryption filtering for case sensitive platforms in the Qt file dialog;
6284 – Clarified warning regarding the blackscreen issue when using RADV drivers with LLVM 8.0.0.
6142 – Cleaned up a lot of code to decrease the warning spam during compilation, particularly with CMake and MSVC;
6219 – Fixed an oversight that reverted the custom game name to the original game name when adding a custom config in grid mode or removing one in grid or list mode. Also, fixed a typo that made it impossible to remove custom pad configs through the game list;
6264 – Revamped the Save Manager GUI by adding resizable game icons (as seen in the Trophy Manager) and showing the save data details conveniently beside the list instead of opening the rudimentary dialog that was originally implemented. See coverage in major improvements here.
6235 – Improved the Virtual File System dialog by replacing the Add New Directory and Reset buttons with “+” and “-” buttons, allowed deletion of a single item which was previously not possible, renamed Reset All to Reset Directories and added a confirmation message, renamed the Okay button to Save to be in line with the rest of RPCS3’s UI and added a Close button was also added, allowing to quit without saving settings. See coverage in major improvements here.
6171 – Added an SPU performance test (spurs_test.self) to the elfs shipped with RPCS3. It benchmarks a CPU’s performance on certain SPU workloads and also provides reference figures to a real PlayStation 3. For those interested, the source may be found here;
5446 – Implemented cellMic library to allow for microphone emulation and currently supports 4 microphone types, namely, Standard, Singstar, Real Singstar and Rocksmith. See coverage in major improvements here;
5781 – Implemented most sys_config syscalls which is necessary to boot and navigate through VSH in the emulator.
6078 – Replaced few hardcoded strings in the Vulkan Backend with corresponding macros from the Vulkan SDK.
6227 – Updated the thread scheduler to better support AMD Ryzen Zen+ and Zen2 architectures.
6214 – Fixed an issue on Linux where the emulator would crash if a file named .directory was created by KDE dolphin in dev_hdd0/game/. This was resolved by ignoring file entries when adding game directories in the game list.
6193 – Set the default SPU Decoder to the LLVM recompiler and renamed the option from “experimental” to “fastest”.
6182 – Fixed a typo in the settings dialog.
6169 – Fixed a build error when using cotire and Clang 8.0 branch.
We hope you liked this report and look forward to the next one! If you would like to contribute to the project, you can do so either by contributing code, helping the community or becoming a patron. RPCS3 has two full-time developers working on it who greatly benefit from the continued support of the many generous patrons. In exchange, patrons also get special support over on our Discord server and get access to early updates directly from our lead developers. If you are interested in supporting us, consider visiting our Patreon page at the link below and becoming a patron, or join our Discord server to learn about other ways of contribution.
We’re always looking for dedicated writers to help us write these reports. If you have the skill, time and are willing to help, please apply here. Also, come check out our YouTube channel and Discord to stay up-to-date with any big news.
This report was written by HerrHulaHoop, MarioSonic2987, Whatcookie, JohnHolmesII and Digitaldude555.