TrustedUser
574
edits
(Improved Documentation For Debugging.) |
|||
Line 1: | Line 1: | ||
== Debug Output == | |||
== Tips == | The functions in common/debug.* provide a basic debug output interface in a platform portable form. | ||
The debuglevel is a global single integer which varies between -1 (minimum - default) and 11 (maximum).<br> | |||
This parameter indicates increasing verbosity of debug output, but does not seperate by function.<br> | |||
This is set by passing the command line parameter, -d <int> to scummvm at runtime.<br> | |||
Debugflags (also known as Debug Channels) are booleans and are engine specific.<br> | |||
An engine can have up to 32 channels.<br> | |||
These can be set by passing the command line parameter, --debugflags=<flag1, flag2, ...> to scummvm at runtime.<br> | |||
They are generally preferred to just using debuglevel, since they allow separation of debug output | |||
into clearly named groupings and can be changed during runtime using the debug console.<br> | |||
== Interactive Engine Debugging == | |||
Most of the ScummVM engines implement the debug console.<br> | |||
The key combination to open this is CTRL-d (though this can be vary by engine if it conflicts with gameplay - See README).<br> | |||
<br> | |||
The default console provides the following default commands :<br> | |||
* help : Display the list of available commands<br> | |||
* quit : Exit the debug console<br> | |||
* debugflag_list : list the available debug flags and their status<br> | |||
* debugflag_enable <debugflag> : enable a given debugflag<br> | |||
* debugflag_disable <debugflag> : disable a given debugflag<br> | |||
This can be extended with further engine-specific commands.<br> | |||
TODO: Document commands for specific engines, or link to subpages in each engine for this.<br> | |||
TODO: Document debug flags/levels for the various ports.<br> | |||
== Tips == | |||
* To prevent SDL from catching segmentation faults (the ''SDL Parachute''), add the following key to the configuration file under <nowiki>[scummvm]</nowiki>: | * To prevent SDL from catching segmentation faults (the ''SDL Parachute''), add the following key to the configuration file under <nowiki>[scummvm]</nowiki>: | ||
disable_sdl_parachute=true | disable_sdl_parachute=true |