Skip to main content
gamedev.net
🔒 Locked

Sample Learning programs :

Started by tnutty Mar 4, 2009 at 6:42 PM 4 replies 600+ views
Original Post
tnutty
tnutty
hi, Since there are a lot of people that are learning opengl, including me, I thought it would be nice to post some small programs so others could learn. Those small programs mostly consisting of, using geometry, trigonometry, physics, textures, camera. I know there are a bunch of stuff on this, but, more is always better. Plus we can see, from you professionals, or rookies what ways to code, how to code, if there are any dynamic way around certain things. Please would you post a sample code of your including a title at the top of what it is supposed to do, like create a blinking cube, or jumping, or turning a camera 2pi around with keyboard action, or any other cool programs you have made. regards, TNUTTY
Our whole life is a opengl application.
tnutty
tnutty
Ya I know. I thought it would help people and me to learn opengl better.

I get that pure source code reading is bad, because most of the time it seems mysterious. But I wasn't implying that there should be no context. I mean
if you comment on the particular line then sooner or later, people will realize that a there is a certain pattern when loading texture, creating terrains, or
optimizing. So the more they see that, the more chance it will click.
I definitely realize that reading code is very bad way of learning for beginners. But if you are past the beginning stage and could comprehend some of the code that some people write (with comments) then he should be fine?

After all don't you include comments in your code, and comments, technically is
context, right?

If anyone does not want to post a sample code, then that is fine, if
you are kind enough to post you code that looks user friendly (has comment/context), then that is great! It will help a lot of aspiring Game programmers, or Opengl users. I know it will definitely benefit me.

And yes I know about Nehe. Its pretty good, but I believe it can be improved.
Our whole life is a opengl application.
Gauge
Gauge
also on this, nehe is good, but often times most people who use openGL want nothing to do with windows API. Also nehe very rarely makes examples what would represent how things are done in a game engine. Learning openGL and using it for a game engine are very separate tasks. Both have unique questions and problems. At least that is from my very limited standpoint. I'm still very much an openGL noob.
tnutty
tnutty
Thanks, I know but, this does not have to be for a gaming purposes. First it should be for learning purpose.

And at first Nehe is intimidating for beginners, because of the API, but I'll just ignore that for now.

Our whole life is a opengl application.
V-man
V-man
That's why they have written The Red Book and it has sample code and it uses GLUT to hide all the OS specific stuff. There are other lib that do the same thing like freeGLUT, SDL, FTGL and a bunch of others.

There is this as well
http://www.opengl.org/code/

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.