Thread: debugging an OpenGL app

  1. #1
    Registered User MathFan's Avatar
    Join Date
    Apr 2002
    Posts
    190

    debugging an OpenGL app

    hi guys...
    I have always wondered how to debug say an OpenGL or a SDL app. 'Cause what I experience every time I try to debug my game is that the debugger (i've tried both the native KDevelop debugger and kdbg) just runs the app until it crashes and I'm not able to use any of the useful functions like step in, step out, watch etc.

    There is probably a very easy solution... so, ehh can anyone help me?

    Oh, yes. there is one more thing. if i have a class in my code named glWorld. then i declare glWorld World=new glWorld(); how can I add a watch on some variable inside World now? I've tried World::var and World->var and so on, but it doesn't seem to work.

    thnx
    The OS requirements were Windows Vista Ultimate or better, so we used Linux.

  2. #2
    Registered User linuxdude's Avatar
    Join Date
    Mar 2003
    Location
    Louisiana
    Posts
    926
    the same way you debug any other program. Do you know how to use gdb? I can't answer your second question I only program in C right now.

  3. #3
    Registered User MathFan's Avatar
    Join Date
    Apr 2002
    Posts
    190
    Well, no I haven't used gdb, but I'll try it. thnx

    But: r u sure it's that simple? u don't need to specify what libraries executable uses or anything?

    and what if my game is running fullscreen?
    Last edited by MathFan; 07-09-2004 at 07:20 AM.
    The OS requirements were Windows Vista Ultimate or better, so we used Linux.

  4. #4
    Registered User linuxdude's Avatar
    Join Date
    Mar 2003
    Location
    Louisiana
    Posts
    926
    gdb tells you were your program goes arrai(I know that is wrong) It tells you what function or whatever screws with your memory. It doesn't matter what libraries. If all else fails post the code here.

  5. #5
    Registered User MathFan's Avatar
    Join Date
    Apr 2002
    Posts
    190
    Thanx, I've got it working all right now...
    The OS requirements were Windows Vista Ultimate or better, so we used Linux.

  6. #6
    Registered User linuxdude's Avatar
    Join Date
    Mar 2003
    Location
    Louisiana
    Posts
    926
    what was wrong? Could you tell us?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Linking OpenGL in Dev-C++
    By linkofazeroth in forum Game Programming
    Replies: 4
    Last Post: 09-13-2005, 10:17 AM
  2. OpenGL Window
    By Morgul in forum Game Programming
    Replies: 1
    Last Post: 05-15-2005, 12:34 PM
  3. OpenGL .dll vs video card dll
    By Silvercord in forum Game Programming
    Replies: 14
    Last Post: 02-12-2003, 07:57 PM
  4. OpenGL and Windows
    By sean345 in forum Game Programming
    Replies: 5
    Last Post: 06-24-2002, 10:14 PM
  5. opengl code not working
    By Unregistered in forum Windows Programming
    Replies: 4
    Last Post: 02-14-2002, 10:01 PM