0

I'm trying to make a game with freeglut, but im still learning it and I don't fully understand what the looping does or whether I have to call it myself,

I've already read this article A good way to build a game loop in OpenGL and didn't understand the answers

I get that glutmainloop() will call whatever I set in glutdisplayfunc() but I don't know how often or where I should put the game loop code

So my question is Where do I put the game loop code and how do I call it?

Vaillancourt
  • 16,325
  • 17
  • 55
  • 61
Jim Jones
  • 153
  • 6
  • Spencer, did you see the link that was provided in your previously closed question about this? http://gamedev.stackexchange.com/questions/8623/a-good-way-to-build-a-game-loop-in-opengl – Inisheer Mar 29 '13 at 21:35
  • Yes, that's the link I have posted in this post it doesn't really fully explain the glutmainloop and it's more about setting a timestep – Jim Jones Mar 30 '13 at 01:00
  • @SpencerKillen: Of course it didn't fully explain the glutMainLoop; It specifically said not to use GLUT. That's your answer: Stop using FreeGLUT and switch to something else if you're making a game – Nicol Bolas Mar 30 '13 at 03:23
  • if its so bad why are there so many tutorials for game dev using it? – Jim Jones Mar 30 '13 at 05:25
  • 1
    because it's been around for quite some time, although that doesn't say anything about the quality or usablity – cppanda Mar 30 '13 at 14:20

0 Answers0