diff --git a/src/config/user_config.hpp b/src/config/user_config.hpp index 0f045acea..802a296c3 100644 --- a/src/config/user_config.hpp +++ b/src/config/user_config.hpp @@ -284,6 +284,12 @@ enum AnimType {ANIMS_NONE = 0, */ namespace UserConfigParams { + /** Some constants to bitmask to enable various messages to be printed. */ + enum { LOG_MEMORY = 0x0001, + LOG_GUI = 0x0002, + LOG_ADDONS = 0x0004, + LOG_MISC = 0x0008}; + // ---- Audio PARAM_PREFIX GroupUserConfigParam m_audio_group PARAM_DEFAULT( GroupUserConfigParam("Audio", "Audio Settings") ); diff --git a/src/tracks/track.cpp b/src/tracks/track.cpp index 0b4007d28..cdc44b220 100644 --- a/src/tracks/track.cpp +++ b/src/tracks/track.cpp @@ -176,7 +176,7 @@ void Track::cleanup() // remove temporary materials loaded by the material manager material_manager->popTempMaterial(); - if(UserConfigParams::m_verbosity>=3) + if(UserConfigParams::m_verbosity&UserConfigParams::LOG_MEMORY) printf("[memory] Number of meshes in cache after cleaning up '%s': %d.\n", getIdent().c_str(), irr_driver->getSceneManager()->getMeshCache()->getMeshCount()); @@ -941,7 +941,7 @@ void Track::createWater(const XMLNode &node) void Track::loadTrackModel(World* parent, unsigned int mode_id) { assert(m_all_cached_meshes.size()==0); - if(UserConfigParams::m_verbosity>=3) + if(UserConfigParams::m_verbosity&UserConfigParams::LOG_MEMORY) printf("[memory] Number of meshes in cache before loading '%s': %d.\n", getIdent().c_str(), irr_driver->getSceneManager()->getMeshCache()->getMeshCount()); @@ -1255,7 +1255,7 @@ void Track::loadTrackModel(World* parent, unsigned int mode_id) printf("Lap counting will not work, and start positions might be incorrect.\n"); } - if(UserConfigParams::m_verbosity>=3) + if(UserConfigParams::m_verbosity&UserConfigParams::LOG_MEMORY) printf("[memory] Number of meshes in cache after loading '%s': %d.\n", getIdent().c_str(), irr_driver->getSceneManager()->getMeshCache()->getMeshCount());