From 6ee56a00e5be2738676dda25e48e10cf9874dae8 Mon Sep 17 00:00:00 2001 From: Stefano Ceccherini Date: Mon, 8 Sep 2008 14:42:38 +0000 Subject: [PATCH] added a comment explaining why the implementation should be moved to the server git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27383 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kits/interface/View.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/kits/interface/View.cpp b/src/kits/interface/View.cpp index 5c0bbbe85f..3efa6f3216 100644 --- a/src/kits/interface/View.cpp +++ b/src/kits/interface/View.cpp @@ -61,8 +61,6 @@ using std::nothrow; # define BVTRACE ; #endif -#define MAX_ATTACHMENT_SIZE 49152 - static property_info sViewPropInfo[] = { { "Frame", { B_GET_PROPERTY, 0 }, @@ -4400,7 +4398,10 @@ BView::_ClipToPicture(BPicture *picture, BPoint where, #if 1 // TODO: Move the implementation to the server!!! - + // This implementation is pretty slow, since just creating an offscreen bitmap + // takes a lot of time. That's the main reason why it should be moved + // to the server. + // Here the idea is to get rid of the padding bytes in the bitmap, // as padding complicates and slows down the iteration. // TODO: Maybe it's not so nice as it assumes BBitmaps to be aligned @@ -4433,7 +4434,7 @@ BView::_ClipToPicture(BPicture *picture, BPoint where, for (int32 y = 0; y < height; y++) { for (int32 x = 0; x < width; x++) { bit = *bits++; - if (bit != (uint32)-1) { + if (bit != 0xFFFFFFFF) { rect.left = x; rect.right = rect.left; rect.top = rect.bottom = y;