Cross-platform development

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Jan 31, 2003 at 20:19

Poll: How many of you are developing cross platform?

I’m just wondering, because it seems like it’s not that many.

30 Replies

Please log in or register to post a reply.

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Jan 31, 2003 at 22:02

i dont use anything but windows (i know linux and co, and worked with it, but they don’t please me currently..).

but i only use crossplatform libraries if they exist, and else i try to wrap it in a way easy to change for other platforms.

2562953b4e8e2602a8bfc24b1123a341
0
EvilSmile 101 Jan 31, 2003 at 23:10

I use ogl and SDL for most of my stuff.

So, in a way it’s cross-platform. I didn’t pick ogl and SDL for that though. OGL coz it’s so cOoL and SDL coz it’s so simple and makes a prefect match for OGL.

I work solely on Linux :]

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 01, 2003 at 00:06

ditto.

although i use SDL cuz of it’s cross-platform api. I tested it on my friend’s windows box. there is _NOTHING_ to change.

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 01, 2003 at 10:01

that’s the advantage of cross-platform libraries. You open up your market with no major concessions. Often there is no overhead as when it is compiled for the OS, all other OS specific code is removed. At least, that’s the impression I get.

2177c9af4b18b1ae139453645cbb09e5
0
dabeav 101 Feb 01, 2003 at 14:30

I only use cross platform code, but I also go one step further, and generaly ONLY use OpenGL style libraries. For instance, GLUT, OpenAL, devIL, etc. Reason? Because I dont have to RELEARN anything, i simply can apply what i already know, and spend the other time, actualy working on code. I believe there is a growing number of people out there that are going to start usign other OSs, and me being a game developer “In Training” I want my product to be able to get to as MANY people as possible. Besides, open platform is MUCH easier to write than platform specific, i think, no need to learn new stuff for each one.

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 01, 2003 at 15:33

I only use cross platform code, but I also go one step further, and generaly ONLY use OpenGL style libraries. For instance, GLUT, OpenAL, devIL, etc. Reason? Because I dont have to RELEARN anything, i simply can apply what i already know, and spend the other time, actualy working on code.

and THAT is why *OpenGL is better than DirectX. ;)
*

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 01, 2003 at 15:49

what do you mean “OpenGL styles libraries”? do you mean C style as apposed to C++?

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 01, 2003 at 17:47

no, he doesn’t. he means…

For instance, GLUT, OpenAL, devIL, etc.

those libraries use/apply OpenGL.

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Feb 02, 2003 at 12:28

@donBerto,Feb 1 2003, 10:33 AM

and THAT is why OpenGL is better than DirectX. ;)

uhm. you learned one dx library, and you know how to use all modern libraries in dx, in windows at all. com is different, but com is easy and great. i use it in my own code all the time. its the way to abstract your code to make all work independent from each other.
dx is great. gl is great. i’m just used to gl, so i use it. but they are equal in power, and equal in easiness to use. dx9 is awesome imho..
actually, dx is more clean and simple to use than gl. but i’m so used to gl i can’t move (i tried several times:D)
crossplatform means nothing for me, but its a nice addon.
(and crossplatform means nothing to me, too, because i want to use rendertexture, and that is not crossplatform on gl eighter.. but it looks like a real version is comming (hope))

2940f695c41efc6cd617f2dbf7d2c065
0
woz1010 101 Feb 02, 2003 at 18:17

I have found myself doing cross platform coding at work recently.
That is code running between different Unix platforms such as SUN, AIX, DEC, True64.

The differences can be plenty and subtle, but they are there in abundance. This is complicated by the fact that it was a decision long ago to use the particular platforms native compiler, not just one like gcc.
Some of the other similar products, like the one I am on, also have a version for windows.

Finally, just a few days ago, I grabbed the opportunity to get the product to build and work on RedHat Linux, so work is sort of interesting for awhile.

As for games:
C3, the game project I am on, was considering using the Torque engine, which is cross platform ready for Windows, Linux, and Mac.

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 02, 2003 at 19:35

woz1010: will C3 run on any platform then?

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Feb 02, 2003 at 21:47

lets hope so.. would be cool..

2940f695c41efc6cd617f2dbf7d2c065
0
woz1010 101 Feb 03, 2003 at 06:07

woz1010: will C3 run on any platform then?

If we stick with the Auran Jet engine for C3, then no, not in the near future.
If we go with Torque, then yes.

Right now we are giving Jet a serious run through, just a lot has to be implemented as it is more a generic do anything you want if you extended it type API. But we will have the game servers able to run on Windows and Linux

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 03, 2003 at 09:47

@davepermen

crossplatform means nothing for me, but its a nice addon.
(and crossplatform means nothing to me, too, because i want to use rendertexture, and that is not crossplatform on gl eighter.. but it looks like a real version is comming (hope))

i’m a little confused. dx and ogl are very similar and they draw nearly equal in power (although many of us can pick through the pros and cons of both). for a person who’s target audience uses a variety of other operating systems then cross-platform development is a key element to consider. it would suck having to write the same code over and over again for different platforms. it’s more than just a “nice addon”.

second, what do you mean by rendertexture? you know you can render to a texture with OpenGL right?

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Feb 03, 2003 at 13:15

yes, you can render to a texture with ogl, but currently over the extensions
WGL_ARB_pbuffer
WGL_ARB_pixel_format (or something like that)
and
WGL_ARB_render_texture..

that means quite complex, and messy, and windows only.

why is my target audience multiplatform? all i know do have windows..

D491261d0cdbea6f1f04129ba87f4d09
0
void 101 Feb 05, 2003 at 03:30

Id like to just say one thing: GLUT is pretty crapola. It is slow performance wise, rewriting the app using say SDL instead boosts peformance quite a bit, i thing that glutSwapBuffers() is pretty poor performer. The keyboard input is also shit… Use SDL.

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 05, 2003 at 04:13

yeah definitely. see the problem is that GLUT was made when OpenGL first came out. that’s cool. but as many other libraries became heavily support from their respective communities, GLUT became nothing but old, heavy, code and now it’s at a point were it’s uneconomical to use it. I don’t even think GLUT has the support it once did.

i could be wrong. feel free to enlighten.

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 05, 2003 at 19:51

I’d say GLUT is adequate for knocking up a simple demo, but you’re right. SDL is better and GLUT is old.

203e4e77a4880ecbd91054865fc5d0b7
0
Phaetos 101 Feb 06, 2003 at 10:17

I am developing for Linux only. I use OpenGL in combination with SDL, but I don’t want to port anything to Windoze. If someone does, its okay as all of my code is GPLed.

I would like to make Linux a far better gaming system than it is today. But my limited time makes this
nearly impossible.

DirectX sucks as it is not available on other platforms. So DirectX is per default a no-choice anyway. Think
of a big gaming development company and what time is needed to port a DirectX game to OpenGL to make
it run under Mac and/or Linux… It would be far more efficient to write it for OpenGL from the beginning, or
am I missing something?

Greets
Stefan

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Feb 06, 2003 at 17:29

you’re missing that porting to xbox is easy as .. well, as recompiling:D

and you’re missing that the linux target is not that big. could (should?) be different. but for me it doesn’t mather, as i said yet:D

possibly dx gets crossplatform implementations thanks to .NET? i mean, mono should support all, not? hehe.. we’ll see:D

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 06, 2003 at 22:19

@davepermen

you’re missing that porting to xbox is easy as .. well, as recompiling:D

oh come on! xbox is just a pc with a kick-ass gfx card running an ms OS. I doubt that counts as being cross-platform.
@davepermen

possibly dx gets crossplatform implementations thanks to .NET? i mean, mono should support all, not? hehe.. we’ll see:D

hmm… perhaps. good thinking.

what does everybody else think?

cheers

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 07, 2003 at 19:04

well, even thought there is a .NET compiler for e.g. linux, there aren’t (AFAIK) and won’t be runtime libs for DX.

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Feb 08, 2003 at 00:23

@baldurk

well, even thought there is a .NET compiler for e.g. linux, there aren’t (AFAIK) and won’t be runtime libs for DX. about the xbox. its a big target platform. you can’t say linux for example is a different platform eighter. its x86 still. once you worked for mac, for nintendo, or for sony, or sun, or whoever, you know what crossplatform really means. from windows to linux and backwards is easy:D

quite easy to write in gl, not? there is no reason to not do. it would give linux a big boost to be able to state they have dx compatible features. like the free gl port mesagl. not allowed to be named opengl, because there is no licence, but fully compatible anyways.

then we would need dx full, and only the .NET runtime.. but anyways, i think it would be quite easy and a great inspiration for a united future, and thats best for all

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 08, 2003 at 11:01

what I meant is that MS would probably never let there be a DX runtime/libs on linux. Think about it, most games would be able to be ported to linux.

6ad5f8c742f1e8ec61000e2b0900fc76
0
davepermen 101 Feb 09, 2003 at 20:07

and? microsoft gamedev section even develops for ps2 and such..

and it would not be dx, just managed dx. big difference..

2177c9af4b18b1ae139453645cbb09e5
0
dabeav 101 Feb 12, 2003 at 02:28

I also agree that GLUT is getting a little out dated, BUT I still use it. WHY? Because i said so, just kidding, actualy its because I find it much easier to work with than SDL, SDL seems to be a little over bearing with the CONTROL of the flow of code. Now probly the BIGGEST bitch people have with GLUT is SLOW input, I simply set a BOOL value (table) When the key is pressed, and check that value each time, so input is not a concern of mine. The other major problem is the glutSwapBuffers, which indeed is a bit slow, but all in all it works nicely. I think SDL has promise, but I dont think I will use it, because like I said, it tends to have a control issue, that and its not as easy of a syntax.

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 12, 2003 at 02:40

[in no way am I trying to shoot your harmony jam session (your view ;7 ) down in any way but it’s hard to ask this question without coming off as offensive. please bear with me]

can I ask you to elaborate on why or where in SDL you have a problem? I don’t mean problem - lack of a better phrase.

I’m curious and I’d like to see your point of view. I made an engine [still in development] and it uses SDL for windowing and input. I made a middle/manager class that controls window placement and behavior, and the input via SDL. granted, I sort of ‘embraced’ SDL and now, I’d like a difference in opinion. maybe there is something that some of us failed to see.

thanks.

2177c9af4b18b1ae139453645cbb09e5
0
dabeav 101 Feb 13, 2003 at 20:50

Its not so much a problem, more a preferance. When i write code, I like to know exactly whats going on, and exactly why im putting a line here or there. When i worked with SDL, it seemed to me, that tooooo much relied on implementation with SDL, it took over the input control, the window control etc, and it did it with code that kind of confused me. I guess my main grip was that I was goign to have to spend time relearning a bunch of stuff, when i could just as easily done it with GLUT, (be it a tad slower for input) but i dont think the way im using it realy matters all that much.

I dont know if SDL is faster at drawing a window though? Anyone know the performace hit, or enhancment of using SDL to swap buffers and such????

C24eb7e6aaefba78b94c831ddc7b4d0b
0
donBerto 101 Feb 14, 2003 at 14:06

I dont know if SDL is faster at drawing a window though? Anyone know the performace hit, or enhancment of using SDL to swap buffers and such????

I did a tiny bit of research [nothing in-depth] about SDL and GLUT and it’s hard to answer. from what I thought and what I found, GLUT sits right on top of OpenGL while SDL merely provides an interface for it. I couldn’t find anything about tests/performance results. anybody want to do a test? for shits and giggles I may just do it.

0684f9d33f52fa189aad7ac9e8c87510
0
baldurk 101 Feb 14, 2003 at 18:16

I have written code which completely modularises SDL into an SDL windowing class and an SDL input class. It would allow me to slot SDL out and use DirectInput or slot SDL out and use X11, with no effect to the rest of the code.