Jump to content

Compiling newer WineD3D for 98SE and/or XP...?


Bruninho

Recommended Posts

Hi, I am looking for someone who can compile WineD3D libraries from newer versions (like 3.x, 4.x and 5.0.5 maximum) for Win 98/XP... I've seen it is possible, but I have no clue how it can be done... all I know is that I'd need msys and mingw. I've failed numerous times using different environments and everything. I need them for a qemu-3dfx fork that has a mesa gl passthrough, kinda like Virtualbox used to do some years ago.

These libraries would enable direct3d gaming for 98/XP qemu virtual machines, so some DX1-7 games would benefit from that. Anyone interested in trying?

https://github.com/kjliew/qemu-3dfx

Link to comment
Share on other sites


@Bruninho I am interested in his project as well. He doesn't seem to provide a way to compile WineD3D libraries in his GitHub page, only Glide and OpenGL?

One day I will pay him and see how it looks like. Which would make it the second 98SE related purchase I made after buying rloew's AHCI Driver back when he was still alive. I guess it'll be already compiled and would require some debugging skills to determine what is different comparing to normal WineD3D libraries which I do not have :( 

Link to comment
Share on other sites

On 1/11/2022 at 6:12 PM, MrMateczko said:

@Bruninho I am interested in his project as well. He doesn't seem to provide a way to compile WineD3D libraries in his GitHub page, only Glide and OpenGL?

One day I will pay him and see how it looks like. Which would make it the second 98SE related purchase I made after buying rloew's AHCI Driver back when he was still alive. I guess it'll be already compiled and would require some debugging skills to determine what is different comparing to normal WineD3D libraries which I do not have :( 

Yup, he only gives glide and opengl for free and the WineD3D libraries to those who pay for it. You have to elect three games for which he will test them (I guessing that it is to find out which version works best, because I believe there is nothing he should modify inside wined3d.dll and d3d8.dll, d3d9.dll... but I do think that he does something inside ddraw.dll for older DX1-7 games). And needs his modified opengl32.dll (Which he does give for free) for it to do WineD3D/OpenGL to MESA GL passthrough (as described on his wiki page). For example, for Moto Racer you need to add next to the executable the following DLLs: wined3d.dll, ddraw.dll and opengl32.dll. 

He doesn't even give how to do compile it by yourself. How Rude.... but I am sure he does nothing secret with them, hes just able to compile more newer WineD3D versions to run on Win32 (Win 98/XP) machines. There's a video on Youtube where he uses WineD3D 5.0.3 on Windows XP to run Grand Prix 3 with Direct3D support.

I have tried myself and failed, this is why I need to find someone who can do it too and test the theory (that he does nothing at all with them really) so we can play these games in our virtual Win 98/XP machines and relive the 90's in full glory. Actually I am able to play Glide games like FIFA 99 and Need For speed II SE on Windows 98 SE.

Edited by Bruninho
Link to comment
Share on other sites

Just now, Bruninho said:

I have tried myself and failed, this is why I need to find someone who can do it too and test the theory (that he does nothing at all with them really) so we can play these games in our virtual Win 98/XP machines and relive the 90's in full glory. Actually I am able to play Glide games like FIFA 99 and Need For speed II SE on Windows 98 SE.

You might not be interested in trying anymore. So I apologize if this reply bares no interest, as you specifically said you need someone to do it. I understand that, and have been there. But if no one comes along, you could list more details of the method(s) you tried, and the errors you ended up with. If nothing else, this provides someone (that knows what's going on) insight into the situation.

I would certainly offer assistance, but I've yet to actually build anything Windows related. I'm nearing that point. I've been able to work out a lot of other compilation issues. I have never written a complex application, but can modify the heck out of one. So I'm not promising I could help much. But I'd for sure give it the time of day. I'm sure there are plenty around like that. Probably more competent than I.

On a side note, I myself am looking into building Qemu 0.9-0.10 for Win95. Something before KVM came along. Maybe even get Kqemu for Win95. Although for completely different reasons. If someone else has already done it, feel free to gloat :) 

Link to comment
Share on other sites

13 hours ago, awkduck said:

You might not be interested in trying anymore. So I apologize if this reply bares no interest, as you specifically said you need someone to do it. I understand that, and have been there. But if no one comes along, you could list more details of the method(s) you tried, and the errors you ended up with. If nothing else, this provides someone (that knows what's going on) insight into the situation.

I would certainly offer assistance, but I've yet to actually build anything Windows related. I'm nearing that point. I've been able to work out a lot of other compilation issues. I have never written a complex application, but can modify the heck out of one. So I'm not promising I could help much. But I'd for sure give it the time of day. I'm sure there are plenty around like that. Probably more competent than I.

On a side note, I myself am looking into building Qemu 0.9-0.10 for Win95. Something before KVM came along. Maybe even get Kqemu for Win95. Although for completely different reasons. If someone else has already done it, feel free to gloat :) 

Thanks, my scenario here is pretty simple, I have his fork compiled with all glide wrappers working on my M1 Mac, I can emulate (since M1 is not same architecture) with a very good speed, Windows 98 SE and XP SP3 under his QEMU fork. Windows 98 glide games in particular are marginally faster than on XP. Actually, they are just ridiculously fast enough.

All windows glide games I have tried run just fine, thanks to his glide wrappers (glide.dll, glide2x.dll and glide3x.dll). It's just the WineD3D libraries I am missing for games that support Direct3D and DirectDraw. I can't seem to compile one that works for this purpose with his fork - unless hes doing something special to his version which I am not aware of. For example, WineD3D 5.0.3 libraries were never publicy compiled for Windows XP, but he did it and is able to play games like Grand Prix 3 and some Star Wars campaigns.

Windows 98 SE WineD3D libraries stops at version 1.3.x, yet he managed to build some newer version to be able to do D3D Guest > MESA GL Host passthrough for games like Moto Racer, inside Windows 98. I did manage to build some for XP, but they aren't working either. I must be missing something "special" he is doing to make it work there.

Here you can see how it works: https://github.com/kjliew/qemu-3dfx/wiki/QEMU-3D-APIs-Pass-Through

My case, I have MESA and OpenGlide on my host machine, I have his qemu fork compiled and working for two architectures only (i386 and x86_64). I have even managed to compile myself the glide wrappers with his instructions. What he is not willing to do is to give instructions on how to compile your own WineD3D libraries for D3D/Mesa passthrough (as explained on the page above, item "Third Party Pass-Through"). He asks for a HEFTY donation just to compile it for three games only. Other users were outraged by this price too. I don't think he has ever managed to sell it to more than two or three people. WineD3D is an open source and free library anyway. His qemu fork code is GPL 2.0 though, he can do whatever he wants with it but I don't think he can ask that much money for custom WineD3D libraries. That value exceeds the 1-year subscription for a Parallels Desktop license to run modern Windows and play games, for example. Even GOG games aren't that expensive.

Anyway, I can play all my glide games on my Windows 98 SE virtual machine, but some games with great graphics that require D3D are only playable under software mode - allthough I can play them this way, graphics aren't just that good and fun. Just not the way I remember having played them when I had a real Win 98 machine decades ago. He has a solution that beats DOSBox and VMware for classic Windows gaming, yet he keeps it to himself. Even dgvoodoo for windows users is free...

Edited by Bruninho
Link to comment
Share on other sites

Just now, Bruninho said:

Thanks, my scenario here is pretty simple, I have his fork compiled with all glide wrappers working on my M1 Mac, I can emulate (since M1 is not same architecture) with a very good speed, Windows 98 SE and XP SP3 under his QEMU fork. Windows 98 glide games in particular are marginally faster than on XP. Actually, they are just ridiculously fast enough.

All windows glide games I have tried run just fine, thanks to his glide wrappers (glide.dll, glide2x.dll and glide3x.dll). It's just the WineD3D libraries I am missing for games that support Direct3D and DirectDraw. I can't seem to compile one that works for this purpose with his fork - unless hes doing something special to his version which I am not aware of. For example, WineD3D 5.0.3 libraries were never publicy compiled for Windows XP, but he did it and is able to play games like Grand Prix 3 and some Star Wars campaigns.

Windows 98 SE WineD3D libraries stops at version 1.3.x, yet he managed to build some newer version to be able to do D3D Guest > MESA GL Host passthrough for games like Moto Racer, inside Windows 98. I did manage to build some for XP, but they aren't working either. I must be missing something "special" he is doing to make it work there.

Here you can see how it works: https://github.com/kjliew/qemu-3dfx/wiki/QEMU-3D-APIs-Pass-Through

My case, I have MESA and OpenGlide on my host machine, I have his qemu fork compiled and working for two architectures only (i386 and x86_64). I have even managed to compile myself the glide wrappers with his instructions. What he is not willing to do is to give instructions on how to compile your own WineD3D libraries for D3D/Mesa passthrough (as explained on the page above, item "Third Party Pass-Through"). He asks for a HEFTY donation just to compile it for three games only. Other users were outraged by this price too. I don't think he has ever managed to sell it to more than two or three people. WineD3D is an open source and free library anyway. His qemu fork code is GPL 2.0 though, he can do whatever he wants with it but I don't think he can ask that much money for custom WineD3D libraries. That value exceeds the 1-year subscription for a Parallels Desktop license to run modern Windows and play games, for example. Even GOG games aren't that expensive.

Anyway, I can play all my glide games on my Windows 98 SE virtual machine, but some games with great graphics that require D3D are only playable under software mode - allthough I can play them this way, graphics aren't just that good and fun. Just not the way I remember having played them when I had a real Win 98 machine decades ago. He has a solution that beats DOSBox and VMware for classic Windows gaming, yet he keeps it to himself. Even dgvoodoo for windows users is free...

So we could distill this down to, compiling newer versions of WinD3D for WinXP and Win98?

And you are suggesting that he altered them in no way, for compatibility with his Qemu fork. But obviously they are altered. Unless you are suggesting that no one ever tried to target the newer versions to build for the older versions of windows.? Meaning you believe no one has actually bother compiling the newer versions (WinD3D), to build for (target) the unsupported versions of Windows. But he has tried, and had some success.

Is that about it?

Link to comment
Share on other sites

2 hours ago, awkduck said:

So we could distill this down to, compiling newer versions of WinD3D for WinXP and Win98?

And you are suggesting that he altered them in no way, for compatibility with his Qemu fork. But obviously they are altered. Unless you are suggesting that no one ever tried to target the newer versions to build for the older versions of windows.? Meaning you believe no one has actually bother compiling the newer versions (WinD3D), to build for (target) the unsupported versions of Windows. But he has tried, and had some success.

Is that about it?

I think you're getting it right, yes.

1) Yes, it's all down to compiling newer versinos of WineD3D for XP and 98. The are builds from Federico Dossena (https://fdossena.com/?p=wined3d/index.frag) but, versions for Windows 98 stops at 1.3.x and Windows XP stops at 1.7.52, and newer ones only work with Vista and above. The developer of Qemu-3dfx did newer ones for XP and 98 himself. You can see some of them working here, here and here. The last video shows him adding the libraries next to the game executable.

2) They may or may not be altered. He does not disclose the details. But I don't think they are, based on the fact that, a decade ago, the same concept was used for Virtualbox to provide Direct3D support through WineD3D doing a passthru to the OpenGL engine on host machine. Sure the results were mixed, but some ppl had success. These libraries weren't altered in any way (except for one method where ddraw.dll had to be renamed and the game executable edited to look for the renamed ddraw.dll instead of the one inside Windows folder) but here his method isn't doing it, he uses the original ddraw.dll name. Today, ReactOS and Exagear are also using the original WineD3D libraries to do the same thing, same concept. Depending of the game DirectX version, one has to add the following DLLs next to the executable before running it inside a Win 9x/XP QEMU-3dfx VM:

  • DX 1-7: ddraw.dll, wined3d.dll, opengl32.dll
  • DX 8 and newer: wined3d.dll, d3d8.dll (or d3d9.dll, d3d10.dll...) and opengl32.dll

2.1) Therefore I don't think he does alter them significantly. I mean, it's just three files. And the third one (opengl32.dll) is compiled by yourself when you compile the glide wrappers; so we have wined3d.dll and ddraw.dll to look inside.

3) Yeah, apparently (and I have searched for the entire internet in months) nobody has bothered to build newer versions of WineD3D for Windows 98 and XP.

The first versions of his fork for macOS required us to install Xquartz/X11, because he didn't want to bother rewriting it for macOS (he did for linux and windows). Performance was reasonable. Then he was convinced to get a M1 Mac, and rewrote it in a way that it does not need X11 anymore on macOS. All you need to have is SDL2, OpenGlide and OpenGL (MESA GL) on your host machine, his wrappers, and it's done. Glide games run fine. Any attempt I did to run D3D games with any WineD3D library on Windows XP (I couldn't find one that worked for 98) fires up X11 while QEMU is running, and then QEMU quits (kills the VM running) with some errors. Since his current versions don't need X11 anymore (the videos I posted above shows that) I need to figure out what is the piece that is missing from this puzzle with WineD3D libraries.

EDIT: Actually, I think that another piece of that puzzle may be which MESA I am using on host machine. I installed it from homebrew. This could explain why it's firing X11 when I try a D3D game. So looks like I need to install a different compiled MESA version?

 

Edited by Bruninho
Link to comment
Share on other sites

Just now, Bruninho said:

Actually, I think that another piece of that puzzle may be which MESA I am using on host machine. I installed it from homebrew. This could explain why it's firing X11 when I try a D3D game. So looks like I need to install a different compiled MESA version?

Hmmm. But it doesn't do this when you load a non-D3D game?

If you are getting different video initiation on the host side, then you might have your answer there. Do you know what I mean?

Edit:You could test your WineD3D build on other VM software (or real machine if available). This way you can determine if it works in it's own right (absence of pass-though). Others might even be willing to test, too. It it ran, it would be slow. But it could eliminate one variable in your process. This edited suggestion has nothing to do with the above questions.

Edited by awkduck
additional support
Link to comment
Share on other sites

2 hours ago, awkduck said:

Hmmm. But it doesn't do this when you load a non-D3D game?

If you are getting different video initiation on the host side, then you might have your answer there. Do you know what I mean?

Edit:You could test your WineD3D build on other VM software (or real machine if available). This way you can determine if it works in it's own right (absence of pass-though). Others might even be willing to test, too. It it ran, it would be slow. But it could eliminate one variable in your process. This edited suggestion has nothing to do with the above questions.

First versions of his fork required X11 for everything (including Glide, OpenGL and D3D passthrough). Now it doesn't. When I run a glide game like FIFA 99, it just needs glide2x.dll. When I run Counter-Strike 1.5, which is a OpenGL game, it only requires opengl32.dll but it also supports Glide (glide2x.dll). Counter-Strike 1.6 (the most popular version before CS:GO) became OpenGL/D3D only, and runs only on XP and later, hence why I used 1.5 here for Windows 98.

When a D3D game is initiated, it must start MESA GL passthrough (you can see on terminal in his videos. where you see mesapt being called, it's WineD3D or OpenGL in action, where as Glide is glidept calls). With me it does call MESA, but it also fires X11 which shouldn't be called. In his videos X11 is not called anymore. I presume that something is either wrong on my end with MESA GL install, or his WineD3D libraries have some kind of implementation not to call it.

I don't have anymore the previous versions I had managed to build, I had done it a few months earlier and gave up when I failed to make it work. But one can try it following this small post: https://www.vogons.org/viewtopic.php?t=41636&p=393105 and Federico Dossena has on github a script to build them for both 32-bit and 64-bit Windows, but the catch is that his scripts must be run in a Debian environment or similar (https://github.com/adolfintel/wined3d4win). I tried both. I could only build them using Windows 10 x64 and MINGW. I think it did cross-compile correctly (or else Windows XP would have thrown an error popup. When it doesn't, QEMU calls X11 and crashes).

Even WineHQ website had a page about it, but they removed it. I found it on web archive though: https://web.archive.org/web/20151224173752/http://wiki.winehq.org/WineD3DOnWindows and I had also tried that one, but it didn't build.

Edit: Sorry for that @Wunderbar98. I know the subject here is Win 98 in 2020 and beyond. But gaming on Win 98 is also related and if I manage to get these libraries working, gaming on Win 98 in a VM would be an amazing feat for a such old operating system. I know it's possible, because the dev in question just managed it himself. He just doesn't want to give it for free, but he did hint in a post on VOGONS that the quest for WineD3D libraries were always free, "pointing his finger" to wineHQ website, as long as we manage to compile them ourselves. However, he obviously will not tell us how... hence why I came here to MSFN to try and find someone who can actually find out how to build it and help testing, to make it free for everyone. I have been researching on this subject myself for nearly a year, and I had already thrown the towel...

Edited by Bruninho
Link to comment
Share on other sites

@Bruninho I agree with OP that a separate thread would be nice for WineD3D on 98SE.

As someone who wants to run GTA IV on Windows 98SE, I am currently stuck at the limitations of the latest available NVIDIA and ATI drivers for 98SE making it impossible to run it so far. NVIDIA drivers don't support the D3DFMT_A32B32G32R32F texture which GTA IV expects, and ATI drivers/cards do not support Shader Model 3.0 which GTA IV expects as well. I've tried SwiftShader and public available WineD3D versions and other 'software renderer' junk to no avail. Having modern/specialized/custom versions of WineD3D for 98SE would open new opportunities for running newer games. He says his $60 donation is 'small'. -_-

Edited by MrMateczko
Link to comment
Share on other sites

28 minutes ago, MrMateczko said:

@Bruninho I agree with OP that a separate thread would be nice for WineD3D on 98SE.

As someone who wants to run GTA IV on Windows 98SE, I am currently stuck at the limitations of the latest available NVIDIA and ATI drivers for 98SE making it impossible to run it so far. NVIDIA drivers don't support the D3DFMT_A32B32G32R32F texture which GTA IV expects, and ATI drivers/cards do not support Shader Model 3.0 which GTA IV expects as well. I've tried SwiftShader and public available WineD3D versions and other 'software renderer' junk to no avail. Having modern/specialized/custom versions of WineD3D for 98SE would open new opportunities for running newer games. He says his $60 donation is 'small'. -_-

I also agree that a separate thread is needed. Can we ask a mod to move the posts about this subject to a new thread, so we don't lose track of it?

I feel your pain about your game, I have a few games that would benefit from it like, for example, Grand Prix 3 and Counter-Strike 1.6.

98SE or XP, I don't care which one as long as I can run them. I already modded the XP look with the Inexperience Patcher, so it looks almost like Windows 2000 (one of my favorite Windows versions, neck to neck with Windows 98).

Yea $60 is "small". One US dollar equals nearly 5,54 brazilian reais, so 60 USD is ~332 brazilian reais, its too much money. Brazilian minimum salary is currently approx. 1200 brazilian reais. R$ 332 is insane.

We need someone who can compile these newer libraries for us to test. I have been trying to compile them myself but so far I am failing miserably.

Edited by Bruninho
Link to comment
Share on other sites

  • LoneCrusader changed the title to Compiling newer WineD3D for 98SE and/or XP...?

Thanks, LoneCrusader!

@MrMateczko I was exchanging some emails with Federico Dossena this night, telling him about these WineD3D libraries. He told me:

“I assume he tried to do an XP build and tried to fix the errors one by one as they popped up, which is complicated and time consuming but clearly possible.”

He also noted something which we should be looking for:

“I should point out that Wine is under the GNU GPL v2 license so he's legally obligated to share his modifications, he can put them behind a paywall if he wants to, but his patches must be made available otherwise he's violating Wine's license (and you should report it to the Wine team).”

I will bring more updates on it later. He will probably help me to get in touch with the Wine team to do it.

Link to comment
Share on other sites

I tend to think the same. But reporting it or not, we don’t get it anyway. However, there’s a chance we can if we report. Like Federico told me, he can still put them behind that donation, but has to make them also freely available. Just like how Wine is free while it’s commercial solution “CrossOver” is paid, for example.

He may still get it from those who know (censored) nothing about compiling it. We might get it, as long as he is legally forced to make available and explain how to do it. Although he hardly explained how to compile his entire qemu code and we had a hard time to figure out how to do it and run it, but in the end I managed to play it, at least the glide games.

I will look into how to contact the wine team for it. Like I said above, he shouldn’t be doing that, since he’s violating Wine license, and either way doesn’t matter if we don’t get it because currently we don’t get it anyway.

Edited by Bruninho
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...