From e9e50497fc33da348e2ab7fda352022afdd3434b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20A=C3=9Fmus?= Date: Fri, 8 Apr 2011 18:34:11 +0000 Subject: [PATCH] Don't prevent shapes from being rendered when the global icon scale is larger than the maximum visibility scale of 4.0f. This just means you cannot prevent shapes from rendering in icons rendered larger than 256x256. visibility scale is 4.0 git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41206 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/libs/icon/IconRenderer.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/libs/icon/IconRenderer.cpp b/src/libs/icon/IconRenderer.cpp index 7d55ccc034..331f54be03 100644 --- a/src/libs/icon/IconRenderer.cpp +++ b/src/libs/icon/IconRenderer.cpp @@ -347,10 +347,14 @@ IconRenderer::_Render(const BRect& r) for (int32 i = 0; i < shapeCount; i++) { Shape* shape = fIcon->Shapes()->ShapeAtFast(i); - // don't render shape if the Level Of Detail falls out of range + // Don't render shape if the Level Of Detail falls out of range. + // That's unless the scale is bigger than the maximum + // MaxVisibilityScale of 4.0f. if (fGlobalTransform.scale() < shape->MinVisibilityScale() - || fGlobalTransform.scale() > shape->MaxVisibilityScale()) + || (fGlobalTransform.scale() > shape->MaxVisibilityScale() + && shape->MaxVisibilityScale() < 4.0f)) { continue; + } Transformation transform(*shape); transform.multiply(fGlobalTransform);