[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SDL vs GLUT



I was reading an earlier thread about OpenGL vs SDL for 2D, and it ended in 
saying that OpenGL is considerably faster than SDL in almost all cases simply 
because of hardware optimization. Then came up a mention of GLUT, and as I see 
it, GLUT and SDL are similar in that they're both utility toolkits.

My question:
What exactly are the differences between GLUT and SDL?

I've been reading through the GLUT docs, and from what I see:
Both are ported to at least Linux and Windows (SDL is a lot more, but those are 
my main targets)
Both offer high-level routines for initialization, windowing, event processing, 
etc.
GLUT uses callbacks for its events whereas SDL are "call-forwards?"
SDL offers blitting, and working with surfaces, wheras (I assume) with GLUT, 
I'd just be using OpenGL.
SDL offers a lot more other routines, that GLUT/OpenGL doesn't, or at least 
doesn't seem to (ie, reading image files, audio output, etc)

What other differences are there?

I've been learning SDL (from reading Programming Linux Games) but after reading 
that thread, I figure I might as well just start working with OpenGL, so I can 
get optimized 2D and then only add a few more things for 3D graphics. I know I 
can use SDL with OpenGL, but I kinda like the GLUT callback features, and might 
just look into using it instead.

Furthermore, are there any recommendations for books on OpenGL, preferably one 
that doesn't focus on a specifc OS?

Thanks
-- milan
ramaiya

---------------------------------------------
This message was sent using Endymion MailMan.
http://www.endymion.com/products/mailman/