diff options
Diffstat (limited to 'dep/g3dlite/source/Stopwatch.cpp')
-rw-r--r-- | dep/g3dlite/source/Stopwatch.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/dep/g3dlite/source/Stopwatch.cpp b/dep/g3dlite/source/Stopwatch.cpp index 9b785d50295..713835ea7ab 100644 --- a/dep/g3dlite/source/Stopwatch.cpp +++ b/dep/g3dlite/source/Stopwatch.cpp @@ -105,15 +105,16 @@ void Stopwatch::reset() { void Stopwatch::after(const std::string& s) { RealTime now = System::time(); - debugPrintf("%s: %10s - %8fs since %s (%fs since start)\n", - myName.c_str(), - s.c_str(), - now - prevTime, - prevMark.c_str(), - now - startTime); + if (m_enabled) { + debugPrintf("%s: %10s - %8fs since %s (%fs since start)\n", + myName.c_str(), + s.c_str(), + now - prevTime, + prevMark.c_str(), + now - startTime); + } prevTime = now; prevMark = s; } } - |