Disabled some logs in Release and Production

This commit is contained in:
Alex Zolotarev 2011-12-07 17:29:54 +03:00 committed by Alex Zolotarev
parent 042c79b1b5
commit 6f096ed00c
5 changed files with 25 additions and 16 deletions

View file

@ -19,7 +19,7 @@
RenderPolicy::~RenderPolicy()
{
LOG(LINFO, ("clearing cached drawing rules"));
LOG(LDEBUG, ("clearing cached drawing rules"));
drule::rules().ClearCaches();
}

View file

@ -60,11 +60,11 @@ void RenderQueueRoutine::Cancel()
if (m_currentRenderCommand != 0)
{
LOG(LINFO, ("cancelling current renderCommand in progress"));
LOG(LDEBUG, ("cancelling current renderCommand in progress"));
m_currentRenderCommand->m_paintEvent->Cancel();
}
LOG(LINFO, ("waking up the sleeping thread..."));
LOG(LDEBUG, ("waking up the sleeping thread..."));
m_hasRenderCommands.Signal();
}
@ -264,7 +264,7 @@ void RenderQueueRoutine::Do()
if (IsCancelled())
{
LOG(LINFO, ("thread is cancelled while waiting for a render command"));
LOG(LDEBUG, ("thread is cancelled while waiting for a render command"));
break;
}
@ -351,7 +351,7 @@ void RenderQueueRoutine::Do()
if (IsCancelled())
{
LOG(LINFO, ("cancelled before processing currentRenderCommand"));
LOG(LDEBUG, ("cancelled before processing currentRenderCommand"));
}
else if (m_currentRenderCommand != 0)
{
@ -475,7 +475,7 @@ void RenderQueueRoutine::addWindowHandle(shared_ptr<WindowHandle> window)
void RenderQueueRoutine::Invalidate::perform()
{
if (isDebugging())
LOG(LINFO, ("performing Invalidate command"));
LOG(LDEBUG, ("performing Invalidate command"));
for_each(m_windowHandles.begin(),
m_windowHandles.end(),
bind(&WindowHandle::invalidate, _1));

View file

@ -129,7 +129,7 @@ namespace yg
if (!fin)
break;
LOG(LINFO, ("whitelisting ", fontName, " for ", ubName));
LOG(LDEBUG, ("whitelisting ", fontName, " for ", ubName));
if (ubName == "*")
for (unicode_blocks_t::iterator it = m_unicodeBlocks.begin(); it != m_unicodeBlocks.end(); ++it)
@ -164,7 +164,7 @@ namespace yg
if (!fin)
break;
LOG(LINFO, ("blacklisting ", fontName, " for ", ubName));
LOG(LDEBUG, ("blacklisting ", fontName, " for ", ubName));
if (ubName == "*")
for (unicode_blocks_t::iterator it = m_unicodeBlocks.begin(); it != m_unicodeBlocks.end(); ++it)
@ -262,7 +262,7 @@ namespace yg
ASSERT ( ccIt != charcodes.end(), () );
if ((*ccIt > lastUBEnd) && (*ccIt < ubIt->m_start))
{
LOG(LINFO, ("Symbol with code ", (uint16_t)*ccIt, " present in font lies between two unicode blocks!"));
LOG(LDEBUG, ("Symbol with code ", (uint16_t)*ccIt, " present in font lies between two unicode blocks!"));
}
if (ubIt->hasSymbol(*ccIt))
break;
@ -370,7 +370,7 @@ namespace yg
{
if (it->m_fonts.empty())
{
LOG(LINFO, ("querying symbol for empty ", it->m_name, " unicode block"));
LOG(LDEBUG, ("querying symbol for empty ", it->m_name, " unicode block"));
it->m_fonts.push_back(m_fonts.front());
}

View file

@ -34,6 +34,7 @@ namespace yg
void DumpGLInformation()
{
#ifndef OMIM_PRODUCTION
LOG(LINFO, ("OpenGL Information"));
LOG(LINFO, ("--------------------------------------------"));
LOG(LINFO, ("Vendor : ", glGetString(GL_VENDOR)));
@ -53,6 +54,7 @@ namespace yg
}
LOG(LINFO, ("--------------------------------------------"));
#endif
}
bool g_isBufferObjectsSupported = true;

View file

@ -132,9 +132,11 @@ namespace yg
if (!m_isFixedBufferCount)
m_storagesCount *= k;
LOG(LINFO, ("resizing ", m_poolName));
LOG(LINFO, (" from : ", oldVBSize / m_vertexSize, " vertices, ", oldIBSize / m_indexSize, " indices, ", oldStoragesCount, " storages, ", oldMemoryUsage, " bytes total"));
LOG(LINFO, (" to : ", m_vbSize / m_vertexSize, " vertices, ", m_ibSize / m_indexSize, " indices, ", m_storagesCount, " storages, ", memoryUsage(), " bytes total"));
#ifndef OMIM_PRODUCTION
LOG(LINFO, ("resizing", m_poolName));
LOG(LINFO, ("from:", oldVBSize / m_vertexSize, "vertices,", oldIBSize / m_indexSize, "indices,", oldStoragesCount, "storages,", oldMemoryUsage, "bytes total"));
LOG(LINFO, ("to :", m_vbSize / m_vertexSize, "vertices,", m_ibSize / m_indexSize, "indices,", m_storagesCount, "storages,", memoryUsage(), "bytes total"));
#endif
}
void ResourceManager::StoragePoolParams::distributeFreeMemory(int freeVideoMemory)
@ -146,8 +148,10 @@ namespace yg
}
else
{
#ifndef OMIM_PRODUCTION
if (m_vbSize && m_vertexSize && m_ibSize && m_indexSize)
LOG(LINFO, (m_poolName, " : ", m_vbSize / m_vertexSize, " vertices, ", m_ibSize / m_indexSize, " indices, ", m_storagesCount, " storages, ", memoryUsage(), " bytes total"));
#endif
}
}
@ -218,8 +222,10 @@ namespace yg
}
else
{
#ifndef OMIM_PRODUCTION
if (m_texWidth && m_texHeight && m_texCount)
LOG(LINFO, (m_poolName, " : ", m_texWidth, "x", m_texHeight, ", ", m_texCount, " textures, ", memoryUsage(), " bytes total"));
#endif
}
}
@ -273,10 +279,11 @@ namespace yg
if (!m_isCountFixed)
m_texCount *= k;
#ifndef OMIM_PRODUCTION
LOG(LINFO, ("scaling memory usage for ", m_poolName));
LOG(LINFO, (" from : ", oldTexWidth, "x", oldTexHeight, ", ", oldTexCount, " textures, ", oldMemoryUsage, " bytes total"));
LOG(LINFO, (" to : ", m_texWidth, "x", m_texHeight, ", ", m_texCount, " textures, ", memoryUsage(), " bytes total"));
#endif
}
ResourceManager::GlyphCacheParams::GlyphCacheParams()
@ -331,7 +338,7 @@ namespace yg
if (videoMemoryLimit < fixedMemoryUsage())
{
LOG(LINFO, ("videoMemoryLimit ", videoMemoryLimit," is less than an amount of fixed resources ", fixedMemoryUsage()));
LOG(LINFO, ("videoMemoryLimit", videoMemoryLimit,"is less than an amount of fixed resources", fixedMemoryUsage()));
videoMemoryLimit = memoryUsage();
}
@ -340,7 +347,7 @@ namespace yg
/// distributing free memory according to the weights
distributeFreeMemory(freeVideoMemory);
LOG(LINFO, ("resizing from ", oldMemoryUsage, " bytes to ", memoryUsage(), " bytes of video memory"));
LOG(LINFO, ("resizing from", oldMemoryUsage, "bytes to", memoryUsage(), "bytes of video memory"));
}
int ResourceManager::Params::memoryUsage() const