How can I ensure that my game runs on every PC?

Started by
17 comments, last by VanillaSnake21 11 years, 5 months ago

[quote name='Aliii' timestamp='1351604824' post='4995404']
Thanks!
To give more info: I compiled the app on my laptop. It worked both on my PC and laptop. I took the code and complied it on my PC, ....and now that exe from that same code is not working under XP properly.
I was not checking for errors cause the most advenced stuff im using is display lists and 2D textures.(Not even glut i think, ...i cant check it now, im at work:))

I also tried to replace the gl headers with the ones from my laptop but it made no difference.


does the laptop have dual GPUs ? (Intel + AMD/nvidia) and if so, did you update the drivers for both the Intel and the AMD/nvidia GPU ? it is unfortunatly not uncommon for laptops to ship without OpenGL drivers for some reason (Which causes Windows to fall back to a software driver (which supports OpenGL 1.1 but really is slow as ....).
[/quote]

It has a single integrated ATI, ....i couldnt find proper drivers for this card, only some hacked "Omega drivers". ....thats what it uses now.
It shouldn have 1 fps even if its software rendered. An another laptop(emulated XP) with i7 and GeForce540 produced 5FPS. Theres something really wrong there:)
Advertisement

[quote name='SimonForsman' timestamp='1351605333' post='4995407']
[quote name='Aliii' timestamp='1351604824' post='4995404']
Thanks!
To give more info: I compiled the app on my laptop. It worked both on my PC and laptop. I took the code and complied it on my PC, ....and now that exe from that same code is not working under XP properly.
I was not checking for errors cause the most advenced stuff im using is display lists and 2D textures.(Not even glut i think, ...i cant check it now, im at work:))

I also tried to replace the gl headers with the ones from my laptop but it made no difference.


does the laptop have dual GPUs ? (Intel + AMD/nvidia) and if so, did you update the drivers for both the Intel and the AMD/nvidia GPU ? it is unfortunatly not uncommon for laptops to ship without OpenGL drivers for some reason (Which causes Windows to fall back to a software driver (which supports OpenGL 1.1 but really is slow as ....).
[/quote]

It has a single integrated ATI, ....i couldnt find proper drivers for this card, only some hacked "Omega drivers". ....thats what it uses now.
It shouldn have 1 fps even if its software rendered. An another laptop(emulated XP) with i7 and GeForce540 produced 5FPS. Theres something really wrong there:)
[/quote]

... Sigh... But if it's emulated then it won't matter much if it's a GeForce540 or a 3DFX Voodoo.
What makes you think that it shouldn't run with 1fps in emulated mode?
Lol! This was the problem: I had a 256x257 texture, which is not OK for older GL versions.(Now it runs on 60-80 FPS on the laptop)
I tried the recommented tools, Gdebugger and VerySleepy ....they are awesome. Thanks!

BTW the original question is still open. How can I ensure that it runs properly(or as much properly as it possible) on every PC? What should I link statically? What dll-s should I put or not put in the games folder? Im not much less clueless about that.
If you're making a game, don't worry about it yet, at some point you will get it out to testers and there will be platform and GPU and to a lesser extent even CPU related issues that crop up and would be very difficult to see in advance as a single programmer with limited resources and available test machines.
These are bugs, to be solved later, don't let them slow you down now. Typically unless you are doing something really really wrong you will find it faster by just continuing to forge ahead, and by the time you do have to solve these bugs you will know your code inside and out and be a better programmer more apt to deal with these types of issues.

-Aeramor

CTO at Conjecture, Inc.


BTW the original question is still open. How can I ensure that it runs properly(or as much properly as it possible) on every PC?


The simple answer is this: you can't.

"Every PC" covers an enormous range of hardware and software configurations, from the most basic and primitive to turbo-charged gaming PCs and workstations, and all points in between. It is just not possible to write a program that is guaranteed to run on all of them.

OpenGL is not software. If you want to run fast and run well you are entirely at the mercy of the hardware installed on a PC; if that hardware is horrible then you just won't run fast or run well; you're lucky if you run at all.

As you've just discovered, OpenGL can be capable of emulating certain features in software, depending on the driver, but - as you've also just discovered - this is often not a desirable state of affairs.

OpenGL may have a reputation for being easy, but that doesn't mean that you get to skip reading documentation. So you need to grab an OpenGL spec (available on http://www.opengl.org), read it, understand it, know what you can do and what you cannot do, know what causes errors and what doesn't.

What your objective should be is to pick a reasonable baseline, declare that you're not even remotely interested in supporting anything below that baseline, then make that your target hardware requirement. There's no point in picking a fight that you can't win, and "run on every PC" is such a fight; choose reasonable and achievable objectives instead.

Direct3D has need of instancing, but we do not. We have plenty of glVertexAttrib calls.

> How can I ensure that it runs properly(or as much properly as it possible) on every PC?

You test your product on as many different system types that meet your minimum specifications as possible. Since testing costs money, you might make do with testing a few representative systems, and then you open it up to Alpha users, who expect some risk in return for free gameplay.

This will provide some level of assurance, however, non-trivial software always has bugs.
Even though you can't ensure it will run on everything, it sounds like your game is quite likely to run on most PCs, since you don't use many advanced features and it runs both on Win7 64 and XP 32.
One thing you probably want to test is running it on a machine that doesn't have any development tools installed, to find out what libraries might be missing. If you discover something that doesn't work, you can create an installer that includes the necessary libraries, or try to link them statically.
I find that discussion very interesting. I use an old computer for my development. That way I make sure my game will run smoothly on most computers, and perform awesomely on newest ones. My game runs at 100 frames a second or so on my PC. Was I ever pleased when I tested my game on my girlfriends PC. I had a whooping 2200 frames a seconds! And her PC is 3 years old, running Windows 7. Mine btw is 7-8 years old running XP. I think it just makes sense to use a slower machine to develop (and test the game periodically on other machines). Not only for speed but for video card features as well. I'm aware I'm not helping you with your immediate issue here, but wish you best of luck and patience in having your game runs smoothly on older machines. Cheers!

Site: Hexmind.com Twitter: @HexmindGames Facebook: /hexmind Working on upcoming game, Reapertom.

There is a way to make sure you code runs on majority of pc's: use an engine. With a well written engine, most of the pc to game interaction is abstracted so that in order to make sure your game runs on a lot of pc's simply test an engine by itself to see how it handles different fallbacks in cases where a function is not supported etc. You can try to write such an engine yourself but to ensure system wide compatibility you would have to be very knowledgeable in multiple API's and be sufficiently knowledgeable of the particular OS that you're working on (even if the os is a part of windows family). So it's highly suggested to forgo building such an engine and use an already available one. I'm currently starting to learn Unity and so far loving every bit. Not only will your code most likely work on 95% of machines that support Unity (and it's been tested on millions and millions of machines by now) but you can also add a grantee* that it will work on Mac, Android, iPhone, Flash Player, and Linux starting in Unity 4. Not sure if it's the answer you're looking for since you probably want to stick with dealing with a raw API and doing everything in c++ but I'm simply saying that yes it's possible to a certain degree using certain tools.

You didn't come into this world. You came out of it, like a wave from the ocean. You are not a stranger here. -Alan Watts

This topic is closed to new replies.

Advertisement