blueclouds8666 / pcsx2_XP

PCSX2 - The Playstation 2 Emulator, now available for Windows XP
https://pcsx2.net/
GNU General Public License v2.0
23 stars 1 forks source link

DirectX11 renderer for PCSX2 XP #2

Open blueclouds8666 opened 3 years ago

blueclouds8666 commented 3 years ago

recently @andika207 mentioned about some unofficial ways to make DirectX 10 and 11 work under Windows XP, a feature i wasn't much aware of or informed. It turns out a russian group managed to port some of the DirectX components to said operating system, althought it seems to be experimental and far from perfect, i thought it could be a good idea to test it out with this project. there are currently several ways to make newer versions of DirectX run under XP:

This testing candidate feature will be first tested under the v1.5.0-dev Sep2018 version, located on the branch release-1.5.0. It seems code modification is needed in order to make GSDx detect the machine is indeed compatible with the DX11 renderer. Any code modifications will logically published on new branch. Also, I don't know what kind of performance and functionality to expect from this unofficial "patches", so if it doesn't mean any improvement in contrast with the other renderers, it might not be worth to invest much time on it.

inline

blueclouds8666 commented 3 years ago

After testing for a while different unofficial DirectX implementations for XP, i've reached some conclusions and also results regarding PCSX2 in DX11 mode:

Here you can see a screenshot running PCSX2 XP on DirectX 11 mode under XP with said library. The bios blue color is messed up indeed which is a funny glitch. Most games don't seem to suffer from this bug, i've only seen it happening on the bios.

image

blueclouds8666 commented 3 years ago

Performance Results:

I've tested 3 different games under my main machine (FX 8300, GTX 960). While compatibility seemed to be quite good for what it is, there's an important performance hit as a reason of the API conversion and wrapping.

I've measured around 20 ~ 50% of performance drop while using WineD3D for DX11 library and renderer in contrast with the OpenGL renderer. Maybe if Vulkan and DXVK could be made run under WinXP, the performance impact would be probably much lower. But nothing of that exists yet, or seems feasible to ever happen. For this reason and others, i've decided i'm not going to do further implementations or modifications into PCSX2 XP as this all can only be considered an experimental/testing feature, offering less than ideal performance and compatibility for stable releasing.

One of the games, Shadow of the Colossus, only showed a black screen while running with DX11 over WineD3D, making it unplayable. The other two ran without any noticable graphical glitch or anomaly. You coulnd't tell it was running a conversion wrapper in behind, leaving performance aside. More details about the benchmarks:

image

blueclouds8666 commented 3 years ago

Guide on how to use PCSX2 XP DirectX 11 renderer under Windows XP:

First of all, you should know any PCSX2 version should be compatible with this method regarding it works on XP, including those from many years ago! However, PCSX2 XP v1.6.0 does NOT work with this method because DirectX was stripped down from that release.

If you now run PCSX2 and open the GSDx plugin settings, you'll now find a DirectX 11 renderer option, which can be used right away, as you would on Windows Vista+. The performance of DirectX 9 and/or OpenGL renderers shouldn't be affected while having WineD3D "installed" into the PCSX2 directory, nevertheless you can always remove those 3 libraries whenever you want.

PS: You might find interesting checking the XomPie project, which tries to extend WinXP software compatibility. Thanks for your efforts towards the Windows XP scene!

DosFreak commented 3 years ago

You may want to try the WineD3D files from BlackWingCat Extended Kernel (Windows 2000) or OneCoreAPI since those should be more recent.

Extended Kernel for 2000 is in some ways more compatible than OneCoreAPI (XP) and is also updated more often, although Extended Kernel is for 2000 the WineD3D files may work. I haven't bothered yet to test if PCSX2 works on Windows 2000 with Extended Kernel but if it works on vanilla XP then it should.

DosFreak commented 3 years ago

http://blog.livedoor.jp/blackwingcat/archives/1299806.html http://win2k.org/wlu/wlu.htm http://win2k.org/cgi-bin/dl.cgi?file=Windows2000-KB935839-v30fM-x86-ENU.wlu