Debug console
[Main]


Defines

#define oslPrintf(format...)   ({ char __str[1000]; sprintf(__str , ##format); oslConsolePrint(__str); })
#define oslPrintf_xy(x, y, str, format...)
#define oslCls()   (oslClearScreen(0), oslMoveTo(0,0))
#define oslMoveTo(x, y)   (osl_consolePosX=x*osl_sceFont->charWidths['0'], osl_consolePosY=y*osl_sceFont->charHeight)

Detailed Description

Debugging features.

Define Documentation

#define oslPrintf ( format...   )     ({ char __str[1000]; sprintf(__str , ##format); oslConsolePrint(__str); })

Prints formatted text to the current position of the cursor. The format system is the same as printf (you can find the description in every good C tutorial or documentation).

#define oslPrintf_xy ( x,
y,
str,
format...   ) 

Value:

({                      osl_consolePosX=x, osl_consolePosY=y;           \
                                                                                                                                oslPrintf(str,##format); })
Prints formatted text at a specific position on the screen.
//Display the value of a variable on the top-left screen corner
oslPrintf_xy(0, 0, "Frame: %i", frameNumber);

 
#define oslCls (  )     (oslClearScreen(0), oslMoveTo(0,0))

Clears the screen (to black) and resets the cursor to the top-left corner of the screen.

oslCls();
oslPrintf("Welcome...\n");

#define oslMoveTo ( x,
 )     (osl_consolePosX=x*osl_sceFont->charWidths['0'], osl_consolePosY=y*osl_sceFont->charHeight)

Moves the cursor to a place on the screen. The x, y coordinates are indicated in terms of characters (by default 8x8 pixels, but depends on the current font).


Generated on Wed Feb 24 10:25:31 2010 by  doxygen 1.5.9