[wx-dev] wxImage scaling patch, useful vs. feature creep

Vadim Zeitlin vadim at wxwindows.org
Sun Sep 3 17:52:56 PDT 2006


On Sun, 03 Sep 2006 15:27:09 +0200 Robert Roebling <robert at roebling.de> wrote:

RR> there is a patch for better (higher quality but
RR> slower) image scaling including docs.
RR> 
RR> https://sourceforge.net/tracker/index.php?func=detail&aid=1537065&group_id=9863&atid=309863
RR> 
RR> This looks nice, but could be called inappropriate
RR> featurism. I'm usually thinking that binary size
RR> if mostly irrelavant and a patch that is potentially
RR> useful and documented should be applied.

 The binary size is indeed mostly irrelavant. But not always. For example,
it surely does count for embedded systems. And it's true that wxImage is
one of the biggest classes in wx already and, what worries me more, there
are literally no bounds for improving and extending it further. I believe
we need to find a way to factor out functionality out of it in separate
files (or, better yet, loadable modules) if we don't want it to collapse
under its own weight.

 For now I think the very least we can do is to split image.cpp, which is
currently one of the largest files in src/common, in several parts. One
containing the required stuff and other(s) with more optional things, such
as scaling, rotation, conversion to grey scale/monochrome, RGB <-> HSV and
so on. This would already help for static linking and if we have
wxUSE_IMAGE_XXX constants for subfeature control it should also help to
reduce the size of the shared builds of wx, like the one we're working on
right now.

 Thanks,
VZ





More information about the wx-dev mailing list