Not console application. Is possilbe?
Not console application. Is possilbe?
Hello every one. I'm new in that of irrlicht and I'm doing some tuturials. I'm using CodeBlocks and VC++ compiler. All is going "fine" (for now) but I have a question. Is it possible maque the "game" a non console application?
When I compile the project, one of the settings is "console application" and when I run it display a console that opens a window. So I want to star the application without the "console window" so I don't have the two windows (console and "game")
Is that possible? Or could I hide the console? When I change to proyect form console application to window application I get a Linker error.
Thanks in advance.
PD: Sorry if I don't write so well, I'm spanish.
When I compile the project, one of the settings is "console application" and when I run it display a console that opens a window. So I want to star the application without the "console window" so I don't have the two windows (console and "game")
Is that possible? Or could I hide the console? When I change to proyect form console application to window application I get a Linker error.
Thanks in advance.
PD: Sorry if I don't write so well, I'm spanish.
Its possible. Under compiler settings targets (in codeblocks anyway) you can choose console or window app.
I find the console very useful when debugging though, but wont be needed for release version.
I find the console very useful when debugging though, but wont be needed for release version.
C++/Irrlicht Noob pl3se B p4t1ent.
Visit www.d-grafix.com
Visit www.d-grafix.com
Yes you can do it the way that dgrafix explained, or you can just do(on Windows):
instead of
Code: Select all
#include <windows.h>
...
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
Code: Select all
int main()
int main(int argc, char **argv)
int main(int argc char *argv[])
etc.
TheQuestion = 2B || !2B
This is how I do it in my engine.
Code: Select all
//! Define _NGE_DISABLE_CONSOLE_ON_VC_RELEASE to enable console Only on Debug build with VC.
/*! This shows console only when the engine is compiled on Debug build. Release build
wont have the console shown. Comment this line out to disable this feature which means
the console will always be shown. */
#define _NGE_DISABLE_CONSOLE_ON_VC_RELEASE
#if defined(_NGE_DISABLE_CONSOLE_ON_VC_RELEASE)
# if(GAME_PLATFORM == PLATFORM_WIN32) && (GAME_COMPILER == COMPILER_MSVC)
# if BUILD_TYPE == DEBUG_BUILD
# pragma comment(linker, "/subsystem:console")
# else
# pragma comment(linker, "/subsystem:windows /ENTRY:mainCRTStartup")
# endif
# endif
#endif
-
- Posts: 362
- Joined: Sun Dec 16, 2007 9:25 pm
Thanks MasterGod! Thats a good code snippetMasterGod wrote:[helpful code]
Post this userbar I made on other websites to show your support for Irrlicht!
http://img147.imageshack.us/img147/1261 ... wernq4.png
http://img147.imageshack.us/img147/1261 ... wernq4.png
Thanks for the info. I solved adding to debug compilation
and to de release compilation
Now, I got another problem. I have that error in debug mode. I was reading about it, and all says that I just could ignore it. Is there anyway to solve it?
Code: Select all
/subsystem:console
Code: Select all
/subsystem:windows
/ENTRY:mainCRTStartup
Now, I got another problem. I have that error in debug mode. I was reading about it, and all says that I just could ignore it. Is there anyway to solve it?
Code: Select all
LIBC.lib(sbheap.obj)||warning LNK4099: PDB 'libc.pdb' was not found with 'C:\Archivos de programa\Microsoft Visual C++ Toolkit 2003\lib\LIBC.lib' or at 'D:\****\bin\Debug\libc.pdb'; linking object as if no debug info|
-
- Admin
- Posts: 3590
- Joined: Mon Oct 09, 2006 9:36 am
- Location: Scotland - gonnae no slag aff mah Engleesh
- Contact:
Code::Blocks using what compiler?
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way