View Full Version : Portals and pure OpenGL
princec
06-20-2005, 01:30 AM
What's the score? Will they take it or not? I'm far too busy to figure out how to write a software renderer, and even if I did, it'd never manage even a tenth of the speed the h/w renderer does, and to boot I'd have to redesign the entire way most of my games are written.
Trouble is I've got this portal-tastic game that I'd quite like to write (which makes it rare for a start) and it'd be a shame if they couldn't be bothered to deal with driver requirements.
Cas :)
Robert Cummings
06-20-2005, 02:05 AM
Could have a bash with the popcap framework. Doesn't get simpler than that...
princec
06-20-2005, 02:19 AM
That's a no-go; I've built up a pretty nifty infrastructure and class library that fairly blows Popcap's amateurish efforts into the weeds :D I want to "leverage" my existing assets not go starting all over again from scratch.
Cas :)
Savant
06-20-2005, 05:09 AM
So what sort of answer are you looking for? It seems like anything short of, "Yeah, go for it!" will be shrugged off. :)
If you're looking to do a small portal game, the PopCap framework would seem like a great choice. You'd get to take a bash at someone elses code and expand your horizons somewhat AND at the end you'd have a game that runs on the crappiest of systems.
If you ended up despising their framework, well, you'd just go back to your code base for your next game.
Sounds like a win-win to me.
Vectrex
06-20-2005, 05:21 AM
well I haven't seen your code but, it *might* be worth taking a look at popcap's framework and seeing what the possibility of ripping their abstraction layer out and into yours... I know it's a long shot being ones c++ and all, but really, the gfx end is pretty straight forward for 2d stuff.
princec
06-20-2005, 05:30 AM
I absolutely need to maximize results versus time spent and if it means using some other codebase, that's right out, I just don't have the time or inclination. What I'm getting at here is: has anyone ever had any success with OpenGL only games on a portal?
Cas :)
mahlzeit
06-20-2005, 06:23 AM
Maybe you can derive that info from the list of top 10 sellers (http://forums.indiegamer.com/showthread.php?t=2337) and by looking at the games the portals carry. So have fun downloading all of these games and seeing whether they link to opengl32.dll. :)
Yarlen
06-20-2005, 07:40 AM
I wouldn't consider OpenGL only to be a drawback personally. It's not like ATI and Nvidia don't support OpenGL in their standard drivers, so just about everyone should have them by default (unless their PC is extremely old).
princec
06-20-2005, 07:54 AM
Regardless of likelihood I've found that about 35% of "random Joes" downloading my game don't have drivers. I wondered whether portals are willing to ignore that if the game's a good un in the first place or whether they flat out reject anything that doesn't run on >99% of systems.
Cas :)
Robert Cummings
06-20-2005, 07:56 AM
As a rule of thumb, the more casual your title is, the more likely you'll find someone with problems using opengl.
They'll take it, but under protest. Hardware accelerated opengl is the worst-case scenario for casual games. Ideal is software and hardware dx7.
You're being stubborn and you should just look into getting a fast compatible DX7 hw accelerated quad engine up and running.
princec
06-20-2005, 08:24 AM
No, not stubborn, just cherry picking. I don't know the 1st thing about DirectX, I haven't got time to learn it, I haven't got time to write a decent Java wrapper, I haven't got time to write a layer to abstract them all away, I haven't got time to test it all as thoroughly as my current system, etc.
Cas :)
Robert Cummings
06-20-2005, 08:33 AM
Well I'm sure it's still worth making the casual game regardless... They should accept it but there will be a % of people who can't run it. How many, I have no idea.
If anything you could be breaking the mould, why not go for it?
Mike Boeh
06-20-2005, 08:52 AM
Wik is the only OpenGL game I can think of that I ever saw on the portals. And they quickly switched it to software 2D mode...
I'd say the chances are not good, and that you should find an alternative, even if it is "amateurish".
Dan Prigg
06-20-2005, 09:10 AM
I would say that OpenGl games are just more difficult to deal with. Its usually has nothing to do with Open, it has to do with the fact that the games doesnt look "pretty" enough mostly. Also just be prepared to deal with massive amounts of bugs and system issues. OpenGL is a pain without a doubt for distributors, but a good game is a good game, so bottom line: portals would take it.
Dan
Jack Norton
06-20-2005, 09:27 AM
Betty's bar is made with opengl,is very casual game, and I saw it on every portal possible in the world (well except Real).
patrox
06-20-2005, 09:30 AM
Wik is the only OpenGL game I can think of that I ever saw on the portals. And they quickly switched it to software 2D mode...
well you can't really compare A puppy title that costs couple thousands ( and probably most of it is cas' time ) to make, and Wik that cost 300 000$. ( Honestly i don't even know how they reached that number, in most normal countries you could easily retire with that amount, maybe they all have PC made out of gold :D .)
The real question is how many units is enough for cas compared to his initial investment. For Wik it wasn't enough so they had to switch to maximize their return of investment. for Cas it might be more than enough to sell 1000 games a year.
Will they take it, i think they will if the game is good. it doesn't cost them much to at least try it for a week or on a trial market before full exposure.
pat.
ggambett
06-20-2005, 09:34 AM
Betty's bar is made with opengl
Hmmm, nope, BBB is done with SDL. SDL does have OpenGL bindings but BBB doesn't use them - it's just software/DirectDraw rendering.
princec
06-20-2005, 09:40 AM
Dan P. has suggested there will be a nightmare of driver issues and bugs but seriously, I'm not encountering them any more. Literally 35% of users simply get a dialog now telling them to get new drivers and 64% of users can just play without a second thought. My code has evolved for years to cope with it all and I've put in every workaround in the book just to be sure.
And Pat is dead right; I'd be completely happy with few thousand sales on Real simply because our games only cost a few thousand bucks to make. As it is Real would be looking at a potential 50% drop in earnings from a GL based game though: but it's not their problem, it's mine - if I'm in competition with non-GL based games that are pulling in more money by virtue of running on 50% more systems I'd better figure out a way of getting 50% better conversion rate.
Cas :)
Sybixsus
06-20-2005, 09:53 AM
Literally 35% of users simply get a dialog now telling them to get new drivers and 64% of users can just play without a second thought. My code has evolved for years to cope with it all and I've put in every workaround in the book just to be sure.
How do you manage that? How can you tell if it's failing or not?
For example, not so long ago I had fairly recent ATI drivers installed ( 9700 Pro too, so not ancient ) and when playing with a little OpenGL 1.1 code, I couldn't understand why I couldn't see any textures on any objects. Finally I gave up, assumed I just had no clue about OpenGL programming and forgot about it. A week or so later I installed a driver update to fix some crashing problems with 3dsMax's OpenGL driver and wondered whether the update would have made any difference to anything else. Sure enough, two OpenGL engines I was testing for friends suddenly started working and my own OpenGL code now displayed textures. Now I can't speak for the engines because I had compiled versions, but my code was returning no error codes anywhere, it just wasn't showing textures.
The other engines were doing all kinds of weird things like stuttering every second. Maybe they could have detected an error somewhere, but I'm doubting it.
ggambett
06-20-2005, 10:07 AM
Dan P. has suggested there will be a nightmare of driver issues and bugs but seriously, I'm not encountering them any more. Literally 35% of users simply get a dialog now telling them to get new drivers
I still think most of that 35% just abandon the game...
And Pat is dead right; I'd be completely happy with few thousand sales on Real simply because our games only cost a few thousand bucks to make.
Sure, but why would Real be interested in distributing a game that sells just a few thousand sales, when they can use that same bandwidth to distribute a game that sells tens of thousands of copies? That's what happened to FaceIt. I think Real had it for two weeks, didn't sell, and disappeared into oblivion.
patrox
06-20-2005, 10:34 AM
I still think most of that 35% just abandon the game...
Sure, but why would Real be interested in distributing a game that sells just a few thousand sales, when they can use that same bandwidth to distribute a game that sells tens of thousands of copies? That's what happened to FaceIt. I think Real had it for two weeks, didn't sell, and disappeared into oblivion.
quiz:
1)they need free games to offer for their new "get a free game" trial.
2)it's hard to find decent content.
3)they need diversity
4)they need new things to keep customers to log back in and click on the ads. ( so even a game that doesn't sell generates revenues )
5)bandwidth is cheap ( they probably have unmetered servers anyway )
6)puppygames rules
pat.
quiz:
1)they need free games to offer for their new "get a free game" trial.
2)it's hard to find decent content.
3)they need diversity
4)they need new things to keep customers to log back in and click on the ads. ( so even a game that doesn't sell generates revenues )
5)bandwidth is cheap ( they probably have unmetered servers anyway )
6)puppygames rules
pat.
1) the free game offer is actually a free month to gamepass, which entitles the customer to one free game every month. the customer picks whatever game they want from the current selection real offers. they don't have or need special games to give away for free. In most case these special free games would be shit (like the free one Big Fish Offers). Games that just don't sell so I assume they pay a low price to use them to help increase their site's stickiness.
2) How does that apply to a game that sells only a few thousand copies compared to one that sells tens of thousands of copies. Surely the better selling title has more quality.
The rest of your points don't really have any meaning on the argument. Sure bandwith is cheap, puppygame rules etc... but they can only add so many games a week without oversaturating, why would they choose a game they know is going to sell only a thousand copies over one that will do much more.
For Cas:
Maybe look into getting someone experienced with DirectX to port your OpenGl code over. Your gfx code should be decoupled from everything else so it shouldn't be too big of a problem..
Sillysoft
06-20-2005, 11:52 AM
You have the game. I say just send it to them and see if they take it. If nobody wants it as-is then you could think about other options. Cross that bridge if you come to it.
Bad Sector
06-20-2005, 11:57 AM
and when playing with a little OpenGL 1.1 code, I couldn't understand why I couldn't see any textures on any objects.
You indeed was doing something wrong. OpenGL 1.1 is way too simple and well tested. Graphical glitches could happen by bad drivers - but not complete absence of textures, especially for a so recent graphics card. The fact that other people's engine were having the same problem means nothing - they could be using wrong patterns too (f.e. many people learn OpenGL by reading NeHe code - ask any person who really knows about OpenGL and graphics programming and he'll tell you that NeHe tutorials have enough bugs to not be that good).
Here is a personal experience. I was writing that OpenGL code. It was working ok with my computer. It was working ok with my second computer and it even worked ok with my father's Voodoo 3500tv-based computer with some weird drivers i found over the net.
But it was NOT working in a friend's computer. After a lot of frustation i decided to do write something like:
frame++;
while ((error = glGetError()) != GL_NO_ERROR)
recordError(frame, error);
at the end of my main loop, after calling the render() function. Guess what... OpenGL was indeed reporting errors - in all of the test machines. It's just that my machines was working around it, while my friend's was not :-).
The moral is: don't blame OpenGL. It's a well-established, proven API. It is very well designed and supported almost everywhere (well, the only OS i can think that doesn't support a basic OpenGL 1.1 implementation is DOS - and even that can be argued because of Mesa's software implementation). Blame the coder. 99% of the cases is coder's fault :-).
...and don't be so sure about this 1%... ;-)
luggage
06-20-2005, 11:59 AM
Cas - do you have any figures on how many of the people who don't have GL drivers actually go and get them? Do you log the fact that they didn't have them and then if they play it again later and it works do you keep track? You could work out a (very) rough idea on how many people just think "bugger it" and go away to play something else that will work.
--Edit--
Oh. And I agree with SillySoft. You have it now so submit and suck it and see.
princec
06-20-2005, 12:01 PM
How do you manage that? How can you tell if it's failing or not?I just know ;)
Cas :)
You have the game. I say just send it to them and see if they take it. If nobody wants it as-is then you could think about other options. Cross that bridge if you come to it.
This is really good advice. See if the portals take it. If they do wait and see the reaction. If you need to port it to make more sales do it then.
soniCron
06-20-2005, 12:10 PM
If you need to port it to make more sales do it then. And if they drop it before development is over?
princec
06-20-2005, 12:24 PM
Cas - do you have any figures on how many of the people who don't have GL drivers actually go and get them? Do you log the fact that they didn't have them and then if they play it again later and it works do you keep track? You could work out a (very) rough idea on how many people just think "bugger it" and go away to play something else that will work.Yes and yes. Let's just say that about 1% of those without drivers will bother to get the game to work by downloading new ones, and of those 1%, 0% will buy the game anyway. There seems to be a strong correlation between people buying the games I write and people who already have drivers...
Real don't want Ultratron that's for sure. Apparently keys are the death of it though. That's to be expected though, I wasn't aiming Ultratron at the casual games crowd. But it wasn't rejected for OpenGL reasons...
Cas :)
princec
06-20-2005, 12:26 PM
Dead right, and probably the main reason I don't want to go switching to something completely new. I've spent over 3 years making my graphics code work flawlessly. Yet at least half the games I have tried from indies here on this very forum don't work properly on most of the machines I have access to.
I'll give you a tip here but the OpenGL ones always work flawlessly; it's the DX ones that fail...
Cas :)
Savant
06-20-2005, 12:30 PM
From a practical standpoint, "I've invested years in this" isn't a valid reason for hanging onto something. If OpenGL is a problem (and we know it is) and Java is a problem (and, again, we know it is), logic would dictate that maybe it's time to try something else.
ggambett
06-20-2005, 12:33 PM
There seems to be a strong correlation between people buying the games I write and people who already have drivers...
Another way of seeing it is that just by changing the underlying technology, your potential market increases by 50%. Without changing the game in the least bit, which I know it's important for you, and I respect that. I'd do it without hesitation.
luggage
06-20-2005, 12:35 PM
Yes and yes. Let's just say that about 1% of those without drivers will bother to get the game to work by downloading new ones, and of those 1%, 0% will buy the game anyway. There seems to be a strong correlation between people buying the games I write and people who already have drivers...
Real don't want Ultratron that's for sure. Apparently keys are the death of it though. That's to be expected though, I wasn't aiming Ultratron at the casual games crowd. But it wasn't rejected for OpenGL reasons...
Cas :)That's quite interesting. 1% sucks. I guess it shows just how fickle our audience actually is.
Have you thought about just putting a cross hair controlled by the mouse that people can just point and shoot with? Have your character in the middle of the screen and it doesn't move. Not the same game I know but you still get the satisfaction when you shoot something and it'd be a cinch to play. For half hours work it may be worth a try.
princec
06-20-2005, 12:36 PM
You're jumping the gun a bit there. There are no problems with either of them in my games. See? My games work. I've taken 3 years to figure out how to do it so reliably it puts many retail games to shame.
Cas :)
And if they drop it before development is over?
then you obviously wouldn't port it. it would have to be doing pretty bad for them to drop it... obviously you wouldn't waste anymore time developing a dud.
Savant
06-20-2005, 12:42 PM
You're jumping the gun a bit there. There are no problems with either of them in my games. See? My games work. I've taken 3 years to figure out how to do it so reliably it puts many retail games to shame.
Maybe I'm misremembering then, but from what I recall every time you post a new game it's followed by a series of posts from people who can't launch the JVM and whatever else goes wrong. Now, maybe that's becoming less of an issue these days because the people here have Puppified their machines to run your games - if that's the case, that's even more dangerous from a testing standpoint.
If you're happy, that's great, but historically the API and language you've chosen have caused countless problems.
princec
06-20-2005, 12:44 PM
The problem is it'd take me another 3 years to get it to the same level it's at now at the rate I can afford to do it. So: I've got all this stuff, and it works. I also would like to point out it runs unmodified on the Mac which is something of an advantage. If it fails on one platform it invariably fails in the same way on another platform which is nice.
Cas :)
princec
06-20-2005, 12:46 PM
No, really, you're just making this up. It's suffered counted problems, and each was easy to solve, once and for all. They're all gone. There may be the odd issue with Webstart but I don't use Webstart for deployment generally, just during testing.
Cas :)
Savant
06-20-2005, 12:50 PM
No, really, you're just making this up.
*shrug* OK, best of luck then! I hope you're right.
soniCron
06-20-2005, 12:54 PM
There are no problems with either of them in my games. See? My games work. I've taken 3 years to figure out how to do it so reliably it puts many retail games to shame. I don't know anyone is suggesting your games are at fault. "I built a car that runs on gasoline more efficiently than anything! What? Nobody sells gasoline anymore? Screw it, I developed it, I'm selling it!"
princec
06-20-2005, 12:55 PM
Try it and see :)
Cas :)
princec
06-20-2005, 12:57 PM
Oh but they are. General concensus of opinion: java+opengl=disaster. Actual fact shown: java+opengl=reliable but 35% of Windowsy people don't get to play. Sadly still no-one has any stats for DX games.
Cas :)
Bad Sector
06-20-2005, 01:13 PM
From a practical standpoint, "I've invested years in this" isn't a valid reason for hanging onto something. If OpenGL is a problem (and we know it is) and Java is a problem (and, again, we know it is), logic would dictate that maybe it's time to try something else.
Okay, Java, i can understand it - it needs a separate download to run and people may not want to do it.
But can someone explain me why OpenGL is a problem? If you use the API right i think it is not.
OpenGL is available since Windows 95 (actually it was since Windows NT, but well, who uses NT anymore?). Major support is there since Windows 98 (actually since Quake 2 and Half-Life came out :-) lets say around 1997-98). Every decent card since then has OpenGL support to do at least what Quake 2 did. What more you want for a 2d game? And even if you do, who is going to use a Pentium MMX (or one of the first P2s) to run the game? I mean you have greater chances to be limited in CPU than in GPU.
Non-existant OpenGL support? Okay i needed to install drivers for my father's Voodoo 3500tv - Windows XP by default didn't had drivers. But this is a very old computer (6 years old). And even if it wasn't, WinXP eats all the memory that a game may need, so in that case a game will be memory limited. Let alone CPU.
Every computer that is been bought the last five years comes with all drivers pre-installed. This includes those nVidia TNT/TNT2 cards which were quire popular back then and -IIRC- they were able to produce realistic stencil shadowing (there is a demo at the nVidia developer page that does that). What more you may need? But also it includes some arcane S3 wanna-be-3d cards. An old crappy S3 i had was able to produce around 10000-15000 triangles per second. Isn't that enough for a 2D game? With proper coding, it is.
I just visited a random internet computer store (typed computer store at Google). One store had a TNT2-based card (http://www.tigerdirect.com/applications/SearchTools/item-details.asp?EdpNo=994992&CatId=28) for $10! If someone can't afford to pay that price to buy a video card, then how is (s)he supposed to pay in order to buy your $19.95 (or $9.95) game?
And let's just say that all players knows zero about computers and they pray before they press the Start button. If they are in this "level" then they probably got their computer recently - at least no more than three years ago. We're in the "good gfx card" range. Three years ago we had GeForce4mx as the best-good card and GeForce2 as the popular-cheap card. If you were too "lucky" you could also find a GeForce 256 or TNT2 - just in case someone had a stock of them.
If someone has a computer for at least three years then, at one point (s)he may think about upgrading it - even a bit. In the least years, you can't just upgrade a single part of your PC - usually you need to replace at least your motherboard, memory, cpu and gfx card (sometimes you can get away with that - if salespersons let you of course :-P). So you may end with a low-priced card. But let's see what today's cards are lowpriced. One that comes to my mind is GeForceMX4000. It was around 40 euros three months ago i looked in a local store. And if it has at least the horsepower of a GeForce2mx, it is enough.
Now take a look at all the mentioned cards: all of them are capable of correct OpenGL support - with the default drivers!
When an OpenGL program A runs with the default drivers while B needs a newer version then something wrong is with B. The newer drivers just are better on working around at the problem.
So when a coder says "upgrade your drivers", he probably means "i'm too lazy to fix my code - the latest drivers do that for me, so go get them" :-). I don't mean that there aren't buggy drivers. There are lots of bugs in them (especially now that companies like to give a multimegabyte driver set for every single gfx card they made the last decades).
However if someone else's program runs without the need of an "upgrade" and yours doesnt - which you both use the same API (and version), who is responsible? The drivers or you?
My vote is you.
Now about the portal's top-ten. I truly don't think it's about OpenGL vs non-OpenGL. It's about the content. The game. These games simply are more fun than the others. Does it have to do with OpenGL? I don't know, but there is a slight possibility that yes, it has. For example i've seen that for "an unknown reason" OpenGL-based games are larger in size, thus making less downloads. However this is not the API's problem; it's the programmer's problem because (s)he doesn't know how to do proper resource management.
Another possible reason that OpenGL-based games are not frequent in top10s, is their quality; it's easier to do a 2D game in OpenGL than in DirectX (or -in some cases- SDL). So more coding "newbies" (i don't have anything against them; i once was one, but that doesn't mean that they don't lack the experience and knowledge that it is required) are using OpenGL for their -bad- games than others. Again, i don't say that every OpenGL-based game is bad or is written by a bad coder - i just say that it's more frequent to see bad coders using OpenGL for bad games than the opposite. Do a google search :-).
Having said all the above, my framework doesn't use OpenGL - yet (it's designed in such a way that i can put whatever API i want underneath it) :-D. However all my tools and a lot of code i write is based on OpenGL. And i'm seriously thinking to add OpenGL support to my framework.
a key goal when making a game for the casual audience is to have the biggest possible reach. that includes catering to people running older computers.
Also... my computer is around 3 years old. It has never played games that use OpenGL all too well. It will slow down my computer til it's unplayable. I'm sure it's just a driver problem but I'm not about to go bother with it when I can get many games that will run perfectly without me having to lift a finger. The typical user mentality will be even more "lazy" than mine.
If you haven't made the game yet, I'd suggest you use the PopCap Framework. It's very highlevel, you don't need to touch any DirectX. If you know C++ it should be a snap.
No shame in using someone else's "amateur" tools. The user doesn't give a flying fuck how the game was made or how slick the code is. They only care that it works without any problems and that it is fun...
Jim Buck
06-20-2005, 01:57 PM
But can someone explain me why OpenGL is a problem? If you use the API right i think it is not.
Search on the forums for this.. it's been discussed a few times. It's not the API (I love it too!). It's the drivers.
Bad Sector
06-20-2005, 02:13 PM
It wasn't supposed to be a real question :-) i know OpenGL is not a problem (drivers is a possibility but not as large as some make it look like). Read the rest of the post ;-)
I'll just add a couple of points.
Unrepresentative sample of one (my machine. Radeon 9000) Fullscreen OpenGL programs reboot the computer on exit. Gish plus others are a bit of a pain because of this. Latest drivers haven't helped. Direct3d works fine. therefore having an ATI card isn't an assurance of compatability.
BlitzMax does OpenGL. Played a casual (not in the wild yet) Blitz Max game. Very nice to play. Rebooted my machine on exit. There may be more OpenGL casual games because of BlitzMax. At the very least this may result in stats on how much sales are affected.
OTOH my Blitz3d game (directx) has a menu display that appears black on a bunch of computers for no good reason.
Bad Sector
06-20-2005, 02:32 PM
Problems will always exist.
Since -as you said- the 'reboot' doesn't happen because of drivers (you said you've updated them) then it may be some damaged DLL in your system that gets used by the OpenGL drivers (but they don't replace it).
In theory, no normal program can just reboot the PC because it runs in a different priviledge level. This means that only ring 0 software can cause the reboot (the os itself and drivers) - or faulty hardware.
This is the case with my PC. After some time running an OpenGL (or Direct3D) application my computer hangs. Why? Well, i thought about memory, under-supply of power, etc, but it was just a "simple" overheating problem :-). A 20" fan near the computer with the case open solved the problem :-P.
Now i have another problem with Windows - while working they show quickly a bluescreen and reboot. I tried everything i could think of - i even formatted the whole partition and reinstalled windows three times (i also tried Windows 2000 instead of WinXP). The problem is still there. I managed to figure out the cause: my SBLive! card wants an IRQ line for itself, but my motherboard forces the card to share it with the firewire controller. Disabling the controller didn't fix the issue. I found out that i need to get some better drivers to fix this - being behind a 56k modem, i refuse to do that temporary, so i work on Linux (windows doesn't even boot anymore).
Robert Cummings
06-20-2005, 02:35 PM
See? My games work. I've taken 3 years to figure out how to do it so reliably it puts many retail games to shame.Thing is, the casual market is so different from retail hardware wise that it isn't even funny.
You're going to find an even bigger gap still as your current userbase is hardcore only. A crowd with a usually better pc setup than anyone else. So that 35% is going to get very big.
Success has eluded you so far, and this might be why. You want bite the bullet, get a strong (even SDL) software renderer done. Those are VERY quick, easy to code and reliable by default. By software I mean straight blitting: forget alpha, forget scaling, so long as there's fallback from opengl... That would not take you more than a few nights to set up... Might just be worth it.
Sybixsus
06-20-2005, 02:47 PM
You indeed was doing something wrong. OpenGL 1.1 is way too simple and well tested. Graphical glitches could happen by bad drivers - but not complete absence of textures, especially for a so recent graphics card. The fact that other people's engine were having the same problem means nothing - they could be using wrong patterns too (f.e. many people learn OpenGL by reading NeHe code - ask any person who really knows about OpenGL and graphics programming and he'll tell you that NeHe tutorials have enough bugs to not be that good).
Here is a personal experience. I was writing that OpenGL code. It was working ok with my computer. It was working ok with my second computer and it even worked ok with my father's Voodoo 3500tv-based computer with some weird drivers i found over the net.
But it was NOT working in a friend's computer. After a lot of frustation i decided to do write something like:
frame++;
while ((error = glGetError()) != GL_NO_ERROR)
recordError(frame, error);
at the end of my main loop, after calling the render() function. Guess what... OpenGL was indeed reporting errors - in all of the test machines. It's just that my machines was working around it, while my friend's was not :-).
The moral is: don't blame OpenGL. It's a well-established, proven API. It is very well designed and supported almost everywhere (well, the only OS i can think that doesn't support a basic OpenGL 1.1 implementation is DOS - and even that can be argued because of Mesa's software implementation). Blame the coder. 99% of the cases is coder's fault :-).
...and don't be so sure about this 1%... ;-)
You missed the point of the entire message. The point was that you cannot always tell in code whether things are working or not. Sometimes things just silently fail. Cas's careful sidestepping of the question confirms as much.
As for my code and the engines, each had completely different problems, all of which were resolved with no code changes and a driver update. One could be coder error but three completely unrelated issues resolved with no code change is a bit too much of a coincidence.
Bad Sector
06-20-2005, 03:05 PM
You missed the point of the entire message. The point was that you cannot always tell in code whether things are working or not. Sometimes things just silently fail. Cas's careful sidestepping of the question confirms as much.
Well, in most cases you can.
For example, about the above textures problem you could do this to be ultra-robust: upload the texture, test (with glGetError) if everything went ok and if everything is ok, try to download it. Compare it with what you've uploaded. If they're ok, then the texture is ok. If not, try to upload it in a different server-side format. Try until it doesn't give you a chance :-). At that point just fail out :-P.
In usage: use glBind correctly. It is possible that some OpenGL implementation to not support some texture targets, namenly GL_TEXTURE_RECTANGLE_ARB. In that case, write some workaround code an don't use texture names directly. Instead use a Texture structure and hold the target with the name and "logical" texture size. When i say logical, i mean the bottom-right corner of the texture according to the texture target. This will be (texture_width,texture_height) for GL_TEXTURE_RECTANGLE_ARB or a computed (x,y) in the range 0..1 for GL_TEXTURE_2D in the case texture rectangles are not available.
That's what i could think about the topic right now...
The only thing i can think that cannot be robustly (cross-platform-ly :-P) verified using plain OpenGL calls is if the rasterization is done in hardware or software. But even this is possible to figure out by doing some scene renders and measure the speed: If it's below a threshold, it's software - else it's hardware. Software OpenGL rasterizers tend to be awfuly slow, so it won't be that hard to measure that.
princec
06-20-2005, 03:20 PM
Sorry - I didn't mean to sidestep the question:
I precisely know that 35% of machines put up a dialog box to the user, and 64% of them work. I'm guessing at 1% figure of cases I have somehow failed to catch but I have yet to come across a machine which did not manage to send me a log the second time the game is run after a hard crash so that's very pessimistic.
Cas :)
princec
06-20-2005, 03:26 PM
No, it's not got anything to do with the success of my games... that's to do with the fact I don't write games for the casual player and finding the target market is tricky.
See how rapidly we have careered off topic!
Screeching back round on topic, basically this is a summary of the thread so far:
Using OpenGL will not neccesarily detract from your success on the portals however you have to have a 50% greater conversion rate than the competing titles to make up for the 50% fewer machines that the game will run on. Reliability of OpenGL is not at issue here as it is pretty much bang on as reliable as anything ever gets if you know how to code it properly.
Currently Ultratron for example is enjoying a CR of 1.5% which ain't too bad considering it needs 8 fingers to play :) To compete versus any portal titles, they'd have to have a CR of 1% or less before a portal would see more money coming in off of Ultratron. The GL-ness of Ultratron is largely irrelevant to the portals, all they care about is the CR and opportunity cost.
So I've got this portal-tastic idea, and it's going to be GL based: can I beat a CR of 1%? What games, say, in the top ten on some portal have a CR less than 1%?
(Probably not many but then I'm expecting that the forthcoming Puppygames productions will outsell Ultratron 4:1 or so)
Cas :)
luggage
06-20-2005, 05:45 PM
i know OpenGL is not a problem (drivers is a possibility but not as large as some make it look like). Bad Sector: Read what Cas has said. 35% of people can't play his game at all because of not having Open GL drivers. How much larger can it be? (well - another 65% for a start I guess).
I'd be pretty alarmed if 35% of windows users were unable to play my game.
soniCron
06-20-2005, 05:53 PM
Using OpenGL will not neccesarily detract from your success on the portals however you have to have a 50% greater conversion rate than the competing titles to make up for the 50% fewer machines that the game will run on. False. It will "detract from your success," and that is why you need to have a 50% greater CR (according to your numbers). Looking at it another way, you'd make 50% more if you updated your framework.
Reliability of OpenGL is not at issue here as it is pretty much bang on as reliable as anything ever gets if you know how to code it properly. False. OpenGL itself is "bang on" reliable, but lack of driver support and frequency if incorrectly installed or updated drivers in Windows break OpenGL support far more frequently than DirectX driver problems.
That said, writing a software renderer is pointless for you (and I think you know that). However, utilizing Direct3D as a backup renderer would be strongly recommended. No fancy hand-coded blending, no problems with unworking GL drivers, and I don't think you care (nor should you) about folks that have pre-TNT2 class video. It'd be worth the extra few days to setup Direct3D and use it to draw sprites, if OpenGL fails.
It depends on how you want to look at it. Lose 50% sales made up by 50% more CR, or make 50% more with greater compatability. Glass half-full or glass half-empty. (Or, in this case, glass full or glass full-and-a-half.)
EDIT: Cas, just noticed you said, "(drivers is a possibility but not as large as some make it look like)." Have you got the data to back this up? If that's the case, I'm sticking with OpenGL and I'll not bother with DirectX at all! ;)
svero
06-20-2005, 06:21 PM
I think the comments about real not wanting to waste bandwidth on a low seller are right on the mark. If a game doesn't sell as well for whatever reason they either won't release it after beta testing or it will die a quick death on the site. Real doesn't have any problem finding new games to promote so its a question of which games they choose. I don't know how compatible your game is relative to say.. some other game like chuzzle, but thats what the beta testing real does is all about. To determine how it would do relative to an average game. At the end of the day they'll decide based on the numbers and how you feel about OpenGL one way or another won't matter.
Bad Sector
06-20-2005, 06:40 PM
Bad Sector: Read what Cas has said. 35% of people can't play his game at all because of not having Open GL drivers. How much larger can it be? (well - another 65% for a start I guess).
I'd be pretty alarmed if 35% of windows users were unable to play my game.
Is this 35% of windows users potential customers? As i said above, if those users can't afford getting a card capable of playing 2D OpenGL games, they won't be able to afford buying your game. But let's say that people doesn't have drivers in their PCs. Personally, last time i checked, my computer was close to unusuable without graphics drivers - i mean i was stuck at 640x480 in 16bit color under XP (and 4bit color 640x480 in Windows 2000). WinXP/2K simply doesn't include drivers. This is what you get since acceleration came in: Windows support only basic VESA modes.
So people will have to have their gfx card's drivers installed - or not being able to play ANY game (except if you plan to put GDI support too - but the speed will be awfully low).
Of course nothing stops you from adding OpenGL, Direct3D, DirectDraw, GDI and console-based graphics using aalib (http://aa-project.sourceforge.net/aalib/).
EDIT: Cas, just noticed you said, "(drivers is a possibility but not as large as some make it look like)." Have you got the data to back this up? If that's the case, I'm sticking with OpenGL and I'll not bother with DirectX at all!
I was the one said that. The post is above... and the large one above it explains everything, i think.
soniCron
06-20-2005, 06:54 PM
II was the one said that. The post is above... and the large one above it explains everything, i think. Ah, ok. I thought you (well, actually, Cas, who doesn't usually talk out of his ass) had numbers and other data, not just speculation. In that case, you've obviouly got no clue how the OpenGL driver system works. I'd recommend you search the net for some information on the internals of OpenGL, and you'll understand why drivers are such a problem. You're speaking almost entirely about a black/white scenario, which this is not. It's not:
User has no video drivers or
User has no hardware accelleration
Someone with a pre TNT2-class card probably won't be able to run software alpha blending, so that's not the issue (adding software emulation, that is). On top of that, I don't care if you can get a GeForce4 Ti for $9.95, if the ICD isn't installed correctly (which happens AN AWEFUL LOT), then you've got no OpenGL support. Period.
Windows comes with many (many, many) DirectX hardware drivers pre-installed. It does not, however, come with OpenGL ICDs pre-installed. So you can have a fully working Windows experience with no OpenGL support, even if you've got the best damn OpenGL card out there. It even happens every so often with DirectX, which is why you're supposed to reinstall it if you've got issues. However, there's no "OpenGL installer" out there, which is why it's up to the supplier of the video card drivers to handle the OpenGL drivers.
While I sympathize with your huge post, it's almost entirely (if not entirely) blathering ignorance. Please search the web for more information about common pitfalls of using OpenGL on a Windows system.
As i said above, if those users can't afford getting a card capable of playing 2D OpenGL games, they won't be able to afford buying your game.
this statement doesn't apply to the casual audience. if may be that they aren't willing to have to buy a new gfx card to play your game... and why would they when there many other games they could play that won't involve (repeating myself) them lifting a finger to get it working.
luggage
06-20-2005, 07:11 PM
Is this 35% of windows users potential customers? Yes! They have downloaded the game and tried to run it - how much more potential need it be?
Besides - everyone is a potential customer. Some just have more potential than others.
PeterM
06-21-2005, 01:59 AM
Whether or not to use OpenGL could be one of those issues that people will just never agree on.
If Cas isn't targetting casual gamers, I believe he can expect them to know how to install drivers. However, I wouldn't expect them to track drivers down and install them just to play a game demo that may or may not be good. I wouldn't. I hate installing drivers and stuff when my PC is running ok as it is.
As for casual gamers, like my Mum the Bejewelled addict, there's no way they'll have OpenGL installed if they have XP. She doesn't know about drivers, doesn't know about graphics cards, and has a crappy modem connection which will stop her downloading the massive (25mb for my Radeon!) driver files. Unless the drivers are preinstalled (or installed by a friend) they won't exist.
When Mum got Bejewelled, the first thing she asked me is "how can I play this during lunchtimes at work?". I suspect a lot of people play casual games in work. Obviously being an office worker, she doesn't have admin rights on the PCs there to install drivers.
If I were writing a casual game, I'd probably use SDL and just 2D blitting. But that's just me.
If I were writing a hardcore game, I'd use OpenGL (the only choice for the Mac version anyway) and write a Direct3D7 renderer to fall back on under Windows, if the OGL renderer fails to initialise.
Oh, also, someone on the forum has a good driver detection utility which can be bundled with games, which may help, if it can say "oops, your drivers need updated, click here to install them".
princec
06-21-2005, 02:45 AM
There's still a bit of confusion about the thrust of this thread from soniCron and Bad Sector, neither of whom are quite on the mark here.
Here's a few facts - and by facts I mean I've got actual hard data to back it up:
35% of all Windows users do not have video drivers, or have broken drivers that don't work. This is almost a totally completely random sample as well. No effort has been made to specifically target "hardcore" or "casual" gamers. It's just random Joes of TEH INTARWEB.
Of that 35%, a tiny bunch will bother to do something about it, or are able to. It doesn't matter about why or why not or should or should not - this is the actual fact. The reality. No arguments, no discussion. You may be able to coax a few more*
Apropos portal game using OpenGL: by the definition of the portals' target marget, these figures are statistically invariants - they're not going to change just because it's a portal game, and the bottom line is, 35% of the portal customers who download such a game will fail to get it to play (however it has to be stated that they almost all will get a meaningful response from the game to tell them why).
The thread question was: would a portal take an OpenGL game, if 35% of their customers can't play it?
The most meaningful response so far is: they took Wik, presumably because Wik's original CR was at least 50% better than the then-current #10 spot; but the Wik guys decided they could do 50% better even than that and rewrote their game to use software blitting. The end result is a product which cost them $300k to develop, which is about a factor of 100x more than my games.
My second issue was that I do not want to write a DX7 or software renderer because I don't have the time or inclination; I am trying to squeeze the most out of the technology I've got handy without wasting time on infrastructure any more. I've got a framework that rocks, now I just want to find out if it can be used in a portal situation with a forthcoming game I have planned.
Cas :)
In my case with my games I needn't bother as not a single one has ever turned into a sale.
ManuelFLara
06-21-2005, 02:59 AM
princec, I'm afraid none of us can give you a true answer, so you'll have to ask directly to the portals.
princec
06-21-2005, 03:59 AM
It's enough to know Wik had some success as an OpenGL only application.
Cas :)
ManuelFLara
06-21-2005, 04:37 AM
Well I don't know how you'd define success. But AFAIK they rushed to add software rendering just after releasing the game. I don't even know if it was after releasing it on Reflexive but before doing so on other major portals.
princec
06-21-2005, 04:42 AM
It was successful enough that they felt that spending the time on adding software rendering would increase their profits by an amount greater than that which they had to spend implementing it.
Anybody know the CR for Wik? (Before & after?) That'd be a nice figure to have.
<edit>Here's some Wik stats from that spreadsheet: 3 weeks in the Realarcade top 10, from mid-April '04 - equal to or beating 50 other titles that have also appeared on Realarcade. So: it's doable, for sure. Just one week in the top ten on Real would see me recovering my development costs completely and be completely worthwhile.
Cas :)
baegsi
06-21-2005, 05:11 AM
I'd put my long-time goal into that decision. Do you plan to focus on portals? Personally, I would find it too vague to base my decision on one game, even more since Wik's production value is out of range for us. Also, the market evolves fast. Would a OpenGLed Wik still be possible next year?
Tough decision. Sometimes, you have to kill your darlings (regardless how much time and sweat you have put into it) and take a new route. Or continue squeezing everything out of what you have already.
Vectrex
06-21-2005, 05:38 AM
well CAS how about bypassing the problem with this? OpenGL emulation layer for DirectX 9 and 8.1
Haven't tried it, but the features sound good and it can play Quake3 so I think it should handle ultratron :D
http://www.scitechsoft.com/products/ent/gld_home.php
Maybe the company would be up for either doing a bundling deal (so ultratron offers to install it if opengl isn't detected, plus you could argue your way out of paying if you played up the free advertising angle (obviously a bundle would only work for that one game)), or perhaps they have an SDK you can build into the windows version for a small fee?
Regardless I'd like to hear how it works for you (I'm on 33.6k at the mo ;) )
princec
06-21-2005, 05:51 AM
Actually I've been looking at the Scitech stuff with a view to getting on to XBox Live...
Cas :)
Bad Sector
06-21-2005, 06:28 AM
On top of that, I don't care if you can get a GeForce4 Ti for $9.95, if the ICD isn't installed correctly (which happens AN AWEFUL LOT), then you've got no OpenGL support.
But if you put this "GeForce4ti" on a computer and fire it up, Windows will be in a plain non-accelerated slow VESA mode (windows XP) or in standard 640x480 4bpp VGA mode (Windows 2K and older). Even if you have a superfast computer, you'll see windows drawing themselves when you move or resize them! In this case you have to install the drivers and as far as i know, when you buy a gfx card it comes with a CD with drivers. Also, as far as i know again, most driver installation software is a simple "setup.exe" or "driver.exe" or something like that (usually launched by a autorun.ini file in the CD).
These drivers include "OpenGL support". Once you install them, you'll have OpenGL support too. There isn't any other way to get OpenGL (some years ago it was glsetup - but that was for early voodoo, s3 and similar cards which weren't bundled with OpenGL support... today every card is bundled with OpenGL).
So you can have a fully working Windows experience with no OpenGL support, even if you've got the best damn OpenGL card out there.
If you consider the crawling performance in basic 60Hz VESA modes under Windows XP (or 640x480 in 16 colors in Win2K or older) as "fully working windows experience", then yes you can have this.
It was successful enough that they felt that spending the time on adding software rendering would increase their profits by an amount greater than that which they had to spend implementing it.
i dont think that would necesarrily be the case. when you spend 300 grand on something and it doesn't sell well because people are having problems with some of the technology you don't just leave it. You fix what isn't working. I also heard that they already had the basis for the software renderer made, so it prolly didn't take as much time as you're thinking it did.
I don't think it was a case of "well the game has sold reasonably well so let's make a software renderer to up the cr"... chances are is was more like "way too many people are having problems with the opengl so we will need to write a software renderer"
I'd face the fact that you are going to need to use something else besides OpenGL or at least have a fallback software renderer to rely on. If you don't do it now you'll just be putting it off until later.
PS. Apparently Wik didn't actually do to well. I believe it was only in the top 10 for a bit, and I don't think it ever got past the lower area.
Jim Buck
06-21-2005, 09:51 AM
For what it's worth, Wik was updated to not use OpenGL in October 2004 (http://forums.indiegamer.com/showthread.php?t=810).
Savant
06-21-2005, 10:36 AM
In fact, James lays it down right there in that thread:
"It does lots of blending and effects which were previously accelerated with OpenGL. We found that GL drivers installed on most consumer machines weren’t reliable enough and rewrote it to do all the effects in software."
soniCron
06-21-2005, 11:01 AM
If you consider the crawling performance in basic 60Hz VESA modes under Windows XP (or 640x480 in 16 colors in Win2K or older) as "fully working windows experience", then yes you can have this. 60Hz VESA modes in XP (or 640x480 16 color in <= Windows 2000) aren't the only indication of non-working OpenGL ICDs. An OpenGL ICD is a separate driver from the windows display driver (even though they're installed together nowadays), and can become corrupt or ruined in a million different ways without any indication other than a failing OpenGL application.
I will repeat myself one last time: Educate yourself about the pitfalls of OpenGL drivers and why they sometimes don't work when you expect they should. Especially with folks that don't know what a "driver" is (the typical audience of portals, which this discussion is about). In fact, I think cas made it perfectly clear, "35% of all Windows users do not have video drivers, or have broken drivers that don't work." He should know, he's run the tests. All he's asking is if he can get by with that level of incompatability.
There is no debate that there is a serious problem with OpenGL ICDs failing or not existing on target machiens. There is no debate that they should work nicely. There is no debate that most visitors of portals have the biggest problem of non-working OpenGL ICDs, because of their general ignorance of computers. There is no debate that anything in this thread about such things is anything but fact. The discussion is whether or not cas will be accepted to portals with 35% of users simply unable to run his software.
Out of the thousands of developers that visit these boards every day, not one person has disagreed with the general consensus that OpenGL drivers are a problem. Except you. And I promise you don't know more about this issue than this many professionals.
Bad Sector
06-21-2005, 11:19 AM
I do know how the OpenGL driver works and that it is a separate thing than the normal video driver (and that's why OpenGL is stuck at 1.1 in windows where every other platform has at least 1.3 - or 2.0 in my case :-)). But that means nothing... every driver, every file and every* can be corrupted. The user can corrupt the OpenGL driver, the video driver, the DirectX, the sound driver, the ... whatever.
Anyway, i will take your word about it, because i don't have any reason to not do so. However i still have my doubts about why OpenGL falls.
princec
06-21-2005, 11:35 AM
Interesting that it never got back into Real - it was in the top 10 in April 2004 for 3 weeks and that was it - finito.
Cas :)
princec
06-21-2005, 11:38 AM
Actually most GL n00bs manage to get it wrong in hundreds of different ways. In fact I fixed a bug in my own code causing a matrix stack overflow error that was entirely down to my own n00bishness. I think I've got it now down to the point where it isn't reasonable to code around any further issues.
I expect the typical GL n00b, like myself back in the day, to barely get their game running properly on an Nvidia card and then have umpteen strange problems on ATI etc etc.
Cas :)
Jim Buck
06-21-2005, 12:03 PM
I think that once you have your 15 minutes of fame on Real, that's it. There is only one shot at it in almost all cases. Hence, I assume, the reason for your posting - should you blow your wad with a gl-only game or are you screwed before even trying?
illume
06-21-2005, 06:53 PM
Use SDL. Multiplatform, very well tested and compatible, and fairly fast.
There are also java bindings around. Not sure how good they are though.
You should be able to get a nice looking game going with it. However you will still need to do some learning, and probably rewrite your games for it.
Take the cost of the learning, and rewriting over the games you have made allready - at least 33% extra sales! What else can you do that will give you 33% extra sales? Would probably two months of work to make playable software versions of all your games, and have your frame work updated to handle opengl + SDL.
soniCron
06-21-2005, 07:13 PM
Use SDL. Multiplatform, very well tested and compatible, and fairly fast... Would probably two months of work to make playable software versions of all your games, and have your frame work updated to handle opengl + SDL. Hehe. :) You can bet your buns he doesn't want to do a software renderer, and why should he? Most people do have a decent 3D accelerator, so that's not the issue. He just doesn't want to futz with DirectX (not that I can blame him). Unless, of course, you were talking about him adding SDL OpenGL support, which... well... :D Hehe.
vBulletin v3.6.0, Copyright ©2000-2008, Jelsoft Enterprises Ltd.