Re: [AD] configurable logging |
[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]
Peter Wang wrote:
I think it's a fine idea. Sounds like log4j, etc.
Well, committed what I have here. For now I made it so by default the log level is "debug" which means everything is logged, and also the default format is with line numbers, function names and timestamps. Should probably be changed to "info" level and a simply format which looks like the current logs.
Whenever someone sees a TRACE in code, it should be changed to one of ALLEGRO_DEBUG, ALLEGRO_INFO, ALLEGRO_WARN or ALLEGRO_ERROR now. The latter three are directly corresponding to PREFIX_I, PREFIX_W and PREFIX_E. As for ALLEGRO_DEBUG, I used it instead of ALLEGRO_INFO in places where there was excessive logging (log info for each keyboard key, each video mode, each pixel format, each opengl extension...).
-- Elias Pschernig <elias@xxxxxxxxxx>
Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |