Linux vs Windows

Is it relatively easy to write an application in openGL to run on both Linux and Windows?

Thanks,

Rick

Yes, if you use libraries that have both Linux and Windows ports. A GLUT program for example should compile and run on both platforms without any changes.

hi!

if you need more than just an opengl window and some event handling routines, then you should try http://www.libsdl.org .
it’s similar to directx, but simpler, easier, and of course it uses opengl for 3d. also, with sdl-addon libraries, you can use network, fonts, threading… and all platform independant. give it a try :wink:

cheers,
Tolga.

I agree about sdl, I’ve been using sdl under windoze and linux and have recently started using the sdl_image package to load all my textures. The only problem is that sdl loads images upside down and inverted. However, with the sdl_image package you can load tga’s, bmp’s, tiff’s, jpg’s,…etc.

I use the SDL_GetTick() command for a timer, can anyone comment on how this timer compares with other timers as far as resolution and performance are concerned?

boris

hi again,

I agree about sdl, I’ve been using sdl under windoze and linux and have recently started using the sdl_image package to load all my textures. The only problem is that sdl loads images upside down and inverted.

hm, i haven’t used sdl_image yet, but i guess that shouldn’t be a problem. you can either switch your texture-coords or you write a simple routine (i believe one of the nehe tutorials use a switching function for bmp, since it’s “by nature” reverted).

good luck :wink:
bye,
Tolga.

oh, i forgot the timer:

afaik, the timer function is quite good, and it’s resolution is about 10 ms, but don’t send me to hell, if i was wrong.
the man page says, SDL_GetTicks(Uint32 t) returns at least the value for t (in ms).

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.