Category:
- Migration
Category:
The Linux gaming scene is not as robust as certain other operating systems, I will admit. However, the myth that there are no popular games published for the Linux platform is a thing of the past. The truth is that there are now companies publishing games for Linux. There are also Open Source projects focusing on the issue of video games, most of whom welcome assistance from anyone who offers, especially in the 3D gaming arena. Below, I cover a couple of the most interesting recent developments in the Linux gaming world. More importantly, I will introduce some of the concepts and tools involved in 3D game programming under Linux. Note that this is not a tutorial on how to program, just an introduction to some of the projects, tools and sources of information involved with the field. For those of you who are serious about learning, I will list a number of books and other sources where you can get more information on the subject. For those of you who are not, then enjoy the article anyway. You might just learn about something you didn’t know that you didn’t know.
Porting or emulation?
When I’m not in front of the computer, you can usually find me wandering up and down the computer section of the local Barnes and Noble. Almost every time go, I meet people who are interested in Linux for one reason or another, usually some techie looking for a new toy or someone who wanted to find information on “this Linux thing” they heard someone talk about. When talking to them, if they know anything about Linux, I’ll normally get a lists of “can I do this?” questions, ranging from office suites to digital cameras to streaming video. A comment I’m constantly receiving is, “Yeah, it sounds great, but there are no popular games for Linux.” Until recently, my answer to that was to talk about Loki and their newest game ports or about a friend who just got some Windows game running under WINE. A couple of months ago, that all changed.
Given the events that took place late January, one would think that commercial gaming on Linux would be a thing of the past. That month, the Linux world received a major blow as Loki Software, once the sweetheart of the Linux gaming scene, closed its doors to the world. Though this was a tough loss, it was not a death blow to the community, at least not if TransGaming has anything to say about it.
Both companies are responsible for bringing a number of popular formerly Windows-only games to Linux. Loki went about bringing games to Linux by porting them to Linux-native code. TransGaming, on the other hand, has taken the increasingly popular emulation road, using a modified version of WINE, called WineX. This is in line with a number of recent developments in the Linux application expansion, as can be witnessed by CodeWeavers‘ newest application, CrossOver Office, which uses WINE in allowing Linux users to use two formerly unattainable pieces of software on the platform: Microsoft Office and IBM Lotus Office Suite.
Though these developments are great, we have to face the underlying problem of the entire porting versus emulation debate: What’s fundamentally wrong with the question?
Made for Linux
Luckily, some gaming companies have realized the potential value of releasing Linux-native video games alongside their Windows and Macintosh counterparts. The Linux community is replete with frustrated gamers, most of whom, until recently, found themselves either giving up commercial games or dual-booting for the purpose of gaming. (Hey, you might as well make use of that Microsoft tax.) Lucky for them, a batch of new commercial games is now beginning to appear on the Linux platform.
The first of these notables was Id Software’sQuake III, which was the first title from a major video game company to be released simultaneously for both Windows and Linux. More recently, BioWare announced the upcoming release of its newest title, Neverwinter Nights, a Dungeons and Dragons role-playing game that is tentatively scheduled to be released on Windows, Macintosh, and Linux simultaneously. In fact, all three versions would come in the same box.
How Open Source fits into the picture
With all this going on, you might think that Open Source and commercial games don’t mix. Not so, my penguin gaming friends. Not according to Sunspire Studios. With its newest title, Tux Racer, Sunspire has decided to use the Open Source model to take an Open-Sourced game commercial. With more than a million downloads, the game is already quite popular, but the question remains as to whether it will be a financially worthwhile endeavor. In Tux Racer, players race as one of four Arctic creatures through 18 downhill courses, all while gobbling up as many herring as possible. The (rather addictive) game is fun, simple to learn and is suitable for all ages.
As you can see, there are already a number of big (and not so big) players in the Linux gaming scene. The great thing is that all of the tools needed to create a 3D game are available in both forms of “free” (beer and speech). Even better is that there are already numerous projects out there that anyone interested in game programming can look at, learn from, and even help in developing. The trick is putting all the information together.
Writing Games: What you’ll need
In order to begin writing your own 3D games under Linux, you need to acquire the necessary tools for the job. To a certain extent, the tools you use will be dependent upon the hardware you’ve got, so make sure that your hardware is supported by whatever software you decide to use. Everything that I talk about here was tested on my own humble, little system: a Pentium III 450mhz with 128mb RAM and 16mb ATI All-In-Wonder 128 video card running SuSE Linux 7.3. I’ll presume that you have at least this much horse-power and that you’re running a version of XFree86 4.x or greater. If you don’t know what version you have running, whip out that handy-dandy virtual console and type the following command:
[gnorb@geex gnorb]$ XFree86 -version
You should get something like this:
XFree86 Version 4.1.0 / X Window System
(protocol Version 11, revision 0, vendor release 6510)
Release Date: 2 June 2001
If the server is older than 6-12 months, or if your card is
newer than the above date, look for a newer version before
reporting problems. (See http://www.XFree86.Org/FAQ)
Build Operating System: SuSE Linux [ELF] SuSE
Module Loader present
Most recent commercial distributions will come XFree86 4 or greater already installed, so you should be fine. If you’re still in the 3.x series of XFree86, you might need to upgrade. You can check whether your video card is supported and get the latest release at the Xfree86.org Web site. You can also check there for installation information. Some distributions have easy-install packages (such as RPMs and DEBs), so make sure to check your distribution’s Web site for details.
Once that’s been straightened out, make sure that you can get 3D support under Linux for your video card. This normally means getting OpenGL (or an OpenGL alternative) up and running. If you’ve got a decent video card and are dealing with a major distro, then this shouldn’t be of much concern. OpenGL, GLX (the glue that binds OpenGL to X) and the X server integration of GLX are Linux system components. They should be part of Debian, Red Hat, Mandrake, SuSE, and Caldera, as well as other distributions.
If you find that you don’t have the necessary components, and you’ve got an ATI, Matrox, 3dfx, 3D Labs or Intel video card, then you should check out Precision Insight’sDRI project status page. XFree86 4 includes DRI GLX drivers for hardware-accelerated OpenGL, so it’s now just a matter of making sure that everything is set up correctly.
*A note to you SuSE users out there, you might want to check out the command switch2xxx (example: switch2xf86_glx). If it looks like everything is set up the way it should be and it still doesn’t work, this will probably help you fix it.
If you’re using an NVIDIA card then you’re pretty much on easy street. You can download pre-compiled drivers for their chipsets from its Web site. Unfortunately, they’re closed source, so if you’re not comfortable with the idea of having a closed source driver near your kernel, then there’s not much you can do. The specifications of NVIDIA drivers are not openly available, so there’s no way to make an Open-Sourced driver for their card.
By now you should have 3D up and running. To actually start the programming process, you’re going to need a few libraries and tools. You can get the Linux Game Development Center’sList of packages containing (more or less) everything you need to code a game at http://lgdc.sunsite.dk/resources/category16.html. Remember, you need to understand concepts like 2D graphics and 3D-to-2D projection before you move on to things like 3D objects and complete interactive 3D worlds. If you don’t yet understand these things, there are a number of books out there which can explain these concepts from top to bottom, my favorite being Norman Lin’s Linux 3D Graphics Programming, published by Wordware Publishing.
What follows is a listing of some of the tools and concepts you’ll need to familiarize yourself with in order to get up and running with 3D game programming under Linux, including where to get more information on the subjects.
Concepts to understand
Before you get started with functions and classes and objects (oh, my!), you have to first understand a few concepts regarding 2D and 3D graphics, at least if you want to do any serious work. You’ll need to understand certain geometric and mathematical theories, like vectors, matrices, intersections, mappings and coordinate systems. To acquire this almost-forbidden knowledge, you should really try to find a good Linux 3D programming textbook, a list of which can be found at the end of this article.
In addition to 2D/3D theory, an understanding of the X Windowing System is necessary. You can get an overview of the protocol at http://www.x.org/about_x.htm. You’ll need a bit of knowledge of hardware display technology and raster displays (a quick explanation of which you can find here). Once you understand this foundation, the rest is merely a matter of implementation.
Some of the basic tools
Earlier, I told you about OpenGL, something you are supposed to install on your system in order to be able to run 3D applications. OpenGL is developed by SGI and is an environment used to develop 2D and 3D graphics applications. Because of its popularity, it has become an industry standard API for cross-platform 3D and 2D application building. In fact, until recently, 3D games that were ported (or emulated) to Linux were exclusively built using OpenGL. TransGaming, however, has recently released for Linux Max Payne, a fully DirectX-based game.
Unfortunately, it’s not all fun and games here. Some people don’t like OpenGL due to its license, so they opt for the alternative, Mesa. Mesa, written by Brian Paul, is a free graphics library with an API almost identical to OpenGL. Programs using OpenGL can use Mesa without changing the source code, so whichever route you want to take is completely up to you and your hardware.
Alongside OpenGL/Mesa, you’ll need a OpenGL/Mesa-based library to serve as a sort of glue between X and the API. That’s where GLX, Utah-GLX, and GLUT come into play. GLX, as I said earlier, is the glue that connects OpenGL to the X Window System. It’s required by any OpenGL implementation using X. A step beyond that is the Utah-GLX implementation, which offers a hardware accelerated GLX module for free Unix-type systems. The Utah-GLX project was born after SGI released GLX under a public source license. Utah-GLX has been included with the DRI release included in XFree86 4.x. The OpenGL Utility Toolkit (GLUT, pronounced as in glutton) is a free library written by Mark Kilgaard. It simplifies the implementation of frequently occurring
OpenGL operations, and because it’s built on top of OpenGL, it’s compatible with Mesa.
Another important component in video game development (or multimedia in general) is the Simple DirectMedia Layer (SDL). SDL is a library that provides fast access to the graphics framebuffer and audio device. SDL doesn’t actually talk to the hardware, unlike many multimedia toolkits. It instead serves as a later between the application and the underlying system. This allows SDL-dependent applications to run unchanged in any environment that SDL runs in with nothing more than an simple recompile.
Still more tools
Most major Linux distributions include the components I have just covered. If you’re just interested in playing games, then these tools will generally suffice. For those of you who want to know a bit more, here is a short list of Open-Sourced tools you might need to pick up along the way. Note that a number of these are alpha and beta versions, still in development or just beginning to be developed.
Currently, it is in alpha release, so it’s not very useful yet as a modeler; however, it currently serves as a good 3D file converter.
*Note: you can check out a full list of modelers available for Linux at http://www.computer.privateweb.at/tech-edv/MODlinks.htm.
For more information…
Now that you have a good bird’s eye view of what’s involved in with programming 3D games on Linux, it’s time to really dig into the subject. There are a number of resources on the Internet to assist you as you delve more deeply into the subject matter. A couple of sites to note are the Linux Game Development Center and the Linux 3D Graphics Programming information site. Both of these will contain a large amount of information, tutorials, and links regarding this subject. Personally speaking, I prefer a good book to online documentation (all other things being equal). As such, here is a list of books which might be helpful to you in case you decide to stop by your local bookstore (and if you live in Tampa, you just might see me wandering about).
Category:
Category:
IBM’s patent claim was made in an intellectual property disclosure filed in late March with the Organization for the Advancement of Structured Information Standards (OASIS).
Executives from both the United Nations and OASIS said they expected the ebXML specification to be royalty-free and unencumbered by patent claims. Both said they were surprised by the sudden appearance of the disclosure.”
These days, Microsoft is singing a slightly different tune.
The company says it still believes its software blueprints should be closely held, but says it has come to see the value in sharing some source code with some of its best customers and selected academic institutions.”
Category:
Category:
Hewlett-Packard has won a U.S. Department of Energy contract to build a $24.5 million environmental-research supercomputer that HP says will be the world’s most powerful Linux-based system.
The 8.3 teraflop machine — roughly 8,300 times faster than a current personal computer — would be the second most powerful supercomputer in the world, if it were running today. The supercomputer, which consists of 1,400 McKinley and Madison Intel Itanium Family Processors, is scheduled to go online in 2003 at the Department of Energy’s Pacific Northwest National Laboratory in southeast Washington state.
The HP supercomputer will be 30 times faster, have 50 times more disk space and 10 times more memory than the PNNL’s current IBM supercomputer, built in 1997. The new supercomputer will have 1.8 terabytes of memory and 170 terabytes of disk space. During a conference call this afternoon, HP officials talked up the successful bid as showing HP can compete in the supercomputing market and how this shows the company’s support for Linux.
Martin Fink, general manager of the Linux systems operation for HP, says this bid is part of an HP push into supercomputing during the past year and a half. Rich DeMillo, vice president and chief technology officer for HP, took a veiled shot at HP’s supercomputing competitors in the press release announcement of the successful bid: “Today’s announcement shows how HP has worked to help accelerate the shift from proprietary platforms to open architectures, which provide increased scalability, speed and functionality at a lower cost,” he said. “This supercomputer is another validation of HP’s service-centric technology vision, exemplifies the power and benefits inherent in the Itanium architecture and Linux, and clearly illustrates that there is more than one top player in the supercomputing market.”
Asked why the project is using Linux, David Dixon, associate director of theory, modeling and simulation for the PNNL’s Environmental Molecular Sciences Laboratory, said Linux is what HP recommended. Fink, however, said that while Linux offered some price advantages, it was the right operating system to use with the Itanium architecture in this case.
“Whenever we make a bid, we try to use the best tool for the job,” Fink said. “That was the determining factor.”
Dixon said the his laboratory will use the new supercomputer to do detailed research and simulations focusing on addressing environmental problems and energy security, some of which weren’t possible with the old supercomputer. Among the projects: research on cell functions, efficient energy use and predicting the reactions of radioactive materials. A big focus of the new computer will be simulations, such as how proteins interact with each other, he added.
“Our goal is not only to interpret experimental results and guide new experiments by doing good simulations, but to provide quantitative results that can actually replace experiments that are too difficult, dangerous or expensive,” he said.
Fink said this Linux announcement is evidence of support for open standards in supercomputing. “This supercomputer validates our belief that the high-performance technical computing market will increasingly adopt industry-standard building blocks, architectures, and open platforms, as opposed to proprietary architectures and platforms,” he said. “As a result, customers will continue to see benefits in terms of cost and performance.”
Asked if the announcement means HP will contribute more to Linux’s Itanium supercomputing code base, Fink said improvements made to the Linux code to deploy the PNNL supercomputer will go back to Linux, and he noted that the maintainer of the Linux for Itanium project works at HP.
“It allows us to have this very close relationship into the whole kernel evolution process,” he said. “As we come up with enhancements to make the system perform better, those will flow through to the (Itanium) kernel maintenance tree, and any enhancements that are generic beyond the Itanium processor family specifically will go into the main kernel source tree, and everyone will benefit from that.”
Category:
Category:
Category: