VOGONS


First post, by kjliew

User metadata
Rank Oldbie
Rank
Oldbie

QEMU just becomes better at retro Windows games! 😉 Any other PC emulators would even try to emulate SB Live! or Aureal Vortex2? 🤣 and what's the expected frame rate then ...

So here's the recipe:
- DSOAL or DSOAL-XP, using libopenal-1.dll as OpenAL driver.
- Latest OpenAL Soft 1.21.1 from MSYS2 repo, recompiled with heavy optimization and support for Windows XP.

OpenAL vendor string: OpenAL Community
OpenAL renderer string: OpenAL Soft
OpenAL version string: 1.1 ALSOFT 1.21.1
OpenAL extensions:
EFX version: 1.0

It currently works best in Linux KVM. Linux with kernel 5.13.x and latest MESA improve virtualization performance across Intel/AMD CPUs by 20~25%. Many games which were struggling in the past on Ryzen 2500U APU now played smoothly at near 60 FPS. And for games that already rendered at over 100 FPS, we could now bring 3D audio processing to CPU for EAX audio effects.

It is passable on Windows 10 WHPX, but not as great as Linux KVM. Sounds would hiss & pop sometimes and may take a while to recover. Tuning QEMU audiodev backends can help but that would be system specific. There is not many audio backends available on Windows. For dsound backend, I had to increase timer-period from default 10ms to 30ms to get smooth sounds.

-audiodev id=dsound,driver=dsound,timer-period=30000,in.voices=0,in.mixing-engine=off,out.mixing-engine=off

If the games work on 32-bit Windows 7, then QEMU audio on Windows 7 guest will be much better with support for HD Audio, finer OS scheduler time quantum and DSOAL/OpenAL Soft can use WASAPI backend for low-latency audio.

Here's some of the tested games:

Ssfe-EAX.png
Filename
Ssfe-EAX.png
File size
378.51 KiB
Views
433 views
File comment
Serious Sam TFE
File license
Fair use/fair dealing exception
NFS3-EAX.png
Filename
NFS3-EAX.png
File size
405.23 KiB
Views
433 views
File comment
Need for Speed 3
File license
Fair use/fair dealing exception
GP3S-EAX.png
Filename
GP3S-EAX.png
File size
896.34 KiB
Views
433 views
File comment
GrandPrix 3 Season 2000
File license
Fair use/fair dealing exception
Fear-EAX.png
Filename
Fear-EAX.png
File size
795.17 KiB
Views
433 views
File comment
F.E.A.R
File license
Fair use/fair dealing exception
Diablo2-EAX.png
Filename
Diablo2-EAX.png
File size
1.38 MiB
Views
433 views
File comment
Diablo 2
File license
Fair use/fair dealing exception

GrandPrix 3 Season 2000 is a fantastic game with EAX audio effects fully upgraded from the original GrandPrix 3.
F.E.A.R is probably another fantastic EAX game and the audio effects add to the horrific atmosphere.

The rest, I am not quite sure, probably just a "feel-good" checked mark "Yeah, I have EAX on my VMs for Windows games".

Last edited by kjliew on 2021-08-27, 09:08. Edited 2 times in total.

Reply 1 of 8, by kjliew

User metadata
Rank Oldbie
Rank
Oldbie

Tomb Raider Angel of Darkness is another great EAX games.

TRAOD-EAX.png
Filename
TRAOD-EAX.png
File size
892.79 KiB
Views
425 views
File comment
TR AoD
File license
Fair use/fair dealing exception

This game played at 60FPS on Ryzen 2500U at 1280x960 32-bit color and max details, including all EAX sound effects enabled on ArchLinux x86_64. 😉 Absolutely fun & enjoyable from the comfort of highly portable thin & light ultrabook.

Can we bring the same DSOAL/EAX support for Win98 VM? Well, it is possible, DSOAL-XP can be made to run on Win98 but the threading library used by OpenAL Soft requires Windows API level of at least Windows XP. If the later issue can be resolved, then we will have DSOAL/EAX on Win98 VM. too.

However, Win98 VM may have other troubles to get smooth audio. Most notable is the coarser time quantum for OS scheduler. Win98/ME VMs run at PIT tick rate which is about 1.19MHz while Windows 2K/XP VMs run at ACPI tick rate which is about 3.57MHz. Windows 7 VMs, with native support for HPET timer, run at 10MHz tick rate. So it is yet unknown if DSOAL/OpenAL Soft would work as great as in WinXP/Win7 even if all the API dependencies issues can be resolved.

Reply 2 of 8, by kjliew

User metadata
Rank Oldbie
Rank
Oldbie

Descent: FreeSpace The Great War (1998)

Freespace-EAX.png
Filename
Freespace-EAX.png
File size
386.96 KiB
Views
389 views
File comment
Freespace-EAX
File license
Fair use/fair dealing exception

Other than Mechwarrior 2 31st, this is another masterpiece that I would never be tired of replaying through the campaign. Great story that I still cherished today, fantastic graphics and in-game animation. It was a rare game released into Win95 era with support for WinNT 4.0 with DirectX update. That made it an easy game to run in later Windows OSes compared to Mechwarrior 2 31st 3Dfx. It also supported 3Dfx Glide in addition to a very good Direct3D implementation. I have been able to replay the game on WinXP & Win7 with native Direct3D. A community sourceport is available but I always prefer the originality of retailed CD version.

The final official patch 1.06EAX brought 3D sound and EAX audio effects to this wonderful game. However, I have never enjoyed the game with 3D sound and EAX audio effects even though I had a SB Live! back then. The game called for minimum requirements of Pentium 133MHz but if anyone would be a fool to ever believe that. I first played the game on Pentium MMX 200MHz w/ Voodoo1. It was OK until the very last few missions. Enabling EAX on SBLive! on that machine just trashed the game experience regardless of how good it might sound. By the time I could afford more powerful system to play it again on WinXP / Win7, I already trashed the SBLive! and just used motherboard audio. Such experience made the so-called "period-correctness", building retro PCs for games ... bla ... bla ..., an utter joke for the best game experience. 🤣 Oh, no thanks, I want the best CPU/GPU, high quality IPS panel and ultra-fast SSD storage.

Today, thanks to QEMU virtualization I can replay the game at maximum quality beyond the game presets "Very High", scaled at any resolution from the game's only supported 640x480. I can play it on Windows 10 and Linux. DSOAL & OpenAL Soft now bring 3D sound and EAX audio effects to complement for the ultimate game experience on QEMU Windows XP VM, yeah 😁!

Reply 3 of 8, by kjliew

User metadata
Rank Oldbie
Rank
Oldbie

Yeah! 😁 It's DONE. DSOAL EAX for QEMU Win98SE VM!

Win98-EAX.png
Filename
Win98-EAX.png
File size
202.26 KiB
Views
349 views
File comment
EAX for Win98SE VM
File license
Fair use/fair dealing exception

And this one works across all legacy Windows VMs before Vista, Win98/2K/ME/XP.

There is still one last puzzle to solve, but it is an easy one which happened to be the same problem for DDRAW in case of WineD3D -- DLL pinning into memory. So far, all 32-bit Windows VMs including Win7 and Win10, except for Win2K, will pin DDRAW.DLL into memory. This is the problem of 2 DDRAW DLLs, one from the OS and another replacement dropped into game folder. The OS seems to remember exactly the name "DDRAW.DLL" and there is no way to run another DLL of the same name without rebooting the VM. Apparently dgVoodoo2 or any dxwrappers would have the same problem or maybe not for 64-bit Windows. The same DLL pinning applies for DSOUND.DLL but this time only in Win98/ME, Win2k/XP do not seem to be doing it.

So since this can be a completely guest-side implementation (just CPU processing for EAX), perhaps it is also a great news for Marvin folks for beef-up Windows 98SE retro PCs to get EAX support from on-board AC97 audio with WDM audio drivers. No more crappy SB Live! or Audigy PCI that hog the PCI bus, especially on non-Intel chipsets PCI implementation. Not all EAX games will have EAX support from DSOAL though, YMMV.

Reply 4 of 8, by digger

User metadata
Rank Oldbie
Rank
Oldbie

Being able to play and experience these games as originally intended on modern and future systems is not just fun, but also historically important.

Thanks for your continued efforts on this, kjliew!

Reply 5 of 8, by kjliew

User metadata
Rank Oldbie
Rank
Oldbie

Alright cut out the artificial Rightmark3DSound. Now, real game on Win98 VM.
MDK2 Default OpenGL w/ DSOAL EAX on QEMU Win98 VM

MDK2-EAX.png
Filename
MDK2-EAX.png
File size
1.15 MiB
Views
329 views
File comment
MDK2 EAX
File license
Fair use/fair dealing exception

EAX option available and enabled. With Virtualization, the CPU will never be the bottleneck even it was loaded up with EAX audio effects processing. There is literally no impact to frame rate by enabling EAX. I don't post a 1920x1080 widescreen FHD screenshot for bluffing, I show real performance stats and 1024x768 is good enough. 😉

digger wrote on 2021-08-30, 23:15:

Being able to play and experience these games as originally intended on modern and future systems is not just fun, but also historically important.

Thanks for your continued efforts on this, kjliew!

Thank you. I thought my strong push for playing games on VM and harsh criticism in telling the truth had pissed off many when they can't swallow the truth. QEMU is just cheating on all fronts, no real full device emulation such as the fantastic Voodoo3/Banshee for games 🤣 and now it is even cheating on audio with DSOAL EAX (on WTF Crappy AC97 audio?!) rather than the bragged SoundBlaster(tm) AWE32 emulation. 🤣

Reply 6 of 8, by Stainlesscat

User metadata
Rank Newbie
Rank
Newbie

Wow that's pretty cool. This maybe the current solution for now going fowards because of the unreliable 3rd party vm software out there. ...well virtualbox & VMware weren't ever mean't to be used for playing games on them to begin with.

Reply 7 of 8, by digger

User metadata
Rank Oldbie
Rank
Oldbie

@kjliew Not that it's your main focus, but while you're at it: how hard do you reckon it would be to replace the old OPL2 emulation code in QEMU with Nuked OPL3? 😇

I would take a stab at it myself, but I'm not very experienced with low-level C programming. I guess I could give it a shot with some help from others, though. It would be fun to learn. 🙂

Reply 8 of 8, by kjliew

User metadata
Rank Oldbie
Rank
Oldbie
Stainlesscat wrote on 2021-09-03, 18:03:

Wow that's pretty cool. This maybe the current solution for now going fowards because of the unreliable 3rd party vm software out there. ...well virtualbox & VMware weren't ever mean't to be used for playing games on them to begin with.

Thanks, neither was QEMU. It is just a one-man ambition & dream to preserve and replay good old games from his young age at the best possible quality.

@digger I don't think Nuked OPL3 would be something that would make an impact for Windows games. QEMU isn't really very good at DOS games and for DOS games that it is somewhat good at (Tomb Raider 1, Screamer 2/Rally, Pyl, Redguard etc.) none of them actually have FM music. If nuked OPL3 was really that great, then I would think upstream DOSBox would have endorsed it, which makes a lot of sense for DOS games. If I would ever be doing anything for QEMU for DOS games, then it would be Munt/MT32. 😉