News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

When using SDL I can't cout anything

Started by Duncan, May 14, 2009, 06:47:46 AM

Previous topic - Next topic

Duncan

Hi I'm using a Windows XP Machine with Code Blocks and the MinGW Compiler.

I've been using SDL for my graphical API lately but for some reason if, for debugging purposes, in my program I try to cout something:
cout << "Ball's X: " ball.x << endl;

I get no output in the console window.

Is there some option that I need to check.. or some other way to get this to work as desired... or is it an unfortunate reality?

Thanks!

Jenna

Searching the forum for "no console output" gave me this thread as first: http://forums.next.codeblocks.org/index.php/topic,10409.0.html

Most likely you have the same problem.

For the next time, please search the forum and/or the web first.

thomas

You get no console output for another reason, and that is because you use SDL. This library redirects standard output and standard error into files. Their documentation explains how to disable this feature (I don't remember, need to #define something...)
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."