writing to the console?

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
powerpop
Posts: 171
Joined: Thu Jan 08, 2004 1:39 am
Location: san francisco

writing to the console?

Post by powerpop »

another silly question - but i cant find an example or posting here in the forums

how do i send some text to the console?
keless
Posts: 805
Joined: Mon Dec 15, 2003 10:37 pm
Location: Los Angeles, California, USA

Post by keless »

simple 'printf()' or 'cout' calls
a screen cap is worth 0x100000 DWORDS
qwe
Posts: 112
Joined: Sun Dec 28, 2003 12:54 am
Location: Oregon, USA

Post by qwe »

under 0.4.2 you can call device->getLogger()->log(L"message") to output to the console as well. do something like

Code: Select all

ILogger* logger = device->getLogger();
logger->log(L"output to console");
i think that's how to do it 8)
tstuefe
Posts: 40
Joined: Wed Jan 07, 2004 12:53 pm
Location: Heidelberg, Germany
Contact:

Post by tstuefe »

check irr::os::Printer, eg irr::os::Printer::log or irr::os::Printer::print
powerpop
Posts: 171
Joined: Thu Jan 08, 2004 1:39 am
Location: san francisco

Post by powerpop »

i dont see an os namespace in IRR - so the above would be irr:ILogger*

i am not up to 4.2 yet - want to get my app running as it is and then upgrade for the new stuff

for now maybe i will just write to the caption window for the little text output i need to see

so the window caption wants a wchar_t and my text in my code is in a std:string - so how does one convert one type of text to another - i find wchar_t and c8 confusing - can someone describe how these different string types work and how to convert then - for instance, sometimes i want to move a string over to a char so i do a strcpy from string.c_str() to get the actual characters - what would i use for grabbing the text elements of wchar_t and c8 ??

i am gathering up all my questions as i get to know how IRR works and i hope to publish them as some kind of intro document for new users

while i am at it:
- what is the base orientation of IRR - which direction are x,y,z set?

and is it indeed true that the default for objects is to have x,z set to the middle of an object and y to be at the base?
Last edited by powerpop on Fri Jan 09, 2004 10:20 pm, edited 3 times in total.
qwe
Posts: 112
Joined: Sun Dec 28, 2003 12:54 am
Location: Oregon, USA

Post by qwe »

I belive you are correct
Post Reply