diff --git a/graphics/text_element.cpp b/graphics/text_element.cpp index 924b7516a1..b2bea7aaff 100644 --- a/graphics/text_element.cpp +++ b/graphics/text_element.cpp @@ -119,10 +119,14 @@ namespace graphics resInfos[i] = &glyphInfos[i]; } - if (firstVis != lastVis) - screen->mapInfo(&resInfos[firstVis], - &glyphIDs[firstVis], - lastVis - firstVis); + if ((firstVis != lastVis) + && !screen->mapInfo(&resInfos[firstVis], + &glyphIDs[firstVis], + lastVis - firstVis)) + { + LOG(LINFO, ("cannot render string", lastVis - firstVis, "characters long")); + return; + } for (unsigned i = firstVis; i < lastVis; ++i) { diff --git a/map/tiling_render_policy_mt.cpp b/map/tiling_render_policy_mt.cpp index ab78262a76..fc62f1dfc1 100644 --- a/map/tiling_render_policy_mt.cpp +++ b/map/tiling_render_policy_mt.cpp @@ -23,6 +23,8 @@ TilingRenderPolicyMT::TilingRenderPolicyMT(Params const & p) ResourceManager::TexturePoolParams tpp; ResourceManager::StoragePoolParams spp; + int k = int(ceil(VisualScale())); + tpp = ResourceManager::TexturePoolParams(512, 512, 1, @@ -32,8 +34,8 @@ TilingRenderPolicyMT::TilingRenderPolicyMT(Params const & p) rmp.m_textureParams[tpp.m_textureType] = tpp; - tpp = ResourceManager::TexturePoolParams(256, - 256, + tpp = ResourceManager::TexturePoolParams(256 * k, + 256 * k, 1, rmp.m_texFormat, EMediumTexture, @@ -50,8 +52,8 @@ TilingRenderPolicyMT::TilingRenderPolicyMT(Params const & p) rmp.m_textureParams[tpp.m_textureType] = tpp; - tpp = ResourceManager::TexturePoolParams(128, - 128, + tpp = ResourceManager::TexturePoolParams(128 * k, + 128 * k, 4, rmp.m_texFormat, ESmallTexture,