C++ + OpenGL - where do I begin

Started by
1 comment, last by 21st Century Moose 12 years, 1 month ago
Hi! I want to make games using c++ and opengl. However I dont know where to start.
-which and what files should I download?
-which IDE would you recommend me?
-how do I start using OpenGL in C++?
-what is a typical base for a game in c++?
-what files does opengl have and where should i put them relative to the folder of my project? are there dlls and such?
thanks in advance

p.s. currently i have only visual studio 2008 - is it good for making games?
Advertisement
If you are new to OpenGL, I wouldn't recommand starting to make a game already. If you want to make a game right away, use a game engine like Ogre3D. If you want to learn OpenGL first and then make a game, start with some simple test applications first and once you know OpenGL start thinking about making a game. That is assuming you do know C++ already, if not don't even start with OpenGL yet but first learn the language.

If you do plan to jump into OpenGL right now, you should really try to use the Core profile from the beginning. You must be careful, there are many OpenGL tutorials still based on outdated OpenGL versions with glBegin() like stuff in it. I would say start with at least OpenGL 3.3, if you do manage to make a game eventually this will run on most PCs from the last 5 years and is easier to upgrade to OpenGL 4.x in the future.
If you have Visual Studio 2008 then you don't need to download anything - everything you need for OpenGL development is already there on your machine.

There are a few things that will make your life easier, however.

An extension-handling library (like GLEW), while not essential, will save you a lot of code-grinding and headaches.
Some kind of debugging/logging/trace tool is always useful. I personally like GLIntercept for logging, and while I don't have much experience with it, I believe that gDEBugger comes with a good reputation.
Up to date drivers always help, of course.

I initially learned OpenGL by taking the old Quake source code and playing around with it - most definitely not an approach I would recommend to anyone. The ArcSynthesis tutorials seem well-regarded as an online resource, and the SuperBible seems to be the popular dead-tree option. I've found the CodeSampler pages useful too, although I need to admit that I've used the D3D stuff there much more than I've used the OpenGL stuff. The old NeHe tutorials are often recommended but best avoided - they're well out of date and contain quite a few bad practices. Speaking of which, whatever you choose, arm yourself with a copy of the OpenGL.org Common Mistakes page - not only does it correct some really really bad things in tutorials but it can also help protect you from going down the wrong way of thinking on a few matters.

Direct3D has need of instancing, but we do not. We have plenty of glVertexAttrib calls.

This topic is closed to new replies.

Advertisement