Originally Published: Monday, 29 May 2000 Author: Terry Warner
Published to: enhance_articles_games/General Page: 1/1 - [Printable]

Stephane Peter Interview

We got to talk with Stephane Peter the project lead for the newest Loki port Sim City 3000. We had fun, talked alot, and also played a little Quake 3. So click below to read the full interview. Once again, thank you to Stephane Peter for taking time out to do this interview.

   Page 1 of 1  

Games_Staff First off, Stephane, thank you for taking time out of your schedule for doing this. MEGASTeP As if I had a schedule. :-) Games_Staff So, Stephane, I'm guessing from your earlier statements that Sim City is an up and coming port. MEGASTeP Yes, the beta is going very well. We hope to have the first gold master in a week or two. Games_Staff I've been trying out the beta and so far it's very nice work. I give you alot of credit Stephane. Games_Staff What's the average time for a game port? MEGASTeP That varies a lot depending on the challenges associated with each game, but usually a few months. With Sim City we had the chance to deal with very professionally written code. Games_Staff Let me get something straight, Loki buys, or somehow gets the source from the original vendor. What is involved with that? MEGASTeP Well, I don't deal with this, but my understanding is that we license the source code from the original vendor, and we basically get the right to distribute the Linux version. Actually getting the contracts is more Scott's role... Games_Staff How many people does it usually take to work on one game? MEGASTeP That also varies on the complexity of the game, but I'd say that the average team of programmers for each game is around 2 to 4 people. Games_Staff Maybe we should back up here. Why don't you tell us a bit about yourself, your expertise, your favorite port, game, interests, etc. MEGASTeP OK. MEGASTeP It's a long story. Well, first of all I am French. Before working for Loki, I was a computer science student at the ESSI school on the French Riviera. I got a degree there in computer science engineering and systems administration. My first work experience in the US involving Linux was actually at SciTech Software, where I was an intern for 2 and a half months (www.scitechsoft.com). I actually was working for SciTech from France after I came back to school, as a parternship project with my school. Games_Staff What did you do there? MEGASTeP I worked on porting their SciTech Display Doctor suite of utilities to Linux. SciTech basically have their own set of high-performance closed-source drivers for graphics cards. Games_Staff This was a commercial effort right? No open source stuff? MEGASTeP It was part closed-source and open-source. MEGASTeP Their drivers are really very good, but their business model relies on them selling binary drivers. In short, they have this very nice driver architecture that's called Nucleus, and it actually allows drivers portable across platforms, at the binary level. It's kind of the new modular drivers for XFree 4.0. Games_Staff Like an openGL API? MEGASTeP It's a very low-level API. MEGASTeP So what I did for SDD/Linux was writing an XFree86 driver that worked on top of that architecture, and I also wrote a SVGAlib wrapper later on. Games_Staff How hard was it to write something like that? MEGASTeP The toughest part was getting familiar with the huge beast that XFree86 is. I really learned a lot about graphics programming while working on that project. MEGASTeP SciTech also has a very nice library called MGL. Games_Staff What is MGL? Games_Staff Multimedia graphics library? MEGASTeP It's completely different stuff. It's a game programming library kind of like SDL, which used to be closed-source, and that SciTech released under an OpenSource license. It's a very good and complete library. It was used to make several commercial games, and while I was working there we were working on making it portable. I did most of the Linux port, and now it works on a lot of platforms such as Windows, DOS, Linux, FreeBSD, QNX, etc. Games_Staff it seems as though alot of companies these days who want to break into the Linux market make their software very portable. MEGASTeP I worked for a few months on porting wxWindows on top of MGL, but never had time to finish it. Games_Staff Sounds like you had a full plate when you worked there. MEGASTeP You may have seen the review for SDD in Linux Journal about one year ago. Basically when you run SDD, it will automatically detect your graphics card and monitor specs, automatically configure XFree and SVGAlib for maximum acceleration, and allow resolutions you could not obtain normally. Too bad it has not been updated in 2 years, so it does not work with glibc 2.1 for now. Games_Staff Did you enjoy the work you did there? MEGASTeP Yes, a lot. MEGASTeP Oh, I also wrote 'makeself' for the SDD installation program. I'm still maintaining it and we're using it at Loki. It is the tool to make self-extractible shell archives. The URL for it is: http://www.lokigames.com/~megastep/makeself/ MEGASTeP We use it for patches, demos, etc. MEGASTeP Well, anyway, SciTech was 2 years ago, and I came to work for Loki almost exactly one year ago (early in May, 1999!), and it was an internship again. My school requires a 4 to 6 months internship at the end of the last year, so I was lucky enough to ask Sam and Scott. I think my previous experience at SciTech helped a lot to make me the first international intern ever working at Loki. Loki was much smaller one year ago. Civ had just been released and I began working on Myth II the day I arrived. I was a programmer, like other employees, except that I had an intern visa. Games_Staff It sounds like they put you on a big project right away. MEGASTeP I did not help anybody in particular, just the Myth II coding team, and in the 5 months of my internship, I completed the Myth II port. It was cool that the Myth II project started when I arrived, and the game was shipping at the end of my internship. Games_Staff Are you an object-oriented programmer? Some programmers have a preference and feel very strongly about object oriented vs. flat function. MEGASTeP I do like OO, but moderately, but I like _clean_ OO. It's very easy to mess things up in OO if you have a bad design. Sim City is a very good example of clean OO applied to games. MEGASTeP I tried to port Quake on IRIX while in school, the code looked quite clean.C Games_Staff You didn't finish? MEGASTeP I half-finished. It was working but I was more trying to add a 32bpp rasterizer to it and that was not working very well, so I gave up. Games_Staff Did Scott decided to hire you after the Myth II project? MEGASTeP Yes, they liked a lot the way this project was conducted, so they offered me a job. Games_Staff Could you go into a bit of the culture at Loki? What the atmosphere is like there, typical day kinda stuff. MEGASTeP Fun is the first word that comes to mind. It's a rewarding job, you really feel like your making Linux progress by working on cutting-edge projects. MEGASTeP And occasional Quake 3 fests at the office aren't bad either. Games_Staff What about pressure, deadlines, and that kind of thing? MEGASTeP Most of the time this is cool, except when the project nears the end and you need a gold master for yesterday. We don't want to release an incomplete product, so this is flexible. We always try to have a better product than the original. Games_Staff What was the worst misshap or bad thing that has happened while you have been at Loki? Ever do an "rm -rf" in your main code tree or anything? :) MEGASTeP I can't think of any, and we use CVS. Games_Staff What about some of the open-source projects Loki does? I know you work with Sam on SMPEG correct? MEGASTeP I did some patches to SMPEG, but Sam is maintaining it. We have a lot of user contributions to SMPEG, that's very cool. Games_Staff Do you currently maintain any of the open-source projects? MEGASTeP I'm the co-author of setup, with Sam, and I'm a regular contributor to SDL. The great thing is that we extend those tools with every project, which has some specific new needs, so the more games we port, the better SDL, SMPEG, setup, etc, become. Games_Staff SDL is used as far as I can tell on all your games, correct? MEGASTeP Absolutely. SDL is defining itself more and more as the DirectX for Linux. As an example, we have added new synchronization objects in SDL (condition variables, semaphores) for the needs of Sim City just last week, and Sam is working right now on adding stretch blits for SMAC. MEGASTeP I also was pretty much the Loki sysadmin until a few weeks ago when we finally hired a full-time sysadmin. MEGASTeP I also worked on Heroes III, by the way. That was interesting, as I did the whole port from my home in France, while waiting for my H1-B visa, while Sam and Andy were helping here. Games_Staff You started to talk about your feelings on objecte oriented programming before, please continue. MEGASTeP Well, here at Loki we more often have to deal with other people's code, so the choice is rarely ours, but if I have to start a new project, I'd be likely to choose C++, or at a least an object-oriented approach. You can have an OO approach in plain ANSI C. Games_Staff How many people are generally working on a project at a time? MEGASTeP 2 or 3, I'd say, but sometimes more. I think HG2 set the record, almost everybody here worked on some part of it at some point. Games_Staff I generally think of OOP as a solution to large group projects. I'm a little close-minded on that, but it does seem to fit better, do you feel that way? MEGASTeP Well, that doesn't really depend on the number of involved people, rather on the goals of the project itself. A project like Sim City really benefits from an OO approach, even if only one person was working on it. The irony is that if you look at all Loki's open-source projects, there is very little C++ or OO in them, because this approach does not benefit all kinds of projects, and we often have to keep C API's for compatibility. Even OpenAL is in C, but I think it still uses an OO approach. Games_Staff How is it decided who works on what projects (aside from HG2 which seems to be an exception)? MEGASTeP Mostly on the skills of the programmers I'd say. We are also flexible about that, so we can express our preferences. Games_Staff Around the office,what are you known for skill wise? MEGASTeP I did mostly 2D games (except for Myth), but I know a lot about most of the open-source projects we have, about systems programming, and general software engineering (that's what I went to school for). I am also kind of a networking guru. I ported the OpenPlay networking API for Myth, and ported the Heroes3 API as well. Games_Staff Any advice for aspiring programmers or projects out there? MEGASTeP Well, just get involved in some open-source project, or start your own. That's the best way to learn, I have found. Open Source projects tend to attract skilled people, and you learn from them. If you have a nice idea, work on it, release it, and if other people like it, they'll help you eventually. Games_Staff Ok, lets talk about X and games. The swing of things seems to be putting all the video card development in X which forces game players to be running X to launch a game. Games_Staff What about svgalib, what happened to it? MEGASTeP SVGALIb is a very poorly designed obsolete API. SVGAlib remains a big hack to access the video hardware directly. Games_Staff It's fast though, and you can spawn consoles for svgalib from within X. MEGASTeP My svgalib wrapper lib that worked on top of the Scitech drivers was really very fast (fully accelerated). Games_Staff Is your wrapper opensource? MEGASTeP Yes. MEGASTeP The problem with X11 is that it really was not designed to get good performance in games. Games_Staff And it's a memory hog. MEGASTeP Not that much, but the whole X protocol has an overhead, and the worse thing is that there is no way to get the full range of hardware accelartion we would need for games, even with DGA. Games_Staff So will Loki develop their own sort of new svgalib? MEGASTeP That's called SDL. SDL has support for the framebuffer console, with optional acceleration on the Matrox and 3Dfx cards. By using SDL in the games, we have an open door to acceleration the day we get a fully accelerated driver. Games_Staff You have to boot into the frame buffer console for that right? MEGASTeP Yes. MEGASTeP I also wrote the aalib driver for SDL, so you can play our games or watch MPEG videos in Ascii-art. Actually, when I saw again Quake in ASCII, I thought, "I want to play Myth II like that", and a few days later I had the fully working driver in CVS. The latest patches for Myth and Heroes3 actually include it. MEGASTeP Well, as far as hw acceleration goes, I think we'll have to stick to XFree for a while, because most people don't want to deal with the console... MEGASTeP I'm probably going to try to write a SDL driver for the SciTech drivers quite soon, and see what kind of performance I can get on the console. I expect it to be the fastest SDL driver ever. MEGASTeP The lack of acceleration in X11 really shows with SC3K. Games_Staff How so? MEGASTeP The Windows version heavily uses hardware acclerated blits in DirectX, and the UI is a LOT more responsive on the same hardware because of this. This is just not available on standard X for now. Actually this should be better with DGA2 or one of the accelerated fbcon drivers, I just did not try yet. All we would need to achieve this on X is a kind of DRI for 2D. Games_Staff Anyone writing it? MEGASTeP DGA and DGA2 have partial support for that, but we have no way in X to tell to the server to store surfaces in hardware memory, which is the real key to high performacne. So when you do a blit you have no guarantee it will be accelerated. MEGASTeP In theory it would be possible to have DRI for 2D, I'm not sure if somebody is working on it. Games_Staff How do you think nVidia's push toward polyhon acceleration will change games in the future? MEGASTeP Better drivers are always a good thing, it will push other vendors to catch up. I just don't like the fact that nVidia does not have open-source drivers now. I hope they have a good reason for this. Games_Staff They don't want a team of college students coming out with better drivers than they did. MEGASTeP My main concern is that you can't have similar drivers for other OSes or architectures this way. Maybe the OSS community could improve them as well, but they seem to have a very good performance right now. MEGASTeP It's more an interoperability thing. Games_Staff The closed-source nVidia drivers? MEGASTeP Yes, they pale in comparison to the 3dfx drivers. The new ones are much much better. Better than 3Dfx actually and closed-source. MEGASTeP Any more questions? Games_Staff What's your favorite joystick? MEGASTeP My mouse. MEGASTeP Actually I never use joysticks. I have a cheap joypad that I use for Xmame. Games_Staff Well, when Descent 3d comes out you're gonna have to use a joystick MEGASTeP But we really have nice joysticks at the office, donated by Logitech, so that we support them in HG2. MEGASTeP The best part about Descent is that it supports the Rock'n'Ride, a special gaming chair (www.rocknride.com). Games_Staff Thank you Very much for your time Stephane! MEGASTeP np :)

Here is Stephane hard at work!

   Page 1 of 1