vcl/source/outdev/bitmap.cxx | 24 +----------------------- 1 file changed, 1 insertion(+), 23 deletions(-)
New commits: commit 12a49fb66a8d3380b9a57ec1c252c2981f1724b1 Author: Michael Stahl <mst...@redhat.com> Date: Thu Jul 10 17:59:28 2014 +0200 fdo#80498: vcl: Revert "fdo#74124: Scale the pictures before calling ... ... ImplDrawAlpha()." This reverts commit 3cf3700b7a903e88f5296076c40ae854bce91cdc. It may look nicer but is unusably slow when scrolling in Writer. Conflicts: vcl/source/gdi/outdev2.cxx Change-Id: I582f3f02a2f8915c244b04b2fe95b6af926396b9 (cherry picked from commit ee36fc7add892690c95a969530ecdcfc1bc9decc) Reviewed-on: https://gerrit.libreoffice.org/10204 Reviewed-by: Michael Meeks <michael.me...@collabora.com> Tested-by: Michael Meeks <michael.me...@collabora.com> diff --git a/vcl/source/outdev/bitmap.cxx b/vcl/source/outdev/bitmap.cxx index 78302b3..56c5033 100644 --- a/vcl/source/outdev/bitmap.cxx +++ b/vcl/source/outdev/bitmap.cxx @@ -492,29 +492,7 @@ void OutputDevice::DrawDeviceBitmap( const Point& rDestPt, const Size& rDestSize { if (rBitmapEx.IsAlpha()) { - Size aDestSizePixel(LogicToPixel(rDestSize)); - - BitmapEx aScaledBitmapEx(rBitmapEx); - Point aSrcPtPixel(rSrcPtPixel); - Size aSrcSizePixel(rSrcSizePixel); - - // we have beautiful scaling algorithms, let's use them - if (aDestSizePixel != rSrcSizePixel && rSrcSizePixel.Width() != 0 && rSrcSizePixel.Height() != 0) - { - double fScaleX = std::abs(aDestSizePixel.Width() / double(rSrcSizePixel.Width())); - double fScaleY = std::abs(aDestSizePixel.Height() / double(rSrcSizePixel.Height())); - - aScaledBitmapEx.Scale(fScaleX, fScaleY); - - // Negative size values are used for mirroring, but Scale already takes - // care of mirroring so convert all negative values to positive. - aSrcSizePixel = Size(std::abs(aDestSizePixel.Width()), - std::abs(aDestSizePixel.Height())); - - aSrcPtPixel.X() = rSrcPtPixel.X() * fScaleX; - aSrcPtPixel.Y() = rSrcPtPixel.Y() * fScaleY; - } - DrawDeviceAlphaBitmap(aScaledBitmapEx.GetBitmap(), aScaledBitmapEx.GetAlpha(), rDestPt, rDestSize, aSrcPtPixel, aSrcSizePixel); + DrawDeviceAlphaBitmap(rBitmapEx.GetBitmap(), rBitmapEx.GetAlpha(), rDestPt, rDestSize, rSrcPtPixel, rSrcSizePixel); } else if (!!rBitmapEx) { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits