]> git.saurik.com Git - wxWidgets.git/commit
Use floating point arithmetic in wxDC::GradientFillConcentric().
authorVadim Zeitlin <vadim@wxwidgets.org>
Thu, 28 Oct 2010 14:23:18 +0000 (14:23 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Thu, 28 Oct 2010 14:23:18 +0000 (14:23 +0000)
commitd176b30156f3e215df74eaa0c2494f0c267beb5f
tree0477c51d326d034203f6366623c495708c799ccc
parent7825e3217173eac7366a2b9bffc39f8d22603536
Use floating point arithmetic in wxDC::GradientFillConcentric().

Use doubles to avoid accumulated rounding errors from using integers in the
generic implementation of wxDC::GradientFillConcentric(). This results in
smoother gradient.

Also avoid using the expensive pow() function inside the inner loop when we
just need to calculate a square.

Closes #12337.

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