Changed wxImage.ResampleBox to always use a box size of at least 2 by 2 pixels.
authorDimitri Schoolwerth <dimitri.schoolwerth@gmail.com>
Tue, 15 Mar 2011 16:37:04 +0000 (16:37 +0000)
committerDimitri Schoolwerth <dimitri.schoolwerth@gmail.com>
Tue, 15 Mar 2011 16:37:04 +0000 (16:37 +0000)
commit41774f1b20ee2462d04f032eb4740cb97346e2ec
tree4f53dd537d510a8f63a4b90314ed4c23f69854af
parentbd448041e742f66b43c74bfddd2dfbda8680394a
Changed wxImage.ResampleBox to always use a box size of at least 2 by 2 pixels.

Previously when resizing by more than 50% (for example resizing from 100x100 to 51x51 or 140x140) a box size of 1x1 would be used which effectively would give the same result as using nearest neighbour. Make sure that at least a box size of 2x2 pixels is always used.

Patch by scottb, see also #12845.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67202 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
src/common/image.cpp