Advertisement

Why aren't there more Linux ports of Windows applications?

Started by October 11, 2003 03:24 AM
31 comments, last by Peon 21 years ago
Linux isn't seen as a game platform now.. so not alot of game companies bother with it.

Windows owns the desktop market.

Edit: Forgot to mention that not alot of application companies bother with it either .



[edited by - Maega on October 12, 2003 2:35:25 AM]
quote: Original post by Dalik
I think you guys are putting in more then what it is.. First of all how many days would it take to add in support for files to another OS ?? maybe 2 days.. How long does it take to make a window to work with in any OS ?? few hours if that.. It comes down to, is it worth spending more money for support for more OS other then windows. As you noticed I used "spending money" and "support" which is turn is money. Will the programmers some or all need training how to use linux and program for it. Also will they need training to use openGL, SDL, openAL ? how much will that cost? how long will it delay the game? These are questions that corp guys are asking. Will adding support bring in more money or lose money for all the related examples I gave above. Its really not the programmers choice but the guys that just look at the money... Which is sad and will not gain *nix support and growth.

Because if you really think about it, it wouldnt be that much of a problem to add support for other OS other then windows. Since opengl, sdl, openAl and winsock are used just about the same on *nix then windows.



I started porting my game engine to linux, and I made sure I kept the OS dependancies in a SINGLE (relatively small) class. I converted it to linux, no problems, ran it... and it crashed. Found out it''s crashing when I load the second texture up. Check online, seems to be a problem a few others have encountered and never solved. Playing around a bit more, I can get it to crash at a few different GL calls, reversing the order of which the 2 textures (was trying it with a minimum app at this point, just font and mouse), and it loaded them properly, but then the window got screwy. Double checked my code a lot, re-wrote it from scratch, same results. Downloaded some nehe tuts for linux, ran fine with multiple textures... until I switched it to store GL_RGBA textures internally, then it all the sudden broke, which leads me to beleive it must be a driver issue. And, that leads me to the reason so little people like to convert their windows apps to linux. Graphics drivers have always been... well, not the best. 3d support was all but non-existant until very recently, and it''s still shaky (although getting better). I will probably install mesa and run it as software to see if that crashes also, if it doesn''t crash and works flawlessly, I can pretty much hands down blame crappy drivers.

The thing is, the part that''s crashing was the NON windows specific code, all my linux specific stuff was fine, but the non-os specific stuff didn''t work properly under linux, but worked fine under windows (and the code itself is fine, no reason it shouldn''t have worked under linux). I pretty much put off the linux conversion until I have a bunch of spare time, and possibly a linux guru there to help. In theory, converting to another OS (if written in GL and using multi platform libraries) should be extremely non-painfull and not take a long time, but in practice, it''s not so pretty of a picture.
Advertisement
I went through a simmilar thing just using SDL. I started making a simple game that I could run under linux. I first made it under Windows. What I had was running I would guess over 100fps. Under Linux it was about 5fps. Searched around and never found any real reason for it. Some O''yeah change this and run it as root(horrrrrrrible thing to be required). I managed to double the speed maybe. Thats still less than 1/10th using the same code under windows. This is across several systems and its totaly unplayable and I stopped making it. Looks like I would have to learn to mix OGL and SDL and use 3D to do what I should be able to do in 2D with the super easy SDL setup. I''ve used DX but right now I haven''t the intrest to learn a new API that I don''t need at all under windows as programing is back seat to other intrest. SDL is short, sweet, simple, and under linux for me useless.
------------------------------------------------------------- neglected projects Lore and The KeepersRandom artwork
Goober:
did you install your drivers for linux? If you are using the default drivers that X uses then thats not surprising that you got 5fps. If you got nvidia or ati card then install there drivers and you should get 100fps or more under linux.

Read4Dis:
I am not trying to be an ass but you would have to find another way. Because Unreal seems to be doing everything correct. Along with other companies. But again it could be driver support which is much better now with nvidia, just heard ATI released there own drivers for it also.

Consider this, OpenGL was ment to run on linux just as much as windows. So its most likely a driver problem more then anything.
Interested in being apart of a team of people that are developing a toolkit that can help anyone product an online game? Then click here http://tangle.thomson.id.au/
If supposedly portable code crashes on one platform, but not on the other, it''s obviously not correct code. Most of the time, this is because somebody didn''t read the documentation carefully...

For example, SDL programmers often forget to lock surfaces before accessing the pixel data directly. On some platforms, this works (because the surfaces are software surfaces). Then, when they go to the other platform, the program crashes, because the lock was missing.

In your case, it''s basically impossible to tell what the problem is without you giving more information.

cu,
Prefect
Widelands - laid back, free software strategy
Yes the drivers are installed and working quite well. I run a great many games like UT2003, RTCW, and anything I can get to run under Winex. As for accessing the pixel data I never went so far. All I ever needed was load bitmap into hardware surface, show bitmap. Thats as deep as it got. I just didn''t seam to be getting actual hardware surfaces under linux. Anyway thats not importaint. I wasn''t looking for a resolution because that would be off topic and only ended in failure in the past. Just showing that even simple things can end up complicated. If I was a better programer It might be fixed easily but dosn''t really matter as I have lost all intrest in finnishing the project.
------------------------------------------------------------- neglected projects Lore and The KeepersRandom artwork
Advertisement
quote: Original post by Prefect
If supposedly portable code crashes on one platform, but not on the other, it's obviously not correct code. Most of the time, this is because somebody didn't read the documentation carefully...

For example, SDL programmers often forget to lock surfaces before accessing the pixel data directly. On some platforms, this works (because the surfaces are software surfaces). Then, when they go to the other platform, the program crashes, because the lock was missing.

In your case, it's basically impossible to tell what the problem is without you giving more information.

cu,
Prefect


It's portable opengl code. There is nothing out of the ordinary going on, and I even changed the order things where called just in case it made a difference, which it didn't. It was a few calls to load a texture in opengl:

unsigned int tID;
glGenTextures(1,&tID);
glBindTexture(GL_TEXTURE_2D,tID);

glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, SizeX, SizeY, 0, GL_RGBA, GL_UNSIGNED_BYTE, img);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_NEAREST);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_NEAREST);
glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);


This crashes under linux, and not windows. If I load the textures in one order it crashes at the BindTexture, otherwise it crashes at the glTexImage2D call.


--- Edit ---
By the way, I have an ati card (radeon 9100) and the standard drivers that it installs for it, the ati drivers don't support the 9100 with 3d acceleration.

[edited by - Ready4Dis on October 12, 2003 11:10:36 AM]
The majority of the Linux users I know prefer to get the source code and compile it their self. Most companies are not keen on the idea of releasing their source code to the general public. Any doubts, look at Loki. Beautiful ports for a community that could not/would not support them. As long as Linux is seen as a super users domain, that is all it will ever be.

Geofery Daskin
Open Source Programmer
actually, my not so very humble opinion on this matter is that blaming on linux that a program crashes is just a lame excuse for not learning to program deacently. It is a major concern i computer science to write portable code and separeate GUI from network and core etc. Okay, i know that linux have problems with graphics drivers, in fact i get lousy fps values with my intel740 card, but the solution is not to give up linux as a gaming platform. We have right now very good 3d driver both from nvidia and ATI is working a great deal on it. DRI is doing a really good job too. Also WINE and WINEX makes it possible to play dx games on linux..at least some of them so actually i agree with peon: why arent there more programs ported to linux.....

thank you



--Spencer

"Relax, this dragon is sleeping..."
--Spencer"All in accordance with the prophecy..."
Why not?

The same reason why people don't make games for the Mac.

There are hundreds of millions of Windows users. Selling a million copies of your game is hopefully a good return on investment.

With the costs of games, companies are afraid to invest in something like a porting project that might not see a return on investment.


Now, if more companies would realize that porting WHILE in development might show them they have improper code that just happens to work, then they save on patches and bug fixing later.

Spend more now to release a game with less bugs. If your game crashes, some people will return it or stop playing it. That means less word of mouth for you, or worse, your game being bad mouthed as buggy. If you make it so that your code works on a few different platforms, there is a greater chance it will be bulletproof. Not everyone remembers to patch their games. You just saved your current sales and possibly improved future sales.

But people don't see that. They see, "If only 10% of all Windows users buy it, we're fine. 10% of all Mac/Linux users doesn't nearly cover our expenses for putting this game out...We'll stick with Windows only since the expense doesn't justify porting."

What does that mean? It means smaller fries, like shareware companies, can take advantage of the small Linux/Mac gamers market. Create a good game and get not only revenue from Windows users, but Mac and Linux users as well.

So let the big companies ignore the benefits of porting their games. While users aren't winning out here, at least some enterprising indie developers or shareware authors can. I understand that most Mac users are big shareware fans. Maybe the same can be said of Linux users. Loki went out of business because of the bad business deals it made ("Sure we can port your game...but you want us to guarantee 100,000 licenses? Uh, sure." I think this is oversimplifying it, but I think this is the general idea of what happened). This doesn't have to be the case for Linux development.




[edited by - GBGames on October 12, 2003 6:59:27 PM]
-------------------------GBGames' Blog: An Indie Game Developer's Somewhat Interesting ThoughtsStaff Reviewer for Game Tunnel

This topic is closed to new replies.

Advertisement