Advertisement

Linux game developement...

Started by May 14, 2002 07:08 PM
26 comments, last by Grellin 22 years, 4 months ago
I was reading the post below asking why Linux gaming hasn''t taken off and after reading all of the responses a question poped in my head and decided to ask for opinions. Just so you all know, I am not trying to start a flame war against Windows and Linux. I use both of them on a daily basis and like them both. So here goes and this is mainly for Linux coders but feel free to chime in... I just started programming on Linux and will be starting MESA and SDL shortly. I have used DX and have been working on OpenGL for Win32. One of the arguments I continously hear about why you should use OpenGL vice DX (*NOTE* I like them both, no fighting) is the ability to port to other OS with little work. Now if I code primarily for Linux using API''s that are available to both Win32 and Linux wouldn''t my code (with minimal tweaks) work on both systems? Otherwise what good is the argument that it is portable... Keep in mind I am NEW to Linux coding and don''t assume to know everything. Just trying to reach the maximum percent of possible new customers (some day). As a developer I don''t really care what "system"(Windows, Linux, Unix, Atari 2600...) it works on as long as there is potential to (being materialistic) be compensated for hard work. Or am I just lost with little hope of finding my sanity? GRELLIN
CGP | IYAOYAS
Steven Bradley .:Personal Journal:. .:WEBPLATES:. .:CGP Beginners Group:. "Time is our most precious resource yet it is the resource we most often waste." ~ Dr. R.M. Powell
No, you''re absolutely right.

Take care,
Bill
Advertisement
Hi, I think I might have touched on this topic earlier regarding DirectX vs OpenGL, where I pointed out that the two things are not comparable because one is strictly for graphics above a system specific layer (OpenGL) and the other is a wrapper for hardware IO (DirectX). One thing I do wish to note is that Linux is far more stable with many more features opened for game makers than Windows, I say this not out of opinion but from experience. I have been writing games for Windows and Linux for a while now and know the pros and cons with each library. My best advice is to know Windows'' low-level routines (which now is probably DirectX) and know Linux''s low-level routines, write modules for each depending on which platform you are compiling for. You might not like the extra work but if you are "going pro" then you need to accept it. The second alternative is to use SDL, but it might irritate some users because it uses the minimals of both systems.
Tara Milana - WP Entertainmenthttp://wolfpack.twu.net/Comp graphics artist and programmer.
quote: Original post by Grellin
I was reading the post below asking why Linux gaming hasn''t taken off and after reading all of the responses a question poped in my head and decided to ask for opinions. Just so you all know, I am not trying to start a flame war against Windows and Linux. I use both of them on a daily basis and like them both. So here goes and this is mainly for Linux coders but feel free to chime in...

I just started programming on Linux and will be starting MESA and SDL shortly. I have used DX and have been working on OpenGL for Win32. One of the arguments I continously hear about why you should use OpenGL vice DX (*NOTE* I like them both, no fighting) is the ability to port to other OS with little work. Now if I code primarily for Linux using API''s that are available to both Win32 and Linux wouldn''t my code (with minimal tweaks) work on both systems? Otherwise what good is the argument that it is portable... Keep in mind I am NEW to Linux coding and don''t assume to know everything. Just trying to reach the maximum percent of possible new customers (some day). As a developer I don''t really care what "system"(Windows, Linux, Unix, Atari 2600...) it works on as long as there is potential to (being materialistic) be compensated for hard work. Or am I just lost with little hope of finding my sanity?

GRELLIN

CGP | IYAOYAS



To answer your question, if you use SDL, your code should compile on any platform that has a port of SDL. If you learn Mesa/Glut, your game should also compile on most platforms that support OGL of course tweeks will be necessary but hey that''s part of coding...


"And that''s the bottom line cause I said so!"

Cyberdrek
danielc@iquebec.com
Founder
Laval Linux

/(bb|[^b]{2})/ that is the Question -- ThinkGeek.com
Hash Bang Slash bin Slash Bash -- #!/bin/bash
[Cyberdrek | ]
I totally agree with you. Portability is wonderful, and I go for it all the time, but the problem lies in the fact that many people are either too lazy to port, or don''t have multiple OS''s themselves to do any porting, not to mention the fact that many people do not release source code. Now, if you ask me, it would be smart for companies to use things such as SDL and OpenGL in order to be able to reach the largest number of people with the minimal amount of recoding, since you''d for the most part only have to code once and compile 3 or so times for Windows, Linux, and Macs.

rm -rf /bin/laden
Thanks for the replies!

GRELLIN

CGP | IYAOYAS | Linux.com | Linux Game Development Center

Don''t fear the penguin!
Steven Bradley .:Personal Journal:. .:WEBPLATES:. .:CGP Beginners Group:. "Time is our most precious resource yet it is the resource we most often waste." ~ Dr. R.M. Powell
Advertisement
quote: Original post by CmndrM
Now, if you ask me, it would be smart for companies to use things such as SDL and OpenGL in order to be able to reach the largest number of people with the minimal amount of recoding, since you''d for the most part only have to code once and compile 3 or so times for Windows, Linux, and Macs.

...Except that SDL is a "lowest common denominator" interface, OpenGL is a little temperamental under Windows (in terms of varying vendor support, non-standard detection routines and the dreaded extensions mechanism) and portability, so far, is overrated. If 80-90% of your target audience is on one platform, there''s little fiscal incentive to port to other platforms.

What most companies that develop multiplatform software do is create their own abstraction layers, specialized for each platform (kinda like pushing SDL to platform-dependent performance limits - using Win32 and DX8.1 hardcore under Windows, Cocoa and OpenGL under MacOS X, Carbon/MacPlay/other junk under MacOS 9 and under, etc). This can be time consuming, so they try to make it extensible for a few years in order to maximize utility. They then build their applications to that layer.

It''s a lot of duplication of effort, but realize that games are highly specialized applications - it has, so far, proven extremely difficult to build a generic "game engine" that works for all or most genres.

I think that this -
quote:
If 80-90% of your target audience is on one platform, there''s little fiscal incentive to port to other platforms.


is much more an issue than this -
quote:
it has, so far, proven extremely difficult to build a generic "game engine" that works for all or most genres.


I don''t have any experience with the Loki ports, are they any good? Most of those use SDL, and would be a good test of how well SDL performs. A better test would be taking the port and "porting" it back to Windows, but that''s probably not going to happen.

I like Linux as a development environment, because I have something of a unix-y mindset. As a market for games, Linux just isn''t there.

Take care,
Bill
I think Linux is a perfect market for games. Yeah, it''s not nearly as big as Windows by a long shot, but let''s face it: a very large portion of the linux community that dual boots or has an extra computer with Windows on it primarily keeps it only to play games. If games suddenly became available for both platforms (not to mention macs), then the linux market share would very likely shoot up to a higher level than it is now (granted, it will still be far below Windows, but it could potentially rival and even surpass the Mac market share for games).

rm -rf /bin/laden
quote: Original post by CmndrM[/i
a very large portion of the linux community that dual boots or has an extra computer with Windows on it primarily keeps it only to play games.

A large proportion of a small percentage is still a small percentage.



--AnkhSVN - A Visual Studio .NET Addin for the Subversion version control system.[Project site] [IRC channel] [Blog]

This topic is closed to new replies.

Advertisement