Skip to main content
GameDev.net gamedev.net
🔒 Locked

Debugging SDL

Started by matrisking Jun 11, 2010 at 8:50 PM 4 replies 1.1k views
Original Post
matrisking
matrisking
I'm still trying to find my way around Visual C++ 2008's debugger. One thing I really don't understand is why nothing seems to work when I debug instead of build and run the binary on its own. Whenever I debug the window appears but nothing is drawn, the game doesn't start, I can't move around the screen, etc.

How do I run programs using SDL through the debugger?

Thanks in advance!
Juanxo
Juanxo
sorry if you know this already, but you need to hit F5 to debug. Perhaps you have any breakpoint that don't let you continue?
matrisking
matrisking
Thanks for the tips. Yeah, I hit F5 to debug, and it doesn't really make a difference if I set breakpoints or not.
Juanxo
Juanxo
Perhaps you could upload your code and let us try it. I have vs2008 and i can take a look to your problem
matrisking
matrisking
Hm... I figured out what the problem is... I don't really have a firm understanding of where it's debugging "from" (that is, what the current working directory is in debug), but when I switched from relative paths to absolute paths for my media, it worked. I guess I need a better directory structure.

Thanks for the help, everyone.
Juanxo
Juanxo
when debugging, default working directory is where you have the "main.cpp" file

Topic Locked

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

Sign in to reply to this topic.